Skip to content

Commit c0831ad

Browse files
Cas1997mconcas
andauthored
ALICE3: TRK now hosts IRIS tracker which is divided into petal cases and made retractable (#13953)
* ALICE3: TRK now hosts IRIS tracker which is divided into petal cases and made retractable * Fixed hits in sensitive volumes + fixed CMakeLists.txt * Applied clang * Uncommented services * Final bug fix * Fixed placement of the beam pipe from earlier PR * Applied clang --------- Co-authored-by: Matteo Concas <matteo.concas@cern.ch>
1 parent 46380fc commit c0831ad

File tree

17 files changed

+764
-240
lines changed

17 files changed

+764
-240
lines changed

Detectors/Upgrades/ALICE3/FT3/simulation/src/Detector.cxx

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -184,8 +184,8 @@ void Detector::buildBasicFT3(const FT3BaseParam& param)
184184
//_________________________________________________________________________________________________
185185
void Detector::buildFT3V1()
186186
{
187-
//Build FT3 detector according to
188-
//https://indico.cern.ch/event/992488/contributions/4174473/attachments/2168881/3661331/tracker_parameters_werner_jan_11_2021.pdf
187+
// Build FT3 detector according to
188+
// https://indico.cern.ch/event/992488/contributions/4174473/attachments/2168881/3661331/tracker_parameters_werner_jan_11_2021.pdf
189189

190190
LOG(info) << "Building FT3 Detector: V1";
191191

@@ -284,17 +284,15 @@ void Detector::buildFT3NewVacuumVessel()
284284
// to adhere to the changes that were presented at the ALICE 3 Upgrade days in March 2024
285285
// Inner radius at C-side to 7 cm
286286
// Inner radius at A-side stays at 5 cm
287+
// 06.02.2025 update: IRIS layers are now in TRK
287288

288289
LOG(info) << "Building FT3 Detector: After Upgrade Days March 2024 version";
289290

290-
mNumberOfLayers = 12;
291+
mNumberOfLayers = 9;
291292
float sensorThickness = 30.e-4;
292293
float layersx2X0 = 1.e-2;
293294
std::vector<std::array<float, 5>> layersConfigCSide{
294-
{26., .5, 2.5, 0.1f * layersx2X0}, // {z_layer, r_in, r_out, Layerx2X0}
295-
{30., .5, 2.5, 0.1f * layersx2X0},
296-
{34., .5, 2.5, 0.1f * layersx2X0},
297-
{77., 7.0, 35., layersx2X0},
295+
{77., 7.0, 35., layersx2X0}, // {z_layer, r_in, r_out, Layerx2X0}
298296
{100., 7.0, 35., layersx2X0},
299297
{122., 7.0, 35., layersx2X0},
300298
{150., 7.0, 68.f, layersx2X0},
@@ -305,10 +303,7 @@ void Detector::buildFT3NewVacuumVessel()
305303
{350., 7.0, 68.f, layersx2X0}};
306304

307305
std::vector<std::array<float, 5>> layersConfigASide{
308-
{26., .5, 2.5, 0.1f * layersx2X0}, // {z_layer, r_in, r_out, Layerx2X0}
309-
{30., .5, 2.5, 0.1f * layersx2X0},
310-
{34., .5, 2.5, 0.1f * layersx2X0},
311-
{77., 5.0, 35., layersx2X0},
306+
{77., 5.0, 35., layersx2X0}, // {z_layer, r_in, r_out, Layerx2X0}
312307
{100., 5.0, 35., layersx2X0},
313308
{122., 5.0, 35., layersx2X0},
314309
{150., 5.0, 68.f, layersx2X0},

Detectors/Upgrades/ALICE3/Passive/include/Alice3DetectorsPassive/Pipe.h

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,6 @@ class Alice3Pipe : public Alice3PassiveBase
2626
~Alice3Pipe() override;
2727
Alice3Pipe(const char* name,
2828
const char* title = "Alice 3 Pipe",
29-
const bool isTRKActivated = false,
30-
const bool isFT3Activated = false,
3129
const float pipeRIn = 0.f,
3230
const float pipeThickness = 0.f,
3331
const float a3ipLength = 0.f,
@@ -50,9 +48,6 @@ class Alice3Pipe : public Alice3PassiveBase
5048
float getVacuumVesselWidth() const { return mVacuumVesselThick; }
5149
float getVacuumVesselLength() const { return mVacuumVesselASideLength; }
5250

53-
bool IsTRKActivated() const { return mIsTRKActivated; }
54-
bool IsFT3Activated() const { return mIsFT3Activated; }
55-
5651
private:
5752
void createMaterials();
5853
Alice3Pipe(const Alice3Pipe& orig) = default;
@@ -62,13 +57,10 @@ class Alice3Pipe : public Alice3PassiveBase
6257
float mPipeThick = 0.; // inner beam pipe section thickness
6358
float mA3IPLength = 0.; // Length of A3IP
6459

65-
float mVacuumVesselRIn = 0.; // inner diameter of the vacuum vessel
66-
float mVacuumVesselThick = 0.; // outer beam pipe section thickness
60+
float mVacuumVesselRIn = 0.; // inner diameter of the vacuum vessel
61+
float mVacuumVesselThick = 0.; // outer beam pipe section thickness
6762
float mVacuumVesselASideLength = 0.; // Length of the A Side of the vacuum vessel around the IP
6863

69-
bool mIsTRKActivated = true; // If TRK is not active don't create TRK layers allocations in the vacuum volume
70-
bool mIsFT3Activated = true;
71-
7264
ClassDefOverride(Alice3Pipe, 1);
7365
};
7466
} // namespace passive

Detectors/Upgrades/ALICE3/Passive/src/Pipe.cxx

Lines changed: 14 additions & 130 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
#include "Alice3DetectorsPassive/Pipe.h"
1313
#include <DetectorsBase/Detector.h>
1414
#include <DetectorsBase/MaterialManager.h>
15-
#include <TGeoTube.h>
16-
#include <TVirtualMC.h>
15+
#include "TGeoTube.h"
16+
#include "TVirtualMC.h"
1717
#include "TGeoManager.h" // for TGeoManager, gGeoManager
1818
#include "TGeoMaterial.h" // for TGeoMaterial
1919
#include "TGeoMedium.h" // for TGeoMedium
@@ -31,17 +31,13 @@ using namespace o2::passive;
3131
Alice3Pipe::Alice3Pipe() : Alice3PassiveBase{"Alice3PIPE", ""} {}
3232
Alice3Pipe::Alice3Pipe(const char* name,
3333
const char* title,
34-
bool isTRKActivated,
35-
bool isFT3Activated,
3634
float pipeRIn,
3735
float pipeThickness,
3836
float a3ipLength,
3937
float vacuumVesselRIn,
4038
float vacuumVesselThickness,
4139
float vacuumVesselASideLength)
4240
: Alice3PassiveBase{name, title},
43-
mIsTRKActivated{isTRKActivated},
44-
mIsFT3Activated{isFT3Activated},
4541
mPipeRIn{pipeRIn},
4642
mPipeThick{pipeThickness},
4743
mA3IPLength{a3ipLength},
@@ -85,7 +81,6 @@ void Alice3Pipe::ConstructGeometry()
8581
auto& matmgr = o2::base::MaterialManager::Instance();
8682

8783
const TGeoMedium* kMedBe = matmgr.getTGeoMedium("ALICE3_PIPE_BE");
88-
const TGeoMedium* kMedVac = matmgr.getTGeoMedium("ALICE3_PIPE_VACUUM");
8984

9085
// Top volume
9186
TGeoVolume* top = gGeoManager->GetVolume("cave");
@@ -96,134 +91,37 @@ void Alice3Pipe::ConstructGeometry()
9691

9792
// We split the naming of the parts if the beam pipe for ALICE 3 into parts
9893
// - pipe A Side
99-
// - vacuum vessel (which hosts the primary vacuum and covers all C Side as well)
100-
// - iris vacuum vessel (which hosts the secondary vacuum)
94+
// - pipe C Side (which hosts the primary vacuum vessel and covers all C Side as well)
10195

10296
// A3IP update
103-
// Vacuum
104-
Double_t pipeASideLength = mA3IPLength / 2. - mVacuumVesselThick - mVacuumVesselASideLength;
105-
Double_t pipeCSideLength = mA3IPLength / 2. + mVacuumVesselASideLength;
106-
TGeoTube* vacuumBasePipe = new TGeoTube("PIPEVACUUM_BASEsh", 0., mPipeRIn, mA3IPLength / 2.);
107-
TGeoTube* vacuumBaseVacuumVessel = new TGeoTube("VACUUM_VESSELVACUUM_BASEsh", mPipeRIn, mVacuumVesselRIn, pipeCSideLength / 2.);
108-
109-
TGeoTranslation* posPipeCSide = new TGeoTranslation("PIPE_CSIDE_POSITION", 0, 0, mVacuumVesselASideLength - pipeCSideLength / 2.);
110-
posPipeCSide->RegisterYourself();
111-
// Excavate volumes from the vacuum such that there is place for the TRK barrel layers and FT3 disc layers of the IRIS tracker
112-
// And the other passive shapes: coldplate, iris tracker vacuum vessel
113-
TGeoCompositeShape* vacuumComposite;
114-
TGeoVolume* vacuumVolume;
115-
TString compositeFormula{"PIPEVACUUM_BASEsh+VACUUM_VESSELVACUUM_BASEsh:PIPE_CSIDE_POSITION"};
116-
TString subtractorsFormula;
117-
118-
if (!mIsTRKActivated) {
119-
std::vector<TGeoTube*> trkLayerShapes;
120-
121-
std::vector<std::array<float, 3>> layersQuotas = {std::array<float, 3>{0.5f, 50.f, 100.e-4}, // TODO: Set layers dynamically. {radius, zLen, thickness}
122-
std::array<float, 3>{1.2f, 50.f, 100.e-4},
123-
std::array<float, 3>{2.5f, 50.f, 100.e-4}};
124-
125-
for (auto iLayer{0}; iLayer < layersQuotas.size(); ++iLayer) { // Create TRK layers shapes
126-
auto& layerData = layersQuotas[iLayer];
127-
trkLayerShapes.emplace_back(new TGeoTube(Form("TRKLAYER_%dsh", iLayer), layerData[0], layerData[0] + layerData[2], layerData[1] / 2.));
128-
if (iLayer != 0) {
129-
subtractorsFormula += "+";
130-
}
131-
subtractorsFormula += Form("TRKLAYER_%dsh", iLayer);
132-
}
133-
134-
// IRIS vacuum vessel and coldplate dimensions
135-
float coldplateRIn = 2.6f; // cm
136-
float coldplateThick = 150.e-3; // cm
137-
float coldplateLength = 50.f; // cm
138-
float irisVacuumVesselInnerRIn = 0.48f; // cm
139-
float irisVacuumVesselOuterRIn = coldplateRIn + coldplateThick;
140-
float irisVacuumVesselLength = 70.f; // cm
141-
float irisVacuumVesselThick = 150.e-4; // cm
142-
143-
// Excavate vacuum for hosting cold plate and IRIS tracker
144-
TGeoTube* coldPlate = new TGeoTube("TRK_COLDPLATEsh", coldplateRIn, coldplateRIn + coldplateThick, coldplateLength / 2.);
145-
subtractorsFormula += "+TRK_COLDPLATEsh";
146-
147-
TGeoTube* irisVacuumVesselInner = new TGeoTube("TRK_IRISVACUUMVESSELINNERsh", irisVacuumVesselInnerRIn, irisVacuumVesselInnerRIn + irisVacuumVesselThick, irisVacuumVesselLength / 2.);
148-
subtractorsFormula += "+TRK_IRISVACUUMVESSELINNERsh";
149-
150-
TGeoTube* irisVacuumVesselOuter = new TGeoTube("TRK_IRISVACUUMVESSELOUTERsh", irisVacuumVesselOuterRIn, irisVacuumVesselOuterRIn + irisVacuumVesselThick, irisVacuumVesselLength / 2.);
151-
subtractorsFormula += "+TRK_IRISVACUUMVESSELOUTERsh";
152-
153-
TGeoTube* irisVacuumVesselWall = new TGeoTube("TRK_IRISVACUUMVESSELWALLsh", irisVacuumVesselInnerRIn, irisVacuumVesselOuterRIn + irisVacuumVesselThick, irisVacuumVesselThick / 2.);
154-
TGeoTranslation* posIrisVacVWallNegZSide = new TGeoTranslation("IRISWALLNEGZ", 0., 0., -irisVacuumVesselLength / 2. - irisVacuumVesselThick / 2.);
155-
posIrisVacVWallNegZSide->RegisterYourself();
156-
subtractorsFormula += "+TRK_IRISVACUUMVESSELWALLsh:IRISWALLNEGZ";
157-
158-
TGeoTranslation* posIrisVacVWallPosZSide = new TGeoTranslation("IRISWALLPOSZ", 0., 0., irisVacuumVesselLength / 2. + irisVacuumVesselThick / 2.);
159-
posIrisVacVWallPosZSide->RegisterYourself();
160-
subtractorsFormula += "+TRK_IRISVACUUMVESSELWALLsh:IRISWALLPOSZ";
161-
}
162-
163-
if (!mIsFT3Activated) {
164-
std::vector<TGeoTube*> ft3DiscShapes;
165-
std::vector<TGeoTranslation*> ft3DiscPositions;
166-
167-
std::vector<std::array<float, 4>> discsQuotas = {std::array<float, 4>{0.5f, 2.5f, 100.e-4, 26.}, // TODO: Set discs dynamically. {rIn, rOut, thickness, zpos}
168-
std::array<float, 4>{0.5f, 2.5f, 100.e-4, 30.},
169-
std::array<float, 4>{0.5f, 2.5f, 100.e-4, 34.},
170-
std::array<float, 4>{0.5f, 2.5f, 100.e-4, -26.},
171-
std::array<float, 4>{0.5f, 2.5f, 100.e-4, -30.},
172-
std::array<float, 4>{0.5f, 2.5f, 100.e-4, -34.}};
173-
TString tempSubtractorsFormula = "";
174-
if (!mIsTRKActivated) {
175-
tempSubtractorsFormula = "+";
176-
}
177-
for (auto iDisc{0}; iDisc < discsQuotas.size(); ++iDisc) {
178-
auto& discData = discsQuotas[iDisc];
179-
ft3DiscShapes.emplace_back(new TGeoTube(Form("FT3DISC_%dsh", iDisc), discData[0], discData[1], discData[2] / 2.));
180-
ft3DiscPositions.emplace_back(new TGeoTranslation(Form("t%d", iDisc), 0., 0., discData[3]));
181-
ft3DiscPositions[iDisc]->RegisterYourself();
182-
if (iDisc != 0) {
183-
tempSubtractorsFormula += "+";
184-
}
185-
tempSubtractorsFormula += Form("FT3DISC_%dsh:t%d", iDisc, iDisc);
186-
}
187-
subtractorsFormula += tempSubtractorsFormula;
188-
}
97+
Double_t pipeASideLength = mA3IPLength / 2. - mVacuumVesselThick - mVacuumVesselASideLength / 2.;
98+
Double_t pipeCSideLength = mA3IPLength / 2. + mVacuumVesselASideLength / 2.;
18999

190100
// Pipe tubes
191101
TGeoTube* pipeASide = new TGeoTube("PIPE_Ash", mPipeRIn, mPipeRIn + mPipeThick, pipeASideLength / 2.);
192102
TGeoTube* pipeCSide = new TGeoTube("PIPE_Csh", mVacuumVesselRIn, mVacuumVesselRIn + mVacuumVesselThick, pipeCSideLength / 2.);
193103
TGeoTube* vacuumVesselWall = new TGeoTube("VACUUM_VESSEL_WALLsh", mPipeRIn, mVacuumVesselRIn + mVacuumVesselThick, mVacuumVesselThick / 2.);
194104

195105
// Pipe and vacuum vessel positions
196-
TGeoTranslation* posVacuumVesselWall = new TGeoTranslation("WALL_POSITION", 0, 0, mVacuumVesselASideLength + mVacuumVesselThick / 2.);
197-
posVacuumVesselWall->RegisterYourself();
198-
TGeoTranslation* posPipeASide = new TGeoTranslation("PIPE_ASIDE_POSITION", 0, 0, mVacuumVesselASideLength + mVacuumVesselThick + pipeASideLength / 2.);
106+
TGeoTranslation* posPipeASide = new TGeoTranslation("PIPE_ASIDE_POSITION", 0, 0, mVacuumVesselASideLength / 2. + mVacuumVesselThick + pipeASideLength / 2.);
199107
posPipeASide->RegisterYourself();
108+
TGeoTranslation* posPipeCSide = new TGeoTranslation("PIPE_CSIDE_POSITION", 0, 0, mVacuumVesselASideLength / 2. - pipeCSideLength / 2.);
109+
posPipeCSide->RegisterYourself();
110+
TGeoTranslation* posVacuumVesselWall = new TGeoTranslation("WALL_POSITION", 0, 0, mVacuumVesselASideLength / 2. + mVacuumVesselThick / 2.);
111+
posVacuumVesselWall->RegisterYourself();
200112

201113
// Pipe composite shape and volume
202114
TString pipeCompositeFormula =
203-
"VACUUM_VESSEL_WALLsh:WALL_POSITION"
204-
"+PIPE_Ash:PIPE_ASIDE_POSITION"
205-
"+PIPE_Csh:PIPE_CSIDE_POSITION";
206-
207-
if (subtractorsFormula.Length()) {
208-
LOG(info) << "Subtractors formula before : " << subtractorsFormula;
209-
subtractorsFormula = Form("-(%s)", subtractorsFormula.Data());
210-
LOG(info) << "Subtractors formula after: " << subtractorsFormula;
211-
212-
vacuumComposite = new TGeoCompositeShape("VACUUM_BASEsh", (compositeFormula + subtractorsFormula).Data());
213-
vacuumVolume = new TGeoVolume("VACUUM_BASE", vacuumComposite, kMedVac);
214-
} else {
215-
vacuumComposite = new TGeoCompositeShape("VACUUM_BASEsh", compositeFormula.Data());
216-
vacuumVolume = new TGeoVolume("VACUUM_BASE", vacuumComposite, kMedVac);
217-
}
115+
"PIPE_Ash:PIPE_ASIDE_POSITION"
116+
"+PIPE_Csh:PIPE_CSIDE_POSITION"
117+
"+VACUUM_VESSEL_WALLsh:WALL_POSITION";
218118

219119
TGeoCompositeShape* pipeComposite = new TGeoCompositeShape("A3IPsh", pipeCompositeFormula);
220120
TGeoVolume* pipeVolume = new TGeoVolume("A3IP", pipeComposite, kMedBe);
221121

222122
// Add everything to the barrel
223-
barrel->AddNode(vacuumVolume, 1, new TGeoTranslation(0, 30.f, 0));
224123
barrel->AddNode(pipeVolume, 1, new TGeoTranslation(0, 30.f, 0));
225124

226-
vacuumVolume->SetLineColor(kGreen + 3);
227125
pipeVolume->SetLineColor(kGreen + 3);
228126
}
229127

@@ -236,15 +134,6 @@ void Alice3Pipe::createMaterials()
236134
float sxmgmx = 10.;
237135
o2::base::Detector::initFieldTrackingParams(isxfld, sxmgmx);
238136

239-
//
240-
// Air
241-
//
242-
float aAir[4] = {12.0107, 14.0067, 15.9994, 39.948};
243-
float zAir[4] = {6., 7., 8., 18.};
244-
float wAir[4] = {0.000124, 0.755267, 0.231781, 0.012827};
245-
float dAir = 1.20479E-3;
246-
float dAir1 = 1.20479E-11;
247-
248137
// ****************
249138
// Defines tracking media parameters.
250139
//
@@ -258,13 +147,8 @@ void Alice3Pipe::createMaterials()
258147
auto& matmgr = o2::base::MaterialManager::Instance();
259148

260149
// Beryllium
261-
matmgr.Material("ALICE3_PIPE", 5, "BERILLIUM$", 9.01, 4., 1.848, 35.3, 36.7);
150+
matmgr.Material("ALICE3_PIPE", 5, "BERYLLIUM$", 9.01, 4., 1.848, 35.3, 36.7);
262151
matmgr.Medium("ALICE3_PIPE", 5, "BE", 5, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
263-
264-
// Vacuum
265-
matmgr.Mixture("ALICE3_PIPE", 16, "VACUUM$ ", aAir, zAir, dAir1, 4, wAir);
266-
267-
matmgr.Medium("ALICE3_PIPE", 16, "VACUUM", 16, 0, isxfld, sxmgmx, tmaxfd, stemax, deemax, epsil, stmin);
268152
}
269153

270154
// ----------------------------------------------------------------------------

Detectors/Upgrades/ALICE3/TRK/base/include/TRKBase/TRKBaseParam.h

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ enum eLayout {
2929
struct TRKBaseParam : public o2::conf::ConfigurableParamHelper<TRKBaseParam> {
3030
std::string configFile = "";
3131
float serviceTubeX0 = 0.02f; // X0 Al2O3
32+
Bool_t irisOpen = false;
33+
3234
eLayout layoutML = kCylinder; // Type of segmentation for the middle layers
3335
eLayout layoutOL = kCylinder; // Type of segmentation for the outer layers
3436

Detectors/Upgrades/ALICE3/TRK/simulation/CMakeLists.txt

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,17 @@ o2_add_library(TRKSimulation
1313
SOURCES src/TRKLayer.cxx
1414
src/Detector.cxx
1515
src/TRKServices.cxx
16+
src/TRKPetalCase.cxx
17+
src/TRKPetalLayer.cxx
18+
src/TRKPetalDisk.cxx
1619
PUBLIC_LINK_LIBRARIES O2::TRKBase
1720
O2::FT3Simulation
1821
O2::ITSMFTSimulation)
1922

2023
o2_target_root_dictionary(TRKSimulation
2124
HEADERS include/TRKSimulation/Detector.h
2225
include/TRKSimulation/TRKLayer.h
23-
include/TRKSimulation/TRKServices.h)
26+
include/TRKSimulation/TRKServices.h
27+
include/TRKSimulation/TRKPetalCase.h
28+
include/TRKSimulation/TRKPetalLayer.h
29+
include/TRKSimulation/TRKPetalDisk.h)

Detectors/Upgrades/ALICE3/TRK/simulation/include/TRKSimulation/Detector.h

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,7 @@
1717

1818
#include "TRKSimulation/TRKLayer.h"
1919
#include "TRKSimulation/TRKServices.h"
20+
#include "TRKSimulation/TRKPetalCase.h"
2021
#include "TRKBase/GeometryTGeo.h"
2122

2223
#include <TLorentzVector.h>
@@ -87,7 +88,11 @@ class Detector : public o2::base::DetImpl<Detector>
8788
GeometryTGeo* mGeometryTGeo; //!
8889
std::vector<o2::itsmft::Hit>* mHits; // ITSMFT ones for the moment
8990
std::vector<TRKLayer> mLayers;
90-
TRKServices mServices;
91+
TRKServices mServices; // Houses the services of the TRK, but not the Iris tracker
92+
std::vector<TRKPetalCase> mPetalCases; // Houses the Iris tracker and its services. Created fully in the beam pipe
93+
94+
std::vector<std::string> mFirstOrLastLayers; // Names of the first or last layers
95+
bool InsideFirstOrLastLayer(std::string layerName);
9196

9297
void defineSensitiveVolumes();
9398

0 commit comments

Comments
 (0)