Skip to content

DOC: constants: explain 0.0 uncertainty #14467

@davidhansen314

Description

@davidhansen314

The CODATA2018 website (https://physics.nist.gov/cuu/Constants/) sometimes rounds an "exact" physical constant. This may occur when a constant is derived from other exact constants. For example, Boltzmann constant in eV/K is rounded to 8.617 333 262... x 10-5 eV K-1, but the website lists it as "exact" because it is the ratio of two exact constants: Boltzmann constant / elementary charge.

In scipy/constants/codata.py, lines 1504 and 1516, the uncertainty is set equal to 0 if the quantity is "exact." This is appropriate for quantities like "elementary charge" (no rounding), but it is NOT appropriate for quantities like
"Boltzmann constant in eV/K" because this quantity has been rounded.

I'm not sure what the best solution is. The CODATA2018 website does not give the uncertainty for rounded values of "exact" constants, so the uncertainty is unknown. Perhaps the uncertainty values in codata.py should be set to reflect this. A better (but more difficult) solution to implement would be to define the derived constants relative to the more fundamental constants. For example, the "Boltzmann constant in eV/K" would be defined as "Boltzmann constant" / "elementary charge". Documentation for this second solution is probably more difficult compared to the current implementation of pointing to the CODATA website for all numerical values.

Metadata

Metadata

Assignees

No one assigned

    Labels

    DocumentationIssues related to the SciPy documentation. Also check https://github.com/scipy/scipy.orgscipy.constants

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions