\(\renewcommand\AA{\unicode{x212B}}\)
Table of Contents
Name | Direction | Type | Default | Description |
---|---|---|---|---|
SampleWorkspace | Input | MatrixWorkspace | Mandatory | Name for the input sample workspace |
SampleChemicalFormula | Input | string | Sample chemical formula | |
SampleCoherentXSection | Input | number | 0 | The coherent cross-section for the sample material in barns. To be used instead of Chemical Formula. |
SampleIncoherentXSection | Input | number | 0 | The incoherent cross-section for the sample material in barns. To be used instead of Chemical Formula. |
SampleAttenuationXSection | Input | number | 0 | The absorption cross-section for the sample material in barns. To be used instead of Chemical Formula. |
SampleDensityType | Input | string | Mass Density | Use of Mass density or Number density for the sample. Allowed values: [‘Mass Density’, ‘Number Density’] |
SampleNumberDensityUnit | Input | string | Atoms | Choose which units SampleDensity refers to. Allowed values: [Atoms, Formula Units]. Allowed values: [‘Atoms’, ‘Formula Units’] |
SampleDensity | Input | number | 0.1 | The value for the sample Mass density (g/cm^3) or Number density (1/Angstrom^3). |
SampleThickness | Input | number | 0 | Sample thickness in cm |
SampleAngle | Input | number | 0 | Angle between incident beam and normal to flat plate surface |
CanWorkspace | Input | MatrixWorkspace | Name for the input container workspace | |
CanChemicalFormula | Input | string | Container chemical formula | |
CanCoherentXSection | Input | number | 0 | The coherent cross-section for the can material in barns. To be used instead of Chemical Formula. |
CanIncoherentXSection | Input | number | 0 | The incoherent cross-section for the can material in barns. To be used instead of Chemical Formula. |
CanAttenuationXSection | Input | number | 0 | The absorption cross-section for the can material in barns. To be used instead of Chemical Formula. |
CanDensityType | Input | string | Mass Density | Use of Mass density or Number density for the can. Allowed values: [‘Mass Density’, ‘Number Density’] |
CanNumberDensityUnit | Input | string | Atoms | Choose which units CanDensity refers to. Allowed values: [Atoms, Formula Units]. Allowed values: [‘Atoms’, ‘Formula Units’] |
CanDensity | Input | number | 0.1 | The value for the can Mass density (g/cm^3) or Number density (1/Angstrom^3). |
CanFrontThickness | Input | number | 0 | Container front thickness in cm |
CanBackThickness | Input | number | 0 | Container back thickness in cm |
NumberWavelengths | Input | number | 10 | Number of wavelengths for calculation |
Interpolate | Input | boolean | True | Interpolate the correction workspaces to match the sample workspace |
Emode | Input | string | Elastic | Energy transfer mode. Allowed values: [‘Elastic’, ‘Indirect’, ‘Direct’, ‘Efixed’] |
Efixed | Input | number | 0 | Analyser energy (mev). By default will be read from the instrument parameters. Specify manually to override. This is used only in Efixed energy transfer mode. |
OutputWorkspace | Output | WorkspaceGroup | Mandatory | The output corrections workspace group |
Calculates absorption corrections for an infinite flat plate sample giving output in the Paalman and Pings absorption factors: \(A_{s,s}\) (scattering and absorption in sample), \(A_{s,sc}\) (scattering in sample and absorption in sample and container), \(A_{c,sc}\) (scattering in container and absorption in sample and container) and \(A_{c,c}\) (scattering and absorption in container).
Details of the analytical method used to calculate the correction factors is available in RAL Technical Report 74-103.
Example:
# Create a sample workspace
sample = CreateSampleWorkspace(NumBanks=1, BankPixelWidth=1,
XUnit='Wavelength',
XMin=6.8, XMax=7.9,
BinWidth=0.1)
# Copy and scale it to make a can workspace
can = CloneWorkspace(InputWorkspace=sample)
can = Scale(InputWorkspace=can, Factor=1.2)
# Calculate absorption corrections
corr = FlatPlatePaalmanPingsCorrection(SampleWorkspace=sample,
SampleChemicalFormula='H2-O',
SampleThickness=0.1,
SampleAngle=45,
CanWorkspace=can,
CanChemicalFormula='V',
CanFrontThickness=0.01,
CanBackThickness=0.01,
Emode='Indirect',
Efixed=1.845)
print('Correction workspaces: %s' % (', '.join(corr.getNames())))
Output:
Correction workspaces: corr_ass, corr_assc, corr_acsc, corr_acc