Warning: Trying to access array offset on value of type null in /home/site/wwwroot/lib/plugins/move/action/rename.php on line 42

Warning: Cannot modify header information - headers already sent by (output started at /home/site/wwwroot/lib/plugins/move/action/rename.php:42) in /home/site/wwwroot/inc/actions.php on line 38
inel_flat_plate_v2 [topas wiki]

User Tools

Site Tools


inel_flat_plate_v2

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
inel_flat_plate_v2 [2009/09/25 04:41] – created ianmadseninel_flat_plate_v2 [2022/11/03 15:08] (current) – external edit 127.0.0.1
Line 1: Line 1:
 +====== Inel Flat Plate Correction ======
  
 +
 +<code topas>
 +macro Inel_Flat_Plate_V2(alpha, alpha_v, sd, sd_v)
 + ' Version by Matthew Rowles CSIRO Minerals
 + ' Equations for correction of intensity and sample displacement for flat plate samples
 + ' in fixed incident beam geometry e.g. when using the Inel CPS120 position sensitive detector
 + ' Intensity correction derived from Toraya et al. (1993)
 + ' Sample displacement model derived by Ian Madsen
 + ' 2Theta = (alpha + beta)
 +  where beta  = angle between diffracted beam(s) and sample surface
 + ' Rs = 250mm for the Inel CPS120 detector - Rs must be defined in the input file
 +{
 +   #m_argu alpha    ' alpha = angle between incident beam and sample surface
 +   #m_argu sd       ' sd = displacement of the sample (in same units as detector radius)
 + If_Prm_Eqn_Rpt(alpha, alpha_v, min 0.0001 max 90)
 +   If_Prm_Eqn_Rpt(sd, sd_v, min -1 max 1)
 +
 + scale_pks = 
 + IF (2 Th) < CeV(alpha, alpha_v) Deg THEN 
 + 0                                 
 + ELSE
 + 2 / (1 + (Sin(CeV(alpha, alpha_v) Deg) / Sin(2 Th - CeV(alpha, alpha_v) Deg)))
 + ENDIF;
 +
 + th2_offset = 
 + IF CeV(sd, sd_v) == 0 THEN 
 + 0
 + ELSE
 + - Rad (CeV(sd, sd_v) Sin(2 Th)) / (Rs Sin(CeV(alpha, alpha_v) Deg))
 + ENDIF;
 +}
 +</code>