BOSS 8.0.0
BESIII Offline Software System
Loading...
Searching...
No Matches
MucStripPlane Class Reference

#include <MucStripPlane.h>

Inheritance diagram for MucStripPlane:

Public Member Functions

 MucStripPlane (int part, int segment, int layer, int id)
 MucStripPlane (const MucStripPlane &other)
MucStripPlaneoperator= (const MucStripPlane &other)
virtual ~MucStripPlane ()
virtual void SetAlignment (double dx, double dy, double dz)
MucStripGetStrip (int id)
Public Member Functions inherited from MucEntity
 MucEntity (int part, int segment, int layer)
 MucEntity (int part, int segment, int layer, int id)
 MucEntity (int part, int segment, int layer, int upDown, int id)
 MucEntity (int part, int segment, int layer, int upDown, int rpcId, int id)
 MucEntity (const MucEntity &other)
MucEntityoperator= (const MucEntity &other)
virtual ~MucEntity ()
int GetPart ()
int GetSegment ()
int GetLayer ()
int GetUpDown ()
int GetRpcId ()
int GetID ()
double GetTheta ()
double GetRin ()
double GetRout ()
double GetRc ()
double GetThin ()
double GetW ()
double GetH ()
double GetL ()
double GetWu ()
double GetWd ()
double GetArea ()
double GetLocOrgInBes (int i)
double GetObjRotToMot (int i)
double GetObjOrgInBes (int i)
double GetObjOrgInLoc (int i)
double * GetLocOrgInBes ()
double * GetObjRotToMot ()
double * GetObjOrgInLoc ()
double * GetObjOrgInBes ()
void TransBesToLoc (double LocCoord[], double BesCoord[], double LocOrgInBes[], double Rot_z)
void TransLocToBes (double LocCoord[], double BesCoord[], double LocOrgInBes[], double Rot_z)

Protected Member Functions

virtual void Init ()
virtual void SetTheta ()
virtual void SetRc ()
virtual void SetRin ()
virtual void SetRout ()
virtual void SetThin ()
virtual void SetW ()
virtual void SetH ()
virtual void SetL ()
virtual void SetWu ()
virtual void SetWd ()
virtual void SetLocOrgInBes ()
virtual void SetObjOrgInBes ()
virtual void SetObjOrgInLoc ()
Protected Member Functions inherited from MucEntity
virtual void SetArea ()
virtual void SetObjRotToMot ()

Additional Inherited Members

Protected Attributes inherited from MucEntity
int m_Part
int m_Segment
int m_Layer
int m_UpDown
int m_RpcId
int m_ID
double m_Theta
double m_Rin
double m_Rout
double m_Rc
double m_Thin
double m_W
double m_H
double m_L
double m_Wu
double m_Wd
double m_Area
double m_LocOrgInBes [3]
double m_ObjRotToMot [3]
double m_ObjOrgInBes [3]
double m_ObjOrgInLoc [3]

Detailed Description

Definition at line 19 of file MucStripPlane.h.

Constructor & Destructor Documentation

◆ MucStripPlane() [1/2]

MucStripPlane::MucStripPlane ( int part,
int segment,
int layer,
int id )

Definition at line 17 of file MucStripPlane.cxx.

18 : MucEntity( part, segment, layer, id ) {
20 m_MucStrip = NULL;
21}
MucEntity(int part, int segment, int layer)
Definition MucEntity.cxx:17
virtual void Init()

Referenced by MucStripPlane(), and operator=().

◆ MucStripPlane() [2/2]

MucStripPlane::MucStripPlane ( const MucStripPlane & other)

Definition at line 24 of file MucStripPlane.cxx.

24 : MucEntity( other ) {
25 m_MucStrip = other.m_MucStrip;
26}
Index other(Index i, Index j)

◆ ~MucStripPlane()

MucStripPlane::~MucStripPlane ( )
virtual

Definition at line 38 of file MucStripPlane.cxx.

38{ delete m_MucStrip; }

Member Function Documentation

◆ GetStrip()

MucStrip * MucStripPlane::GetStrip ( int id)

Definition at line 61 of file MucStripPlane.cxx.

61 {
62 if ( m_MucStrip != NULL ) delete m_MucStrip;
63 return ( m_MucStrip = new MucStrip( m_Part, m_Segment, m_Layer, id ) );
64}
int m_Layer
Definition MucEntity.h:89
int m_Segment
Definition MucEntity.h:88
int m_Part
Definition MucEntity.h:87

◆ Init()

void MucStripPlane::Init ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 41 of file MucStripPlane.cxx.

41 {
42 SetTheta();
43 SetRin();
44 SetRout();
45 SetRc();
46
47 SetThin();
48 SetW();
49 SetWu();
50 SetWd();
51 SetH();
52 SetL();
53
57}
virtual void SetL()
virtual void SetRc()
virtual void SetRout()
virtual void SetH()
virtual void SetTheta()
virtual void SetObjOrgInLoc()
virtual void SetObjOrgInBes()
virtual void SetLocOrgInBes()
virtual void SetThin()
virtual void SetW()
virtual void SetWd()
virtual void SetWu()
virtual void SetRin()

Referenced by MucStripPlane().

◆ operator=()

MucStripPlane & MucStripPlane::operator= ( const MucStripPlane & other)

Definition at line 29 of file MucStripPlane.cxx.

29 {
30 if ( this == &other ) return *this;
31 MucEntity::operator=( other );
32 m_MucStrip = other.m_MucStrip;
33
34 return *this;
35}
MucEntity & operator=(const MucEntity &other)
Definition MucEntity.cxx:87

◆ SetAlignment()

void MucStripPlane::SetAlignment ( double dx,
double dy,
double dz )
virtual

Reimplemented from MucEntity.

Definition at line 342 of file MucStripPlane.cxx.

342 {
343 if ( m_Part == BRID || m_ID == -1 )
344 {
345 m_ObjOrgInLoc[0] += dx;
346 m_ObjOrgInLoc[1] += dy;
347 m_ObjOrgInLoc[2] += dz;
348 }
349}
double m_ObjOrgInLoc[3]
Definition MucEntity.h:118

Referenced by MucGeoMgr::CreateStripPlane().

◆ SetH()

void MucStripPlane::SetH ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 126 of file MucStripPlane.cxx.

126 {
127 if ( m_Part == BRID ) m_H = STR_TH;
128 else
129 {
130 if ( m_ID == -1 ) // temparory strip plane
131 m_H = E_AS_RMAX - E_BOX_DR - E_GP_DY -
132 ( E_STRPLN_DA + E_STRPLN_DB[( m_Layer == 0 ) ? 0 : 1] );
133 else
134 {
135 m_H = E_AS_RMAX - E_BOX_DR - E_GP_RMIN[m_Layer] - E_STRPLN_DR -
136 E_STRPLN_DB[( m_Layer == 0 ) ? 0 : 1];
137 if ( m_ID == 1 ) m_H += ( E_STR_DST + 5.0 ) / sqrt( 2.0 );
138 m_H += 4 * OVERLAP_WIDTH;
139 }
140 }
141}
double m_H
Definition MucEntity.h:102

Referenced by Init().

◆ SetL()

void MucStripPlane::SetL ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 143 of file MucStripPlane.cxx.

143 {
144 if ( m_Part == BRID )
145 {
146 if ( m_Segment == B_TOP )
147 {
148 // 0,1,2,3,7: CUT = 1; 2,4,6,8: CUT = 0;
149 if ( m_ID == -1 ) m_L = B_BOX_LT - 2 * B_BOX_DZ[SL_DOWN];
150 else if ( m_ID == 2 )
151 m_L = B_BOX_LT - 2 * B_BOX_DZ[SL_DOWN] -
152 B_ZSTR_CUT[( m_Layer == 0 ) ? 1 : ( m_Layer % 2 )];
153 else m_L = B_ZSTR_CUT[( m_Layer == 0 ) ? 1 : ( m_Layer % 2 )];
154 }
155 else m_L = B_BOX_LT - 2 * B_BOX_DZ[SL_DOWN];
156 }
157 else m_L = STR_TH;
158}
double m_L
Definition MucEntity.h:103

