Belle II Software development
ARICHGeoGlobalDisplacement Class Reference

Global displacement parameters for ARICH. More...

#include <ARICHGeoGlobalDisplacement.h>

Inheritance diagram for ARICHGeoGlobalDisplacement:
ARICHGeoBase

Public Member Functions

 ARICHGeoGlobalDisplacement ()
 Default constructor.
 
 ARICHGeoGlobalDisplacement (double x, double y, double z, double alpha, double beta, double gamma)
 Full constructor.
 
void setX (double x)
 Sets translation in x.
 
void setY (double y)
 Sets translation in y.
 
void setZ (double z)
 Sets translation in z.
 
void setAlpha (double alpha)
 Sets rotation around x.
 
void setBeta (double beta)
 Sets rotation around y.
 
void setGamma (double gamma)
 Sets rotation around z.
 
double getX () const
 Returns translation in x.
 
double getY () const
 Returns translation in y.
 
double getZ () const
 Returns translation in z.
 
double getAlpha () const
 Returns rotation angle around x.
 
double getBeta () const
 Returns rotation angle around y.
 
double getGamma () const
 Returns rotation angle around z.
 
void setName (const std::string &name)
 Sets object name.
 
const std::string & getName () const
 Returns object name.
 
virtual bool isConsistent () const
 Check for consistency of data members.
 
virtual void print (const std::string &title) const
 Print the content of the class.
 
virtual void printSurface (const GeoOpticalSurface &surface) const
 Print the content of optical surface.
 
virtual void printPlacement (double x, double y, double z, double rx, double ry, double rz) const
 Print volume positioning parameters.
 

Protected Member Functions

 ClassDef (ARICHGeoBase, 2)
 ClassDef.
 

Protected Attributes

std::string m_name
 geometry object name
 

Static Protected Attributes

static double s_unit = Unit::cm
 conversion unit for length
 
static std::string s_unitName
 conversion unit name
 

Private Member Functions

 ClassDef (ARICHGeoGlobalDisplacement, 1)
 ClassDef.
 

Private Attributes

float m_x = 0
 translation in x
 
float m_y = 0
 translation in y
 
float m_z = 0
 translation in z
 
float m_alpha = 0
 rotation angle around x
 
float m_beta = 0
 rotation angle around y
 
float m_gamma = 0
 rotation angle around z
 

Detailed Description

Global displacement parameters for ARICH.

Definition at line 22 of file ARICHGeoGlobalDisplacement.h.

Constructor & Destructor Documentation

◆ ARICHGeoGlobalDisplacement() [1/2]

Default constructor.

Definition at line 28 of file ARICHGeoGlobalDisplacement.h.

29 {}

◆ ARICHGeoGlobalDisplacement() [2/2]

ARICHGeoGlobalDisplacement ( double  x,
double  y,
double  z,
double  alpha,
double  beta,
double  gamma 
)
inline

Full constructor.

Parameters
xdisplacement in x
ydisplacement in y
zdisplacement in z
alpharotation angle around x
betarotation angle around y
gammarotation angle around z

Definition at line 40 of file ARICHGeoGlobalDisplacement.h.

41 :
42 m_x(x), m_y(y), m_z(z),
43 m_alpha(alpha), m_beta(beta), m_gamma(gamma)
44 {}

◆ ~ARICHGeoGlobalDisplacement()

Definition at line 46 of file ARICHGeoGlobalDisplacement.h.

47 {}

Member Function Documentation

◆ getAlpha()

double getAlpha ( ) const
inline

Returns rotation angle around x.

Returns
rotation angle

Definition at line 109 of file ARICHGeoGlobalDisplacement.h.

109{return m_alpha;}

◆ getBeta()

double getBeta ( ) const
inline

Returns rotation angle around y.

Returns
rotation angle

Definition at line 115 of file ARICHGeoGlobalDisplacement.h.

115{return m_beta;}

◆ getGamma()

double getGamma ( ) const
inline

Returns rotation angle around z.

Returns
rotation angle

Definition at line 121 of file ARICHGeoGlobalDisplacement.h.

121{return m_gamma;}

◆ getName()

const std::string & getName ( ) const
inlineinherited

Returns object name.

Returns
object name

Definition at line 49 of file ARICHGeoBase.h.

49{return m_name;}
std::string m_name
geometry object name
Definition: ARICHGeoBase.h:82

◆ getX()

double getX ( ) const
inline

Returns translation in x.

Returns
x coordinate

Definition at line 91 of file ARICHGeoGlobalDisplacement.h.

91{return m_x / s_unit;}
static double s_unit
conversion unit for length
Definition: ARICHGeoBase.h:83

◆ getY()

double getY ( ) const
inline

Returns translation in y.

Returns
y coordinate

Definition at line 97 of file ARICHGeoGlobalDisplacement.h.

97{return m_y / s_unit;}

◆ getZ()

double getZ ( ) const
inline

Returns translation in z.

Returns
z coordinate

Definition at line 103 of file ARICHGeoGlobalDisplacement.h.

103{return m_z / s_unit;}

◆ isConsistent()

virtual bool isConsistent ( ) const
inlinevirtualinherited

Check for consistency of data members.

Returns
true if values consistent (valid)

Reimplemented in ARICHGeoAerogelPlane, ARICHGeoDetectorPlane, ARICHGeoHAPD, ARICHGeoMasterVolume, ARICHGeoMirrors, ARICHGeoSupport, and ARICHPositionElement.

