criptic v1
Cosmic Ray Interstellar Propagation Tool using Itô Calculus
Loading...
Searching...
No Matches
Functions
criptic::sr Namespace Reference

A namespace to hold special relativistic functions. More...

Functions

static Real gamma_from_p (const Real m, const Real p)
 Compute Lorentz factor from rest mass and momentum.
 
static Real gamma_from_T (const Real m, const Real T)
 Compute Lorentz factor from rest mass and kinetic energy.
 
static Real gamma_from_E (const Real m, const Real E)
 Compute Lorentz factor from rest mass and total energy.
 
static Real p_from_gamma (const Real m, const Real gamma)
 Compute momentum from rest mass and Lorentz factor.
 
static Real p_from_T (const Real m, const Real T)
 Compute momentum from rest mass and kinetic energy.
 
static Real p_from_E (const Real m, const Real E)
 Compute momentum from rest mass and total energy.
 
static Real T_from_gamma (const Real m, const Real gamma)
 Compute kinetic energy from rest mass and Lorentz factor.
 
static Real T_from_p (const Real m, const Real p)
 Compute kinetic energy from rest mass and momentum.
 
static Real E_from_gamma (const Real m, const Real gamma)
 Compute total energy from rest mass and Lorentz factor.
 
static Real E_from_p (const Real m, const Real p)
 Compute total energy from rest mass and momentum.
 
static Real dT_dp (const Real m, const Real p)
 Compute derivative of kinetic energy with respect to momentum.
 
static Real v_from_p (const Real m, const Real p)
 Compute velocity from momentum.
 
static Real gamma_from_p (const partTypes::pType pt, const Real p)
 Compute Lorentz factor from particle type and momentum.
 
static Real gamma_from_T (const partTypes::pType pt, const Real T)
 Compute Lorentz factor from particle type and kinetic energy.
 
static Real p_from_gamma (const partTypes::pType pt, const Real gamma)
 Compute momentum from particle type and Lorentz factor.
 
static Real p_from_T (const partTypes::pType pt, const Real T)
 Compute momentum from particle type and kinetic energy.
 
static Real T_from_gamma (const partTypes::pType pt, const Real gamma)
 Compute kinetic energy from particle type and Lorentz factor.
 
static Real T_from_p (const partTypes::pType pt, const Real p)
 Compute kinetic energy from particle type and momentum.
 
static Real dT_dp (const partTypes::pType pt, const Real p)
 Compute derivative of kinetic energy with respect to momentum.
 
static Real v_from_p (const partTypes::pType pt, const Real p)
 Compute particle velocity from particle type and momentum.
 
static Real ECM (const Real mt, const Real mp, const Real T)
 Compute center of mass energy for collision with fixed target.
 
static Real ECM (const partTypes::pType ptt, const partTypes::pType ptp, const Real T)
 Compute center of mass energy for collision with fixed target.
 

Detailed Description

A namespace to hold special relativistic functions.

Function Documentation

◆ dT_dp() [1/2]

static Real criptic::sr::dT_dp ( const partTypes::pType  pt,
const Real  p 
)
inlinestatic

Compute derivative of kinetic energy with respect to momentum.

Parameters
ptParticle type
pParticle momentum
Returns
Derivative of kinetic energy with respect to momentum

◆ dT_dp() [2/2]

static Real criptic::sr::dT_dp ( const Real  m,
const Real  p 
)
inlinestatic

Compute derivative of kinetic energy with respect to momentum.

Parameters
mParticle rest mass
pParticle momentum
Returns
Derivative of kinetic energy with respect to momentum

◆ E_from_gamma()

static Real criptic::sr::E_from_gamma ( const Real  m,
const Real  gamma 
)
inlinestatic

Compute total energy from rest mass and Lorentz factor.

Parameters
mParticle rest mass
gammaParticle Lorentz factor
Returns
Particle kinetic energy

◆ E_from_p()

static Real criptic::sr::E_from_p ( const Real  m,
const Real  p 
)
inlinestatic

Compute total energy from rest mass and momentum.

Parameters
mParticle rest mass
pParticle momentum
Returns
Particle kinetic energy

◆ ECM() [1/2]

static Real criptic::sr::ECM ( const partTypes::pType  ptt,
const partTypes::pType  ptp,
const Real  T 
)
inlinestatic

Compute center of mass energy for collision with fixed target.

Parameters
ptpParticle type of projectile
pttParticle type of target
TKinetic energy of moving particle

◆ ECM() [2/2]

static Real criptic::sr::ECM ( const Real  mt,
const Real  mp,
const Real  T 
)
inlinestatic

Compute center of mass energy for collision with fixed target.

Parameters
mpMass of projectile
mtMass of target
TKinetic energy of moving particle

