Geant4-11
Public Member Functions | Static Public Member Functions | Protected Member Functions | Protected Attributes | Friends
CLHEP::HepBoost Class Reference

#include <Boost.h>

Public Member Functions

double beta () const
 
Hep3Vector boostVector () const
 
HepLorentzVector col1 () const
 
HepLorentzVector col2 () const
 
HepLorentzVector col3 () const
 
HepLorentzVector col4 () const
 
int compare (const HepBoost &b) const
 
void decompose (Hep3Vector &boost, HepAxisAngle &rotation) const
 
void decompose (HepAxisAngle &rotation, Hep3Vector &boost) const
 
void decompose (HepBoost &boost, HepRotation &rotation) const
 
void decompose (HepRotation &rotation, HepBoost &boost) const
 
Hep3Vector direction () const
 
double distance2 (const HepBoost &b) const
 
double distance2 (const HepBoostX &bx) const
 
double distance2 (const HepBoostY &by) const
 
double distance2 (const HepBoostZ &bz) const
 
double distance2 (const HepLorentzRotation &lt) const
 
double distance2 (const HepRotation &r) const
 
double gamma () const
 
Hep3Vector getDirection () const
 
 HepBoost ()
 
 HepBoost (const Hep3Vector &boost)
 
 HepBoost (const HepBoost &m)
 
 HepBoost (const HepBoostX &boost)
 
 HepBoost (const HepBoostY &boost)
 
 HepBoost (const HepBoostZ &boost)
 
 HepBoost (const HepRep4x4Symmetric &m)
 
 HepBoost (double betaX, double betaY, double betaZ)
 
 HepBoost (Hep3Vector direction, double beta)
 
 HepBoost (HepBoost &&m)=default
 
double howNear (const HepBoost &b) const
 
double howNear (const HepLorentzRotation &lt) const
 
double howNear (const HepRotation &r) const
 
HepBoost inverse () const
 
HepBoostinvert ()
 
bool isIdentity () const
 
bool isNear (const HepBoost &b, double epsilon=Hep4RotationInterface::tolerance) const
 
bool isNear (const HepLorentzRotation &lt, double epsilon=Hep4RotationInterface::tolerance) const
 
bool isNear (const HepRotation &r, double epsilon=Hep4RotationInterface::tolerance) const
 
double norm2 () const
 
bool operator!= (const HepBoost &b) const
 
HepLorentzVector operator() (const HepLorentzVector &p) const
 
HepLorentzRotation operator* (const HepBoost &b) const
 
HepLorentzRotation operator* (const HepLorentzRotation &lt) const
 
HepLorentzVector operator* (const HepLorentzVector &p) const
 
HepLorentzRotation operator* (const HepRotation &r) const
 
bool operator< (const HepBoost &b) const
 
bool operator<= (const HepBoost &b) const
 
HepBoostoperator= (const HepBoost &m)
 
HepBoostoperator= (HepBoost &&m)=default
 
bool operator== (const HepBoost &b) const
 
bool operator> (const HepBoost &b) const
 
bool operator>= (const HepBoost &b) const
 
std::ostream & print (std::ostream &os) const
 
void rectify ()
 
HepRep4x4 rep4x4 () const
 
HepRep4x4Symmetric rep4x4Symmetric () const
 
HepLorentzVector row1 () const
 
HepLorentzVector row2 () const
 
HepLorentzVector row3 () const
 
HepLorentzVector row4 () const
 
HepBoostset (const Hep3Vector &boost)
 
HepBoostset (const HepBoostX &boost)
 
HepBoostset (const HepBoostY &boost)
 
HepBoostset (const HepBoostZ &boost)
 
HepBoostset (const HepRep4x4Symmetric &m)
 
HepBoostset (double betaX, double betaY, double betaZ)
 
HepBoostset (Hep3Vector direction, double beta)
 
double tt () const
 
double tx () const
 
double ty () const
 
double tz () const
 
double xt () const
 
double xx () const
 
double xy () const
 
double xz () const
 
double yt () const
 
double yx () const
 
double yy () const
 
double yz () const
 
double zt () const
 
double zx () const
 
double zy () const
 
double zz () const
 

Static Public Member Functions

static double getTolerance ()
 
static double setTolerance (double tol)
 

Protected Member Functions

 HepBoost (double xx, double xy, double xz, double xt, double yy, double yz, double yt, double zz, double zt, double tt)
 
HepLorentzRotation matrixMultiplication (const HepRep4x4 &m) const
 
HepLorentzRotation matrixMultiplication (const HepRep4x4Symmetric &m) const
 
void setBoost (double bx, double by, double bz)
 
HepLorentzVector vectorMultiplication (const HepLorentzVector &w) const
 

Protected Attributes

HepRep4x4Symmetric rep_
 

Friends

HepBoost inverseOf (const HepBoost &lt)
 

Detailed Description

Author

Definition at line 38 of file Boost.h.

Constructor & Destructor Documentation

◆ HepBoost() [1/11]

CLHEP::HepBoost::HepBoost ( )
inline

Referenced by decompose().

◆ HepBoost() [2/11]

CLHEP::HepBoost::HepBoost ( const HepBoost m)
inline

◆ HepBoost() [3/11]

CLHEP::HepBoost::HepBoost ( HepBoost &&  m)
inlinedefault

◆ HepBoost() [4/11]

CLHEP::HepBoost::HepBoost ( double  betaX,
double  betaY,
double  betaZ 
)
inline

◆ HepBoost() [5/11]

CLHEP::HepBoost::HepBoost ( const HepRep4x4Symmetric m)
inline

◆ HepBoost() [6/11]

CLHEP::HepBoost::HepBoost ( Hep3Vector  direction,
double  beta 
)
inline

◆ HepBoost() [7/11]

CLHEP::HepBoost::HepBoost ( const Hep3Vector boost)
inline

◆ HepBoost() [8/11]

CLHEP::HepBoost::HepBoost ( const HepBoostX boost)
inline

◆ HepBoost() [9/11]

CLHEP::HepBoost::HepBoost ( const HepBoostY boost)
inline

◆ HepBoost() [10/11]

CLHEP::HepBoost::HepBoost ( const HepBoostZ boost)
inline

◆ HepBoost() [11/11]

CLHEP::HepBoost::HepBoost ( double  xx,
double  xy,
double  xz,
double  xt,
double  yy,
double  yz,
double  yt,
double  zz,
double  zt,
double  tt 
)
inlineprotected

Member Function Documentation

◆ beta()

double CLHEP::HepBoost::beta ( ) const
inline

Referenced by print().

◆ boostVector()

Hep3Vector CLHEP::HepBoost::boostVector ( ) const
inline

◆ col1()

HepLorentzVector CLHEP::HepBoost::col1 ( ) const
inline

◆ col2()

HepLorentzVector CLHEP::HepBoost::col2 ( ) const
inline

◆ col3()

HepLorentzVector CLHEP::HepBoost::col3 ( ) const
inline

◆ col4()

HepLorentzVector CLHEP::HepBoost::col4 ( ) const
inline

◆ compare()

int CLHEP::HepBoost::compare ( const HepBoost b) const
inline

◆ decompose() [1/4]

void CLHEP::HepBoost::decompose ( Hep3Vector boost,
HepAxisAngle rotation 
) const

Definition at line 87 of file Boost.cc.

87 {
88 rotation = HepAxisAngle();
89 boost = boostVector();
90}
Hep3Vector boostVector() const

References boostVector().

◆ decompose() [2/4]

void CLHEP::HepBoost::decompose ( HepAxisAngle rotation,
Hep3Vector boost 
) const

Definition at line 75 of file Boost.cc.

75 {
76 rotation = HepAxisAngle();
77 boost = boostVector();
78}

References boostVector().

◆ decompose() [3/4]

