iData_Sqw2D [from iData]
  iData_Sqw2D: create a 2D S(q,w) data set (iData flavour)
  The iData_Sqw2D class is a 2D data set holding a S(q,w) dynamic structure factor
    aka scattering function/law.
    The first  axis (rows)    is the Energy   transfer [meV].
    The second axis (columns) is the Momentum transfer [Angs-1] (wavevector). 
  This quantity usually derives from the double differential neutron cross section
     d2 sigma 
    ---------   = N kf/ki [ sigma /4pi S(q,w)]
    dOMEGA dEf
  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
  Example: s=iData_Sqw2D('')
  Useful methods for this iData flavour:
    all iData methods can be used.
    convert input [e.g. a 2D iData object] into an iData_Sqw2D to give access to
    the methods below.
  Sqw = ddcs2Sqw(s)
    convert a double differential neutron scattering cross section to a S(q,w) [Kf/Ki]
  ddcs = Sqw2ddcs(s)
    convert a S(q,w) to a double differential neutron scattering cross section [Kf/Ki]
  spw = qw2phiw(s, lambda)
    Convert a S(q,w) into a S(phi,w) iData (scattering angle)
  sqt = qw2qt(s, lambda)
    Compute S(q,tof) from S(q,w) for given wavelength [Angs]
  [spt,spc] = qw2phi(s, lambda)
    Compute S(phi,tof) from S(q,w) for given wavelength [Angs]. 
    Also return the S(phi,channel) as 2nd arg.
  sab = Sab(s, M, T)
    Compute S(alpha,beta) [iData_Sab] from S(q,w) for given mass and temperature
  d   = dos(s)
    Compute the vibrational density of states.
  t   = thermochemistry(s)
    Compute and display thermochemistry quantities from the density of states.
  m   = moments(s)
    Compute the S(q,w) moments/sum rules (harmonic frequencies).
  sym = symmetrize(s)
    Extend the S(|q|,w) in both energy sides.
  sb  = Bosify(s)
    Apply the 'Bose' factor (detailed balance) to a classical data set.
  s   = deBosify(sb)
    Remove Bose factor (detailed balance) from an 'experimental/quantum' data set.
  p   = parseparams(s)
    Search for physical quantities in S(q,w) data set.
  sab = Sab(s)
    Convert to an S(alpha,beta) [iData_Sab] suitable for nuclear data bases (ENDF, etc).
  xs  = scattering_cross_section(s)
    Compute the total integrated scattering cross section
  dr  = dynamic_range(s, Ei, angles)
    Compute the dynamic range restricted to given incident energy and detector angles
  sq  = structure_factor(s)
    Compute the structure factor S(q)
  [inc, multi] = incoherent(s, q, T, m, n)
    Compute an estimate of the incoherent neutron scattering law in the gaussian approximation (Sjolander)
  [coh] = coherent(inc, sq)
    Compute an estimate of the coherent S(q,w) from an incoherent S(q,w) and a structure factor (Skold)
  [gDOS,M]     = iData_Sab(s)
    Compute the integrated multi-phonon DOS terms from an initial density of states (Sjolander)
  saveas(s, filename, 'McStas'|'Sqw'|'inx'|'spe')
    Save the S(q,w) as a McStas Sqw, INX or ISIS SPE file format
sqw2d = iData_Sqw2D(s)
input: s: can be a 2D iData or filename to generate a 2D Sqw object. output: an iData_Sqw2D object
See also
Class Details
Superclasses iData
Sealed false
Construct on load false
Constructor Summary
iData_Sqw2D : create the iData_Sqw2D subclass 
Property Summary
Alias Holds all defined aliases 
Command Matlab commands/history of the object 
Creator Creator (program) name 
Data Data storage area 
Date Creation Date 
DisplayName User name for handling data set as a variable and legends 
Label User label (color, tag, ...) 
ModificationDate Modification Date 
Source Origin of data (filename/path) 
Tag Unique ID 
Title Data title 
User User ID 
UserData User data storage area 
class Class of the object, e.g iData or other derived class 
Method Summary
  Bosify iData_Sqw2D: Bosify: apply the 'Bose' factor (detailed balance) to a classical data set. 
  Sab iData_Sqw2D: Sab: convert a 2D S(q,w) into an S(alpha,beta).  
  Sqw2ddcs iData_Sqw2D: Sqw2ddcs: convert a S(q,w) into a double differential cross-section (q,w) 
  abs b = abs(s) : absolute value of iData object 
  acos b = acos(s) : computes the arc cosine of iData object 
  acosh b = acosh(s) : computes the inverse hyperbolic cosine of iData object 
  asin b = asin(s) : computes the arc sine of iData object 
  asinh b = asinh(s) : computes the inverse hyperbolic sine of iData object 
  atan b = atan(s) : computes the arc tangent of iData object 
  atanh b = atanh(s) : computes the inverse hyperbolic tangent of iData object 
  avifile f = avifile(s, filename, options) : save iData object into a movie 
  camproj s = camproj(a,dim) : projection/radial integration of iData objects elements 
  cart2sph s = cart2sph(a,dim) : cartesian to polar/spherical representation of iData objects 
  cat s = cat(dim,a,...) : catenate iData objects elements along dimension 
  caxis c = caxis(s, h) : Use the 2D/3D data as the colormap (CData property) in current object. 
  ceil b = ceil(s) : upper integer round of iData object 
  cell [content,fields]=cell(s) : convert iData objects into cells 
  char c = char(s) : convert iData into character 
  circshift b=circshift(a, rank, shift): shifts the axis of specified rank by a value 
  clabel b = clabel(s,label) : Change iData C axis label 
  clim b = clim(s,[ cmin cmax ]) : Reduce iData C axis limits 
  coherent iData_Sqw2D: coherent: compute the coherent scattering cross section from the incoherent and structure factor, in the Skold approximation 
  colon b = colon(s) : vector of arrays 
  colormap h=colormap(objects, colormaps, ..., options): Produce surfaces from iData 2D objects with different colormaps 
  combine c = combine(a,b) : combines iData objects 
  commandhistory (s) : show the command history of iData object 
  conj b = conj(s) : conjugate of iData object 
  contour h = contour(s,option) : Plot a 2D/3D object as contour 
  contour3 h = contour3(s,option) : Plot a 2D/3D object as 3D contour 
  contourf h = contourf(s,option) : Plot a 2D/3D object as filled contour 
  conv c = conv(a,b) : computes the convolution of iData objects 
  convn c = convn(a,b) : computes the convolution of an iData object with a response function  
  copyobj b = copyobj(s) : makes a copy of iData object 
  corrcoef c = corrcoef(a,b) : correlation coefficient with an iData object 
  cos b = cos(s) : computes the cosine of iData object 
  cosh b = cosh(s) : computes the hyperbolic cosine of iData object 
  csvwrite f = csvwrite(s, filename, options) : save iData object into a Comma Separated Values (CSV) file 
  ctranspose b = ctranspose(s) : complex conjugate transpose of iData object 
  cumprod s = cumprod(a,dim) : computes the cumulative product of iData objects elements 
  cumsum s = cumsum(a,dim) : computes the cumulative sum of iData objects elements 
  cumtrapz s = cumtrapz(a,dim) : computes the cumulative product of iData objects elements 
  cwt b = cwt(s,dim,scales,wname,'wname',...) : Continuous wavelet transform 
  ddcs2Sqw iData_Sqw2D: ddcs2Sqw: convert a double differential cross-section (q,w) into a S(q,w) 
  deBosify iData_Sqw2D: deBosify: remove Bose factor (detailed balance) from an 'experimental/quantum' data set. 
  deconv c = deconv(a,b) : computes the deconvolution of iData objects 
  del2 b = del2(s) : computes the Discrete Laplacian of iData object 
  diff b = diff(s) : computes the difference long 1st axis of iData object 
  disp (s) : display iData object (details) 
  display d = display(s) : display iData object (from command line) 
  doc (iData): iData web page documentation 
  dog s= dog(dim,a) : split iData objects elements along dimension 
  dos iData_Sqw2D: dos: compute the generalised density of states (gDOS) from a S(q,w) 
  double d = double(s) : convert iData into doubles 
  dynamic_range iData_Sqw2D: dynamic_range: crop the S(|q|,w) to the available dynamic range 
  edit (s) : edit iData object Signal/Monitor 
  end b = end(s,index,n) : end value for iData objects 
  eq c = eq(a,b) : equal comparison of iData objects 
  event c = event(a) : build an event list  
  exp b = exp(s) : exponential value of iData object 
  fft c = fft(a) : computes the Discrete Fourier transform of iData objects 
  fileattrib [attribute, link] = fileattrib(s, field) : return a field Attribute 
  fill fill-in over missing data 
  find d = find(s) : find iData signal non zeros values 
  findfield [match, types, nelements]=findfield(iData, field, option) : look for iData fields 
  findobj [s,...]=findobj(s,...) : look for existing iData objects 
  findstr [match, field]=findstr(s, str, option) : look for strings stored in iData 
  fits [pars,criteria,message,output] = fits(a, model, pars, options, constraints, ...) : fit data set on a model 
  fliplr b = fliplr(s) : Flip object in left/right direction 
  flipud b = flipud(s) : Flip object in up/down direction 
  floor b = floor(s) : lower integer round of iData object 
  full b = full(s) : Convert iData object storage to full matrix 
  gdos iData_Sqw2D: gdos: compute the generalised density of states (gDOS) from a S(q,w) 
  ge c = ge(a,b) : greater-than-or-equal comparison of iData objects 
  get [...] = get(s, 'PropertyName', ...) : get iData object properties 
  getalias [link, label,names] = getalias(s, 'AliasName') : get iData alias 
  getaxis [val, lab] = getaxis(s, AxisIndex) : get iData axis value and label 
  getframe frame = getframe(s, dim, options) : create an iData object thumbnail/frame matrix 
  gradient g = gradient(a, dim) : computes the gradient (derivative) of iData objects 
  gt c = gt(a,b) : greater-than comparison of iData objects 
  help c = help(s) : display iData information as a Dialogue window 
  hist (a, axis1, axis2, ...) computes the accumulated histogram from event data sets 
  iData _Sqw2D: iData: convert a iData_Sqw2D back to iData 
  ifft c = ifft(a) : computes the inverse Discrete Fourier transform of iData objects 
  imag b = imag(s) : imaginary part of iData object 
  image h = image(r,g,b, option) : Plot up to 3 images overlayed on the RGB channels 
  imroi : define a region of interest on a data set 
  imwrite f = imwrite(s, filename, format) : save iData object into an image 
  incoherent iData_Sqw2D: incoherent: incoherent neutron scattering law estimate in the incoherent gaussian approximation 
  ind2sub (s,index) : get indexed element in an iData array 
  interp [b...] = interp(s, ...) : interpolate iData object 
  intersect [ai,bi] = intersect(a, b) : computes object intersection area and values 
  isempty (s) : true for empty iData object 
  isequal c = isequal(a,b) : full numerical equality comparison of iData objects 
  isfield b = isfield(s, field) : check existence of field/alias in iData objects 
  isfinite b = isfinite(s) : True for finite iData object elements 
  isfloat b = isfloat(s) : True for float iData object elements 
  isinf b = isinf(s) : True for infinite iData object elements 
  isinteger b = isinterger(s) : True for integer iData object elements 
  islogical b = islogical(s) : True for logical iData object elements 
  isnan b = isnan(s) : True for NaN iData object elements 
  isnumeric b = isnumeric(s) : True for numeric iData object elements 
  isreal b = isreal(s) : True for real iData object elements 
  isscalar b = isscalar(s) : True for scalar iData objects 
  issparse b = issparse(s) : True for sparse matrix iData object 
  isvector b = isvector(s) : True for vector iData object 
  jacobian [b, j] = jacobian(a, new_axes, 'new_axes_labels'...) : computes the gradient (derivative) of iData objects 
  kmeans [b,c] = kmeans(X, k) : k-means clustering of iData object 
  label b = label(s, alias, label) : Change iData label for a given alias/axis 
  ldivide c = ldivide(a,b) : fast notation for combine iData objects 
  le c = le(a,b) : lower-than-or-equal comparison of iData objects 
  linspace v = linspace(a,b,n) : creates a linearly spaced vector of objects 
  load d = load(s, file, loader, ...): iData file loader 
  log b = log(s) : natural logarithm value of iData object 
  log10 b = log10(s) : base 10 logarithm value of iData object 
  logical d = logical(s) : convert iData into logical array 
  logspace v = logspace(a,b,n) : creates a logarithmically spaced vector of objects 
  lt c = lt(a,b) : lower-than comparison of iData objects 
  max [m,id] = max(a,b, dim) : computes the maximum value of iData object(s) 
  mean b = mean(s, dim) : mean value of iData object 
  median b = median(s, dim) : median value of iData object 
  mesh h = mesh(s,option) : Plot a 2D/3D object as mesh 
  meshgrid s = meshgrid(a) : transforms an iData object so that its axes are grids 
  min [m,id] = min(a,b, dim) : computes the maximum value of iData object(s) 
  minus c = minus(a,b) : computes the difference of iData objects 
  mldivide c = mldivide(a,b) : a\b is fast notation for combine(a,b) 
  moments iData_Sqw2D: moments=moments(sqw, M, T, classical): compute Sqw moments/sum rules (harmonic frequencies) 
  mpower c = mpower(a,b) : computes the matrix-power of iData objects 
  mrdivide c = mrdivide(a,b) : computes the division of iData objects 
  mtimes c = mtimes(a,b) : computes the matrix product of iData objects 
  multi_phonons iData_Sqw2D: multi_phonons: compute the integrated multi-phonon intensity from a scattering law 
  muphocor run MUPHOCOR on the given S(q,w) data set, incident wavelength and Temperature 
  ndims d = ndims(s) : get the dimensionality of iData object 
  ne c = ne(a,b) : not-equal comparison of iData objects 
  norm b = norm(s) : norm-2 of iData object 
  not b = not(s) : computes the logical 'not' of iData object 
  ones s = ones(s,N,M,P,...) : initialize an iData array 
  pack b = pack(a) : compress iData storage to save memory 
  parseparams iData_Sqw2D: parseparams: search for physical quantities in object. 
  pca [b] = pca(X, k) : Principal component analysis of iData object(s) 
  pcolor h = pcolor(s,option) : Plot a 2D/3D object as a flat matrix image 
  peaks [half_width, center, amplitude, baseline] = peaks(s, dim, m) : peak position and width of iData 
  permute c = permute(a, order) : Permute object dimensions from iData objects/arrays 
  plot h = plot(s, method, ...) : plot iData object 
  plot3 h = plot3(s,option) : Plot a 2D/3D object as separate points or semi-transparent volume 
  plus c = plus(a,b) : computes the sum of iData objects 
  power c = power(a,b) : computes the power of iData objects 
  prod s = prod(a,dim) : computes the product of iData objects elements 
  publish b = publish(s) : export the Dataset object as an HTML document. 
  qw2phi iData_Sqw2D: qw2phi: convert a S(q,w) into S(phi,tof) iData (scattering angle,ToF) 
  qw2phiw iData_Sqw2D: qw2phiw: convert a S(q,w) into a S(phi,w) iData (scattering angle) 
  qw2qt iData_Sqw2D: qw2qt: convert a S(q,w) into a S(q,tof) iData (time-of-flight from sample) 
  rdivide c = rdivide(a,b) : computes the ratio of iData objects 
  real b = real(s) : real value of iData object 
  reducevolume h = reducevolume(s, factor) : reduce an iData object size 
  reshape c = reshape(a) : reshape the object Signal 
  resize c = resize(a) : resize/rebin the object Signal 
  rmalias s = rmalias(s, AliasName) : removes iData aliases 
  rmaxis s = rmaxis(s, Axis) : delete iData axes 
  rotate s = rotate(a, theta) : computes the rotation of iData objects around the origin 
  round b = round(s) : upper integer round of iData object 
  save f = save(s, filename, format, options) : save iData object into various data formats 
  saveas iData_Sqw2D: saveas: save S(q,w) into a file. 
  scatter h = scatter(s,option) : Plot a 2D/3D object as separate colored points 
  scatter3 h = scatter3(s,option) : Plot a 2D/3D object as separate colored points 
  scattering_cross_section iData_Sqw2D: scattering_cross_section: compute the total neutron scattering cross section for 
  set [s,...] = set(s, 'PropertyName', Propertyvalue, ...) : set iData properties 
  setalias [s,...] = setalias(s, AliasName, AliasLink, {AliasLabel}) : set iData aliases 
  setaxis s = setaxis(s, rank, alias, value) : set iData axes 
  sign b = sign(s) : sign of iData object 
  sin b = sin(s) : computes the sine of iData object 
  single d = single(s) : convert iData into single floats 
  sinh b = sinh(s) : computes the hyperbolic sine of iData object 
  size (s) : get iData object size (number of elements) 
  slice (s) : Plot a 2D/3D object with slice rendering 
  smooth Z = smooth(Y) : smooth iData objects 
  sort s = sort(a,dim) : Sort iData objects axes in ascending or descending order 
  sparse b = sparse(s) : Convert iData object storage to sparse 
  sqr c = sqr(a) : computes the square of iData objects 
  sqrt b = sqrt(s) : square root value of iData object 
  squeeze c = squeeze(a) : remove singleton dimensions from iData objects/arrays 
  std [half_width, center] = std(s, dim) : standard deviation of iData 
  strfind [match, field]=strfind(s, pattern, option) : search for pattern in iData 
  structure_factor iData_Sqw2D: structure_factor: compute the structure factor 
  subplot h = subplot(s) : plot iData array as subplots 
  subsasgn b = subsasgn(a,index,b) : iData indexed assignement 
  subsindex d = subsindex(s) : subscript index for iData objects 
  subsref b = subsref(a,s) : iData indexed references 
  sum s = sum(a,dim) : computes the sum of iData objects elements 
  surf h = surf(s,option) : Plot a 2D/3D object as surface 
  surfc h = surfc(s,option) : Plot a 2D/3D object as surface+contour 
  surfl h = surfl(s,option) : Plot a 2D/3D object as surface with light 
  symmetrize iData_Sqw2D: symmetrize(s): extend the S(|q|,w) in both energy sides 
  tan b = tan(s) : computes the tangent of iData object 
  tanh b = tanh(s) : computes the hyperbolic tangent of iData object 
  thermochemistry iData_Sqw2D/thermochemistry: compute thermodynamic quantities for 2D S(q,w) data sets. 
  times c = times(a,b) : computes the product of iData objects 
  title b = title(s,label) : Change iData Signal label 
  transpose b = transpose(s) : non-conjugate transpose of iData object 
  trapz s = trapz(a,dim) : computes the integral of iData objects elements along given dimension 
  uminus b = uminus(s) : opposite value of iData object 
  union [ai,bi] = union(a, b) : computes object union area and values 
  unique s = unique(a,dim) : set unique iData objects axes with no repetitions 
  uplus b = uplus(s) : makes a copy of iData object 
  vdos iData_Sqw2D: vdos: compute the 'true' vibrational density of states 
  version v = version(iData): iData class version 
  waterfall h = waterfall(s,option) : Plot a 2D/3D object as waterfall (side by side lines) 
  xcorr c = xcorr(a,b,shape) : computes the correlation of iData objects 
  xlabel b = xlabel(s,label) : Change iData X axis label 
  xlim b = xlim(s,[ xmin xmax ]) : Reduce iData X axis limits 
  xmlwrite f = xmlwrite(s, filename) : save iData object into an XML file 
  ylabel b = ylabel(s,label) : Change iData Y axis label 
  ylim b = ylim(s,[ ymin ymax ]) : Reduce iData Y axis limits 
  zeros s = zeros(s,N,M,P,...) : initialize an iData array 
  zlabel b = zlabel(s,label) : Change iData Z axis label 
  zlim b = zlim(s,[ zmin zmax ]) : Reduce iData Z axis limits