Element

class curie.Element(element)[source]

Elemental data and properties

The Element class provides useful data about the natural elements, such as mass, density, and isotopic composition. Additionally, it contains functions for determining the interaction of radiation with the natural elements. Principally it provides the mass-attenuation of photons, and the stopping power/ranges of charged particles.

Parameters:
elementstr

Symbol for the element, e.g. ‘H’, ‘In’, ‘Zn’, ‘Fe’. Case insensitive. Note that ‘n’ (“neutron”) is not considered a valid element in this context, and will be interpreted as ‘N’ (“nitrogen”).

Examples

>>> el = ci.Element('Fe')
>>> print(el.mass)
55.847
>>> print(el.density)
7.866
Attributes:
namestr

Symbol for the element, in title-case. E.g. if input was ‘fe’, name will be ‘Fe’.

Zint

Atomic number of the element.

massfloat

Molar mass of the natural element in atomic mass units (amu).

isotopeslist

List of isotopes with non-zero natural abundance.

abundancespd.DataFrame

Natural abundances, in percent, for all isotopes found in nature. Structure is a DataFrame with the columns ‘isotope’, ‘abundance’, and ‘unc_abundance’.

densityfloat

Density of the natural element in g/cm^3. The density is used in calculations of charged particle dEdx and photon attenuation, so you can assign a new density using el.density = new_density if needed, or using the density keyword in either of those functions.

mass_coeffpd.DataFrame

Table of mass-attenuation coefficients as a function of photon energy, from the NIST XCOM database. Energies are in keV, and mass-attenuation coefficients, or mu/rho, are given in cm^2/g. DataFrame columns are ‘energy’, ‘mu’ and ‘mu_en’ for the mass-energy absorption coefficient.

Methods

S(energy[, particle, density])

Charged particle stopping power in matter

attenuation(energy, x[, density])

Photon attenuation in matter

mu(energy)

Mass-attenuation coefficient

mu_en(energy)

Mass energy-absorption coefficient

plot_S([particle, energy])

Plot the stopping power in the element

plot_mass_coeff([energy])

Plot the mass-attenuation coefficient in the element

plot_mass_coeff_en([energy])

Plot the mass energy-absorption coefficient in the element

plot_range([particle, energy, density])

Plot the charged particle range in the element

range(energy[, particle, density])

Charged particle range in matter

S(energy, particle='p', density=None)[source]

Charged particle stopping power in matter

Calculate the stopping power, S=-dE/dx, for a given ion as a function of the ion energy in MeV. Units of S are MeV/cm. To return stopping power in units of MeV/(mg/cm^2), use option density=1E-3.

Parameters:
energyarray_like

Incident ion energy in MeV.

particlestr, optional

Incident ion. For light ions, options are ‘p’ (default), ‘d’, ‘t’, ‘a’ for proton, deuteron, triton and alpha, respectively. Additionally, heavy ions can be specified either by element or isotope, e.g. ‘Fe’, ‘40CA’, ‘U’, ‘Bi-209’. For light ions, the charge state is assumed to be fully stripped. For heavy ions the charge state is handled by a Bohr/Northcliffe parameterization consistent with the Anderson-Ziegler formalism.

densityfloat, optional

Density of the element in g/cm^3. Default behavior is to use Element.density. To return stopping power in units of MeV/(mg/cm^2), i.e. the mass-stopping power, use density=1E-3.

Returns:
stopping_powernumpy.ndarray

Stopping power, S=-dE/dx, for a given ion as a function of the ion energy in MeV. Units of S are MeV/cm.

Examples

>>> el = ci.Element('La')
>>> print(el.S(60.0))
36.8687750516453
>>> print(el.S(55.0, density=1E-3)) ### S in MeV/(mg/cm^2)
0.006371657662505643
attenuation(energy, x, density=None)[source]

Photon attenuation in matter

Calculate the attenuation factor I(x)/I_0 = e^(-mu*x) for a given photon energy (in keV) and slab thickness (in cm).

Parameters:
energyarray_like

Incident photon energy in keV.

xfloat

Thickness of slab of given element, in cm.

densityfloat, optional

Density of the element in g/cm^3. Default behavior is to use Element.density.

Returns:
attenuationnumpy.ndarray

The slab attenuation factor as an absolute number (i.e. from 0 to 1). E.g. if the incident intensity is I_0, the transmitted intensity I(x) is I_0 times the attenuation factor.

Examples

>>> el = ci.Element('Fe')
>>> print(el.attenuation(511, x=0.3))
0.821621630674751
>>> print(el.attenuation(300, x=0.5, density=8))
0.6442940871813587
mu(energy)[source]

Mass-attenuation coefficient

Interpolates the mass-attenuation coefficient, mu/rho, for the element along the input energy grid.

Parameters:
energyarray_like

The incident photon energy, in keV.

Returns:
munp.ndarray

Mass attenuation coefficient, mu/rho, in cm^2/g.