void CLHEP::HepBoost::decompose ( HepBoost boost,
HepRotation rotation 
) const

Definition at line 80 of file Boost.cc.

80 {
81 HepAxisAngle vdelta = HepAxisAngle();
82 rotation = HepRotation(vdelta);
83 Hep3Vector bbeta = boostVector();
84 boost = HepBoost(bbeta);
85}

References boostVector(), and HepBoost().

◆ decompose() [4/4]

void CLHEP::HepBoost::decompose ( HepRotation rotation,
HepBoost boost 
) const

Definition at line 68 of file Boost.cc.

68 {
69 HepAxisAngle vdelta = HepAxisAngle();
70 rotation = HepRotation(vdelta);
71 Hep3Vector bbeta = boostVector();
72 boost = HepBoost(bbeta);
73}

References boostVector(), and HepBoost().

◆ direction()

Hep3Vector CLHEP::HepBoost::direction ( ) const
inline

◆ distance2() [1/6]

double CLHEP::HepBoost::distance2 ( const HepBoost b) const
inline

◆ distance2() [2/6]

double CLHEP::HepBoost::distance2 ( const HepBoostX bx) const
inline

◆ distance2() [3/6]

double CLHEP::HepBoost::distance2 ( const HepBoostY by) const
inline

◆ distance2() [4/6]

double CLHEP::HepBoost::distance2 ( const HepBoostZ bz) const
inline

◆ distance2() [5/6]

double CLHEP::HepBoost::distance2 ( const HepLorentzRotation lt) const

Definition at line 100 of file Boost.cc.

100 {
101 HepBoost b1;
102 HepRotation r1;
103 lt.decompose(b1,r1);
104 double db2 = distance2(b1);
105 double dr2 = r1.norm2();
106 return (db2 + dr2);
107}
double distance2(const HepBoost &b) const

References CLHEP::HepLorentzRotation::decompose(), distance2(), and CLHEP::HepRotation::norm2().

◆ distance2() [6/6]

double CLHEP::HepBoost::distance2 ( const HepRotation r) const

Definition at line 94 of file Boost.cc.

94 {
95 double db2 = norm2();
96 double dr2 = r.norm2();
97 return (db2 + dr2);
98}
double norm2() const
Definition: Boost.cc:137

References norm2(), and CLHEP::HepRotation::norm2().

◆ gamma()

double CLHEP::HepBoost::gamma ( ) const
inline

Referenced by print().

◆ getDirection()

Hep3Vector CLHEP::HepBoost::getDirection ( ) const
inline

◆ getTolerance()

static double CLHEP::HepBoost::getTolerance ( )
inlinestatic

◆ howNear() [1/3]

double CLHEP::HepBoost::howNear ( const HepBoost b) const
inline

◆ howNear() [2/3]

double CLHEP::HepBoost::howNear ( const HepLorentzRotation lt) const

Definition at line 113 of file Boost.cc.

113 {
114 return std::sqrt(distance2(lt));
115}

References distance2().

◆ howNear() [3/3]

double CLHEP::HepBoost::howNear ( const HepRotation r) const

Definition at line 109 of file Boost.cc.

109 {
110 return std::sqrt(distance2(r));
111}

References distance2().

◆ inverse()

HepBoost CLHEP::HepBoost::inverse ( ) const
inline

◆ invert()

HepBoost & CLHEP::HepBoost::invert ( )
inline

◆ isIdentity()

bool CLHEP::HepBoost::isIdentity ( ) const
inline

◆ isNear() [1/3]

bool CLHEP::HepBoost::isNear ( const HepBoost b,
double  epsilon = Hep4RotationInterface::tolerance 
) const
inline

◆ isNear() [2/3]

bool CLHEP::HepBoost::isNear ( const HepLorentzRotation lt,
double  epsilon = Hep4RotationInterface::tolerance 
) const

Definition at line 124 of file Boost.cc.

