Belle II Software development
CDCGeometry Class Reference

The Class for CDC geometry. More...

#include <CDCGeometry.h>

Inheritance diagram for CDCGeometry:

Classes

class  Cover
 Cover structure geometry parameters. More...
 
class  Cover2
 Cover2 structure geometry parameters. More...
 
class  EndPlate
 Endplate geometry parameters. More...
 
class  EndPlateLayer
 Endplate layer geometry parameters. More...
 
class  FieldLayer
 Field layer geometry parameters. More...
 
class  Frontend
 Frontend layer geometry parameters. More...
 
class  InnerWall
 Inner wall geometry parameters. More...
 
class  MotherVolume
 Mother volume geometry parameters. More...
 
class  NeutronShield
 Neutron shield geometry parameters. More...
 
class  OuterWall
 Outer wall geometry parameters. More...
 
class  Rib
 Rib structure geometry parameters. More...
 
class  Rib2
 Rib2 structure geometry parameters. More...
 
class  Rib3
 Rib3 structure geometry parameters. More...
 
class  Rib4
 Rib4 structure geometry parameters. More...
 
class  Rib5
 Rib5 structure geometry parameters. More...
 
class  SenseLayer
 Sense layer geometry parameters. More...
 

Public Member Functions

 CDCGeometry ()
 Default constructor.
 
 CDCGeometry (const GearDir &)
 Constructor.
 
 ~CDCGeometry ()
 Destructor.
 
void read (const GearDir &)
 Get geometry parameters from Gearbox.
 
double getGlobalPhiRotation () const
 Get the global phi rotation of CDC.
 
double getGlobalOffsetX () const
 Get the global x offset of CDC wrt Belle2 coord.
 
double getGlobalOffsetY () const
 Get the global y offset of CDC wrt Belle2 coord.
 
double getGlobalOffsetZ () const
 Get the global z offset of CDC wrt Belle2 coord.
 
double getGlobalOffsetA () const
 Get the global offset angle a of CDC wrt Belle2 coord.
 
double getGlobalOffsetB () const
 Get the global offset angle b of CDC wrt Belle2 coord.
 
double getGlobalOffsetC () const
 Get the global offset angle c of CDC wrt Belle2 coord.
 
double getFiducialRmin () const
 Get the fiducial Rmin of CDC sensitive volume.
 
double getFiducialRmax () const
 Get the fiducial Rmax of CDC sensitive volume.
 
MotherVolume getMotherVolume () const
 Get the mother volume geometry of CDC.
 
std::vector< OuterWallgetOuterWalls () const
 Get the list of outer walls.
 
OuterWall getOuterWall (int i) const
 Get the i-th outer wall.
 
std::vector< InnerWallgetInnerWalls () const
 Get the list of inner walls.
 
InnerWall getInnerWall (int i) const
 Get the i-th inner wall.
 
int getNEndplates () const
 Get the number of endplates.
 
EndPlate getEndPlate (int i) const
 Get the i-th endplate.
 
std::vector< EndPlategetEndPlates () const
 Get the list of endplates.
 
int getNFrontends () const
 Get the number of frontend layers.
 
std::vector< FrontendgetFrontends () const
 Get the list of frontend layers.
 
SenseLayer getSenseLayer (int i) const
 Get i-th sense layer.
 
std::vector< SenseLayergetSenseLayers () const
 Get the list of sense layers.
 
int getNSenseLayers () const
 Get the number of sense layers.
 
double getSenseDiameter () const
 Get the diameter of sense wire.
 
double getSenseTension () const
 Get the tension applied to sense wire.
 
int getNSenseWires () const
 Get the number of sense wires.
 
FieldLayer getFieldLayer (int i) const
 Get the i-th field layer.
 
std::vector< FieldLayergetFieldLayers () const
 Get the list of field layers.
 
int getNFieldLayers () const
 Get the number of field layers.
 
std::vector< NeutronShieldgetNeutronShields () const
 Get the list of neutron shields.
 
std::vector< CovergetCovers () const
 Get the list of covers.
 
std::vector< Cover2getCover2s () const
 Get the list of covers.
 
std::vector< RibgetRibs () const
 Get the list of ribs.
 
std::vector< Rib2getRib2s () const
 Get the list of rib2s.
 
std::vector< Rib3getRib3s () const
 Get the list of rib3s.
 
std::vector< Rib4getRib4s () const
 Get the list of rib4s.
 
std::vector< Rib5getRib5s () const
 Get the list of rib5s.
 
double getFieldDiameter () const
 Get the diameter of field wire.
 
int getNFieldWires () const
 Get the number of field wires.
 
double getFeedthroughLength () const
 Get the length of feedthrough.
 
double getClockFrequency () const
 Get the clock frequency.
 
double getNominalSpaceResolution () const
 Get the nominal space resolution.
 
ushort getNumberOfSenseLayers () const
 Get the number of sense layers.
 
ushort getNumberOfFieldLayers () const
 Get the number of field layers.
 
ushort getMaxNumberOfSuperLayers () const
 Get the maximum number of super layers.
 
ushort getOffsetOfFirstLayer () const
 Get the offset of the first layer.
 
ushort getOffsetOfFirstSuperLayer () const
 Get the offset of the first super layer.
 
ushort getMaxNumberOfCellsPerLayer () const
 Get the maximum number of cells in one layer.
 

Private Member Functions

 ClassDef (CDCGeometry, 5)
 ClassDef, must be the last term before the closing {}.
 

Private Attributes

double m_globalPhiRotation = 0.0
 Global rotation in phi (rad).
 
double m_globalOffsetX = 0.0
 Offset x of the whole cdc wrt B2 coord system (cm).
 
double m_globalOffsetY = 0.0
 Offset y of the whole cdc wrt B2 coord system (cm).
 
double m_globalOffsetZ = 0.0
 Offset z of the whole cdc wrt B2 coord system (cm).
 
double m_globalOffsetA = 0.0
 Offset angle a of the whole cdc wrt B2 coord system (rad).
 