Referenced by Init().

◆ SetLocOrgInBes()

void MucStripPlane::SetLocOrgInBes ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 200 of file MucStripPlane.cxx.

200 {
201 double x, y, z = 0;
202
203 if ( m_Part == BRID )
204 {
205 x = m_Rc * cos( m_Theta );
206 y = m_Rc * sin( m_Theta );
207 z = 0.;
208 } // barrel
209 else
210 {
211 //-------------- set x and y ----------------------
212 // segment 0 as reference
213 if ( m_ID == -1 )
214 {
215 x = ( E_AS_RMAX - E_BOX_DR + E_GP_DX ) / 2.0;
216 y = ( E_AS_RMAX - E_BOX_DR + E_GP_DY ) / 2.0;
217 }
218 else
219 {
220 x = ( E_AS_RMAX + E_GP_DX + E_STRPLN_DA - E_BOX_DR -
221 E_STRPLN_DB[( m_Layer == 0 ) ? 0 : 1] ) /
222 2.0;
223 y = ( E_AS_RMAX + E_GP_DY + E_STRPLN_DA - E_BOX_DR -
224 E_STRPLN_DB[( m_Layer == 0 ) ? 0 : 1] ) /
225 2.0;
226 }
227
228 // x, y signs of coordinate different by segment
229 if ( m_Segment == 0 ) { ; }
230 else if ( m_Segment == 1 ) { x = -x; }
231 else if ( m_Segment == 2 )
232 {
233 x = -x;
234 y = -y;
235 }
236 else { y = -y; }
237
238 //-------------- set z -----------------------------
239 for ( int i = 0; i < m_Layer + 1; i++ ) z += E_AS_TH[i];
240
241 z += m_Layer * AS_GAP;
242 z += ( E_AS_ZMAX - E_AS_TOTAL_TH + z ) + AS_GAP / 2.0;
243 z *= cos( m_Part * MUC_PI / 2.0 );
244 } // endcap
245
246 m_LocOrgInBes[0] = x;
247 m_LocOrgInBes[1] = y;
248 m_LocOrgInBes[2] = z;
249
250 // limit cut
251 for ( int i = 0; i < 3; i++ )
252 if ( fabs( m_LocOrgInBes[i] ) < ERR_LIMIT ) m_LocOrgInBes[i] = 0.;
253}
Double_t x[10]
double m_Theta
Definition MucEntity.h:94
double m_LocOrgInBes[3]
Definition MucEntity.h:108
double m_Rc
Definition MucEntity.h:99

Referenced by Init().

◆ SetObjOrgInBes()

void MucStripPlane::SetObjOrgInBes ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 255 of file MucStripPlane.cxx.

255 {
256 if ( m_Part == BRID )
257 {
258 for ( int i = 0; i < 3; i++ ) m_ObjOrgInBes[i] = m_LocOrgInBes[i];
259 }
260 else // endcap
261 {
262 //------------- set x and y --------------------
263 // segment 0 as reference
264 double x, y;
265 if ( m_ID == -1 )
266 {
267 x = E_GP_DX + E_STRPLN_DA + m_W / 2.0;
268 y = E_GP_DY + E_STRPLN_DA + m_H / 2.0;
269 }
270 else if ( m_ID == 0 )
271 {
272 x = m_Rc;
273 y = ( m_Rc * tan( m_Theta ) + E_GP_DY + E_STRPLN_DA ) / 2.0;
274 }
275 else if ( m_ID == 1 )
276 {
277 x = m_Rc * cos( m_Theta );
278 y = m_Rc * sin( m_Theta );
279 }
280 else
281 { // m_ID == 2
282 x = ( m_Rc / tan( m_Theta ) + E_GP_DX + E_STRPLN_DA ) / 2.0;
283 y = m_Rc;
284 }
285
286 // x, y signs of coordinate different by segment
287 if ( m_Segment == 0 ) { ; }
288 else if ( m_Segment == 1 ) { x = -x; }
289 else if ( m_Segment == 2 )
290 {
291 x = -x;
292 y = -y;
293 }
294 else { y = -y; }
295
296 m_ObjOrgInBes[0] = x;
297 m_ObjOrgInBes[1] = y;
298
299 // limit cut
300 for ( int i = 0; i < 2; i++ )
301 if ( fabs( m_ObjOrgInBes[i] ) < ERR_LIMIT ) m_ObjOrgInBes[i] = 0.;
302
303 // ---------------- set z ----------------------
305
306 } // else, endcap
307}
double m_W
Definition MucEntity.h:101
double m_ObjOrgInBes[3]
Definition MucEntity.h:117

