Shamrock 2025.10.0
Astrophysical Code
Loading...
Searching...
No Matches
Classes | Public Types | Public Member Functions | Public Attributes | List of all members
shamunits::Constants< T > Struct Template Reference

Physical constants. More...

#include <shamunits/include/shamunits/Constants.hpp>

Classes

struct  Si
 Physical constant in SI units. More...
 

Public Types

using Conv = ConversionConstants< T >
 Alias to the conversion constants.
 

Public Member Functions

 Constants (const UnitSystem< T > units)
 Construct the shamunits::Constants class with a unit system.
 
template<int power = 1>
constexpr T delta_nu_cs ()
 get delta_nu_cs in the current unit system units (s-1)
 
template<int power = 1>
constexpr T c ()
 get c in the current unit system units (m.s-1)
 
template<int power = 1>
constexpr T h ()
 get h in the current unit system units (J.s-1)
 
template<int power = 1>
constexpr T e ()
 get e in the current unit system units (C)
 
template<int power = 1>
constexpr T k ()
 get k in the current unit system units (J.K-1 )
 
template<int power = 1>
constexpr T Na ()
 get Na in the current unit system units (mol-1 )
 
template<int power = 1>
constexpr T Kcd ()
 get Kcd in the current unit system units (lm.W-1)
 
template<int power = 1>
constexpr T second ()
 
template<int power = 1>
constexpr T minute ()
 
template<int power = 1>
constexpr T hour ()
 get the value of a hour in the time unit of the current unit system units
 
template<int power = 1>
constexpr T day ()
 get the value of a day in the time unit of the current unit system units
 
template<int power = 1>
constexpr T year ()
 get the value of a year in the time unit of the current unit system units
 
template<int power = 1>
constexpr T au ()
 get the value of an au in the distance unit of the current unit system units
 
template<int power = 1>
constexpr T astronomical_unit ()
 get the value of an astronomical_unit in the distance unit of the current unit system units
 
template<int power = 1>
constexpr T light_year ()
 get the value of a light_year in the distance unit of the current unit system units
 
template<int power = 1>
constexpr T parsec ()
 get the value of a parsec in the distance unit of the current unit system units
 
template<int power = 1>
constexpr T solar_radius ()
 get the value of a solar radius in the distance unit of the current unit system units
 
template<int power = 1>
constexpr T earth_radius ()
 get the value of one earth equatorial radius in the distance unit of the current unit system units
 
template<int power = 1>
constexpr T planck_length ()
 get the value of a planck_length in the distance unit of the current unit system units
 
template<int power = 1>
constexpr T proton_mass ()
 get the value of a proton_mass in the mass unit of the current unit system units
 
template<int power = 1>
constexpr T electron_mass ()
 get the value of a electron_mass in the mass unit of the current unit system units
 
template<int power = 1>
constexpr T earth_mass ()
 get the value of a earth_mass in the mass unit of the current unit system units
 
template<int power = 1>
constexpr T jupiter_mass ()
 get the value of a jupiter_mass in the mass unit of the current unit system units
 
template<int power = 1>
constexpr T sol_mass ()
 get the value of a sol_mass in the mass unit of the current unit system units
 
template<int power = 1>
constexpr T planck_mass ()
 get the value of a planck_mass in the mass unit of the current unit system units
 
template<int power = 1>
constexpr T dalton ()
 
template<int power = 1>
constexpr T guiness_density ()
 get the value of the guiness density in the density unit of the current unit system units
 
template<int power = 1>
constexpr T G ()
 get the value of G in the current unit system units
 
template<int power = 1>
constexpr T hbar ()
 get the value of hbar in the current unit system units
 
template<int power = 1>
constexpr T mu_0 ()
 get the value of mu_0 in the current unit system units
 
template<int power = 1>
constexpr T Z_0 ()
 get the value of Z_0 in the current unit system units
 
template<int power = 1>
constexpr T epsilon_0 ()
 get the value of epsilon_0 in the current unit system units
 
