BOSS 7.0.2
BESIII Offline Software System
Loading...
Searching...
No Matches
InstallArea/include/MucGeoCreateAlg/MucGeoCreateAlg/MucEntity.h
Go to the documentation of this file.
1//------------------------------------------------------------------------------|
2// [File ]: MucEntity.h |
3// [Brief ]: Head file of MUC geometry entity class |
4// [Author]: Xie Yuguang, <[email protected]> |
5// [Date ]: May 22, 2005 |
6//------------------------------------------------------------------------------|
7
8#ifndef MUC_ENTITY_H
9#define MUC_ENTITY_H
10
11#include<iostream>
12
13//#include "CLHEP/Geometry/Vector3D.h"
14//#include "CLHEP/Geometry/Point3D.h"
15
16using namespace std;
17
19{
20 public:
21 MucEntity( int part, int segment, int layer );
22 MucEntity( int part, int segment, int layer, int id );
23 MucEntity( int part, int segment, int layer, int upDown, int id );
24 MucEntity( int part, int segment, int layer, int upDown, int rpcId, int id );
25 MucEntity( const MucEntity &other );
26 MucEntity &operator =( const MucEntity &other );
27 virtual ~MucEntity() ;
28
29 int GetPart();
30 int GetSegment();
31 int GetLayer();
32 int GetUpDown();
33 int GetRpcId();
34 int GetID();
35
36 double GetTheta();
37 double GetRin();
38 double GetRout();
39 double GetRc();
40 double GetThin();
41 double GetW();
42 double GetH();
43 double GetL();
44 double GetWu();
45 double GetWd();
46 double GetArea();
47
48 double GetLocOrgInBes( int i ); // 1: Bes_x, 2: Bes_y, 3, Bes_z
49 double GetObjRotToMot( int i ); // 1: Rot_x, 2: Rot_y, 3, Rot_z
50 double GetObjOrgInBes( int i ); // 1: Bes_x, 2: Bes_y, 3, Bes_z
51 double GetObjOrgInLoc( int i ); // 1: Pos_x, 2: Pos_y, 3, Pos_z
52
53 double* GetLocOrgInBes();
54 double* GetObjRotToMot();
55 double* GetObjOrgInLoc();
56 double* GetObjOrgInBes();
57
58 // coordinate transform function, from old to new,
59 // Rot_z is the direction angle of new x axis in old coordinate system
60 void TransBesToLoc( double LocCoord[], double BesCoord[], double LocOrgInBes[], double Rot_z );
61 void TransLocToBes( double LocCoord[], double BesCoord[], double LocOrgInBes[], double Rot_z );
62
63 protected:
64
65 virtual void Init(); // all geometry information initilization
66
67 virtual void SetTheta(); // set theta
68 virtual void SetRin(); // set r inner
69 virtual void SetRout(); // set r outer
70 virtual void SetRc(); // set r center
71 virtual void SetThin(); // set thickness
72 virtual void SetW(); // set width
73 virtual void SetH(); // set height
74 virtual void SetL(); // set stretching length
75 virtual void SetWu(); // set up width
76 virtual void SetWd(); // set down width
77 virtual void SetArea(); // set area of entity(mm^2)
78 virtual void SetLocOrgInBes(); // set x, y, z of local origin in BES coordinate system
79 virtual void SetObjRotToMot(); // set rotation angles of x, y, z axises of local coordinate system
80 // relative to BES
81 virtual void SetObjOrgInBes(); // set x, y and z of object origin in BES coordinate system
82 virtual void SetObjOrgInLoc(); // set x, y and z of object origin in local or
83 // temporary local coordinate system
84
85 virtual void SetAlignment( double dx, double dy, double dz); // set alignment
86
87 protected:
88 int m_Part; // part id
89 int m_Segment; // segment id
90 int m_Layer; // layer id
91 int m_UpDown; // up or down superlayer id, only valid for superlayer objects
92 int m_RpcId; // rpc id in up or down superlayer
93 int m_ID; // object id
94
95 double m_Theta; // barrel: inclination angle of R and Bes_X
96 // endcap: inclination angle of panel boudary and Bes_X
97
98 double m_Rin; // r of the inner surface relative to BES origin
99 double m_Rout; // r of the outer surface relative to BES origin
100 double m_Rc; // r of the center surface relative to BES orign
101 double m_Thin; // thickness of entity
102 double m_W; // width of cross section
103 double m_H; // height of cross section
104 double m_L; // stretching length of cross section
105 double m_Wu; // up width of trapezoid cross section
106 double m_Wd; // down width of trapezoid cross section
107 double m_Area; // area of entity,mm^2
108
109 double m_LocOrgInBes[3]; // x, y, z of the mother origin in BES coordinate system
110 // for panel, the mother is temporary local coordinate system
111 double m_ObjRotToMot[3]; // rotation angles of x, y, z axises of the object coordinate system
112 // relative to the mother
113 // only rotation angle relative to Bes_z axis is useful
114 // defined as the angle of local xy plane circling mother's z axis,
115 // not Euler angle
116 // for local or temparory local, the mother is BES, for panel,
117 // the mother is the local or temparory local
118 double m_ObjOrgInBes[3]; // x, y and z of object origin in BES coordinate system
119 double m_ObjOrgInLoc[3]; // x, y and z of object origin in its mother coordinate system
120 // for panel, the mother is temporary local coordinate system
121
122//-------------------------------------------------------------NOTE---------------------------------------------------------------
123// 1: There are four coordinate systems: BES(the world), local(the mother), temporary local(the temp, for many panels object)
124// and object, the posterior one is always located in the anterior one.
125// 2: If the local coordinate system of one entity is BES, m_MotOrgInBes is unuseful.
126// 3: According to the detector structure, the origin coordinates and rotation angles of geometry entities relative to BES
127// coordinate system can be calculated easily and conveniently, so these values will be initialized first in constructor.
128// 4: For objects having many panels, the id of integral object is -1, and the id of panel begins from 0 to panel number.
129// These objects must be added a temporary local coordinate system for locating the panels, the temporary local
130
131};
132
133#endif
134
double GetWu()
Definition: MucEntity.cxx:148
virtual void SetArea()
Definition: MucEntity.cxx:212
double GetW()
Definition: MucEntity.cxx:145
virtual void SetObjOrgInBes()
Definition: MucEntity.cxx:216
virtual void SetObjRotToMot()
Definition: MucEntity.cxx:215
double GetThin()
Definition: MucEntity.cxx:144
virtual void SetWd()
Definition: MucEntity.cxx:209
MucEntity & operator=(const MucEntity &other)
Definition: MucEntity.cxx:92
virtual ~MucEntity()
Definition: MucEntity.cxx:125
virtual void SetW()
Definition: MucEntity.cxx:207
virtual void SetL()
Definition: MucEntity.cxx:211
double GetWd()
Definition: MucEntity.cxx:149
double GetH()
Definition: MucEntity.cxx:146
virtual void SetLocOrgInBes()
Definition: MucEntity.cxx:214
virtual void SetAlignment(double dx, double dy, double dz)
Definition: MucEntity.cxx:219
double GetArea()
Definition: MucEntity.cxx:150
int GetID()
Definition: MucEntity.cxx:139
virtual void SetH()
Definition: MucEntity.cxx:210
double * GetLocOrgInBes()
Definition: MucEntity.cxx:176
virtual void SetThin()
Definition: MucEntity.cxx:206
double * GetObjRotToMot()
Definition: MucEntity.cxx:177
virtual void SetObjOrgInLoc()
Definition: MucEntity.cxx:217
double GetRc()
Definition: MucEntity.cxx:143
virtual void SetRc()
Definition: MucEntity.cxx:205
double GetTheta()
Definition: MucEntity.cxx:140
void TransBesToLoc(double LocCoord[], double BesCoord[], double LocOrgInBes[], double Rot_z)
Definition: MucEntity.cxx:223
int GetSegment()
Definition: MucEntity.cxx:135
virtual void SetRout()
Definition: MucEntity.cxx:204
int GetUpDown()
Definition: MucEntity.cxx:137
virtual void SetRin()
Definition: MucEntity.cxx:203
virtual void SetTheta()
Definition: MucEntity.cxx:202
int GetRpcId()
Definition: MucEntity.cxx:138
double * GetObjOrgInBes()
Definition: MucEntity.cxx:178
double GetRin()
Definition: MucEntity.cxx:141
int GetLayer()
Definition: MucEntity.cxx:136
void TransLocToBes(double LocCoord[], double BesCoord[], double LocOrgInBes[], double Rot_z)
Definition: MucEntity.cxx:232
double GetL()
Definition: MucEntity.cxx:147
double * GetObjOrgInLoc()
Definition: MucEntity.cxx:179
double GetRout()
Definition: MucEntity.cxx:142
virtual void SetWu()
Definition: MucEntity.cxx:208
int GetPart()
Definition: MucEntity.cxx:134
virtual void Init()
Definition: MucEntity.cxx:183