Referenced by Init().

◆ SetObjOrgInLoc()

void MucStripPlane::SetObjOrgInLoc ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 309 of file MucStripPlane.cxx.

309 {
310 double x, y, z;
311 if ( m_Part == BRID )
312 {
313 if ( m_Segment == B_TOP && m_ID != -1 )
314 {
315 // x
316 if ( m_ID == 2 ) x = 0.0;
317 else if ( m_ID == 0 ) x = ( B_PHISTR_CUT + m_W ) / 2.0;
318 else x = -( B_PHISTR_CUT + m_W ) / 2.0;
319
320 // y
321 y = 0.0;
322
323 // z
324 if ( m_ID == 2 ) z = -B_ZSTR_CUT[( m_Layer == 0 ) ? 1 : ( m_Layer % 2 )] / 2.0;
325 else
326 z = B_BOX_LT / 2.0 - B_BOX_DZ[SL_DOWN] -
327 B_ZSTR_CUT[( m_Layer == 0 ) ? 1 : ( m_Layer % 2 )] / 2;
328
329 m_ObjOrgInLoc[0] = x;
330 m_ObjOrgInLoc[1] = y;
331 m_ObjOrgInLoc[2] = z;
332 }
333 else
334 {
335 for ( int i = 0; i < 3; i++ ) m_ObjOrgInLoc[i] = 0.;
336 }
337 }
338 else
339 for ( int i = 0; i < 3; i++ ) m_ObjOrgInLoc[i] = m_ObjOrgInBes[i] - m_LocOrgInBes[i];
340}

Referenced by Init().

◆ SetRc()

void MucStripPlane::SetRc ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 90 of file MucStripPlane.cxx.

90 {
91 if ( m_Part == BRID ) m_Rc = B_AS_RMIN[m_Layer] - AS_GAP / 2.0;
92 else
93 {
94 if ( m_ID == -1 )
95 m_Rc =
96 sqrt( 2.0 ) * ( E_AS_RMAX - E_BOX_DR - E_STRPLN_DB[( m_Layer == 0 ) ? 0 : 1] ) / 2.0;
97 else m_Rc = ( m_Rin + m_Rout ) / 2.0;
98 }
99}
double m_Rin
Definition MucEntity.h:97
double m_Rout
Definition MucEntity.h:98

Referenced by Init().

◆ SetRin()

void MucStripPlane::SetRin ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 76 of file MucStripPlane.cxx.

76 {
77 if ( m_Part == BRID ) m_Rin = B_AS_RMIN[m_Layer] - ( AS_GAP + STR_TH ) / 2.0;
78 else
79 {
80 if ( m_ID == -1 ) m_Rin = 0.;
81 else m_Rin = E_GP_RMIN[m_Layer] + E_STRPLN_DR;
82 }
83}

Referenced by Init().

◆ SetRout()

void MucStripPlane::SetRout ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 85 of file MucStripPlane.cxx.

85 {
86 if ( m_Part == BRID ) m_Rout = B_AS_RMIN[m_Layer] - ( AS_GAP - STR_TH ) / 2.0;
87 else m_Rout = E_AS_RMAX - E_BOX_DR - E_STRPLN_DB[( m_Layer == 0 ) ? 0 : 1];
88}

Referenced by Init().

◆ SetTheta()