template<int power = 1>
constexpr T ke ()
 get the value of ke in the current unit system units
 
template<int power = 1>
constexpr T kb ()
 get the value of kb in the current unit system units
 
template<int power = 1>
constexpr T sigma ()
 get the value of sigma (Stephan Boltzmann constant) in the current unit system units
 

Public Attributes

const UnitSystem< T > units
 Current unit system of the constants.
 

Detailed Description

template<class T>
struct shamunits::Constants< T >

Physical constants.

Definition at line 112 of file Constants.hpp.

Member Typedef Documentation

◆ Conv

template<class T >
using shamunits::Constants< T >::Conv = ConversionConstants<T>

Alias to the conversion constants.

Definition at line 115 of file Constants.hpp.

Constructor & Destructor Documentation

◆ Constants()

template<class T >
shamunits::Constants< T >::Constants ( const UnitSystem< T >  units)
inlineexplicit

Construct the shamunits::Constants class with a unit system.

Definition at line 170 of file Constants.hpp.

Member Function Documentation

◆ astronomical_unit()

template<class T >
template<int power = 1>
shamunits::Constants< T >::astronomical_unit ( )
inlineconstexpr

get the value of an astronomical_unit in the distance unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ au()

template<class T >
template<int power = 1>
shamunits::Constants< T >::au ( )
inlineconstexpr

get the value of an au in the distance unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ c()

template<class T >
template<int power = 1>
shamunits::Constants< T >::c ( )
inlineconstexpr

get c in the current unit system units (m.s-1)

Definition at line 175 of file Constants.hpp.

◆ dalton()

template<class T >
template<int power = 1>
constexpr T shamunits::Constants< T >::dalton ( )
inlineconstexpr

Definition at line 175 of file Constants.hpp.

◆ day()

template<class T >
template<int power = 1>
shamunits::Constants< T >::day ( )
inlineconstexpr

get the value of a day in the time unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ delta_nu_cs()

template<class T >
template<int power = 1>
shamunits::Constants< T >::delta_nu_cs ( )
inlineconstexpr

get delta_nu_cs in the current unit system units (s-1)

Definition at line 175 of file Constants.hpp.

◆ e()

template<class T >
template<int power = 1>
shamunits::Constants< T >::e ( )
inlineconstexpr

get e in the current unit system units (C)

Definition at line 175 of file Constants.hpp.

◆ earth_mass()

template<class T >
template<int power = 1>
shamunits::Constants< T >::earth_mass ( )
inlineconstexpr

get the value of a earth_mass in the mass unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ earth_radius()

template<class T >
template<int power = 1>
shamunits::Constants< T >::earth_radius ( )
inlineconstexpr

get the value of one earth equatorial radius in the distance unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ electron_mass()

template<class T >
template<int power = 1>
shamunits::Constants< T >::electron_mass ( )
inlineconstexpr

get the value of a electron_mass in the mass unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ epsilon_0()

template<class T >
template<int power = 1>
shamunits::Constants< T >::epsilon_0 ( )
inlineconstexpr

get the value of epsilon_0 in the current unit system units

Definition at line 175 of file Constants.hpp.

◆ G()

template<class T >
template<int power = 1>
shamunits::Constants< T >::G ( )
inlineconstexpr

get the value of G in the current unit system units

Definition at line 175 of file Constants.hpp.

◆ guiness_density()

template<class T >
template<int power = 1>
shamunits::Constants< T >::guiness_density ( )
inlineconstexpr

get the value of the guiness density in the density unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ h()

template<class T >
template<int power = 1>
shamunits::Constants< T >::h ( )
inlineconstexpr

get h in the current unit system units (J.s-1)

Definition at line 175 of file Constants.hpp.

◆ hbar()

template<class T >
template<int power = 1>
shamunits::Constants< T >::hbar ( )
inlineconstexpr

get the value of hbar in the current unit system units

Definition at line 175 of file Constants.hpp.

◆ hour()

template<class T >
template<int power = 1>
shamunits::Constants< T >::hour ( )
inlineconstexpr

