Skip to content

Commit e0bf0b3

Browse files
committed
Fix extrusions for OT layers
1 parent e8d17ce commit e0bf0b3

File tree

2 files changed

+12
-2
lines changed

2 files changed

+12
-2
lines changed

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

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,9 @@ class TRKOTLayer : public TRKSegmentedLayer
146146
static constexpr double sInStaveOverlap = constants::moduleMLOT::gaps::outerEdgeLongSide + constants::moduleMLOT::chip::passiveEdgeReadOut + 0.1; // 1.5mm outer-edge + 1mm deadzone + 1mm (true) overlap
147147
static constexpr double sStaveWidth = constants::OT::width - sInStaveOverlap;
148148

149+
// Override to account for the staggering offset present in OT layers
150+
std::pair<float, float> getBoundingRadii(double staveWidth) const override;
151+
149152
ClassDefOverride(TRKOTLayer, 0)
150153
};
151154

Detectors/Upgrades/ALICE3/TRK/simulation/src/TRKLayer.cxx

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ std::pair<float, float> TRKSegmentedLayer::getBoundingRadii(double staveWidth) c
234234
}
235235

236236
// Add a 10-micron safety margin to prevent false-positive overlaps in ROOT's geometry checker caused by floating-point inaccuracies
237-
const float precisionMargin = 0.001;
237+
const float precisionMargin = 0.05f;
238238

239239
return {radiusMin - precisionMargin, radiusMax + precisionMargin};
240240
}
@@ -353,7 +353,7 @@ std::pair<float, float> TRKMLLayer::getBoundingRadii(double staveWidth) const
353353
float v_max = avgRadiusOuter * std::cos(alpha) + staveSizeY / 2.0;
354354
float radiusMax = std::sqrt(u_max * u_max + v_max * v_max);
355355

356-
const float precisionMargin = 0.001;
356+
const float precisionMargin = 0.05f;
357357

358358
return {radiusMin, radiusMax + precisionMargin};
359359
}
@@ -448,6 +448,13 @@ void TRKOTLayer::createLayer(TGeoVolume* motherVolume)
448448
LOGP(debug, "Inserting {} in {} ", layerVol->GetName(), motherVolume->GetName());
449449
motherVolume->AddNode(layerVol, 1, nullptr);
450450
}
451+
452+
std::pair<float, float> TRKOTLayer::getBoundingRadii(double staveWidth) const
453+
{
454+
auto [radiusMin, radiusMax] = TRKSegmentedLayer::getBoundingRadii(staveWidth);
455+
456+
return {radiusMin - 0.201f, radiusMax};
457+
}
451458
// ClassImp(TRKLayer);
452459

453460
} // namespace trk

0 commit comments

Comments
 (0)