Examples

>>> el = ci.Element('Hg')
>>> print(el.mu(200))
0.9456
mu_en(energy)[source]

Mass energy-absorption coefficient

Interpolates the mass-energy absorption coefficient, mu_en/rho, for the element along the input energy grid.

Parameters:
energyarray_like

The incident photon energy, in keV.

Returns:
mu_ennp.ndarray

Mass energy absorption coefficient, mu_en/rho, in cm^2/g.

Examples

>>> el = ci.Element('Hg')
>>> print(el.mu_en(200))
0.5661
plot_S(particle='p', energy=None, **kwargs)[source]

Plot the stopping power in the element

Creates a plot of the charged particle stopping power (in MeV/(mg/cm^2)) in the element as a function of the incident ion energy (in MeV).

Parameters:
particlestr

Incident ion. For light ions, options are ‘p’ (default), ‘d’, ‘t’, ‘a’ for proton, deuteron, triton and alpha, respectively. Additionally, heavy ions can be specified either by element or isotope, e.g. ‘Fe’, ‘40CA’, ‘U’, ‘Bi-209’.

energyarray_like, optional

Energy grid on which to plot, replacing the default energy grid. Units are in MeV.

Other Parameters:
**kwargs

Optional keyword arguments for plotting. See the plotting section of the curie API for a complete list of kwargs.

Examples

>>> el = ci.Element('He')
>>> el.plot_S(particle='a')
>>> el = ci.Element('Fe')
>>> el.plot_S(particle='d')
plot_mass_coeff(energy=None, **kwargs)[source]

Plot the mass-attenuation coefficient in the element

Creates a plot of the mass-attenuation coefficient (in cm^2/g) as a function of photon energy in keV.

Parameters:
energyarray_like, optional

Energy grid on which to plot, replacing the default energy grid. Units are in keV.

Other Parameters:
**kwargs

Optional keyword arguments for plotting. See the plotting section of the curie API for a complete list of kwargs.

Examples

>>> el = ci.Element('Fe')
>>> el.plot_mass_coeff()
>>> el.plot_mass_coeff(style='poster')
plot_mass_coeff_en(energy=None, **kwargs)[source]

Plot the mass energy-absorption coefficient in the element

Creates a plot of the mass energy-absorption coefficient (in cm^2/g) as a function of photon energy in keV.

Parameters:
energyarray_like, optional

Energy grid on which to plot, replacing the default energy grid. Units are in keV.

Other Parameters:
**kwargs

Optional keyword arguments for plotting. See the plotting section of the curie API for a complete list of kwargs.

Examples

>>> el = ci.Element('Hf')

Example plotting the mass-attenuation coefficient together with the mass energy-absorption coefficient, on the same axes.

>>> f,ax = el.plot_mass_coeff(return_plot=True)
>>> el.plot_mass_coeff_en(f=f, ax=ax)
plot_range(particle='p', energy=None, density=None, **kwargs)[source]

Plot the charged particle range in the element

Creates a plot of the charged particle range (in cm) in the element as a function of the incident ion energy (in MeV).

Parameters:
particlestr

Incident ion. For light ions, options are ‘p’ (default), ‘d’, ‘t’, ‘a’ for proton, deuteron, triton and alpha, respectively. Additionally, heavy ions can be specified either by element or isotope, e.g. ‘Fe’, ‘40CA’, ‘U’, ‘Bi-209’.

energyarray_like, optional

Energy grid on which to plot, replacing the default energy grid. Units are in MeV.

densityfloat, optional

Density of the element in g/cm^3. Default behavior is to use Element.density.

Other Parameters:
**kwargs

Optional keyword arguments for plotting. See the plotting section of the curie API for a complete list of kwargs.

Examples

>>> el = ci.Element('Ar')
>>> el.plot_range()
>>> el.plot_range(density=0.5)
range(energy, particle='p', density=None)[source]

Charged particle range in matter

Calculates the charged particle range in the element, in cm. Incident energy should be in MeV, and the particle type definition is identical to Element.S().

Parameters:
energyarray_like

Incident ion energy in MeV.

particlestr, optional

Incident ion. For light ions, options are ‘p’ (default), ‘d’, ‘t’, ‘a’ for proton, deuteron, triton and alpha, respectively. Additionally, heavy ions can be specified either by element or isotope, e.g. ‘Fe’, ‘40CA’, ‘U’, ‘Bi-209’. For light ions, the charge state is assumed to be fully stripped. For heavy ions the charge state is handled by a Bohr/Northcliffe parameterization consistent with the Anderson-Ziegler formalism.

densityfloat, optional

Density of the element in g/cm^3. Default behavior is to use Element.density.

Returns:
rangenp.ndarray

Charged particle range in the element, in cm.

Examples

>>> el = ci.Element('Fe')
>>> print(el.range(60.0))
0.5858151125192633
>>> el = ci.Element('U')
>>> print(el.range(60.0))
0.3763111404628591