◆ gamma_from_E()

static Real criptic::sr::gamma_from_E ( const Real  m,
const Real  E 
)
inlinestatic

Compute Lorentz factor from rest mass and total energy.

Parameters
mParticle rest mass
EParticle total energy
Returns
The Lorentz factor

◆ gamma_from_p() [1/2]

static Real criptic::sr::gamma_from_p ( const partTypes::pType  pt,
const Real  p 
)
inlinestatic

Compute Lorentz factor from particle type and momentum.

Parameters
ptParticle type
pParticle momentum
Returns
The Lorentz factor

◆ gamma_from_p() [2/2]

static Real criptic::sr::gamma_from_p ( const Real  m,
const Real  p 
)
inlinestatic

Compute Lorentz factor from rest mass and momentum.

Parameters
mParticle rest mass
pParticle momentum
Returns
The Lorentz factor

◆ gamma_from_T() [1/2]

static Real criptic::sr::gamma_from_T ( const partTypes::pType  pt,
const Real  T 
)
inlinestatic

Compute Lorentz factor from particle type and kinetic energy.

Parameters
ptParticle type
TParticle kinetic energy
Returns
The Lorentz factor

◆ gamma_from_T() [2/2]

static Real criptic::sr::gamma_from_T ( const Real  m,
const Real  T 
)
inlinestatic

Compute Lorentz factor from rest mass and kinetic energy.

Parameters
mParticle rest mass
TParticle kinetic energy
Returns
The Lorentz factor

◆ p_from_E()

static Real criptic::sr::p_from_E ( const Real  m,
const Real  E 
)
inlinestatic

Compute momentum from rest mass and total energy.

Parameters
mParticle rest mass
EParticle energy
Returns
Particle momentum

◆ p_from_gamma() [1/2]

static Real criptic::sr::p_from_gamma ( const partTypes::pType  pt,
const Real  gamma 
)
inlinestatic

Compute momentum from particle type and Lorentz factor.

Parameters
ptParticle type
gammaParticle Lorentz factor
Returns
Particle momentum

◆ p_from_gamma() [2/2]

static Real criptic::sr::p_from_gamma ( const Real  m,
const Real  gamma 
)
inlinestatic

Compute momentum from rest mass and Lorentz factor.

Parameters
mParticle rest mass
gammaParticle Lorentz factor
Returns
Particle momentum

◆ p_from_T() [1/2]

static Real criptic::sr::p_from_T ( const partTypes::pType  pt,
const Real  T 
)
inlinestatic

Compute momentum from particle type and kinetic energy.

Parameters
ptParticle type
TParticle kinetic energy
Returns
Particle momentum

◆ p_from_T() [2/2]

static Real criptic::sr::p_from_T ( const Real  m,
const Real  T 
)
inlinestatic

Compute momentum from rest mass and kinetic energy.

Parameters
mParticle rest mass
TParticle kinetic energy
Returns
Particle momentum

◆ T_from_gamma() [1/2]

static Real criptic::sr::T_from_gamma ( const partTypes::pType  pt,
const Real  gamma 
)
inlinestatic

Compute kinetic energy from particle type and Lorentz factor.

Parameters
ptParticle type
gammaParticle Lorentz factor
Returns
Particle kinetic energy

◆ T_from_gamma() [2/2]

static Real criptic::sr::T_from_gamma ( const Real  m,
const Real  gamma 
)
inlinestatic

Compute kinetic energy from rest mass and Lorentz factor.

Parameters
mParticle rest mass
gammaParticle Lorentz factor
Returns
Particle kinetic energy

◆ T_from_p() [1/2]

static Real criptic::sr::T_from_p ( const partTypes::pType  pt,
const Real  p 
)
inlinestatic

Compute kinetic energy from particle type and momentum.

Parameters
ptParticle type
pParticle momentum
Returns
Particle kinetic energy

◆ T_from_p() [2/2]

static Real criptic::sr::T_from_p ( const Real  m,
const Real  p 
)
inlinestatic

Compute kinetic energy from rest mass and momentum.

Parameters
mParticle rest mass
pParticle momentum
Returns
Particle kinetic energy

◆ v_from_p() [1/2]

static Real criptic::sr::v_from_p ( const partTypes::pType  pt,
const Real  p 
)
inlinestatic

Compute particle velocity from particle type and momentum.

Parameters
ptParticle type
pParticle momentum
Returns
Particle velocity

◆ v_from_p() [2/2]

static Real criptic::sr::v_from_p ( const Real  m,
const Real  p 
)
inlinestatic

Compute velocity from momentum.

Parameters
mParticle rest mass
pParticle momentum
Returns
Particle velocity