TDS intensity distribution in 3D reciprocal space:ΒΆ
The script make_TDS_intensityVolume calculates 3D distribution of TDS intensities for xrays and neutrons. It can calculate partial and weighted densities of states, but this should be preferably done with make_TDS_IntensityVolumeOnlyHisto. It requires that you have previously done the following operations:
 symmetrisation
 Fourier transform
 Debye waller calculation for the temperature of choice
The usage is
make_TDS_IntensityVolume castep_filename input_filenamethe file castep_filename can be either the name of the original castep output or the associated hdf5 file. In any case the associated hdf5 file must exist already (make_TDS_Simmetrization must be run beforehand)
The input_file must set the variables :
Mandatories
 APPLYTIMEREVERSAL
 subN1
 subN2
 subN3
 N1
 N2
 N3
 Nfour_interp
 Temperature
If NEUTRONCALC==0 ( default )
 Lambda
If NEUTRONCALC==1
 CohB
 NeutronE
If do_histogram==1
Nbins
xvdos
DOQLIMITS
 QMIN=0
 QMAX=0
 The following block of three parameters are eithe all None (default), or outputname must be set together with
one of branchWeight and energyWindow
 outputname
 branchWeight
 energyWindow
set RemoveBose=1 if you want to remove Bose statistics factors
Output files
The calculated intensities are written to a .ccp and .h5 file for visualization with chimera and pymca respectively. Density of states are written to histogram.h5, use pymca to open
The input variables are documented with docstrings below

make_TDS_IntensityVolume.
APPLYTIMEREVERSAL
= 1 this is one by default. Must be coherent with previous steps

make_TDS_IntensityVolume.
subN1
= 20 Subdivision, in the elementary brillouin zone, along the Z dimension of the reconstructed volume, which is parallel to the first axis of the brilloin zone.

make_TDS_IntensityVolume.
subN2
= 20 Subdivision, in the elementary brillouin zone, along the Y dimension of the reconstructed volume, which is parallel to the second axis of the brilloin zone.

make_TDS_IntensityVolume.
subN3
= 20 Subdivision, in the elementary brillouin zone, along the X dimension of the reconstructed volume, which is parallel to the third axis of the brilloin zone.

make_TDS_IntensityVolume.
N1
= 4 Besides being subdivised, the Brillouin zone, is replicated alonx the first axis for N1 up to N11 included. In reciprocal cell vector units. N1 can be either an integer or a pair of integer. In the latter case the first element is the starting shift, the second is the ending shift+1.

make_TDS_IntensityVolume.
N2
= 4 same thing as N1 but along the second reciprocal cell vector

make_TDS_IntensityVolume.
N3
= 4 same thing as N1 but along the third reciprocal cell vector

make_TDS_IntensityVolume.
Nfour_interp
= 4 The number of points in each direction of the 3D reciprocal grid. The hdf5 file must contain a previous pretreatement done with the same parameter.

make_TDS_IntensityVolume.
Temperature
= 100  The hdf5 file must include DW factors calculated ALSO at this temperature.
 The temperature at which DW factors have been calculated.
 Units are Kelvin

make_TDS_IntensityVolume.
Lambda
= 0.2 For Xray scattering : the wavelenght in Angstroems.

make_TDS_IntensityVolume.
NEUTRONCALC
= 0 This activate neutron scattering calculations.

make_TDS_IntensityVolume.
CohB
= None When neutroncalc is on, this must be a dictionary : for each atom name the Coherent lenght.

make_TDS_IntensityVolume.
NeutronE
= 0 When neutroncalc is on, the neutron energy in meV

make_TDS_IntensityVolume.
do_histogram
= 0 this variable activsates the histogram calculations

make_TDS_IntensityVolume.
Nbins
= 0 Numer of bins in the histogram

make_TDS_IntensityVolume.
xvdos
= 0  when this option is on, the DOS is calculated with a weight given by scattering factors, structure factor, DW etc. etc.
 almost the same as the one used for scattering but without bose statistics.

make_TDS_IntensityVolume.
DOQLIMITS
= 0 If on : when calculating xvdos only contributions from q points having modulus inside a given window are considered.

make_TDS_IntensityVolume.
QMIN
= 0 the minimum Q modulus for the DOQLIMITS=1 window

make_TDS_IntensityVolume.
QMAX
= 0 the maximum Q modulus for the DOQLIMITS=1 window

make_TDS_IntensityVolume.
outputname
= None a name to design the output file with data from calculation considering branchWeight or energyWindow

make_TDS_IntensityVolume.
branchWeight
= None a list of weights : one per branch.

make_TDS_IntensityVolume.
energyWindow
= None a list of two numbers : minimum and maximum in meV

make_TDS_IntensityVolume.
RemoveBose
= 0 RemoveBose=1 desactivates the Bose statistics.