double m_globalOffsetB = 0.0
 Offset angle b of the whole cdc wrt B2 coord system (rad).
 
double m_globalOffsetC = 0.0
 Offset angle c of the whole cdc wrt B2 coord system (rad).
 
double m_fiducialRmin
 Minimum radius of the CDC fiducial volume.
 
double m_fiducialRmax
 Maximum radius of the CDC fiducial volume.
 
MotherVolume m_mother
 CDC mother volume.
 
std::vector< SenseLayerm_senseLayers
 Sense layer.
 
std::vector< FieldLayerm_fieldLayers
 Field layer.
 
std::vector< InnerWallm_innerWalls
 Inner wall.
 
std::vector< OuterWallm_outerWalls
 Outer wall.
 
std::vector< EndPlatem_endplates
 Endplate.
 
std::vector< Frontendm_frontends
 Electronics board.
 
std::vector< NeutronShieldm_neutronShields
 Neutron shields.
 
std::vector< Coverm_covers
 Covers.
 
std::vector< Cover2m_cover2s
 Cover2s.
 
std::vector< Ribm_ribs
 Ribs.
 
std::vector< Rib2m_rib2s
 Rib2s.
 
std::vector< Rib3m_rib3s
 Rib3s.
 
std::vector< Rib4m_rib4s
 Rib4s.
 
std::vector< Rib5m_rib5s
 Rib5s.
 
double m_senseWireDiameter = 0.003
 Sense wire diameter (cm).
 
int m_senseWireNumbers = 14336
 Number of sense wires.
 
double m_senseWireTension = 50.0
 Sense wire tension (gW).
 
double m_fieldWireDiameter = 0.0126
 Field wire diameter (cm).
 
int m_fieldWireNumbers = 42240
 Number of field wires.
 
double m_feedThroughLength = 1.5
 Feedthrough length (cm).
 
double m_clockFrequency
 Clock frequency.
 
double m_nominalSpaceResolution
 Nominal space resolution.
 
ushort m_maxNSenseLayers = 56
 Maximum number of Sense Wire Layers.
 
ushort m_maxNFieldLayers = 55
 Maximum number of Field Wire Layers.
 
ushort m_maxNSuperLayers = 9
 Maximum number of Super Layers.
 
ushort m_firstLayerOffset = 0
 Offset of the first layer (for reduced CDC studies)
 
ushort m_firstSuperLayerOffset = 0
 Offset of the first super layer (for reduced CDC studies)
 
ushort m_maxNCellsPerLayer = 384
 Maximum number wires within a layer.
 

Detailed Description

The Class for CDC geometry.

Definition at line 27 of file CDCGeometry.h.

Constructor & Destructor Documentation

◆ CDCGeometry() [1/2]

CDCGeometry ( )
inline

Default constructor.

Definition at line 1408 of file CDCGeometry.h.

1408{};

◆ CDCGeometry() [2/2]

CDCGeometry ( const GearDir content)
explicit

Constructor.

Definition at line 25 of file CDCGeometry.cc.

26{
27 read(content);
28}
void read(const GearDir &)
Get geometry parameters from Gearbox.
Definition: CDCGeometry.cc:34

◆ ~CDCGeometry()

Destructor.

Definition at line 30 of file CDCGeometry.cc.

31{
32}

Member Function Documentation

◆ getClockFrequency()

double getClockFrequency ( ) const
inline

Get the clock frequency.

Definition at line 1625 of file CDCGeometry.h.

1625{ return m_clockFrequency;}
double m_clockFrequency
Clock frequency.
Definition: CDCGeometry.h:1697

◆ getCover2s()

std::vector< Cover2 > getCover2s ( ) const
inline

Get the list of covers.

Definition at line 1579 of file CDCGeometry.h.

1579{ return m_cover2s;}
std::vector< Cover2 > m_cover2s
Cover2s.
Definition: CDCGeometry.h:1684

◆ getCovers()

std::vector< Cover > getCovers ( ) const
inline

Get the list of covers.

Definition at line 1574 of file CDCGeometry.h.

1574{ return m_covers;}
std::vector< Cover > m_covers
Covers.
Definition: CDCGeometry.h:1683

◆ getEndPlate()

EndPlate getEndPlate ( int  i) const
inline

Get the i-th endplate.

Definition at line 1503 of file CDCGeometry.h.

1503{return m_endplates.at(i);};
std::vector< EndPlate > m_endplates
Endplate.
Definition: CDCGeometry.h:1680

◆ getEndPlates()

std::vector< EndPlate > getEndPlates ( ) const
inline

Get the list of endplates.

Definition at line 1508 of file CDCGeometry.h.

1508{ return m_endplates;}

◆ getFeedthroughLength()

double getFeedthroughLength ( ) const
inline

Get the length of feedthrough.

Definition at line 1620 of file CDCGeometry.h.

1620{return m_feedThroughLength;}
double m_feedThroughLength
Feedthrough length (cm).
Definition: CDCGeometry.h:1696

◆ getFiducialRmax()

double getFiducialRmax ( ) const
inline

Get the fiducial Rmax of CDC sensitive volume.

Definition at line 1468 of file CDCGeometry.h.

1468{ return m_fiducialRmax;}
double m_fiducialRmax
Maximum radius of the CDC fiducial volume.
Definition: CDCGeometry.h:1674

◆ getFiducialRmin()

double getFiducialRmin ( ) const
inline

Get the fiducial Rmin of CDC sensitive volume.

Definition at line 1463 of file CDCGeometry.h.

1463{ return m_fiducialRmin;}
double m_fiducialRmin
Minimum radius of the CDC fiducial volume.
Definition: CDCGeometry.h:1673

◆ getFieldDiameter()

double getFieldDiameter ( ) const
inline

Get the diameter of field wire.

Definition at line 1610 of file CDCGeometry.h.

1610{ return m_fieldWireDiameter;}
double m_fieldWireDiameter
Field wire diameter (cm).
Definition: CDCGeometry.h:1694

◆ getFieldLayer()

FieldLayer getFieldLayer ( int  i) const
inline

Get the i-th field layer.

Definition at line 1553 of file CDCGeometry.h.

1553{ return m_fieldLayers.at(i);}
std::vector< FieldLayer > m_fieldLayers
Field layer.
Definition: CDCGeometry.h:1677

◆ getFieldLayers()

std::vector< FieldLayer > getFieldLayers ( ) const
inline

Get the list of field layers.

Definition at line 1558 of file CDCGeometry.h.

1558{ return m_fieldLayers;}

◆ getFrontends()

std::vector< Frontend > getFrontends ( ) const
inline

Get the list of frontend layers.

Definition at line 1518 of file CDCGeometry.h.

1518{return m_frontends;}
std::vector< Frontend > m_frontends
Electronics board.
Definition: CDCGeometry.h:1681

◆ getGlobalOffsetA()

double getGlobalOffsetA ( ) const
inline

Get the global offset angle a of CDC wrt Belle2 coord.

system.

Definition at line 1448 of file CDCGeometry.h.

1448{ return m_globalOffsetA;}
double m_globalOffsetA
Offset angle a of the whole cdc wrt B2 coord system (rad).
Definition: CDCGeometry.h:1670

◆ getGlobalOffsetB()

double getGlobalOffsetB ( ) const
inline

Get the global offset angle b of CDC wrt Belle2 coord.

system.

Definition at line 1453 of file CDCGeometry.h.

1453{ return m_globalOffsetB;}
double m_globalOffsetB
Offset angle b of the whole cdc wrt B2 coord system (rad).
Definition: CDCGeometry.h:1671

◆ getGlobalOffsetC()

double getGlobalOffsetC ( ) const
inline

Get the global offset angle c of CDC wrt Belle2 coord.

system.

Definition at line 1458 of file CDCGeometry.h.

1458{ return m_globalOffsetC;}
double m_globalOffsetC
Offset angle c of the whole cdc wrt B2 coord system (rad).
Definition: CDCGeometry.h:1672

◆ getGlobalOffsetX()

double getGlobalOffsetX ( ) const
inline

Get the global x offset of CDC wrt Belle2 coord.

system.

Definition at line 1433 of file CDCGeometry.h.

1433{ return m_globalOffsetX;}
double m_globalOffsetX
Offset x of the whole cdc wrt B2 coord system (cm).
Definition: CDCGeometry.h:1667

◆ getGlobalOffsetY()

double getGlobalOffsetY ( ) const
inline

Get the global y offset of CDC wrt Belle2 coord.

system.

Definition at line 1438 of file CDCGeometry.h.

1438{ return m_globalOffsetY;}
double m_globalOffsetY
Offset y of the whole cdc wrt B2 coord system (cm).
Definition: CDCGeometry.h:1668

◆ getGlobalOffsetZ()

double getGlobalOffsetZ ( ) const
inline

Get the global z offset of CDC wrt Belle2 coord.

system.

Definition at line 1443 of file CDCGeometry.h.

1443{ return m_globalOffsetZ;}
double m_globalOffsetZ
Offset z of the whole cdc wrt B2 coord system (cm).
Definition: CDCGeometry.h:1669

◆ getGlobalPhiRotation()

double getGlobalPhiRotation ( ) const
inline

Get the global phi rotation of CDC.

Definition at line 1428 of file CDCGeometry.h.

1428{ return m_globalPhiRotation;}
double m_globalPhiRotation
Global rotation in phi (rad).
Definition: CDCGeometry.h:1666

◆ getInnerWall()

InnerWall getInnerWall ( int  i) const
inline

Get the i-th inner wall.

Definition at line 1493 of file CDCGeometry.h.

1493{ return m_innerWalls.at(i);}
std::vector< InnerWall > m_innerWalls
Inner wall.
Definition: CDCGeometry.h:1678

◆ getInnerWalls()

std::vector< InnerWall > getInnerWalls ( ) const
inline

Get the list of inner walls.

Definition at line 1488 of file CDCGeometry.h.

1488{ return m_innerWalls;}

◆ getMaxNumberOfCellsPerLayer()

ushort getMaxNumberOfCellsPerLayer ( ) const
inline

Get the maximum number of cells in one layer.

Definition at line 1661 of file CDCGeometry.h.

1661{ return m_maxNCellsPerLayer;}
ushort m_maxNCellsPerLayer
Maximum number wires within a layer.
Definition: CDCGeometry.h:1705

◆ getMaxNumberOfSuperLayers()

ushort getMaxNumberOfSuperLayers ( ) const
inline

Get the maximum number of super layers.

Definition at line 1646 of file CDCGeometry.h.

1646{ return m_maxNSuperLayers;}
ushort m_maxNSuperLayers
Maximum number of Super Layers.
Definition: CDCGeometry.h:1702

◆ getMotherVolume()

MotherVolume getMotherVolume ( ) const
inline

Get the mother volume geometry of CDC.

Definition at line 1473 of file CDCGeometry.h.

1473{ return m_mother;}
MotherVolume m_mother
CDC mother volume.
Definition: CDCGeometry.h:1675

◆ getNEndplates()

int getNEndplates ( ) const
inline

Get the number of endplates.

Definition at line 1498 of file CDCGeometry.h.

1498{ return m_endplates.size();}

◆ getNeutronShields()

std::vector< NeutronShield > getNeutronShields ( ) const
inline

Get the list of neutron shields.

Definition at line 1569 of file CDCGeometry.h.

1569{ return m_neutronShields;}
std::vector< NeutronShield > m_neutronShields
Neutron shields.
Definition: CDCGeometry.h:1682

◆ getNFieldLayers()

int getNFieldLayers ( ) const
inline

Get the number of field layers.

Definition at line 1563 of file CDCGeometry.h.

1563{ return m_fieldLayers.size();}

◆ getNFieldWires()

int getNFieldWires ( ) const
inline

Get the number of field wires.

Definition at line 1615 of file CDCGeometry.h.