get the value of a hour in the time unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ jupiter_mass()

template<class T >
template<int power = 1>
shamunits::Constants< T >::jupiter_mass ( )
inlineconstexpr

get the value of a jupiter_mass in the mass unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ k()

template<class T >
template<int power = 1>
shamunits::Constants< T >::k ( )
inlineconstexpr

get k in the current unit system units (J.K-1 )

Definition at line 175 of file Constants.hpp.

◆ kb()

template<class T >
template<int power = 1>
shamunits::Constants< T >::kb ( )
inlineconstexpr

get the value of kb in the current unit system units

Definition at line 175 of file Constants.hpp.

◆ Kcd()

template<class T >
template<int power = 1>
shamunits::Constants< T >::Kcd ( )
inlineconstexpr

get Kcd in the current unit system units (lm.W-1)

Definition at line 175 of file Constants.hpp.

◆ ke()

template<class T >
template<int power = 1>
shamunits::Constants< T >::ke ( )
inlineconstexpr

get the value of ke in the current unit system units

Definition at line 175 of file Constants.hpp.

◆ light_year()

template<class T >
template<int power = 1>
shamunits::Constants< T >::light_year ( )
inlineconstexpr

get the value of a light_year in the distance unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ minute()

template<class T >
template<int power = 1>
constexpr T shamunits::Constants< T >::minute ( )
inlineconstexpr

Definition at line 175 of file Constants.hpp.

◆ mu_0()

template<class T >
template<int power = 1>
shamunits::Constants< T >::mu_0 ( )
inlineconstexpr

get the value of mu_0 in the current unit system units

Definition at line 175 of file Constants.hpp.

◆ Na()

template<class T >
template<int power = 1>
shamunits::Constants< T >::Na ( )
inlineconstexpr

get Na in the current unit system units (mol-1 )

Definition at line 175 of file Constants.hpp.

◆ parsec()

template<class T >
template<int power = 1>
shamunits::Constants< T >::parsec ( )
inlineconstexpr

get the value of a parsec in the distance unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ planck_length()

template<class T >
template<int power = 1>
shamunits::Constants< T >::planck_length ( )
inlineconstexpr

get the value of a planck_length in the distance unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ planck_mass()

template<class T >
template<int power = 1>
shamunits::Constants< T >::planck_mass ( )
inlineconstexpr

get the value of a planck_mass in the mass unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ proton_mass()

template<class T >
template<int power = 1>
shamunits::Constants< T >::proton_mass ( )
inlineconstexpr

get the value of a proton_mass in the mass unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ second()

template<class T >
template<int power = 1>
constexpr T shamunits::Constants< T >::second ( )
inlineconstexpr

Definition at line 175 of file Constants.hpp.

◆ sigma()

template<class T >
template<int power = 1>
shamunits::Constants< T >::sigma ( )
inlineconstexpr

get the value of sigma (Stephan Boltzmann constant) in the current unit system units

Definition at line 175 of file Constants.hpp.

◆ sol_mass()

template<class T >
template<int power = 1>
shamunits::Constants< T >::sol_mass ( )
inlineconstexpr

get the value of a sol_mass in the mass unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ solar_radius()

template<class T >
template<int power = 1>
shamunits::Constants< T >::solar_radius ( )
inlineconstexpr

get the value of a solar radius in the distance unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ year()

template<class T >
template<int power = 1>
shamunits::Constants< T >::year ( )
inlineconstexpr

get the value of a year in the time unit of the current unit system units

Definition at line 175 of file Constants.hpp.

◆ Z_0()

template<class T >
template<int power = 1>
shamunits::Constants< T >::Z_0 ( )
inlineconstexpr

get the value of Z_0 in the current unit system units

Definition at line 175 of file Constants.hpp.

Member Data Documentation

◆ units

template<class T >
const UnitSystem<T> shamunits::Constants< T >::units

Current unit system of the constants.

Definition at line 167 of file Constants.hpp.


The documentation for this struct was generated from the following file: