Home > Scripts > Treatment > Sqw > Sqw_Sab.m

iFit/Sqw_Sab

PURPOSE ^

Sqw = Sqw_Sab(Sqw, M, T)

SYNOPSIS ^

function Sab = Sqw_Sab(s, M, T)

DESCRIPTION ^

 Sqw = Sqw_Sab(Sqw, M, T)
  Sqw_Sab: convert an S(alpha,beta) into a 2D S(q,w). 

  The S(alpha,beta) is a representation of the dynamic structure factor 
  using unitless momentum and energy variables defined as:
     alpha= h2q2/2MkT  = (Ei+Ef-2*mu*sqrt(Ei*Ef))/AkT
     beta = -hw/kT     = (Ef-Ei)/kT
     A    = M/m
     mu   = cos(theta) = (Ki.^2 + Kf.^2 - q.^2) ./ (2*Ki.*Kf)
  
 input:
   s:  S(alpha,beta) data set e.g. 2D data set with alpha as 1st axis (rows), beta as 2nd axis.
   M:  molar weight of the atom/molecule in [g/mol].
     when omitted or empty, it is searched as 'weight' or 'mass' is the object.
   T: when given, Temperature to use. When not given or empty, the Temperature
      is searched in the object. The temperature is in [K]. 1 meV=11.605 K.
 output:
   Sqw: S(q,w) 2D data set, classical/symmetric (iData)

 conventions:
 w = omega = Ei-Ef = energy lost by the neutron [meV]
    omega > 0, neutron looses energy, can not be higher than Ei (Stokes)
    omega < 0, neutron gains energy, anti-Stokes

 references: M. Mattes and J. Keinert, IAEA INDC(NDS)-0470, 2005.
             R. E. MacFarlane, LA-12639-MS (ENDF-356), 1994.

 Example: Sqw = iData( fullfile(ifitpath,'Data','SQW_coh_lGe.nc') );
          Sab = Sqw_Sab(Sqw,72.6,300);
          plot(log(Sab)

 (c) E.Farhi, ILL. License: EUPL.

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:
Generated on Tue 22-Aug-2017 11:03:30 by m2html © 2005. iFit (c) E.Farhi/ILL EUPL 1.1