Table of Contents
Name | Direction | Type | Default | Description |
---|---|---|---|---|
ReflectionsFile | Input | string | Name of [http://www.ill.eu/sites/fullprof/ Fullprof] .hkl file that contains the peaks. Allowed extensions: [‘.hkl’] | |
FullprofParameterFile | Input | string | Mandatory | Fullprof’s .irf file containing the peak parameters. Allowed extensions: [‘.irf’] |
GenerateBraggReflections | Input | boolean | False | Generate Bragg reflections other than reading a Fullprof .irf file. |
MaxHKL | Input | int list | 12,12,12 | Maximum reflection (HKL) to generate |
Bank | Input | number | 1 | Bank ID for output if there are more than one bank in .irf file. |
LatticeConstant | Input | number | Mandatory | Lattice constant for cubic crystal. |
InstrumentParameterWorkspace | Output | TableWorkspace | Mandatory | Name of Table Workspace Containing Peak Parameters From .irf File. |
BraggPeakParameterWorkspace | Output | TableWorkspace | Mandatory | Name of Table Workspace Containing Peaks’ Miller Indices From .prf File. |
This algorithm is to import Fullprof .irf file (peak parameters) and .hkl file (reflections) and record the information to TableWorkspaces, which serve as the inputs for algorithm LeBailFit.
Instrument parameter TableWorkspace contains all the peak profile parameters imported from Fullprof .irf file.
Presently these are the peak profiles supported
* Thermal neutron back to back exponential convoluted with pseudo-voigt (profile No. 10 in Fullprof)
Each row in TableWorkspace corresponds to one profile parameter.
Columns include Name, Value, FitOrTie, Min, Max and StepSize.
Each row of this workspace corresponds to one diffraction peak. The information contains the peak’s Miller index and (local) peak profile parameters of this peak. For instance of a back-to-back exponential convoluted with Gaussian peak, the peak profile parameters include Alpha, Beta, Sigma, centre and height.
This algorithm is designed to work with other algorithms to do Le Bail fit. The introduction can be found in the wiki page of Le Bail Fit.
Example - create inputs for LeBail fit of Pg3:
CreateLeBailFitInput(ReflectionsFile=r'LB4854b3.hkl',
FullprofParameterFile=r'2013A_HR60b3.irf',
Bank='3',
LatticeConstant='4.1568899999999998',
InstrumentParameterWorkspace='PG3_Bank3_ParTable',
BraggPeakParameterWorkspace='LaB6_HKL_Table')
# Examine
partablews = mtd["PG3_Bank3_ParTable"]
braggtablews = mtd["LaB6_HKL_Table"]
print "Number Bragg peaks from .hkl file is %d. Number of peak profile parameters is %d." % (braggtablews.rowCount(), partablews.rowCount())
Output:
GeneraateHKL? = False
Number Bragg peaks from .hkl file is 76. Number of peak profile parameters is 30.
Categories: Algorithms | Diffraction | Utility
Python: CreateLeBailFitInput.py