1615{ return m_fieldWireNumbers;}
int m_fieldWireNumbers
Number of field wires.
Definition: CDCGeometry.h:1695

◆ getNFrontends()

int getNFrontends ( ) const
inline

Get the number of frontend layers.

Definition at line 1513 of file CDCGeometry.h.

1513{return m_frontends.size();}

◆ getNominalSpaceResolution()

double getNominalSpaceResolution ( ) const
inline

Get the nominal space resolution.

Definition at line 1630 of file CDCGeometry.h.

1630{ return m_nominalSpaceResolution;}
double m_nominalSpaceResolution
Nominal space resolution.
Definition: CDCGeometry.h:1698

◆ getNSenseLayers()

int getNSenseLayers ( ) const
inline

Get the number of sense layers.

Definition at line 1533 of file CDCGeometry.h.

1533{ return m_senseLayers.size();}
std::vector< SenseLayer > m_senseLayers
Sense layer.
Definition: CDCGeometry.h:1676

◆ getNSenseWires()

int getNSenseWires ( ) const
inline

Get the number of sense wires.

Definition at line 1548 of file CDCGeometry.h.

1548{ return m_senseWireNumbers;}
int m_senseWireNumbers
Number of sense wires.
Definition: CDCGeometry.h:1692

◆ getNumberOfFieldLayers()

ushort getNumberOfFieldLayers ( ) const
inline

Get the number of field layers.

Definition at line 1641 of file CDCGeometry.h.

1641{ return m_maxNFieldLayers;}
ushort m_maxNFieldLayers
Maximum number of Field Wire Layers.
Definition: CDCGeometry.h:1701

◆ getNumberOfSenseLayers()

ushort getNumberOfSenseLayers ( ) const
inline

Get the number of sense layers.

Definition at line 1636 of file CDCGeometry.h.

1636{ return m_maxNSenseLayers;}
ushort m_maxNSenseLayers
Maximum number of Sense Wire Layers.
Definition: CDCGeometry.h:1700

◆ getOffsetOfFirstLayer()

ushort getOffsetOfFirstLayer ( ) const
inline

Get the offset of the first layer.

Definition at line 1651 of file CDCGeometry.h.

1651{ return m_firstLayerOffset;}
ushort m_firstLayerOffset
Offset of the first layer (for reduced CDC studies)
Definition: CDCGeometry.h:1703

◆ getOffsetOfFirstSuperLayer()

ushort getOffsetOfFirstSuperLayer ( ) const
inline

Get the offset of the first super layer.

Definition at line 1656 of file CDCGeometry.h.

1656{ return m_firstSuperLayerOffset;}
ushort m_firstSuperLayerOffset
Offset of the first super layer (for reduced CDC studies)
Definition: CDCGeometry.h:1704

◆ getOuterWall()

OuterWall getOuterWall ( int  i) const
inline

Get the i-th outer wall.

Definition at line 1483 of file CDCGeometry.h.

1483{ return m_outerWalls.at(i);}
std::vector< OuterWall > m_outerWalls
Outer wall.
Definition: CDCGeometry.h:1679

◆ getOuterWalls()

std::vector< OuterWall > getOuterWalls ( ) const
inline

Get the list of outer walls.

Definition at line 1478 of file CDCGeometry.h.

1478{ return m_outerWalls;}

◆ getRib2s()

std::vector< Rib2 > getRib2s ( ) const
inline

Get the list of rib2s.

Definition at line 1589 of file CDCGeometry.h.

1589{ return m_rib2s;}
std::vector< Rib2 > m_rib2s
Rib2s.
Definition: CDCGeometry.h:1686

◆ getRib3s()

std::vector< Rib3 > getRib3s ( ) const
inline

Get the list of rib3s.

Definition at line 1594 of file CDCGeometry.h.

1594{ return m_rib3s;}
std::vector< Rib3 > m_rib3s
Rib3s.
Definition: CDCGeometry.h:1687

◆ getRib4s()

std::vector< Rib4 > getRib4s ( ) const
inline

Get the list of rib4s.

Definition at line 1599 of file CDCGeometry.h.

1599{ return m_rib4s;}
std::vector< Rib4 > m_rib4s
Rib4s.
Definition: CDCGeometry.h:1688

◆ getRib5s()

std::vector< Rib5 > getRib5s ( ) const
inline

Get the list of rib5s.

Definition at line 1604 of file CDCGeometry.h.

1604{ return m_rib5s;}
std::vector< Rib5 > m_rib5s
Rib5s.
Definition: CDCGeometry.h:1689

◆ getRibs()

std::vector< Rib > getRibs ( ) const
inline

Get the list of ribs.

Definition at line 1584 of file CDCGeometry.h.

1584{ return m_ribs;}
std::vector< Rib > m_ribs
Ribs.
Definition: CDCGeometry.h:1685

◆ getSenseDiameter()

double getSenseDiameter ( ) const
inline

Get the diameter of sense wire.

Definition at line 1538 of file CDCGeometry.h.

1538{ return m_senseWireDiameter;}
double m_senseWireDiameter
Sense wire diameter (cm).
Definition: CDCGeometry.h:1691

◆ getSenseLayer()

SenseLayer getSenseLayer ( int  i) const
inline

Get i-th sense layer.

Definition at line 1523 of file CDCGeometry.h.

1523{ return m_senseLayers.at(i);}

◆ getSenseLayers()

std::vector< SenseLayer > getSenseLayers ( ) const
inline

Get the list of sense layers.

Definition at line 1528 of file CDCGeometry.h.

1528{ return m_senseLayers;}

◆ getSenseTension()

double getSenseTension ( ) const
inline

Get the tension applied to sense wire.

Definition at line 1543 of file CDCGeometry.h.

1543{ return m_senseWireTension;}
double m_senseWireTension
Sense wire tension (gW).
Definition: CDCGeometry.h:1693

◆ read()

void read ( const GearDir content)

Get geometry parameters from Gearbox.

Definition at line 34 of file CDCGeometry.cc.

35{
36 // Global.
37 m_globalOffsetX = content.getLength("OffsetX");
38 m_globalOffsetY = content.getLength("OffsetY");
39 m_globalOffsetZ = content.getLength("OffsetZ");
40 m_globalPhiRotation = content.getAngle("GlobalPhiRotation");
41 m_globalOffsetA = content.getAngle("OffsetA");
42 m_globalOffsetB = content.getAngle("OffsetB");
43 m_globalOffsetC = content.getAngle("OffsetC");
44
45 m_maxNSenseLayers = content.getInt("MaxNSenseLayers");
46 m_maxNFieldLayers = content.getInt("MaxNFieldLayers");
47 m_maxNSuperLayers = content.getInt("SuperLayers");
48 m_firstLayerOffset = content.getInt("FirstLayerOffset");
49 m_firstSuperLayerOffset = content.getInt("SuperLayerOffset");
50 m_maxNCellsPerLayer = content.getInt("MaxNCells");
51
52 // Mother volume.
53 const int nBound = content.getNumberNodes("MomVol/ZBound");
54 for (int iBound = 0; iBound < nBound; iBound++) {
55 const double rmin = content.getLength((format("MomVol/ZBound[%1%]/Rmin") % (iBound + 1)).str()) / Unit::mm;
56 const double rmax = content.getLength((format("MomVol/ZBound[%1%]/Rmax") % (iBound + 1)).str()) / Unit::mm;
57 const double z = content.getLength((format("MomVol/ZBound[%1%]/Z") % (iBound + 1)).str()) / Unit::mm;
58 m_mother.appendNode(rmin, rmax, z);
59 }
60
61
62 // Sense layer.
63 const int nSLayer = content.getNumberNodes("SLayers/SLayer");
64
65 for (int iSLayer = 0; iSLayer < nSLayer; ++iSLayer) {
66 GearDir layerContent(content);
67 layerContent.append((format("/SLayers/SLayer[%1%]/") % (iSLayer + 1)).str());
68 const double r = layerContent.getLength("Radius");
69 const double zfwd = layerContent.getLength("ForwardZ");
70 const double zbwd = layerContent.getLength("BackwardZ");
71 const double dzfwd = layerContent.getLength("FwdDeltaZ");
72 const double dzbwd = layerContent.getLength("BwdDeltaZ");
73 const double offset = atof((layerContent.getString("Offset")).c_str());
74 const int nWires = atoi((layerContent.getString("NHoles")).c_str()) / 2;
75 const double nShifts = atof((layerContent.getString("NShift")).c_str());
76
77 SenseLayer sense(iSLayer + m_firstLayerOffset, r, zfwd, zbwd,
78 dzfwd, dzbwd, offset, nWires, nShifts);
79
80 m_senseLayers.push_back(sense);
81 }
82
83 // Field layer.
84 const int nFLayer = content.getNumberNodes("FLayers/FLayer");
85
86 for (int iFLayer = 0; iFLayer < nFLayer; ++iFLayer) {
87 GearDir layerContent(content);
88 layerContent.append((format("/FLayers/FLayer[%1%]/") % (iFLayer + 1)).str());
89 const double r = layerContent.getLength("Radius");
90 const double zfwd = layerContent.getLength("ForwardZ");
91 const double zbwd = layerContent.getLength("BackwardZ");
92 FieldLayer field(iFLayer + m_firstLayerOffset, r, zfwd, zbwd);
93 m_fieldLayers.push_back(field);
94 }
95
96 // Endplate.
97 const int nEndplates = content.getNumberNodes("Endplates/Endplate");
98 for (int i = 0; i < nEndplates; ++i) {
99
100 EndPlate ep(i);
101
102 GearDir epContent(content);
103 epContent.append((format("/Endplates/Endplate[%1%]/") % (i + 1)).str());
104 const int nEPLayer = epContent.getNumberNodes("EndplateLayer");
105
106 for (int iEPLayer = 0; iEPLayer < nEPLayer; ++iEPLayer) {
107 GearDir epLayerContent(epContent);
108 epLayerContent.append((format("/EndplateLayer[%1%]/") % (iEPLayer + 1)).str());
109 string epName = epLayerContent.getString("Name");
110 double rmin = epLayerContent.getLength("InnerR");
111 double rmax = epLayerContent.getLength("OuterR");
112 double zfwd = epLayerContent.getLength("ForwardZ");
113 double zbwd = epLayerContent.getLength("BackwardZ");
114 std::string name = "Layer" + to_string(i + m_firstLayerOffset) + epName + to_string(iEPLayer);
115
116 ep.appendNew(name, iEPLayer, rmin, rmax, zfwd, zbwd);
117 }
118 m_endplates.push_back(ep);
119 }
120
121 // Inner wall.
122 const int nInnerWall = content.getNumberNodes("InnerWalls/InnerWall");
123 for (int i = 0; i < nInnerWall; ++i) {
124 GearDir innerWallContent(content);
125 innerWallContent.append((format("/InnerWalls/InnerWall[%1%]/") % (i + 1)).str());
126
127 string sInnerWallID = innerWallContent.getString("@id");
128 const string name = "InnerWall_" + sInnerWallID + "_" + innerWallContent.getString("Name");
129 const double rmin = innerWallContent.getLength("InnerR");
130 const double rmax = innerWallContent.getLength("OuterR");
131 const double zfwd = innerWallContent.getLength("ForwardZ");
132 const double zbwd = innerWallContent.getLength("BackwardZ");
133 const InnerWall wall(name, i, rmin, rmax, zfwd, zbwd);
134 m_innerWalls.push_back(wall);
135 if (innerWallContent.getString("Name") == "Shield") {
136 m_fiducialRmin = rmax;
137 }
138 }
139
140
141 // Outer wall.
142 const int nOuterWall = content.getNumberNodes("OuterWalls/OuterWall");
143 for (int i = 0; i < nOuterWall; ++i) {
144 GearDir outerWallContent(content);
145 outerWallContent.append((format("/OuterWalls/OuterWall[%1%]/") % (i + 1)).str());
146
147 string sOuterWallID = outerWallContent.getString("@id");
148 const string name = "OuterWall_" + sOuterWallID + "_" + outerWallContent.getString("Name");
149 const double rmin = outerWallContent.getLength("InnerR");
150 const double rmax = outerWallContent.getLength("OuterR");
151 const double zfwd = outerWallContent.getLength("ForwardZ");
152 const double zbwd = outerWallContent.getLength("BackwardZ");
153 const OuterWall wall(name, i, rmin, rmax, zfwd, zbwd);
154 m_outerWalls.push_back(wall);
155 if (outerWallContent.getString("Name") == "Shield") {
156 m_fiducialRmax = rmin;
157 }
158 }
159
160
161 // Electronics board.
162 const int nEB = content.getNumberNodes("ElectronicsBoards/ElectronicsBoard");
163 for (int iEB = 0; iEB < nEB; ++iEB) {
164 GearDir ebContent(content);
165 ebContent.append((format("/ElectronicsBoards/ElectronicsBoard[%1%]/") % (iEB + 1)).str());
166
167 const double rmin = ebContent.getLength("EBInnerR");
168 const double rmax = ebContent.getLength("EBOuterR");
169 const double zfwd = ebContent.getLength("EBForwardZ");
170 const double zbwd = ebContent.getLength("EBBackwardZ");
171 Frontend frontend(iEB, rmin, rmax, zfwd, zbwd);
172 m_frontends.push_back(frontend);
173 }
174
175 // Neutron shield.
176 const int nShields = content.getNumberNodes("Shields/Shield");
177 for (int i = 0; i < nShields; ++i) {
178 GearDir neuContent(content);
179 neuContent.append((format("/Shields/Shield[%1%]/") % (i + 1)).str());
180
181 const double rmin1 = neuContent.getLength("InnerR1");
182 const double rmin2 = neuContent.getLength("InnerR2");
183 const double rmax1 = neuContent.getLength("OuterR1");
184 const double rmax2 = neuContent.getLength("OuterR2");
185 const double thick = neuContent.getLength("Thickness");
186 const double z = neuContent.getLength("PosZ");
187 NeutronShield shield(i, rmin1, rmin2, rmax1, rmax2, thick, z);
188 m_neutronShields.push_back(shield);
189 }
190
191 // Support structure.
192 const int nCovers = content.getNumberNodes("Covers/Cover");
193 for (int i = 0; i < nCovers; ++i) {
194 GearDir coverContent(content);
195 coverContent.append((format("/Covers/Cover[%1%]/") % (i + 1)).str());
196
197 const int coverID = atoi((coverContent.getString("@id")).c_str());
198 const double rmin1 = coverContent.getLength("InnerR1");
199 const double rmin2 = coverContent.getLength("InnerR2");
200 const double rmax1 = coverContent.getLength("OuterR1");
201 const double rmax2 = coverContent.getLength("OuterR2");
202 const double thick = coverContent.getLength("Thickness");
203 const double z = coverContent.getLength("PosZ");
204 Cover cover(coverID, rmin1, rmin2, rmax1, rmax2, thick, z);
205 m_covers.push_back(cover);
206 }
207
208 const int nCover2s = content.getNumberNodes("Covers/Cover2");
209 for (int i = 0; i < nCover2s; ++i) {
210 GearDir cover2Content(content);
211 cover2Content.append((format("/Covers/Cover2[%1%]/") % (i + 1)).str());
212
213 const int cover2ID = atoi((cover2Content.getString("@id")).c_str());
214 const double rmin = cover2Content.getLength("InnerR");
215 const double rmax = cover2Content.getLength("OuterR");
216 const double phis = cover2Content.getLength("StartPhi");
217 const double dphi = cover2Content.getLength("DeltaPhi");
218 const double thick = cover2Content.getLength("Thickness");
219 const double z = cover2Content.getLength("PosZ");
220 Cover2 cover2(cover2ID, rmin, rmax, phis, dphi, thick, z);
221 m_cover2s.push_back(cover2);
222 }
223
224 const int nRibs = content.getNumberNodes("Covers/Rib");
225 for (int i = 0; i < nRibs; ++i) {
226 GearDir ribContent(content);
227 ribContent.append((format("/Covers/Rib[%1%]/") % (i + 1)).str());
228
229 const int ribID = atoi((ribContent.getString("@id")).c_str());
230 const double length = ribContent.getLength("Length");
231 const double width = ribContent.getLength("Width");
232 const double thick = ribContent.getLength("Thickness");
233 const double rotx = ribContent.getLength("RotX");
234 const double roty = ribContent.getLength("RotY");
235 const double rotz = ribContent.getLength("RotZ");
236 const double x = ribContent.getLength("PosX");
237 const double y = ribContent.getLength("PosY");
238 const double z = ribContent.getLength("PosZ");
239 const int offset = atoi((ribContent.getString("Offset")).c_str());
240 const int ndiv = atoi((ribContent.getString("NDiv")).c_str());
241 Rib rib(ribID, length, width, thick, rotx, roty, rotz, x, y, z, offset, ndiv);
242 m_ribs.push_back(rib);
243 }
244
245 const int nRib2s = content.getNumberNodes("Covers/Rib2");
246 for (int i = 0; i < nRib2s; ++i) {
247 GearDir rib2Content(content);
248 rib2Content.append((format("/Covers/Rib2[%1%]/") % (i + 1)).str());
249
250 const int rib2ID = atoi((rib2Content.getString("@id")).c_str());
251 const double length = rib2Content.getLength("Length");
252 const double width = rib2Content.getLength("Width");
253 const double thick = rib2Content.getLength("Thickness");
254 const double width2 = rib2Content.getLength("Width2");
255 const double thick2 = rib2Content.getLength("Thickness2");
256 const double rotx = rib2Content.getLength("RotX");
257 const double roty = rib2Content.getLength("RotY");
258 const double rotz = rib2Content.getLength("RotZ");
259 const double x = rib2Content.getLength("PosX");
260 const double y = rib2Content.getLength("PosY");
261 const double z = rib2Content.getLength("PosZ");
262 const int ndiv = atoi((rib2Content.getString("NDiv")).c_str());
263 Rib2 rib2(rib2ID, length, width, thick, width2, thick2, rotx, roty, rotz,
264 x, y, z, ndiv);
265 m_rib2s.push_back(rib2);
266 }
267
268 const int nRib3s = content.getNumberNodes("Covers/Rib3");
269 for (int i = 0; i < nRib3s; ++i) {
270 GearDir rib3Content(content);
271 rib3Content.append((format("/Covers/Rib3[%1%]/") % (i + 1)).str());
272
273 const int rib3ID = atoi((rib3Content.getString("@id")).c_str());
274 const double length = rib3Content.getLength("Length");
275 const double width = rib3Content.getLength("Width");
276 const double thick = rib3Content.getLength("Thickness");
277 const double r = rib3Content.getLength("HoleR");
278 const double x = rib3Content.getLength("PosX");
279 const double y = rib3Content.getLength("PosY");
280 const double z = rib3Content.getLength("PosZ");
281 const double rx = rib3Content.getLength("HoleX");
282 const double ry = rib3Content.getLength("HoleY");
283 const double rz = rib3Content.getLength("HoleZ");
284 const int offset = atoi((rib3Content.getString("Offset")).c_str());
285 const int ndiv = atoi((rib3Content.getString("NDiv")).c_str());
286 Rib3 rib3(rib3ID, length, width, thick, r, x, y, z, rx, ry, rz, offset, ndiv);
287 m_rib3s.push_back(rib3);
288 }
289
290 const int nRib4s = content.getNumberNodes("Covers/Rib4");
291 for (int i = 0; i < nRib4s; ++i) {
292 GearDir rib4Content(content);
293 rib4Content.append((format("/Covers/Rib4[%1%]/") % (i + 1)).str());
294
295 const int rib4ID = atoi((rib4Content.getString("@id")).c_str());
296 const double length = rib4Content.getLength("Length");
297 const double width = rib4Content.getLength("Width");
298 const double thick = rib4Content.getLength("Thickness");
299 const double length2 = rib4Content.getLength("Length2");
300 const double width2 = rib4Content.getLength("Width2");
301 const double thick2 = rib4Content.getLength("Thickness2");
302 const double x = rib4Content.getLength("PosX");
303 const double y = rib4Content.getLength("PosY");
304 const double z = rib4Content.getLength("PosZ");
305 const double x2 = rib4Content.getLength("HoleX");
306 const double y2 = rib4Content.getLength("HoleY");
307 const double z2 = rib4Content.getLength("HoleZ");
308 const int offset = atoi((rib4Content.getString("Offset")).c_str());
309 const int ndiv = atoi((rib4Content.getString("NDiv")).c_str());
310 Rib4 rib4(rib4ID, length, width, thick, length2, width2, thick2, x, y, z, x2, y2, z2, offset, ndiv);
311 m_rib4s.push_back(rib4);
312 }
313
314 const int nRib5s = content.getNumberNodes("Covers/Rib5");
315 for (int i = 0; i < nRib5s; ++i) {
316 GearDir rib5Content(content);
317 rib5Content.append((format("/Covers/Rib5[%1%]/") % (i + 1)).str());
318
319 const int rib5ID = atoi((rib5Content.getString("@id")).c_str());
320 const double dr = rib5Content.getLength("DR");
321 const double dz = rib5Content.getLength("DZ");
322 const double width = rib5Content.getLength("Width");
323 const double thick = rib5Content.getLength("Thickness");
324 const double rin = rib5Content.getLength("Rin");
325 const double x = rib5Content.getLength("PosX");
326 const double y = rib5Content.getLength("PosY");
327 const double z = rib5Content.getLength("PosZ");
328 const double rotx = rib5Content.getLength("RotX");
329 const double roty = rib5Content.getLength("RotY");
330 const double rotz = rib5Content.getLength("RotZ");
331 const int offset = atoi((rib5Content.getString("Offset")).c_str());
332 const int ndiv = atoi((rib5Content.getString("NDiv")).c_str());
333 Rib5 rib5(rib5ID, dr, dz, width, thick, rin, x, y, z,
334 rotx, roty, rotz, offset, ndiv);
335 m_rib5s.push_back(rib5);
336 }
337
338
339 // Sense wire.
340 GearDir senseWire(content);
341 senseWire.append("/SenseWire/");
342 m_senseWireDiameter = senseWire.getLength("Diameter");
343 // B2INFO("m_senseWireDiameter= " << m_senseWireDiameter);
344 m_senseWireNumbers = atoi((senseWire.getString("Number")).c_str());
345
346 // Field wire.
347 GearDir fieldWire(content);
348 fieldWire.append("/FieldWire/");
349 m_fieldWireDiameter = fieldWire.getLength("Diameter");
350 // B2INFO("m_fieldWireDiameter= " << m_fieldWireDiameter);
351 m_fieldWireNumbers = atoi((fieldWire.getString("Number")).c_str());
352
353
354 // Feedthrough.
355 m_feedThroughLength = content.getLength("/FeedThrough/Length");
356 // B2INFO("m_feedThroughLength= " << m_feedThroughLength);
357
358 // Get control switch for gas and wire material definition
359 m_clockFrequency = content.getDouble("ClockFrequencyForTDC");
360 m_nominalSpaceResolution = content.getLength("SenseWire/SpaceResol");
361
362}
void appendNode(double rmin, double rmax, double z)
Append a new node.
Definition: CDCGeometry.cc:17
GearDir is the basic class used for accessing the parameter store.
Definition: GearDir.h:31
static const double mm
[millimeters]
Definition: Unit.h:70

Member Data Documentation

◆ m_clockFrequency

double m_clockFrequency
private

Clock frequency.

Definition at line 1697 of file CDCGeometry.h.

◆ m_cover2s

std::vector<Cover2> m_cover2s
private

Cover2s.

Definition at line 1684 of file CDCGeometry.h.

◆ m_covers

std::vector<Cover> m_covers
private

Covers.

Definition at line 1683 of file CDCGeometry.h.

◆ m_endplates

std::vector<EndPlate> m_endplates
private

Endplate.

Definition at line 1680 of file CDCGeometry.h.

◆ m_feedThroughLength

double m_feedThroughLength = 1.5
private

Feedthrough length (cm).

Definition at line 1696 of file CDCGeometry.h.

◆ m_fiducialRmax

double m_fiducialRmax
private

Maximum radius of the CDC fiducial volume.

Definition at line 1674 of file CDCGeometry.h.

◆ m_fiducialRmin

double m_fiducialRmin
private

Minimum radius of the CDC fiducial volume.

Definition at line 1673 of file CDCGeometry.h.

◆ m_fieldLayers

std::vector<FieldLayer> m_fieldLayers
private

Field layer.

Definition at line 1677 of file CDCGeometry.h.

◆ m_fieldWireDiameter

double m_fieldWireDiameter = 0.0126
private

