spectra = sw_tofres(spectra,Name,Value)
spectra = sw_tofres(spectra,Name,Value) simulates the finite bin size
of the cuts of direct TOF neutron scattering data. It calculates the
spectrum at multiple points within the given bin volume and sums them up.
The function is usefull if relatively large bins were used to analyse the
data due to low signal to noise ratio of the measurement.
- Input structure, contains calculated correlation functions withouth the resolution effect.
Name-Value Pair Arguments
- String that determines the method to generate the points, options:
'random'The bin volume will be randomly sampled.
'grid'The bin volume will be split up to a finer regular grid.
- Row vector with 3 elements. The width of the bin
along the three reciprocal lattice directions. The spectrum
will be integrated in the range. Default value is
[0.1 0.1 0.1].
- Row vector with 3 elements when
gridand gives the number of points along the three reciprocal lattice directions to average over. When
randomit is a scalar that determines the number of random points.
- Defines whether to provide text output. The default value is determined
fidpreference stored in swpref. The possible values are:
0No text output is generated.
1Text output in the MATLAB Command Window.
fidFile ID provided by the
fopencommand, the output is written into the opened file stream.
- Determines if the elapsed and required time for the calculation is
displayed. The default value is determined by the
tidpreference stored in swpref. The following values are allowed (for more details see sw_timeit):
0No timing is executed.
1Display the timing in the Command Window.
2Show the timing in a separat pup-up window.
- Same as the input except that it contains the calculated intensity in