125 {
126 HepBoost b1;
127 HepRotation r1;
128 double db2 = distance2(b1);
129 lt.decompose(b1,r1);
130 if (db2 > epsilon*epsilon) return false;
131 double dr2 = r1.norm2();
132 return (db2 + dr2);
133}
G4double epsilon(G4double density, G4double temperature)

References CLHEP::HepLorentzRotation::decompose(), distance2(), epsilon(), and CLHEP::HepRotation::norm2().

◆ isNear() [3/3]

bool CLHEP::HepBoost::isNear ( const HepRotation r,
double  epsilon = Hep4RotationInterface::tolerance 
) const

Definition at line 117 of file Boost.cc.

117 {
118 double db2 = norm2();
119 if (db2 > epsilon*epsilon) return false;
120 double dr2 = r.norm2();
121 return (db2+dr2 <= epsilon*epsilon);
122}

References epsilon(), norm2(), and CLHEP::HepRotation::norm2().

◆ matrixMultiplication() [1/2]

HepLorentzRotation CLHEP::HepBoost::matrixMultiplication ( const HepRep4x4 m) const
protected

Definition at line 179 of file Boost.cc.

179 {
180 HepRep4x4Symmetric r = rep4x4Symmetric();
181 return HepLorentzRotation( HepRep4x4 (
182 r.xx_*m1.xx_ + r.xy_*m1.yx_ + r.xz_*m1.zx_ + r.xt_*m1.tx_,
183 r.xx_*m1.xy_ + r.xy_*m1.yy_ + r.xz_*m1.zy_ + r.xt_*m1.ty_,
184 r.xx_*m1.xz_ + r.xy_*m1.yz_ + r.xz_*m1.zz_ + r.xt_*m1.tz_,
185 r.xx_*m1.xt_ + r.xy_*m1.yt_ + r.xz_*m1.zt_ + r.xt_*m1.tt_,
186
187 r.xy_*m1.xx_ + r.yy_*m1.yx_ + r.yz_*m1.zx_ + r.yt_*m1.tx_,
188 r.xy_*m1.xy_ + r.yy_*m1.yy_ + r.yz_*m1.zy_ + r.yt_*m1.ty_,
189 r.xy_*m1.xz_ + r.yy_*m1.yz_ + r.yz_*m1.zz_ + r.yt_*m1.tz_,
190 r.xy_*m1.xt_ + r.yy_*m1.yt_ + r.yz_*m1.zt_ + r.yt_*m1.tt_,
191
192 r.xz_*m1.xx_ + r.yz_*m1.yx_ + r.zz_*m1.zx_ + r.zt_*m1.tx_,
193 r.xz_*m1.xy_ + r.yz_*m1.yy_ + r.zz_*m1.zy_ + r.zt_*m1.ty_,
194 r.xz_*m1.xz_ + r.yz_*m1.yz_ + r.zz_*m1.zz_ + r.zt_*m1.tz_,
195 r.xz_*m1.xt_ + r.yz_*m1.yt_ + r.zz_*m1.zt_ + r.zt_*m1.tt_,
196
197 r.xt_*m1.xx_ + r.yt_*m1.yx_ + r.zt_*m1.zx_ + r.tt_*m1.tx_,
198 r.xt_*m1.xy_ + r.yt_*m1.yy_ + r.zt_*m1.zy_ + r.tt_*m1.ty_,
199 r.xt_*m1.xz_ + r.yt_*m1.yz_ + r.zt_*m1.zz_ + r.tt_*m1.tz_,
200 r.xt_*m1.xt_ + r.yt_*m1.yt_ + r.zt_*m1.zt_ + r.tt_*m1.tt_) );
201}
HepRep4x4Symmetric rep4x4Symmetric() const

References rep4x4Symmetric(), CLHEP::HepRep4x4::tt_, CLHEP::HepRep4x4Symmetric::tt_, CLHEP::HepRep4x4::tx_, CLHEP::HepRep4x4::ty_, CLHEP::HepRep4x4::tz_, CLHEP::HepRep4x4::xt_, CLHEP::HepRep4x4Symmetric::xt_, CLHEP::HepRep4x4::xx_, CLHEP::HepRep4x4Symmetric::xx_, CLHEP::HepRep4x4::xy_, CLHEP::HepRep4x4Symmetric::xy_, CLHEP::HepRep4x4::xz_, CLHEP::HepRep4x4Symmetric::xz_, CLHEP::HepRep4x4::yt_, CLHEP::HepRep4x4Symmetric::yt_, CLHEP::HepRep4x4::yx_, CLHEP::HepRep4x4::yy_, CLHEP::HepRep4x4Symmetric::yy_, CLHEP::HepRep4x4::yz_, CLHEP::HepRep4x4Symmetric::yz_, CLHEP::HepRep4x4::zt_, CLHEP::HepRep4x4Symmetric::zt_, CLHEP::HepRep4x4::zx_, CLHEP::HepRep4x4::zy_, CLHEP::HepRep4x4::zz_, and CLHEP::HepRep4x4Symmetric::zz_.

Referenced by operator*().

◆ matrixMultiplication() [2/2]

HepLorentzRotation CLHEP::HepBoost::matrixMultiplication ( const HepRep4x4Symmetric m) const
protected

Definition at line 204 of file Boost.cc.

204 {
205 HepRep4x4Symmetric r = rep4x4Symmetric();
206 return HepLorentzRotation( HepRep4x4 (
207 r.xx_*m1.xx_ + r.xy_*m1.xy_ + r.xz_*m1.xz_ + r.xt_*m1.xt_,
208 r.xx_*m1.xy_ + r.xy_*m1.yy_ + r.xz_*m1.yz_ + r.xt_*m1.yt_,
209 r.xx_*m1.xz_ + r.xy_*m1.yz_ + r.xz_*m1.zz_ + r.xt_*m1.zt_,
210 r.xx_*m1.xt_ + r.xy_*m1.yt_ + r.xz_*m1.zt_ + r.xt_*m1.tt_,
211
212 r.xy_*m1.xx_ + r.yy_*m1.xy_ + r.yz_*m1.xz_ + r.yt_*m1.xt_,
213 r.xy_*m1.xy_ + r.yy_*m1.yy_ + r.yz_*m1.yz_ + r.yt_*m1.yt_,
214 r.xy_*m1.xz_ + r.yy_*m1.yz_ + r.yz_*m1.zz_ + r.yt_*m1.zt_,
215 r.xy_*m1.xt_ + r.yy_*m1.yt_ + r.yz_*m1.zt_ + r.yt_*m1.tt_,
216
217 r.xz_*m1.xx_ + r.yz_*m1.xy_ + r.zz_*m1.xz_ + r.zt_*m1.xt_,
218 r.xz_*m1.xy_ + r.yz_*m1.yy_ + r.zz_*m1.yz_ + r.zt_*m1.yt_,
219 r.xz_*m1.xz_ + r.yz_*m1.yz_ + r.zz_*m1.zz_ + r.zt_*m1.zt_,
220 r.xz_*m1.xt_ + r.yz_*m1.yt_ + r.zz_*m1.zt_ + r.zt_*m1.tt_,
221
222 r.xt_*m1.xx_ + r.yt_*m1.xy_ + r.zt_*m1.xz_ + r.tt_*m1.xt_,
223 r.xt_*m1.xy_ + r.yt_*m1.yy_ + r.zt_*m1.yz_ + r.tt_*m1.yt_,
224 r.xt_*m1.xz_ + r.yt_*m1.yz_ + r.zt_*m1.zz_ + r.tt_*m1.zt_,
225 r.xt_*m1.xt_ + r.yt_*m1.yt_ + r.zt_*m1.zt_ + r.tt_*m1.tt_) );
226}