Field wire diameter (cm).

Definition at line 1694 of file CDCGeometry.h.

◆ m_fieldWireNumbers

int m_fieldWireNumbers = 42240
private

Number of field wires.

Definition at line 1695 of file CDCGeometry.h.

◆ m_firstLayerOffset

ushort m_firstLayerOffset = 0
private

Offset of the first layer (for reduced CDC studies)

Definition at line 1703 of file CDCGeometry.h.

◆ m_firstSuperLayerOffset

ushort m_firstSuperLayerOffset = 0
private

Offset of the first super layer (for reduced CDC studies)

Definition at line 1704 of file CDCGeometry.h.

◆ m_frontends

std::vector<Frontend> m_frontends
private

Electronics board.

Definition at line 1681 of file CDCGeometry.h.

◆ m_globalOffsetA

double m_globalOffsetA = 0.0
private

Offset angle a of the whole cdc wrt B2 coord system (rad).

Definition at line 1670 of file CDCGeometry.h.

◆ m_globalOffsetB

double m_globalOffsetB = 0.0
private

Offset angle b of the whole cdc wrt B2 coord system (rad).

Definition at line 1671 of file CDCGeometry.h.

◆ m_globalOffsetC

double m_globalOffsetC = 0.0
private

Offset angle c of the whole cdc wrt B2 coord system (rad).

