Geant4 11.2.2
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
HepGeom::Vector3D< T > Class Template Reference

#include <Vector3D.h>

+ Inheritance diagram for HepGeom::Vector3D< T >:

Related Symbols

(Note that these are not member symbols.)

Vector3D< float > operator* (const Transform3D &m, const Vector3D< float > &v)
 
Vector3D< double > operator* (const Transform3D &m, const Vector3D< double > &v)
 

Additional Inherited Members

- Public Types inherited from HepGeom::BasicVector3D< T >
enum  {
  X = 0 , Y = 1 , Z = 2 , NUM_COORDINATES = 3 ,
  SIZE = NUM_COORDINATES
}
 
- Public Member Functions inherited from HepGeom::BasicVector3D< T >
 BasicVector3D (T x1, T y1, T z1)
 
 BasicVector3D (const BasicVector3D< T > &)=default
 
template<typename U = T, typename = typename std::enable_if<!std::is_same<U,float>::value >::type>
 BasicVector3D (const BasicVector3D< float > &v)
 
 BasicVector3D (BasicVector3D< T > &&)=default
 
virtual ~BasicVector3D ()=default
 
 operator T* ()
 
 operator const T * () const
 
 operator CLHEP::Hep3Vector () const
 
BasicVector3D< T > & operator= (const BasicVector3D< T > &)=default
 
BasicVector3D< T > & operator= (BasicVector3D< T > &&)=default
 
BasicVector3D< T > & operator+= (const BasicVector3D< T > &v)
 
BasicVector3D< T > & operator-= (const BasicVector3D< T > &v)
 
BasicVector3D< T > & operator*= (double a)
 
BasicVector3D< T > & operator/= (double a)
 
operator() (int i) const
 
operator[] (int i) const
 
T & operator() (int i)
 
T & operator[] (int i)
 
x () const
 
y () const
 
z () const
 
void setX (T a)
 
void setY (T a)
 
void setZ (T a)
 
void set (T x1, T y1, T z1)
 
perp2 () const
 
perp () const
 
rho () const
 
void setPerp (T rh)
 
mag2 () const
 
mag () const
 
r () const
 
phi () const
 
theta () const
 
cosTheta () const
 
getR () const
 
getPhi () const
 
getTheta () const
 
void setMag (T ma)
 
void setR (T ma)
 
void setPhi (T ph)
 
void setTheta (T th)
 
pseudoRapidity () const
 
eta () const
 
getEta () const
 
void setEta (T a)
 
dot (const BasicVector3D< T > &v) const
 
BasicVector3D< T > cross (const BasicVector3D< T > &v) const
 
perp2 (const BasicVector3D< T > &v) const
 
perp (const BasicVector3D< T > &v) const
 
angle (const BasicVector3D< T > &v) const
 
BasicVector3D< T > unit () const
 
BasicVector3D< T > orthogonal () const
 
BasicVector3D< T > & rotateX (T a)
 
BasicVector3D< T > & rotateY (T a)
 
BasicVector3D< T > & rotateZ (T a)
 
BasicVector3D< T > & rotate (T a, const BasicVector3D< T > &v)
 
float pseudoRapidity () const
 
void setEta (float a)
 
float angle (const BasicVector3D< float > &v) const
 
BasicVector3D< float > & rotateX (float a)
 
BasicVector3D< float > & rotateY (float a)
 
BasicVector3D< float > & rotateZ (float a)
 
BasicVector3D< float > & rotate (float a, const BasicVector3D< float > &v)
 
double pseudoRapidity () const
 
void setEta (double a)
 
double angle (const BasicVector3D< double > &v) const
 
BasicVector3D< double > & rotateX (double a)
 
BasicVector3D< double > & rotateY (double a)
 
BasicVector3D< double > & rotateZ (double a)
 
BasicVector3D< double > & rotate (double a, const BasicVector3D< double > &v)
 
- Protected Member Functions inherited from HepGeom::BasicVector3D< T >
 BasicVector3D ()
 
- Protected Attributes inherited from HepGeom::BasicVector3D< T >
v_ [3]
 

Detailed Description

template<class T>
class HepGeom::Vector3D< T >

Geometrical 3D Vector. This is just a declaration of the class needed to define specializations Vector3D<float> and Vector3D<double>.

Author
Evgeni Chernyaev Evgue.nosp@m.ni.T.nosp@m.chern.nosp@m.iaev.nosp@m.@cern.nosp@m..ch

Definition at line 33 of file Vector3D.h.

Friends And Related Symbol Documentation

◆ operator*() [1/2]

template<class T >
Vector3D< double > operator* ( const Transform3D & m,
const Vector3D< double > & v )
related

Transformation of Vector<double> by Transform3D.

Definition at line 40 of file Vector3D.cc.

40 {
41 double vx = v.x(), vy = v.y(), vz = v.z();
42 return Vector3D<double>
43 (m.xx()*vx + m.xy()*vy + m.xz()*vz,
44 m.yx()*vx + m.yy()*vy + m.yz()*vz,
45 m.zx()*vx + m.zy()*vy + m.zz()*vz);
46 }

◆ operator*() [2/2]

template<class T >
Vector3D< float > operator* ( const Transform3D & m,
const Vector3D< float > & v )
related

Transformation of Vector<float> by Transform3D.

Definition at line 20 of file Vector3D.cc.

20 {
21 double vx = v.x(), vy = v.y(), vz = v.z();
22 return Vector3D<float>
23 (m.xx()*vx + m.xy()*vy + m.xz()*vz,
24 m.yx()*vx + m.yy()*vy + m.yz()*vz,
25 m.zx()*vx + m.zy()*vy + m.zz()*vz);
26 }

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