References rep4x4Symmetric(), CLHEP::HepRep4x4Symmetric::tt_, CLHEP::HepRep4x4Symmetric::xt_, CLHEP::HepRep4x4Symmetric::xx_, CLHEP::HepRep4x4Symmetric::xy_, CLHEP::HepRep4x4Symmetric::xz_, CLHEP::HepRep4x4Symmetric::yt_, CLHEP::HepRep4x4Symmetric::yy_, CLHEP::HepRep4x4Symmetric::yz_, CLHEP::HepRep4x4Symmetric::zt_, and CLHEP::HepRep4x4Symmetric::zz_.

◆ norm2()

double CLHEP::HepBoost::norm2 ( ) const

◆ operator!=()

bool CLHEP::HepBoost::operator!= ( const HepBoost b) const
inline

◆ operator()()

HepLorentzVector CLHEP::HepBoost::operator() ( const HepLorentzVector p) const
inline

◆ operator*() [1/4]

HepLorentzRotation CLHEP::HepBoost::operator* ( const HepBoost b) const

Definition at line 234 of file Boost.cc.

234 {
235 return matrixMultiplication(b.rep_);
236}
HepLorentzRotation matrixMultiplication(const HepRep4x4 &m) const
Definition: Boost.cc:179

References matrixMultiplication(), and rep_.

◆ operator*() [2/4]

HepLorentzRotation CLHEP::HepBoost::operator* ( const HepLorentzRotation lt) const

Definition at line 229 of file Boost.cc.

229 {
230 return matrixMultiplication(lt.rep4x4());
231}

References matrixMultiplication(), and CLHEP::HepLorentzRotation::rep4x4().

◆ operator*() [3/4]

HepLorentzVector CLHEP::HepBoost::operator* ( const HepLorentzVector p) const
inline

◆ operator*() [4/4]

HepLorentzRotation CLHEP::HepBoost::operator* ( const HepRotation r) const

Definition at line 239 of file Boost.cc.

239 {
240 return matrixMultiplication(r.rep4x4());
241}

References matrixMultiplication(), and CLHEP::HepRotation::rep4x4().

◆ operator<()

bool CLHEP::HepBoost::operator< ( const HepBoost b) const
inline

◆ operator<=()

bool CLHEP::HepBoost::operator<= ( const HepBoost b) const
inline

◆ operator=() [1/2]

HepBoost & CLHEP::HepBoost::operator= ( const HepBoost m)
inline

◆ operator=() [2/2]

HepBoost & CLHEP::HepBoost::operator= ( HepBoost &&  m)
inlinedefault

◆ operator==()

bool CLHEP::HepBoost::operator== ( const HepBoost b) const
inline

◆ operator>()

bool CLHEP::HepBoost::operator> ( const HepBoost b) const
inline

◆ operator>=()

bool CLHEP::HepBoost::operator>= ( const HepBoost b) const
inline

◆ print()

std::ostream & CLHEP::HepBoost::print ( std::ostream &  os) const

Definition at line 245 of file Boost.cc.

245 {
246 if ( rep_.tt_ <= 1 ) {
247 os << "Lorentz Boost( IDENTITY )";
248 } else {
249 double norm = boostVector().mag();
250 os << "\nLorentz Boost " << boostVector()/norm <<
251 "\n{beta = " << beta() << " gamma = " << gamma() << "}\n";
252 }
253 return os;
254}
double mag() const
double beta() const
double gamma() const

References beta(), boostVector(), gamma(), CLHEP::Hep3Vector::mag(), rep_, and CLHEP::HepRep4x4Symmetric::tt_.

◆ rectify()

void CLHEP::HepBoost::rectify ( )

Definition at line 144 of file Boost.cc.

