ThePEG is hosted by Hepforge, IPPP Durham
ThePEG  2.1.0
ThePEG::Units Namespace Reference

The Units namespace contains the declaration of a number of classes for variables with dimension. More...

Typedefs

typedef Qty< 0, 1, 0 > Energy
 Energy. More...
 
typedef Energy Mass
 Mass has the same unit as Energy <=> c == 1. More...
 
typedef Qty< 1, 0, 0 > Length
 Length. More...
 
typedef Length Time
 Time has the same unit as Length. More...
 
typedef Qty<-1, 0, 0 > InvLength
 Inverse Length. More...
 
typedef double Velocity
 Velocities are dimensionless fractions of c. More...
 
typedef Qty< 0, 0, 1 > Charge
 Charge. More...
 
typedef Qty< 1, 1, 0 > AngularMomentum
 Angular momentum. More...
 
typedef Qty<-1, 1, 0 > Tension
 Tension. More...
 
typedef Qty< 2, 0, 0 > Area
 Area will be assumed to be Length $^2$. More...
 
typedef Qty<-2, 0, 0 > InvArea
 Inverse Area. More...
 
typedef Area CrossSection
 Cross section is an area. More...
 
typedef Qty< 2, 2, 0 > Energy2XSec
 CrossSection*Energy2. More...
 
typedef Qty< 2,-2, 0 > DiffXSec
 CrossSection/Energy2. More...
 
typedef Qty< 2,-4, 0 > Diff2XSec
 CrossSection/Energy4. More...
 
typedef Qty< 2,-6, 0 > Diff3XSec
 CrossSection/Energy6.
 
typedef Energy2 Scale
 Scale is the same as a squared energy. More...
 
typedef ThreeVector< LengthPoint
 A point in three-dimensional euclidean space. More...
 
typedef ThreeVector< LengthDistance
 A distance in three-dimensional euclidean space. More...
 
typedef ThreeVector< double > Axis
 A direction in three-dimensional euclidean space. More...
 
typedef ThreeVector< EnergyMomentum3
 A momentum in three-dimensional euclidean space. More...
 
typedef ThreeVector< double > Boost
 A three-dimensional boost vector. More...
 
typedef LorentzVector< LengthLorentzDistance
 A distance in four-dimensional space-time. More...
 
typedef Lorentz5Vector< LengthLorentz5Distance
 A distance in four-dimensional space-time with an explicit invariant time component. More...
 
typedef LorentzVector< LengthLorentzPoint
 A point in four-dimensional space-time. More...
 
typedef LorentzVector< EnergyLorentzMomentum
 A momentum in four-dimensional space-time. More...
 
typedef Lorentz5Vector< EnergyLorentz5Momentum
 A momentum in four-dimensional space-time with an explicit invariant mass component. More...
 
typedef Transverse< EnergyTransverseMomentum
 Transverse components of a momentum. More...
 
Higher powers of energy.

Even higher powers can be created with similar typedefs.

typedef Qty< 0, 2, 0 > Energy2
 
typedef Qty< 0, 3, 0 > Energy3
 
typedef Qty< 0, 4, 0 > Energy4
 
typedef Qty< 0, 5, 0 > Energy5
 
typedef Qty< 0, 6, 0 > Energy6
 
typedef Qty< 0, 7, 0 > Energy7
 
typedef Qty< 0, 8, 0 > Energy8
 
typedef Qty< 0, 9, 0 > Energy9
 
typedef Qty< 0, 10, 0 > Energy10
 
typedef Qty< 0, 11, 0 > Energy11
 
typedef Qty< 0, 12, 0 > Energy12
 
typedef Qty< 0, 1, 0, 1, 2, 1 > SqrtEnergy
 
typedef Qty< 0,-1, 0, 1, 2, 1 > InvSqrtEnergy
 
typedef Qty< 0, -1, 0 > InvEnergy
 
typedef Qty< 0, -2, 0 > InvEnergy2
 
typedef Qty< 0, -3, 0 > InvEnergy3
 
typedef Qty< 0, -4, 0 > InvEnergy4
 
typedef Qty< 0, -5, 0 > InvEnergy5
 
typedef Qty< 0, -6, 0 > InvEnergy6
 
typedef Qty< 0, -7, 0 > InvEnergy7
 
typedef Qty< 0, -8, 0 > InvEnergy8
 
typedef Qty< 0, -9, 0 > InvEnergy9
 
typedef Qty< 0,-10, 0 > InvEnergy10
 
typedef Qty< 0,-11, 0 > InvEnergy11
 
typedef Qty< 0,-12, 0 > InvEnergy12
 

Variables

constexpr Qty< 1, 1, 0 > hbarc = 197.326968e-15 * MeV * meter
 Planck's constant times c (PDG 2006 value 197.326968(17) MeV fm)
 
constexpr Qty< 1, 1, 0 > hbar_Planck = hbarc / 1.0
 Planck's constant (PDG 2006 value 197.326968(17) MeV fm)
 

Pre-defined basic units.

constexpr Length meter = 1.0e+3_mm
 
constexpr Length millimeter = 1_mm
 
constexpr Length mm = 1_mm
 
constexpr Length centimeter = 10_mm
 
constexpr Length micrometer = 1.0e-3_mm
 
constexpr Length nanometer = 1.0e-6_mm
 
constexpr Length picometer = 1.0e-9_mm
 
constexpr Length femtometer = 1.0e-12_mm
 
constexpr Energy keV = 1.0e-3_MeV
 
constexpr Energy MeV = 1_MeV
 
constexpr Energy GeV = 1_GeV
 
constexpr Energy TeV = 1.0e+6_MeV
 
constexpr Energy2 MeV2 = 1_MeV2
 
constexpr Energy2 GeV2 = 1_GeV2
 
constexpr InvEnergy InvGeV = 1/GeV
 
constexpr Area femtobarn = 1.0e-03_pb
 
constexpr Area picobarn = 1_pb
 
constexpr Area nanobarn = 1.0e+03_pb
 
constexpr Area microbarn = 1.0e+06_pb
 
constexpr Area millibarn = 1.0e+09_pb
 
constexpr Area barn = 1.0e+12_pb
 
constexpr Charge eplus = Charge::baseunit()
 
constexpr Length operator"" _mm (long double x)
 
constexpr Length operator"" _mm (unsigned long long x)
 
constexpr Energy operator"" _MeV (long double x)
 
constexpr Energy operator"" _MeV (unsigned long long x)
 
constexpr Energy operator"" _GeV (long double x)
 
constexpr Energy operator"" _GeV (unsigned long long x)
 
constexpr Energy2 operator"" _MeV2 (long double x)
 
constexpr Energy2 operator"" _MeV2 (unsigned long long x)
 
constexpr Energy2 operator"" _GeV2 (long double x)
 
constexpr Energy2 operator"" _GeV2 (unsigned long long x)
 
constexpr Area operator"" _pb (long double x)
 
constexpr Area operator"" _pb (unsigned long long x)
 

Detailed Description

The Units namespace contains the declaration of a number of classes for variables with dimension.

Currently they are all typedefs of double, but in the future the SIUnits package will be used.

The file Utilities/UnitIO.h defines helper-classes and helper functions to read and write variables with dimensions. As an example, to read and write an energy variable e in units of GeV, use: os << ounit(e, GeV) and is >> iunit(e, GeV)

Typedef Documentation

◆ AngularMomentum

Angular momentum.

Definition at line 59 of file Unitsystem.h.

◆ Area

typedef Qty<2,0,0> ThePEG::Units::Area

Area will be assumed to be Length $^2$.

Definition at line 65 of file Unitsystem.h.

◆ Axis

A direction in three-dimensional euclidean space.

Definition at line 129 of file Unitsystem.h.

◆ Boost

A three-dimensional boost vector.

Definition at line 135 of file Unitsystem.h.

◆ Charge

typedef Qty<0,0,1> ThePEG::Units::Charge

Charge.

Definition at line 56 of file Unitsystem.h.

◆ CrossSection

Cross section is an area.

Definition at line 71 of file Unitsystem.h.

◆ Diff2XSec

typedef Qty<2,-4,0> ThePEG::Units::Diff2XSec

CrossSection/Energy4.

Definition at line 114 of file Unitsystem.h.

◆ DiffXSec

typedef Qty<2,-2,0> ThePEG::Units::DiffXSec

CrossSection/Energy2.

Definition at line 111 of file Unitsystem.h.

◆ Distance

A distance in three-dimensional euclidean space.

Definition at line 126 of file Unitsystem.h.

◆ Energy

typedef Qty<0,1,0> ThePEG::Units::Energy

Energy.

Definition at line 38 of file Unitsystem.h.

◆ Energy2XSec

CrossSection*Energy2.

Definition at line 108 of file Unitsystem.h.

◆ InvArea

typedef Qty<-2,0,0> ThePEG::Units::InvArea

Inverse Area.

Definition at line 68 of file Unitsystem.h.

◆ InvLength

typedef Qty<-1,0,0> ThePEG::Units::InvLength

Inverse Length.

Definition at line 50 of file Unitsystem.h.

◆ Length

typedef Qty<1,0,0> ThePEG::Units::Length

Length.

Definition at line 44 of file Unitsystem.h.

◆ Lorentz5Distance

A distance in four-dimensional space-time with an explicit invariant time component.

Definition at line 142 of file Unitsystem.h.

◆ Lorentz5Momentum

A momentum in four-dimensional space-time with an explicit invariant mass component.

Definition at line 152 of file Unitsystem.h.

◆ LorentzDistance

A distance in four-dimensional space-time.

Definition at line 138 of file Unitsystem.h.

◆ LorentzMomentum

A momentum in four-dimensional space-time.

Definition at line 148 of file Unitsystem.h.

◆ LorentzPoint

A point in four-dimensional space-time.

Definition at line 145 of file Unitsystem.h.

◆ Mass

Mass has the same unit as Energy <=> c == 1.

Definition at line 41 of file Unitsystem.h.

◆ Momentum3

A momentum in three-dimensional euclidean space.

Definition at line 132 of file Unitsystem.h.

◆ Point

A point in three-dimensional euclidean space.

Definition at line 123 of file Unitsystem.h.

◆ Scale

Scale is the same as a squared energy.

Definition at line 120 of file Unitsystem.h.

◆ Tension

typedef Qty<-1,1,0> ThePEG::Units::Tension

Tension.

Definition at line 62 of file Unitsystem.h.

◆ Time

Time has the same unit as Length.

<=> c == 1.

Definition at line 47 of file Unitsystem.h.

◆ TransverseMomentum

Transverse components of a momentum.

Definition at line 155 of file Unitsystem.h.

◆ Velocity

typedef double ThePEG::Units::Velocity

Velocities are dimensionless fractions of c.

Definition at line 53 of file Unitsystem.h.