void MucStripPlane::SetTheta ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 67 of file MucStripPlane.cxx.

67 {
68 if ( m_Part == BRID ) m_Theta = m_Segment * ( MUC_PI / 4.0 );
69 else
70 {
71 if ( m_ID == -1 ) m_Theta = ( 2 * m_Segment + 1 ) * ( MUC_PI / 4.0 );
72 else m_Theta = ( MUC_PI / 4.0 ) + ( m_ID - 1 ) * MUC_PI / 8.0;
73 }
74}

Referenced by Init().

◆ SetThin()

void MucStripPlane::SetThin ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 101 of file MucStripPlane.cxx.

101{ m_Thin = STR_TH; }
double m_Thin
Definition MucEntity.h:100

Referenced by Init().

◆ SetW()

void MucStripPlane::SetW ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 103 of file MucStripPlane.cxx.

103 {
104 double offset = 0;
105 if ( ( m_Layer + 1 ) % 2 == 0 ) offset = 2 * B_BOX_DZ[1]; // even layers
106 else offset = 2 * B_BOX_DT[1]; // odd layers
107
108 if ( m_Part == BRID )
109 {
110 if ( m_Segment == B_TOP )
111 {
112 if ( m_ID == -1 || m_ID == 2 ) m_W = B_BOX_WT[m_Layer] - offset;
113 else m_W = ( B_BOX_WT[m_Layer] - offset - B_PHISTR_CUT ) / 2.0;
114 }
115 else m_W = B_BOX_WT[m_Layer] - offset;
116 }
117 else
118 {
119 if ( m_ID == -1 ) // temparory strip plane
120 m_W = E_AS_RMAX - E_BOX_DR - E_GP_DX -
121 ( E_STRPLN_DA + E_STRPLN_DB[( m_Layer == 0 ) ? 0 : 1] );
122 else m_W = 0.;
123 }
124}

Referenced by Init().

◆ SetWd()

void MucStripPlane::SetWd ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 179 of file MucStripPlane.cxx.

179 {
180 if ( m_Part == BRID ) m_Wd = m_W;
181 else
182 {
183 if ( m_ID == -1 ) // temparory strip plane
184 m_Wd = m_W;
185 else if ( m_ID == 1 ) // center panel
186 {
187 m_Wd = 2 * VALUE * m_Rout;
188 // zoom in with a small dimension for covering strips
189 m_Wd += VALUE * ( E_STR_DST + 5.0 ) / sqrt( 2.0 );
190 }
191 else if ( m_ID == 0 ) m_Wd = VALUE * m_Rout - E_GP_DY - E_STRPLN_DA;
192 else m_Wd = VALUE * m_Rout - E_GP_DX - E_STRPLN_DA;
193
194 // for "AND" operation of panels
195 // m_Wd += (VALUE + 1.0)*OVERLAP_WIDTH;
196 m_Wd += 4 * OVERLAP_WIDTH;
197 }
198}
double m_Wd
Definition MucEntity.h:105

Referenced by Init().

◆ SetWu()

void MucStripPlane::SetWu ( )
protectedvirtual

Reimplemented from MucEntity.

Definition at line 160 of file MucStripPlane.cxx.

160 {
161 if ( m_Part == BRID ) m_Wu = m_W;
162 else
163 {
164 if ( m_ID == -1 ) // temparory strip plane
165 m_Wu = m_W;
166 else if ( m_ID == 1 ) // center panel
167 {
168 m_Wu = 2 * VALUE * m_Rin;
169 m_Wu -= VALUE * ( E_STR_DST + 5.0 ) / sqrt( 2.0 );
170 }
171 else if ( m_ID == 0 ) m_Wu = VALUE * m_Rin - E_GP_DY - E_STRPLN_DA;
172 else m_Wu = VALUE * m_Rin - E_GP_DX - E_STRPLN_DA;
173
174 // m_Wu += (1-VALUE)*OVERLAP_WIDTH;
175 // m_Wu += 2*OVERLAP_WIDTH;
176 }
177}
double m_Wu
Definition MucEntity.h:104

Referenced by Init().


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