From 4ec531be35b061a279a5a4ae2e93f134e08f1ba0 Mon Sep 17 00:00:00 2001 From: Felix Schlepper Date: Thu, 8 Oct 2026 11:20:18 +0200 Subject: [PATCH] TRK: IRIS service aluminium from the MaterialManager The IRIS service modules (addIRISServiceModules and addIRISServiceModulesSegmented) created their medium by hand as new TGeoMedium("ALUMINUM", 4, ...): a hard-coded medium ID 4 and all tracking parameters 0, i.e. ifield = 0. ID 4 is already TRK_AIR$, the medium of the TRKLayer* mother volumes and the VD petal cases. Geant4 VMC keys media by ID (TG4GeometryManager::FillMediumMapFromRoot): the second medium with ID 4 reuses the first one's entry and overwrites its ifield with 0. With /mcDet/setIsZeroMagField true, every volume of TRK_AIR$ then gets a zero field, so tracks cross each ML/OT layer volume (1.2-1.5 cm of air around the staves) without bending. The geometry file still shows TRK_AIR$ with ifield = 2. A muon gun (p 2-5 GeV, |eta| < 0.8, A3IP + TRK, ALICE 3 field 2 T) measures the field each pair of consecutive layers turned the momentum in: before 0.84 T (7 -> 9 cm) rising to 1.95 T (60 -> 80 cm), the VD 2.00 T; after, every pair 1.99-2.01 T. The aluminium is now registered in TRKServices::createMaterials with the TRK's field parameters (ALICE3_TRKSERVICES_ALUMINIUM) and taken from MaterialManager::getTGeoMedium, which gives it a unique ID. The material is unchanged (A, Z, density, radiation and interaction lengths). Co-Authored-By: Claude Opus 5 Signed-off-by: Felix Schlepper --- .../ALICE3/TRKFT3/TRK/simulation/src/TRKServices.cxx | 2 ++ .../TRKFT3/TRK/simulation/src/VDGeometryBuilder.cxx | 12 ++++++------ 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/Detectors/Upgrades/ALICE3/TRKFT3/TRK/simulation/src/TRKServices.cxx b/Detectors/Upgrades/ALICE3/TRKFT3/TRK/simulation/src/TRKServices.cxx index ec028c16086e7..8165e40ae0124 100644 --- a/Detectors/Upgrades/ALICE3/TRKFT3/TRK/simulation/src/TRKServices.cxx +++ b/Detectors/Upgrades/ALICE3/TRKFT3/TRK/simulation/src/TRKServices.cxx @@ -113,6 +113,7 @@ void TRKServices::createMaterials() matmgr.Mixture("ALICE3_TRKSERVICES", 74, "ALUMINIUM5083", aAl5083, zAl5083, dAl5083, 9, wAl5083); // AL5083 - Candidate for IRIS vacuum vessel matmgr.Mixture("ALICE3_TRKSERVICES", 75, "ALUMINIUMBERYLLIUMMETAL", aAlBeMet, zAlBeMet, dAlBeMet, 2, wAlBeMet); // Aluminium-Beryllium metal - Candidate for IRIS vacuum vessel matmgr.Material("ALICE3_TRKSERVICES", 76, "CARBONFIBERM55J6K", 12.0107, 6, 1.92, 22.4, 45.4); // Carbon Fiber M55J + matmgr.Material("ALICE3_TRKSERVICES", 78, "ALUMINIUM", 26.9815, 13, 2.70, 8.897, 39.70); // Aluminium for the IRIS service modules matmgr.Mixture("ALICE3_PIPE", 77, "VACUUM", aAir, zAir, dAir1, 4, wAir); matmgr.Medium("ALICE3_TRKSERVICES", 1, "CERAMIC", 66, 0, ifield, fieldm, tmaxfd, stemax, deemax, epsil, stmin); // Ceramic for cold plate @@ -127,6 +128,7 @@ void TRKServices::createMaterials() matmgr.Medium("ALICE3_TRKSERVICES", 10, "ALUMINIUMBERYLLIUMMETAL", 75, 0, ifield, fieldm, tmaxfd, stemax, deemax, epsil, stmin); // AlBeMet for IRIS vacuum vessel matmgr.Medium("ALICE3_TRKSERVICES", 11, "CARBONFIBERM55J6K", 76, 0, ifield, fieldm, tmaxfd, stemax, deemax, epsil, stmin); // Carbon Fiber M55J matmgr.Medium("ALICE3_PIPE", 12, "VACUUM", 77, 0, ifield, fieldm, tmaxfd, stemax, deemax, epsil, stmin); // Vacuum inside the beam pipe + matmgr.Medium("ALICE3_TRKSERVICES", 13, "ALUMINIUM", 78, 0, ifield, fieldm, tmaxfd, stemax, deemax, epsil, stmin); // Aluminium for the IRIS service modules } void TRKServices::createServices(TGeoVolume* motherVolume) diff --git a/Detectors/Upgrades/ALICE3/TRKFT3/TRK/simulation/src/VDGeometryBuilder.cxx b/Detectors/Upgrades/ALICE3/TRKFT3/TRK/simulation/src/VDGeometryBuilder.cxx index 809923b048234..ba44b645c1f5a 100644 --- a/Detectors/Upgrades/ALICE3/TRKFT3/TRK/simulation/src/VDGeometryBuilder.cxx +++ b/Detectors/Upgrades/ALICE3/TRKFT3/TRK/simulation/src/VDGeometryBuilder.cxx @@ -541,11 +541,11 @@ static void addIRISServiceModules(TGeoVolume* petalAsm, int nPetals) return; } - auto* matAl = new TGeoMaterial("ALUMINUM", 26.9815, 13, 2.70); - const TGeoMedium* med = new TGeoMedium("ALUMINUM", 4, matAl); + auto& matmgr = o2::base::MaterialManager::Instance(); + const TGeoMedium* med = matmgr.getTGeoMedium("ALICE3_TRKSERVICES_ALUMINIUM"); if (!med) { - LOGP(error, "addIRISServiceModules: ALUMINUM medium not found."); + LOGP(error, "addIRISServiceModules: ALICE3_TRKSERVICES_ALUMINIUM medium not found."); return; } @@ -617,11 +617,11 @@ static void addIRISServiceModulesSegmented(TGeoVolume* petalAsm, int nPetals) // --- Petal φ-span (segment) const double halfPhi = 0.5 * (360.0 / double(nPetals)); - auto* matAl = new TGeoMaterial("ALUMINUM", 26.9815, 13, 2.70); - const TGeoMedium* med = new TGeoMedium("ALUMINUM", 4, matAl); + auto& matmgr = o2::base::MaterialManager::Instance(); + const TGeoMedium* med = matmgr.getTGeoMedium("ALICE3_TRKSERVICES_ALUMINIUM"); if (!med) { - LOGP(error, "addIRISServiceModules: ALUMINUM medium not found."); + LOGP(error, "addIRISServiceModulesSegmented: ALICE3_TRKSERVICES_ALUMINIUM medium not found."); return; }