Project
Loading...
Searching...
No Matches
TRKLayer.h
Go to the documentation of this file.
1// Copyright 2019-2020 CERN and copyright holders of ALICE O2.
2// See https://alice-o2.web.cern.ch/copyright for details of the copyright holders.
3// All rights not expressly granted are reserved.
4//
5// This software is distributed under the terms of the GNU General Public
6// License v3 (GPL Version 3), copied verbatim in the file "COPYING".
7//
8// In applying this license CERN does not waive the privileges and immunities
9// granted to it by virtue of its status as an Intergovernmental Organization
10// or submit itself to any jurisdiction.
11
12#ifndef ALICEO2_TRK_LAYER_H
13#define ALICEO2_TRK_LAYER_H
14
15#include "TRKBase/Specs.h"
16#include <TGeoManager.h>
17
18#include <Rtypes.h>
19
20#include <string>
21#include <utility>
22
23namespace o2
24{
25namespace trk
26{
29 X2X0
30};
31
33{
34 public:
36 TRKCylindricalLayer(int layerNumber, std::string layerName, float rInn, float length, float thickOrX2X0, MatBudgetParamMode mode);
37 virtual ~TRKCylindricalLayer() = default;
38
39 auto getInnerRadius() const { return mInnerRadius; }
40 auto getOuterRadius() const { return mOuterRadius; }
41 auto getZ() const { return mLength; }
42 auto getx2X0() const { return mX2X0; }
43 auto getChipThickness() const { return mChipThickness; }
44 auto getNumber() const { return mLayerNumber; }
45 auto getName() const { return mLayerName; }
46
47 virtual TGeoVolume* createSensor();
48 virtual TGeoVolume* createMetalStack();
49 virtual void createLayer(TGeoVolume* motherVolume);
50
51 protected:
52 // User defined parameters for the layer, to be set in the constructor
54 std::string mLayerName;
57 float mLength;
58 float mX2X0;
60
61 // Fixed parameters for the layer, to be set based on the specifications of the chip and module
63
64 static constexpr float Si_X0 = 9.5f;
65
67};
68
70{
71 public:
72 TRKSegmentedLayer() = default;
73 TRKSegmentedLayer(int layerNumber, std::string layerName, float rInn, float tiltAngle, int numberOfStaves, int numberOfModules, float thickOrX2X0, MatBudgetParamMode mode);
74 ~TRKSegmentedLayer() override = default;
75
76 TGeoVolume* createSensor() override;
77 TGeoVolume* createDeadzone();
78 TGeoVolume* createMetalStack() override;
79 virtual TGeoVolume* createChip();
80 virtual TGeoVolume* createModule();
81 virtual TGeoVolume* createStave() = 0;
82 void createLayer(TGeoVolume* motherVolume) override = 0;
83
84 protected:
88 bool mIsFlipped = false;
89
90 // Fixed parameters for the layer, to be set based on the specifications of the chip and module
93 static constexpr double sDeadzoneWidth = constants::moduleMLOT::chip::passiveEdgeReadOut;
95 static constexpr double sModuleWidth = constants::moduleMLOT::width;
96 static constexpr int sHalfNumberOfChips = 4;
97
98 // TGeo objects outside logical volumes can cause errors
99 static constexpr float sLogicalVolumeThickness = 1.3;
100
101 // For the segmented layers, because of tilting and staggering the bounding radii can be different
102 // from the inner radius and inner radius + thickness.
103 // This function calculates the bounding radii based on the geometry of the stave and the tilt angle,
104 // to ensure that the layer volume is large enough to contain all the staves without overlaps.
105 virtual std::pair<float, float> getBoundingRadii(double staveWidth) const;
106
108};
109
111{
112 public:
113 TRKMLLayer() = default;
114 TRKMLLayer(int layerNumber, std::string layerName, float rInn, float staggerOffset, float tiltAngle, int numberOfStaves, int numberOfModules, float thickOrX2X0, MatBudgetParamMode mode);
115 ~TRKMLLayer() override = default;
116
117 TGeoVolume* createStave() override;
118 void createLayer(TGeoVolume* motherVolume) override;
119
120 private:
121 float mStaggerOffset;
122
123 static constexpr double sStaveWidth = constants::ML::width;
124 static constexpr int sFlippedLayerNumber = 3;
125
126 // Override to account for the staggering offset present in specific ML layers
127 std::pair<float, float> getBoundingRadii(double staveWidth) const override;
128
129 ClassDefOverride(TRKMLLayer, 0);
130};
131
133{
134 public:
135 TRKOTLayer() = default;
136 TRKOTLayer(int layerNumber, std::string layerName, float rInn, float tiltAngle, int numberOfStaves, int numberOfModules, float thickOrX2X0, MatBudgetParamMode mode);
137 ~TRKOTLayer() override = default;
138
139 TGeoVolume* createStave() override;
140 TGeoVolume* createHalfStave();
141 void createLayer(TGeoVolume* motherVolume) override;
142
143 protected:
144 static constexpr float sGapBetweenOuterTrackerBarrelHalves = 0.8; // cm, gap between the two halves of the OT barrel
145
146 private:
147 static constexpr double sHalfStaveWidth = constants::OT::halfstave::width;
148 static constexpr double sInStaveOverlap = constants::moduleMLOT::gaps::outerEdgeLongSide + constants::moduleMLOT::chip::passiveEdgeReadOut + 0.1; // 1.5mm outer-edge + 1mm deadzone + 1mm (true) overlap
149 static constexpr double sStaveWidth = constants::OT::width - sInStaveOverlap;
150
151 // Override to account for the staggering offset present in OT layers
152 std::pair<float, float> getBoundingRadii(double staveWidth) const override;
153
154 ClassDefOverride(TRKOTLayer, 0);
155};
156
157// Simplified-realistic OT barrel: modules built from their real parts (FPC, cold plate,
158// connector, capacitors, brackets), two-row staves overlapping in phi, four quarter
159// barrels. Dimensions in constants::OT.
161{
162 public:
164 TRKOTLayerRealistic(int layerNumber, std::string layerName, float rInn, float tiltAngle, int numberOfStaves, int numberOfModules, float thickOrX2X0, MatBudgetParamMode mode);
165 ~TRKOTLayerRealistic() override = default;
166
167 TGeoVolume* createChip() override;
168 TGeoVolume* createModule() override;
169 TGeoVolume* createStave() override;
170 TGeoVolume* createHalfStave();
171 void createLayer(TGeoVolume* motherVolume) override;
172
173 private:
174 TGeoVolume* createFPC();
175 TGeoVolume* createColdPlate();
176 TGeoVolume* createCoolingPipe();
177 TGeoVolume* createEndOfStaveCard();
178 TGeoVolume* createSupportRing(double rMin, double rMax, double phi1, double phi2, int id);
179 void addConnector(TGeoVolume* moduleVol, double rMid);
180 void addCapacitors(TGeoVolume* moduleVol, double rMid);
181 void addBrackets(TGeoVolume* moduleVol, double rMid);
182
183 double getRowHalfLength() const; // z half-length of one module row (= one eta half-barrel)
184 double getPipeTrim() const; // z removed from the mid-rapidity pipe end to clear the support ring
185
186 std::pair<float, float> getBoundingRadii(double staveWidth) const override;
187
188 ClassDefOverride(TRKOTLayerRealistic, 0);
189};
190
191} // namespace trk
192} // namespace o2
193#endif // ALICEO2_TRK_LAYER_H
specs of the ALICE3 TRK
ClassDef(TRKCylindricalLayer, 0)
static constexpr float Si_X0
Definition TRKLayer.h:64
virtual void createLayer(TGeoVolume *motherVolume)
Definition TRKLayer.cxx:73
auto getChipThickness() const
Definition TRKLayer.h:43
virtual TGeoVolume * createSensor()
Definition TRKLayer.cxx:51
auto getInnerRadius() const
Definition TRKLayer.h:39
virtual ~TRKCylindricalLayer()=default
virtual TGeoVolume * createMetalStack()
Definition TRKLayer.cxx:62
static constexpr double sSensorThickness
Definition TRKLayer.h:62
auto getOuterRadius() const
Definition TRKLayer.h:40
void createLayer(TGeoVolume *motherVolume) override
Definition TRKLayer.cxx:268
TGeoVolume * createStave() override
Definition TRKLayer.cxx:248
~TRKMLLayer() override=default
TGeoVolume * createModule() override
Definition TRKLayer.cxx:632
TGeoVolume * createChip() override
Definition TRKLayer.cxx:468
void createLayer(TGeoVolume *motherVolume) override
Definition TRKLayer.cxx:726
TGeoVolume * createHalfStave()
Definition TRKLayer.cxx:674
TGeoVolume * createStave() override
Definition TRKLayer.cxx:694
~TRKOTLayerRealistic() override=default
TGeoVolume * createHalfStave()
Definition TRKLayer.cxx:379
void createLayer(TGeoVolume *motherVolume) override
Definition TRKLayer.cxx:415
static constexpr float sGapBetweenOuterTrackerBarrelHalves
Definition TRKLayer.h:144
TGeoVolume * createStave() override
Definition TRKLayer.cxx:399
~TRKOTLayer() override=default
static constexpr double sChipWidth
Definition TRKLayer.h:91
virtual TGeoVolume * createStave()=0
TGeoVolume * createMetalStack() override
Definition TRKLayer.cxx:122
void createLayer(TGeoVolume *motherVolume) override=0
static constexpr float sLogicalVolumeThickness
Definition TRKLayer.h:99
static constexpr int sHalfNumberOfChips
Definition TRKLayer.h:96
TGeoVolume * createSensor() override
Definition TRKLayer.cxx:100
ClassDefOverride(TRKSegmentedLayer, 0)
virtual TGeoVolume * createModule()
Definition TRKLayer.cxx:161
static constexpr double sChipLength
Definition TRKLayer.h:92
virtual TGeoVolume * createChip()
Definition TRKLayer.cxx:133
static constexpr double sDeadzoneWidth
Definition TRKLayer.h:93
~TRKSegmentedLayer() override=default
static constexpr double sModuleLength
Definition TRKLayer.h:94
static constexpr double sModuleWidth
Definition TRKLayer.h:95
TGeoVolume * createDeadzone()
Definition TRKLayer.cxx:111
virtual std::pair< float, float > getBoundingRadii(double staveWidth) const
Definition TRKLayer.cxx:193
GLenum mode
Definition glcorearb.h:266
GLuint GLsizei GLsizei * length
Definition glcorearb.h:790
constexpr double width
Definition Specs.h:106
constexpr double width
Definition Specs.h:124
constexpr double outerEdgeLongSide
Definition Specs.h:94
constexpr double length
Definition Specs.h:98
constexpr double width
Definition Specs.h:97
MatBudgetParamMode
Definition TRKLayer.h:27
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...