SHiP Geometry
SHiP experiment geometry implementation using GeoModel.
Loading...
Searching...
No Matches
Layout.h File Reference
Include dependency graph for Layout.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  SHiP::geometry::layout::Slot
struct  SHiP::geometry::layout::KnownOverlap
 Two containers that overlap, although Geant4 does not support overlapping siblings. More...
struct  SHiP::geometry::layout::CutOut
 A container with a cavity of another container's shape cut out of it. More...

Namespaces

namespace  SHiP
namespace  SHiP::geometry
namespace  SHiP::geometry::layout
 Where each subsystem container sits in the world volume.
namespace  SHiP::geometry::layout::detail

Typedefs

using SHiP::geometry::layout::LengthMm
 Spellings for struct members and function parameters.

Functions

template<typename Factory>
constexpr Slot SHiP::geometry::layout::slotOf (LengthMm halfX, LengthMm halfY, LengthMm halfZ)
 A factory's slot: its registered placement (descriptor()) together with its container half-lengths.
template<std::size_t N>
constexpr std::size_t SHiP::geometry::layout::firstOutOfOrder (const std::array< Slot, N > &slots)
 Centres never decrease along the slot list.
template<std::size_t M>
constexpr bool SHiP::geometry::layout::isKnownOverlap (const std::array< KnownOverlap, M > &known, const Slot &a, const Slot &b)
 The pair is listed in known and overlaps no further than its region.
template<std::size_t K>
constexpr bool SHiP::geometry::layout::isCutOut (const std::array< CutOut, K > &cutOuts, const Slot &a, const Slot &b)
 One of the pair has the other's shape cut out of it (listed in cutOuts), and the other lies within that cavity.
template<std::size_t N, std::size_t M = kKnownOverlaps.size(), std::size_t K = kCutOuts.size()>
constexpr std::size_t SHiP::geometry::layout::firstUnexpectedOverlap (const std::array< Slot, N > &slots, const std::array< KnownOverlap, M > &known=kKnownOverlaps, const std::array< CutOut, K > &cutOuts=kCutOuts)
 Index of the first slot that overlaps a later one, unless the pair is a known overlap that has not grown, or one sits in a cavity cut out of the other; npos if there is none.
constexpr bool SHiP::geometry::layout::fitsEnvelopeZ (const Slot &slot, const envelopes::Envelope &env, LengthMm tol=1e-6 *detail::mm)
 Container lies inside the envelope along the beam (with tol of slack, for values that are equal on paper but rounded differently).
constexpr bool SHiP::geometry::layout::fitsEnvelopeXY (const Slot &slot, const envelopes::Envelope &env, LengthMm tolX=detail::zero, LengthMm tolY=detail::zero)
 Container stays inside the envelope's largest transverse size (with tolX and tolY of slack).
constexpr bool SHiP::geometry::layout::isInCavity (const Slot &slot)
 The container lies within the halls taken together: the muon shield runs from TCC8 across the step into ECN3, and the magnet sits partly in the yoke pit.
constexpr checks::Span SHiP::geometry::layout::trackerStation (LengthMm centreZ)
 Absolute z-span of one tracker station.

Variables

constexpr auto SHiP::geometry::layout::detail::mm = units::mm
constexpr auto SHiP::geometry::layout::detail::zero = 0.0 * units::mm
constexpr Slot SHiP::geometry::layout::kTarget
constexpr Slot SHiP::geometry::layout::kMuonShield
constexpr Slot SHiP::geometry::layout::kNeutrinoDetector
 z 22.94-27.99 m, in the end of muon-shield magnet M5 and the whole of M6 (FairShip TRY_2026).
constexpr Slot SHiP::geometry::layout::kUpstreamTagger
constexpr Slot SHiP::geometry::layout::kDecayVolume
constexpr Slot SHiP::geometry::layout::kTrackers
 The factory positions its stations relative to s_containerCentreZ, so the container goes there and the stations land on their absolute z.
constexpr Slot SHiP::geometry::layout::kMagnet
constexpr Slot SHiP::geometry::layout::kTimingDetector
constexpr Slot SHiP::geometry::layout::kCalorimeter
constexpr std::array SHiP::geometry::layout::kSlots
 All subsystems, in placement order (upstream to downstream).
constexpr std::array SHiP::geometry::layout::kKnownOverlaps
constexpr std::array SHiP::geometry::layout::kCutOuts
 The SND sits in a cavity of the muon-shield container (#117).
constexpr checks::Box SHiP::geometry::layout::kWorld
 The world volume built by CavernFactory, centred on the origin.
constexpr std::array SHiP::geometry::layout::kCavities
 The halls CavernFactory cuts out of the rock, in the world frame.
constexpr auto SHiP::geometry::layout::kTrackersIntoFloor = 66.0 * detail::mm
constexpr auto SHiP::geometry::layout::kCalorimeterIntoFloor = 136.0 * detail::mm
constexpr envelopes::Envelope SHiP::geometry::layout::detail::kMuonShieldRegion
 Muon shield region: the hadron stopper start to the end of the last magnet.
constexpr envelopes::Envelope SHiP::geometry::layout::detail::kDecayVolumeWithSBT
 Decay volume plus the SBT shell wrapped around it.
constexpr auto SHiP::geometry::layout::detail::kTrackerRegion = envelopes::hull("Trackers", envelopes::kTrackerStations)
 Tracker stations 1 to 4, including the magnet gap between 2 and 3.
constexpr auto SHiP::geometry::layout::detail::kCalorimeterRegion = envelopes::hull("Calorimeter", envelopes::kCalorimeter)
 Split ECAL front and back plus the HCAL.
constexpr auto SHiP::geometry::layout::kNeutrinoDetectorEarlyStart = 3461.0 * detail::mm
constexpr auto SHiP::geometry::layout::kUpstreamTaggerExcessX = 1450.0 * detail::mm
constexpr auto SHiP::geometry::layout::kUpstreamTaggerExcessY = 1600.0 * detail::mm
constexpr auto SHiP::geometry::layout::kTimingDetectorEarlyStart = 168.0 * detail::mm
constexpr std::array SHiP::geometry::layout::kTrackerStationZ