144 {
145 // Assuming the representation of this is close to a true pure boost,
146 // but may have drifted due to round-off error from many operations,
147 // this forms an "exact" pure boost matrix for the LT again.
148
149 // The natural way to do this is to use the t column as a boost and set
150 // based on that boost vector.
151
152 // There is perhaps danger that this boost vector will appear equal to or
153 // greater than a unit vector; the best we can do for such a case is use
154 // a boost in that direction but rescaled to just less than one.
155
156 // There is in principle no way that gamma could have become negative,
157 // but if that happens, we ZMthrow and (if continuing) just rescale, which
158 // will change the sign of the last column when computing the boost.
159
160 double gam = tt();
161 if (gam <= 0) { // 4/12/01 mf
162 std::cerr << "HepBoost::rectify() - "
163 << "Attempt to rectify a boost with non-positive gamma." << std::endl;
164 if (gam==0) return; // NaN-proofing
165 }
166 Hep3Vector boost (xt(), yt(), zt());
167 boost /= tt();
168 if ( boost.mag2() >= 1 ) { // NaN-proofing:
169 boost /= ( boost.mag() * ( 1.0 + 1.0e-16 ) ); // used to just check > 1
170 }
171 set ( boost );
172}
HepBoost & set(double betaX, double betaY, double betaZ)
Definition: Boost.cc:20
double yt() const
double xt() const
double tt() const
double zt() const

References G4InuclParticleNames::gam, CLHEP::Hep3Vector::mag(), CLHEP::Hep3Vector::mag2(), set(), tt(), xt(), yt(), and zt().

◆ rep4x4()

HepRep4x4 CLHEP::HepBoost::rep4x4 ( ) const
inline

◆ rep4x4Symmetric()

HepRep4x4Symmetric CLHEP::HepBoost::rep4x4Symmetric ( ) const
inline

Referenced by matrixMultiplication().

◆ row1()

HepLorentzVector CLHEP::HepBoost::row1 ( ) const
inline

◆ row2()

HepLorentzVector CLHEP::HepBoost::row2 ( ) const
inline

◆ row3()

HepLorentzVector CLHEP::HepBoost::row3 ( ) const
inline

◆ row4()

HepLorentzVector CLHEP::HepBoost::row4 ( ) const
inline

◆ set() [1/7]

HepBoost & CLHEP::HepBoost::set ( const Hep3Vector boost)

Definition at line 60 of file Boost.cc.

60 {
61 return set (bboost.x(), bboost.y(), bboost.z());
62}

References set(), CLHEP::Hep3Vector::x(), CLHEP::Hep3Vector::y(), and CLHEP::Hep3Vector::z().

◆ set() [2/7]

HepBoost & CLHEP::HepBoost::set ( const HepBoostX boost)
inline

◆ set() [3/7]

HepBoost & CLHEP::HepBoost::set ( const HepBoostY boost)
inline

◆ set() [4/7]

HepBoost & CLHEP::HepBoost::set ( const HepBoostZ boost)
inline

◆ set() [5/7]

HepBoost & CLHEP::HepBoost::set ( const HepRep4x4Symmetric m)

Definition at line 41 of file Boost.cc.

41 {
42 rep_ = m1;
43 return *this;
44}

References rep_.

◆ set() [6/7]

HepBoost & CLHEP::HepBoost::set ( double  betaX,
double  betaY,
double  betaZ 
)

Definition at line 20 of file Boost.cc.

20 {
21 double bp2 = bx*bx + by*by + bz*bz;
22// if (bp2 >= 1) {
23// std::cerr << "HepBoost::set() - "
24// << "Boost Vector supplied to set HepBoost represents speed >= c." << std::endl;
25// }
26 double ggamma = 1.0 / std::sqrt(1.0 - bp2);
27 double bgamma = ggamma * ggamma / (1.0 + ggamma);
28 rep_.xx_ = 1.0 + bgamma * bx * bx;
29 rep_.yy_ = 1.0 + bgamma * by * by;
30 rep_.zz_ = 1.0 + bgamma * bz * bz;
31 rep_.xy_ = bgamma * bx * by;
32 rep_.xz_ = bgamma * bx * bz;
33 rep_.yz_ = bgamma * by * bz;
34 rep_.xt_ = ggamma * bx;
35 rep_.yt_ = ggamma * by;
36 rep_.zt_ = ggamma * bz;
37 rep_.tt_ = ggamma;
38 return *this;
39}