Definition at line 55 of file ARICHGeoBase.h.

55{return false;}

◆ print()

void print ( const std::string &  title) const
virtualinherited

◆ printPlacement()

void printPlacement ( double  x,
double  y,
double  z,
double  rx,
double  ry,
double  rz 
) const
virtualinherited

Print volume positioning parameters.

Parameters
xx position
yy position
zz position
rxrotation around x-axis
ryrotation around y-axis
rzrotation around z-axis

Definition at line 25 of file ARICHGeoBase.cc.

26{
27// cout << "Volume positioning information (inside local ARICH frame)" << endl;
28 cout << " Center position; x: " << x << " " << s_unitName << ", y: " << y << " " << s_unitName << ", z: " << z << " " << s_unitName
29 << endl;
30 cout << " Rotations; x-axis: " << rx << " y-axis: " << ry << " z-axis: " << rz << " (in rad)" << endl;
31}
static std::string s_unitName
conversion unit name
Definition: ARICHGeoBase.h:84

◆ printSurface()

void printSurface ( const GeoOpticalSurface surface) const
virtualinherited

Print the content of optical surface.

Parameters
surfaceoptical surface parameters

Definition at line 32 of file ARICHGeoBase.cc.

33{
34 cout << " Optical surface: ";
35 if (surface.getName().empty() and !surface.hasProperties()) {
36 cout << "not defined" << endl;
37 return;
38 }
39 cout << surface.getName();
40 cout << ", model: " << surface.getModel();
41 cout << ", finish: " << surface.getFinish();
42 cout << ", type: " << surface.getType();
43 cout << ", value: " << surface.getValue();
44 cout << endl;
45 if (surface.hasProperties()) {
46 for (const auto& property : surface.getProperties()) {
47 cout << " - property: ";
48 cout << property.getName() << " [";
49 for (const auto& value : property.getValues()) cout << value << ", ";
50 cout << "], @[";
51 for (const auto& value : property.getEnergies()) cout << value / Unit::eV << ", ";
52 cout << "] eV" << endl;
53 }
54 } else {
55 cout << " - properties: None" << endl;
56 }
57
58}
const std::string & getName() const
get name of the optical surface
int getFinish() const
get finish of the surface
const std::vector< GeoMaterialProperty > & getProperties() const
get all properties
double getValue() const
get value for the surface condition
int getType() const
get type of the surface
bool hasProperties() const
check if the material has at least one property
int getModel() const
get model for the surface
static const double eV
[electronvolt]
Definition: Unit.h:112

◆ setAlpha()

void setAlpha ( double  alpha)
inline

Sets rotation around x.

Parameters
alpharotation angle around x

Definition at line 71 of file ARICHGeoGlobalDisplacement.h.

71{m_alpha = alpha;}

◆ setBeta()

void setBeta ( double  beta)
inline

Sets rotation around y.

Parameters
betarotation angle around y

Definition at line 78 of file ARICHGeoGlobalDisplacement.h.

78{m_beta = beta;}

◆ setGamma()

void setGamma ( double  gamma)
inline

Sets rotation around z.

Parameters
gammarotation angle around z

Definition at line 85 of file ARICHGeoGlobalDisplacement.h.

85{m_gamma = gamma;}

◆ setName()

void setName ( const std::string &  name)
inlineinherited

Sets object name.

Parameters
nameobject name

Definition at line 43 of file ARICHGeoBase.h.

43{m_name = name;}

◆ setX()

void setX ( double  x)
inline

Sets translation in x.

Parameters
xtranslation in x

Definition at line 53 of file ARICHGeoGlobalDisplacement.h.

53{m_x = x;}

◆ setY()

void setY ( double  y)
inline

Sets translation in y.

Parameters
ytranslation in y

Definition at line 59 of file ARICHGeoGlobalDisplacement.h.

59{m_y = y;}

◆ setZ()

void setZ ( double  z)
inline

Sets translation in z.

Parameters
ztranslation in z

Definition at line 65 of file ARICHGeoGlobalDisplacement.h.

65{m_z = z;}

Member Data Documentation

◆ m_alpha

float m_alpha = 0
private

rotation angle around x

Definition at line 129 of file ARICHGeoGlobalDisplacement.h.

◆ m_beta

float m_beta = 0
private

rotation angle around y

Definition at line 130 of file ARICHGeoGlobalDisplacement.h.

◆ m_gamma

float m_gamma = 0
private

rotation angle around z

Definition at line 131 of file ARICHGeoGlobalDisplacement.h.

◆ m_name

std::string m_name
protectedinherited

geometry object name

Definition at line 82 of file ARICHGeoBase.h.

◆ m_x

float m_x = 0
private

translation in x

Definition at line 126 of file ARICHGeoGlobalDisplacement.h.

◆ m_y

float m_y = 0
private

translation in y

Definition at line 127 of file ARICHGeoGlobalDisplacement.h.

◆ m_z

float m_z = 0
private

translation in z

Definition at line 128 of file ARICHGeoGlobalDisplacement.h.

◆ s_unit

double s_unit = Unit::cm
staticprotectedinherited

conversion unit for length

Definition at line 83 of file ARICHGeoBase.h.

◆ s_unitName

std::string s_unitName
staticprotectedinherited

conversion unit name

Definition at line 84 of file ARICHGeoBase.h.


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