Differences

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

Link to this comparison view

Last revision Both sides next revision
all_macros [2009/08/31 16:05]
johnsoevans created
all_macros [2009/09/25 05:13]
ianmadsen
Line 535: Line 535:
                "​ %9.5f" = Get_From_String(Get(current_atom),​ u23);                "​ %9.5f" = Get_From_String(Get(current_atom),​ u23);
             }             }
-}</​code>​+}
  
 +macro INEL_FLAT_PLATE_V1(alpha,​ alpha_val, sd, sd_val)
 + ' Version by Ian Madsen 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
 +        ' ​  alpha = angle between incident beam and sample surface
 +        ' ​  ​2Theta = (alpha + beta)
 +        ' ​     where beta  = angle between diffracted beam(s) and sample surface
 + ​ ' ​  sd = sample displacement (in same units as detector radius)
 +        ' ​  Rs = 250mm for the Inel CPS120 detector
 +{
 +   local alpha alpha_val
 +   local sd sd_val
  
 +   ​scale_pks = If(2 Th <= alpha Deg , 0, 2.0 / (1 + Sin (alpha Deg)/Sin (2 * Th - alpha Deg)));
 +   ​th2_offset = -(Rad sd Sin (2 Th)) / (Rs Sin (alpha Deg));
 +}
 +</​code>​

Personal Tools