Definition at line 1672 of file CDCGeometry.h.

◆ m_globalOffsetX

double m_globalOffsetX = 0.0
private

Offset x of the whole cdc wrt B2 coord system (cm).

Definition at line 1667 of file CDCGeometry.h.

◆ m_globalOffsetY

double m_globalOffsetY = 0.0
private

Offset y of the whole cdc wrt B2 coord system (cm).

Definition at line 1668 of file CDCGeometry.h.

◆ m_globalOffsetZ

double m_globalOffsetZ = 0.0
private

Offset z of the whole cdc wrt B2 coord system (cm).

Definition at line 1669 of file CDCGeometry.h.

◆ m_globalPhiRotation

double m_globalPhiRotation = 0.0
private

Global rotation in phi (rad).

Definition at line 1666 of file CDCGeometry.h.

◆ m_innerWalls

std::vector<InnerWall> m_innerWalls
private

Inner wall.

Definition at line 1678 of file CDCGeometry.h.

◆ m_maxNCellsPerLayer

ushort m_maxNCellsPerLayer = 384
private

Maximum number wires within a layer.

Definition at line 1705 of file CDCGeometry.h.

◆ m_maxNFieldLayers

ushort m_maxNFieldLayers = 55
private

Maximum number of Field Wire Layers.

Definition at line 1701 of file CDCGeometry.h.

◆ m_maxNSenseLayers

ushort m_maxNSenseLayers = 56
private

Maximum number of Sense Wire Layers.

Definition at line 1700 of file CDCGeometry.h.

◆ m_maxNSuperLayers

ushort m_maxNSuperLayers = 9
private

Maximum number of Super Layers.

Definition at line 1702 of file CDCGeometry.h.

◆ m_mother

MotherVolume m_mother
private

CDC mother volume.

Definition at line 1675 of file CDCGeometry.h.

◆ m_neutronShields

std::vector<NeutronShield> m_neutronShields
private

Neutron shields.

Definition at line 1682 of file CDCGeometry.h.

◆ m_nominalSpaceResolution

double m_nominalSpaceResolution
private

Nominal space resolution.

Definition at line 1698 of file CDCGeometry.h.

◆ m_outerWalls

std::vector<OuterWall> m_outerWalls
private

Outer wall.

Definition at line 1679 of file CDCGeometry.h.

◆ m_rib2s

std::vector<Rib2> m_rib2s
private

Rib2s.

Definition at line 1686 of file CDCGeometry.h.

◆ m_rib3s

std::vector<Rib3> m_rib3s
private

Rib3s.

Definition at line 1687 of file CDCGeometry.h.

◆ m_rib4s

std::vector<Rib4> m_rib4s
private

Rib4s.

Definition at line 1688 of file CDCGeometry.h.

◆ m_rib5s

std::vector<Rib5> m_rib5s
private

Rib5s.

Definition at line 1689 of file CDCGeometry.h.

◆ m_ribs

std::vector<Rib> m_ribs
private

Ribs.

Definition at line 1685 of file CDCGeometry.h.

◆ m_senseLayers

std::vector<SenseLayer> m_senseLayers
private

Sense layer.

Definition at line 1676 of file CDCGeometry.h.

◆ m_senseWireDiameter

double m_senseWireDiameter = 0.003
private

Sense wire diameter (cm).

Definition at line 1691 of file CDCGeometry.h.

◆ m_senseWireNumbers

int m_senseWireNumbers = 14336
private

Number of sense wires.

Definition at line 1692 of file CDCGeometry.h.

◆ m_senseWireTension

double m_senseWireTension = 50.0
private

Sense wire tension (gW).

Definition at line 1693 of file CDCGeometry.h.


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