Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhance internal standard and add external standard quantification #12

Closed
rowlesmr opened this issue Sep 15, 2022 · 8 comments · Fixed by #46 or #89
Closed

Enhance internal standard and add external standard quantification #12

rowlesmr opened this issue Sep 15, 2022 · 8 comments · Fixed by #46 or #89
Labels
enhancement New feature or request

Comments

@rowlesmr
Copy link
Collaborator

rowlesmr commented Sep 15, 2022

Hi all

Some ideas on reporting quantitative phases analysis from the internal and external standard approaches.

.

For quantitative phase analysis (QPA), there are two predominant whole-pattern approaches utilising crystal structures: internal and external standard.

Other methods include RIR, DDM, and single peak methods, but these won't be considered further.

Current data names for QPA consist of _pd_phase.mass_percent, _pd_calib.std_internal_mass_percent, and _pd_calib.std_internal_name. Other data names currently being added to the dictionary which are of relevance are _pd_char.mass_atten_coef_mu_calc and _pd_char.mass_atten_coef_mu_obs

Internal standard

The most applied quantification methodology uses the Rietveld approach and Hill & Howard algorithm.

In this method, the relative mass fraction of a phase is given as

$$ w^{\mathrm{rel}}_a=\frac{(sMV)_a}{\sum_k (sMV)_k}$$

where $s$ is the Rietveld scale factor, $M$ is the mass of the unit cell, and $V$ is the volume of the unit cell. The sum in the denominator is made over all phases present in the specimen, including $a$.

This approach gives relative mass fractions, as the values are normalised to 100%. If the absolute mass fractions are needed, then an internal standard can be used.

A known amount of a crystalline phase, which doesn't exist in the sample, is added and mixed well. In the analysis procedure, the absolute mass fractions are given as

$$ w^{\mathrm{abs}}_a = w^{\mathrm{rel}}_a \frac{ w^{\mathrm{known}}_s }{ w^{\mathrm{rel}}_s}$$

where the relative mass fractions are corrected by the ratio of the known addition of internal standard, and the calculated relative mass fraction of the internal standard.

The data names, and some definitions, currently in the powder dictionary are just not enough to capture all of the required information. Two additional data names are proposed:

  • _pd_calib.std_internal_block_id : to link to the block id of the structure used to model the internal std.
  • _pd_phase.scale_factor : to record the Rietveld scale factor of that phase used in modelling a diffraction pattern.

The definition of _pd_phase.mass_percent should be expanded to add:

"If _pd_calib.std_internal_mass_percent is present, the values given are assumed to be in absolute terms. The mass percent given to the internal standard represent the total crystalline contribution of that standard.". This will remove any ambiguity as to which type of mass percentages they are. It also allows for the use of standards which are not 100% crystalline.

The definition of _pd_calib.std_internal_mass_percent is incorrect, and also needs expansion:

"Per cent amount of the internal standard specified by the data item _pd_calib.std_internal_name. The value is expressed as 100 times the mass of standard added divided by the sum of the mass of standard added and the original sample mass. This value does not take into account the crystallinity of the internal standard."

eg add 1 g std to 2 g sample = 33% std in the final specimen. It doesn't matter if the standard is only 90% crystalline. The answer (in this case) is always 33%.

The enumeration of the difference between the total mass added of internal standard and the crystalline mass of internal std added is necessary for the calculation of mass fractions in the original sample, before the std was added.

An example CIF file would look like this:

data_theStd
_pd_block.id std
_pd_block_diffractogram.id diffpat
#crystal structure information

data_thePyritePhase
_pd_block.id pyrite
_pd_block_diffractogram.id diffpat
#crystal structure information

data_theAlbitePhase
_pd_block.id albite
_pd_block_diffractogram.id diffpat
#crystal structure information

data_aDiffractionPattern
_pd_block.id diffpat

loop_
_pd_phase.id
_pd_phase.block_id
_pd_phase.scale_factor #the scale factors don't make sense, I didn't want to calculate them
_pd_phase.mass_percent
1	std	0.000124	33.006
2	pyrite	0.000123	10.54(12)  
3	albite	0.000123	40.75(12)

_pd_calib.std_internal_mass_percent	33.333  #ie the internal std is 99.02% crystalline
_pd_calib.std_internal_name		"NIST SRM676a Al2O3"
_pd_calib.std_block_id			std

loop_
_pd_meas.2theta_scan
_pd_meas.counts_total
_pd_calc.intensity_net
5.00	1231	1024.212
5.10	1254	1024.212
#...

External standard

Just after the publication of the Hill & Howard algorithm, O'Connor and Raven published their external standard approach to quantification. This method is superior, as it inherently gives absolute quantification, rather than relative.

In this method, the mass fraction of a given phases is given by

$$ w^\mathrm{abs}_a = \frac{(sMV)a \mu{\mathrm{specimen}}^* } {K} $$

where $\mu_{\mathrm{specimen}}^*$ is the mass absorption coefficient of the entire specimen, and $K$ is a diffractometer constant. $\mu_{\mathrm{specimen}}^*$ can be measured, calculated from elemental analysis, or calculated from a Rietveld analysis (which assumes that the amorphous and crystalline fractions are of the same composition, and that the composition of the crystal structures used match those of the actual crystals in the specimen). $K$ must be measured from a well-characterised standard material using exactly the same instrument conditions as the unknown specimen. It is particular concern that beam intensity is consistent.

Two new data names are proposed:

_pd_calib_std.external_k_factor : this is used to record the K factor used in the analysis of a diffraction pattern.
_pd_calib_std.k_factor : this is used to report the K factor calculated from a standard pattern.

An example CIF file would look like this:

data_theStd
_pd_block.id std
_pd_block_diffractogram.id stdDiffPatt
#crystal structure information


data_theStandardDiffractionPattern
_pd_block.id stdDiffPatt

loop_
_pd_phase.id
_pd_phase.block_id
_pd_phase.scale_factor 
_pd_phase.mass_percent
1	std	0.000124	99.02

_pd_calib_std.k_factor		456.789
_pd_char.mass_atten_coef_mu_calc	123
_pd_char.special_details
;mass_atten_coef calculated from crystal structure
assuming 100% density
;

loop_
_pd_meas.2theta_scan
_pd_meas.counts_total
_pd_calc.intensity_net
5.00	4521	4524.212
5.10	4624	4524.212
#...


data_thePyritePhase
_pd_block.id pyrite
_pd_block_diffractogram.id diffpat
#crystal structure information


data_theAlbitePhase
_pd_block.id albite
_pd_block_diffractogram.id diffpat
#crystal structure information


data_aDiffractionPattern
_pd_block.id diffpat

loop_
_pd_phase.id
_pd_phase.block_id
_pd_phase.scale_factor 
_pd_phase.mass_percent
1	pyrite	0.000123	10.54(12)  
2	albite	0.000123	40.75(12)

_pd_calib_std.external_name		"NIST SRM676a Al2O3"
_pd_calib_std.external_block_id		std
_pd_calib_std.external_k_factor		456.789
_pd_char.mass_atten_coef_mu_calc	157
_pd_char.special_details
;the specimen mass_atten_coef calculated from elemental
analysis by XRF.
;

loop_
_pd_meas.2theta_scan
_pd_meas.counts_total
_pd_calc.intensity_net
5.00	1231	1024.212
5.10	1254	1024.212
#...

@jamesrhester
Copy link
Contributor

Note relationship to #11

@jamesrhester jamesrhester added the enhancement New feature or request label Sep 16, 2022
@rowlesmr
Copy link
Collaborator Author

With the external standard, I don't know if the K factor should only appear in the diffraction pattern of the standard, and you get the value by following the links, or if it should be in both. When I set up refinements in TOPAS, I calc it once in the std, and reference that value in all the unknowns; I don't copy/past the value.

@rowlesmr
Copy link
Collaborator Author

Maybe it could be considered to be a _pd_instr.-type value?

@rowlesmr
Copy link
Collaborator Author

rowlesmr commented Oct 3, 2022

Internal standard

New data names:

  • _pd_calib.std_internal_block_id
    • to link to the block id of the structure used to model the internal std.
  • _pd_phase.scale_factor
    • to record the Rietveld scale factor of that phase used in modelling a diffraction pattern. This needs to be loopable to record values for every phase in a diffractogram. It is a PD_PROC_LS-type of thing, but that category isn't loopable.

Ammended descriptions of existing data names:

  • _pd_phase.mass_percent
    • This to be added to the definition:
      • "If _pd_calib.std_internal_mass_percent is present, the values given are assumed to be in absolute terms. The mass percent given to the internal standard represent the total crystalline contribution of that standard.".
    • This will remove any ambiguity as to which type of mass percentages they are. It also allows for the use of standards which are not 100% crystalline.
  • _pd_calib.std_internal_mass_percent
    • This existing description is incorrect, and should probably be:
      • "Per cent amount of the internal standard specified by the data item _pd_calib.std_internal_name. The value is expressed as 100 times the mass of standard added divided by the sum of the mass of standard added and the original sample mass. This value does not take into account the crystallinity of the internal standard."

External standard

New data names:

  • _pd_calib_std.external_k_factor
    • this is used to record the K factor used in the analysis of a diffraction pattern.
  • _pd_calib_std.k_factor
    • this is used to report the K factor calculated from a standard diffractogram, in that standard diffractogram..
  • _pd_calib_std.special_details
    • To record details of the calibration procedure if the actual data used to calculate K are not present in the CIF.

@briantoby
Copy link
Collaborator

briantoby commented Oct 12, 2022 via email

@rowlesmr
Copy link
Collaborator Author

This was the sort of thing that I was reluctant to put in without a formal definition, since I am certain that the value is not transferable between codes.

Yes, you're right. And potentially even not transferable between different versions of different input files, as it all depends on how you scale data. eg do you include the constant in the denominator of Lp?

scratch that thought for the moment.

@rowlesmr
Copy link
Collaborator Author

rowlesmr commented Dec 1, 2022

I'm confused by the description of _pd_calib_std.external_block_id:

Identifies the _pd_block.id used as an external standard for the
diffraction angle or the intensity calibrations.

Is this refering to a block containing a histogram or a phase?

@briantoby
Copy link
Collaborator

I would have envisioned a standard as being a single phase material so this would point to a block that could contain a dataset with phase as refinement information. I guess for something more complex, the block could summarize the calibration process where there could be links to other blocks.

@rowlesmr rowlesmr linked a pull request Jan 6, 2023 that will close this issue
@rowlesmr rowlesmr linked a pull request Feb 2, 2023 that will close this issue
@rowlesmr rowlesmr closed this as completed Feb 2, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
3 participants