Skip to content

decay

Half-lives, decay constants, atomic masses and alpha branching.

decay

Half-lives, decay constants and atomic masses.

The vendored tables are ENDF/B-VIII.0 half-lives and AME2020 atomic masses, both regenerated by tools/build_decay_data.py and compiled into the extension. Nothing here reaches the network.

A depletion study's own chain file can be substituted with DecayData.from_chain_xml, which matters when reproducing numbers from a run exactly: recent OpenMC takes half-lives from the chain rather than from ENDF, and the two disagree for some nuclides.

Classes:

  • DecayData –

    Half-life and atomic mass lookups for a set of nuclides.

  • UnknownNuclideError –

    Raised when a nuclide is absent from the decay data tables.

Functions:

  • alpha_fraction –

    Fraction of decays proceeding by alpha emission, from the default tables.

  • atomic_mass –

    Relative atomic mass in u from the default tables.

  • decay_constant –

    Decay constant in 1/s from the default tables, zero if stable.

  • default_decay_data –

    Return the shared default tables.

  • half_life –

    Half-life in seconds from the default tables, None if stable.

  • is_radioactive –

    Whether the nuclide is radioactive according to the default tables.

Attributes:

  • AVOGADRO (float) –

    Convert a string or number to a floating-point number, if possible.

  • BECQUEREL_PER_CURIE (float) –

    Convert a string or number to a floating-point number, if possible.

AVOGADRO module-attribute

AVOGADRO: float = 6.02214076e+23

Convert a string or number to a floating-point number, if possible.

BECQUEREL_PER_CURIE module-attribute

BECQUEREL_PER_CURIE: float = 37000000000.0

Convert a string or number to a floating-point number, if possible.

DecayData

DecayData(half_lives: Mapping[str, float] | None = None, atomic_masses: Mapping[str, float] | None = None)

Half-life and atomic mass lookups for a set of nuclides.

Every lookup accepts any spelling normalise does. A nuclide in neither table raises UnknownNuclideError rather than being assumed stable.

Parameters:

  • half_lives

    (Mapping[str, float] | None, default: None ) –

    Half-lives in seconds keyed by nuclide name. A nuclide present in atomic_masses but absent here is stable. Defaults to the vendored ENDF/B-VIII.0 values.

  • atomic_masses

    (Mapping[str, float] | None, default: None ) –

    Relative atomic masses in u keyed by nuclide name. Defaults to the vendored AME2020 values.

Methods:

  • __new__ –

    Create and return a new object. See help(type) for accurate signature.

  • __repr__ –

    Return repr(self).

  • alpha_fraction –

    Fraction of this nuclide's decays that proceed by alpha emission.

  • atomic_mass –

    Return the relative atomic mass in u.

  • decay_constant –

    Return the decay constant in 1/s, zero for a stable nuclide.

  • from_chain_xml –

    Take half-lives from an OpenMC depletion chain file.

  • half_life –

    Return the half-life in seconds, or None if the nuclide is stable.

  • is_radioactive –

    Whether the nuclide has a tabulated half-life.

  • knows –

    Whether the tables cover this nuclide at all.

  • with_overrides –

    Return a copy with some half-lives replaced.

Attributes:

__doc__ class-attribute

__doc__ = 'Half-life and atomic mass lookups for a set of nuclides.\n\nEvery lookup accepts any spelling `normalise` does. A nuclide in neither\ntable raises `UnknownNuclideError` rather than being assumed stable.\n\nArgs:\n    half_lives: Half-lives in seconds keyed by nuclide name. A nuclide\n        present in ``atomic_masses`` but absent here is stable. Defaults to\n        the vendored ENDF/B-VIII.0 values.\n    atomic_masses: Relative atomic masses in u keyed by nuclide name.\n        Defaults to the vendored AME2020 values.'

str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str

Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'.

__module__ class-attribute

__module__ = 'radiological_material_clearance_finder._core'

str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str

Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'.

__new__ builtin

__new__(*args, **kwargs)

Create and return a new object. See help(type) for accurate signature.

__repr__ method descriptor

__repr__()

Return repr(self).

alpha_fraction method descriptor

alpha_fraction(name: str) -> float

Fraction of this nuclide's decays that proceed by alpha emission.

Returns 0.0 for a nuclide with no alpha branch, which includes every metastable state. Bi-212, which branches 35.94 percent alpha, returns 0.3594.

atomic_mass method descriptor

atomic_mass(name: str) -> float

Return the relative atomic mass in u.

A metastable state with no tabulated mass takes its ground state's, which is accurate to better than 1e-5.

Raises:

  • UnknownNuclideError –

    If neither the nuclide nor its ground state has a tabulated mass, since a guess would corrupt the mass of the whole material.

decay_constant method descriptor

decay_constant(name: str) -> float

Return the decay constant in 1/s, zero for a stable nuclide.

from_chain_xml staticmethod

from_chain_xml(path: str | PathLike[str]) -> DecayData

Take half-lives from an OpenMC depletion chain file.

Parsed without OpenMC. Nuclides absent from the chain fall back to the vendored ENDF values, matching how OpenMC resolves a chain against its own data. A chain entry with no half_life marks the nuclide stable.

Parameters:

Returns:

  • DecayData –

    A DecayData using the chain's half-lives.

Raises:

  • ValueError –

    If the file is not a readable chain, or a half-life is not a positive finite number.

half_life method descriptor

half_life(name: str) -> float | None

Return the half-life in seconds, or None if the nuclide is stable.

Raises:

  • UnknownNuclideError –

    If the nuclide is in neither table, so "stable" would be a guess rather than a fact.

is_radioactive method descriptor

is_radioactive(name: str) -> bool

Whether the nuclide has a tabulated half-life.

knows method descriptor

knows(name: str) -> bool

Whether the tables cover this nuclide at all.

with_overrides method descriptor

with_overrides(half_lives: Mapping[str, float | None]) -> DecayData

Return a copy with some half-lives replaced.

Parameters:

  • half_lives
    (Mapping[str, float | None]) –

    Half-lives in seconds, keyed by any accepted nuclide spelling. A value of None marks a nuclide stable.

UnknownNuclideError

Bases: builtins.KeyError

Raised when a nuclide is absent from the decay data tables.

The canonical nuclide name is available as the name attribute.

Attributes:

__doc__ class-attribute

__doc__ = 'Raised when a nuclide is absent from the decay data tables.\n\nThe canonical nuclide name is available as the ``name`` attribute.'

str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str

Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'.

__module__ class-attribute

__module__ = 'radiological_material_clearance_finder._core'

str(object='') -> str str(bytes_or_buffer[, encoding[, errors]]) -> str

Create a new string object from the given object. If encoding or errors is specified, then the object must expose a data buffer that will be decoded using the given encoding and error handler. Otherwise, returns the result of object.str() (if defined) or repr(object). encoding defaults to sys.getdefaultencoding(). errors defaults to 'strict'.

__weakref__ property

__weakref__

list of weak references to the object

alpha_fraction builtin

alpha_fraction(name: str) -> float

Fraction of decays proceeding by alpha emission, from the default tables.

atomic_mass builtin

atomic_mass(name: str) -> float

Relative atomic mass in u from the default tables.

decay_constant builtin

decay_constant(name: str) -> float

Decay constant in 1/s from the default tables, zero if stable.

default_decay_data builtin

default_decay_data() -> DecayData

Return the shared default tables.

half_life builtin

half_life(name: str) -> float | None

Half-life in seconds from the default tables, None if stable.

is_radioactive builtin

is_radioactive(name: str) -> bool

Whether the nuclide is radioactive according to the default tables.