References rep_, CLHEP::HepRep4x4Symmetric::tt_, CLHEP::HepRep4x4Symmetric::xt_, CLHEP::HepRep4x4Symmetric::xx_, CLHEP::HepRep4x4Symmetric::xy_, CLHEP::HepRep4x4Symmetric::xz_, CLHEP::HepRep4x4Symmetric::yt_, CLHEP::HepRep4x4Symmetric::yy_, CLHEP::HepRep4x4Symmetric::yz_, CLHEP::HepRep4x4Symmetric::zt_, and CLHEP::HepRep4x4Symmetric::zz_.

Referenced by CLHEP::HepLorentzRotation::decompose(), CLHEP::HepRotationX::decompose(), CLHEP::HepRotationY::decompose(), CLHEP::HepRotationZ::decompose(), rectify(), and set().

◆ set() [7/7]

HepBoost & CLHEP::HepBoost::set ( Hep3Vector  direction,
double  beta 
)

Definition at line 46 of file Boost.cc.

46 {
47 double length = ddirection.mag();
48 if (length <= 0) { // Nan-proofing
49 std::cerr << "HepBoost::set() - "
50 << "Direction supplied to set HepBoost is zero." << std::endl;
51 set (0,0,0);
52 return *this;
53 }
54 set(bbeta*ddirection.x()/length,
55 bbeta*ddirection.y()/length,
56 bbeta*ddirection.z()/length);
57 return *this;
58}

References CLHEP::Hep3Vector::mag(), set(), CLHEP::Hep3Vector::x(), CLHEP::Hep3Vector::y(), and CLHEP::Hep3Vector::z().

◆ setBoost()

void CLHEP::HepBoost::setBoost ( double  bx,
double  by,
double  bz 
)
inlineprotected

◆ setTolerance()

static double CLHEP::HepBoost::setTolerance ( double  tol)
inlinestatic

◆ tt()

double CLHEP::HepBoost::tt ( ) const
inline

Referenced by rectify().

◆ tx()

double CLHEP::HepBoost::tx ( ) const
inline

◆ ty()

double CLHEP::HepBoost::ty ( ) const
inline

◆ tz()

double CLHEP::HepBoost::tz ( ) const
inline

◆ vectorMultiplication()

HepLorentzVector CLHEP::HepBoost::vectorMultiplication ( const HepLorentzVector w) const
inlineprotected

◆ xt()

double CLHEP::HepBoost::xt ( ) const
inline

Referenced by rectify().

◆ xx()

double CLHEP::HepBoost::xx ( ) const
inline

◆ xy()

double CLHEP::HepBoost::xy ( ) const
inline

◆ xz()

double CLHEP::HepBoost::xz ( ) const
inline

◆ yt()

double CLHEP::HepBoost::yt ( ) const
inline

Referenced by rectify().

◆ yx()

double CLHEP::HepBoost::yx ( ) const
inline

◆ yy()

double CLHEP::HepBoost::yy ( ) const
inline

◆ yz()

double CLHEP::HepBoost::yz ( ) const
inline

◆ zt()

double CLHEP::HepBoost::zt ( ) const
inline

Referenced by rectify().

◆ zx()

double CLHEP::HepBoost::zx ( ) const
inline

◆ zy()

double CLHEP::HepBoost::zy ( ) const
inline

◆ zz()

double CLHEP::HepBoost::zz ( ) const
inline

Friends And Related Function Documentation

◆ inverseOf

HepBoost inverseOf ( const HepBoost lt)
friend

Field Documentation

◆ rep_

HepRep4x4Symmetric CLHEP::HepBoost::rep_
protected

Definition at line 233 of file Boost.h.

Referenced by norm2(), operator*(), print(), and set().


The documentation for this class was generated from the following files: