Module: Units
This module contains physical constants relevant for nuclear matter and neutron star physics. It also provides functions for converting one type of units into another.
Numerical
- Constants for dealing with extreme numerics:
NUMZERO= 1e-12 (the lowest numerical value allowed)NUMINF= 1e30 (the largest numerical value allowed)DENSEPSILON= 1e-12 this value is used to renormalize division and avoid dividing but extremely small numbers that cause numerical instabilities
Note
DENSEPSILON is used whenever division by density has to be applied.
Those cases usually will give zero in proper analytical limit.
Physical
Note
- Physical constants are from NIST website:
Constant |
Value |
Unit |
Description |
|---|---|---|---|
HBARC |
197.3269804 |
[MeV fm] |
\(\hbar c\) |
MN |
939.5654205 |
[MeV] |
neutron mass \(m_n\) |
MP |
938.2720882 |
[MeV] |
proton mass \(m_p\) |
HBAR2M_n |
20.72124837 |
[MeV*fm \(^2\)] |
\(\\hbar^2/(2 m_n)\) |
HBAR2M_p |
20.74981092 |
[MeV*fm \(^2\)] |
\(\\hbar^2/(2 m_p)\) |
Nucleon masses
The masses of proton, neutron and nucleon (which is their averaged mass). The nucleon mass is an average of proton and neutron mass:
Mass |
Value |
|---|---|
neutron \(m_n\) |
1.6749286 \(\cdot 10^{27}\) kg |
proton \(m_p\) |
1.6726231 \(\cdot 10^{27}\) kg |
nucleon \(m_N\) |
1.6737759 \(\cdot 10^{27}\) kg |
Neutron star
Some constants are relevant from the point of view of neutron star’s physics. One of them is the neutron drip density \(\\rho_{\\mathrm{ND}}\) at which excesive neutrons are not bound to the nuclei anymore and form superfluid sea. This is how the border of outer crust and inner crust are defined. Then, there is saturation density \(\\rho_0\) at which the crust-core transition should occure. This is the density of nuclei.
Variable |
Density |
[g cm -3] |
[fm -3] |
|---|---|---|---|
RHOSAT |
\(\\rho_0\) |
3 \(\\cdot 10^{14}\) |
0.18 |
RHOND |
\(\\rho_{\\mathrm{ND}}\) |
4 \(\\cdot 10^{11}\) |
0.00042 |
List of functions
- libnest.units.KtoMev(temp)
Converts temperature \(T\) units from Kelvins to energy \(E\) units in MeVs by setting the Boltzmann constant to 1.
\[E = \frac{k_B}{1eV} 10^{-6} T \approx 11604525006.1598 \cdot T \]- Parameters:
temp (float) – temperature \(T\) [K]
- Returns:
energy \(E\) [MeV]
- Return type:
float
See also
- libnest.units.MeVtoK(energy)
Converts energy \(E\) units in MeVs to temperature \(T\) units from Kelvins by setting the Boltzmann constant to 1.
\[T = \frac{e V}{k_B} 10^6 E \approx 11604525006.1598 \cdot E \]- Parameters:
energy (float) – energy \(E\) [MeV]
- Returns:
temperature \(T\) [K]
- Return type:
float
See also
- libnest.units.fm3togcm3(rho)
Function converts desnity units: fm -3 into g cm -3. See more here. The numerical factor
\[\frac{m_N}{\mathrm{fm}^3} = 1.67377585 \cdot 10^{15}\frac{\mathrm{g}}{\mathrm{cm}^3} \]- Parameters:
rho (float) – density \(\rho\) [fm -3]
- Returns:
rho \(\rho\) [g cm -3]
- Return type:
float
See also
- libnest.units.gcm3tofm3(rho)
Function converts desnity units: fm -3 into g cm -3. See more here. The numerical factor
\[\frac{\mathrm{g}}{\mathrm{cm}^3} = \frac{10^{-15}}{1.67377585} \frac{m_N}{\mathrm{fm}^3} \]- Parameters:
rho (float) – density \(\rho\) [g cm -3]
- Returns:
rho \(\rho\) [fm -3]
- Return type:
float
See also