Class MPGDTrapezoidGeant4Factory
java.lang.Object
org.jlab.detector.geant4.v2.Geant4Factory
org.jlab.detector.geant4.v2.MPGD.trapezoid.MPGDTrapezoidGeant4Factory
- Direct Known Subclasses:
MUVTGeant4Factory, URWTGeant4Factory
Generic Geant4 factory for trapezoidal MPGD-like trackers.
It builds: - a world volume - NREGIONS = NLAYERS/2 (by convention) - NSECTORS
per region
The exact geometry parameters and material stack are taken from an
MPGDTrapezoidConstants instance.
Concrete detectors should: - extend this class - pass the appropriate
constants + detector name in the constructor-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final MPGDTrapezoidConstantsDetector constants (geometry + materials from CCDB).Fields inherited from class Geant4Factory
motherVolume, properties -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedMPGDTrapezoidGeant4Factory(MPGDTrapezoidConstants constants) -
Method Summary
Modifier and TypeMethodDescriptioncreateSector(int isector, int iregion) Builds a single sector for a given region and returns its volume.protected Geant4BasiccreateSectorVolume(int isector, int iregion, MPGDTrapezoidGeant4Factory.SectorDimensions dimSect) Creates the main trapezoidal sector volume and places it in the world.getCenterCoordinate(int isector, int iregion) Computes the barycenter coordinates of a given sector/region in the CLAS12 coordinate system.getSectorActiveVolumeDimensions(int region) getSectorContainerDimensions(int region) doublegetSectorHeight(int region) Computes the sector height (longitudinal extension in the RZ plane) for a given region.doubleComputes the total thickness (mm) of a sector by summing the thickness of all material volumes.protected final voidinit()Initializes the world volume and constructs all regions and sectors.protected voidpopulateSectorWithDetectorStructure(Geant4Basic sectorVolume, int isector, int iregion, MPGDTrapezoidGeant4Factory.SectorDimensions dimSect) Fills the given sector volume with material sub-volumes according to the CCDB material structure (layer/component stack).Stacking is done along the local Z direction (thickness).Methods inherited from class Geant4Factory
getAllVolumes, getComponents, getIntersections, getProperty, toString
-
Field Details
-
C
Detector constants (geometry + materials from CCDB).
-
-
Constructor Details
-
MPGDTrapezoidGeant4Factory
- Parameters:
constants- detector constants (already configured with CCDB paths/table names)
-
-
Method Details
-
init
protected final void init()Initializes the world volume and constructs all regions and sectors. This must be called after the constants have been loaded from CCDB. -
getSectorThickness
public double getSectorThickness()Computes the total thickness (mm) of a sector by summing the thickness of all material volumes.- Returns:
-
getSectorActiveVolumeDimensions
- Parameters:
region-- Returns:
-
getSectorContainerDimensions
- Parameters:
region-- Returns:
-
getSectorHeight
public double getSectorHeight(int region) Computes the sector height (longitudinal extension in the RZ plane) for a given region.- Parameters:
region-- Returns:
-
getCenterCoordinate
Computes the barycenter coordinates of a given sector/region in the CLAS12 coordinate system.- Parameters:
isector-iregion-- Returns:
-
createSector
Builds a single sector for a given region and returns its volume.- Parameters:
isector-iregion-- Returns:
-
createSectorVolume
protected Geant4Basic createSectorVolume(int isector, int iregion, MPGDTrapezoidGeant4Factory.SectorDimensions dimSect) Creates the main trapezoidal sector volume and places it in the world.- Parameters:
isector-iregion-dimSect-- Returns:
-
populateSectorWithDetectorStructure
protected void populateSectorWithDetectorStructure(Geant4Basic sectorVolume, int isector, int iregion, MPGDTrapezoidGeant4Factory.SectorDimensions dimSect) Fills the given sector volume with material sub-volumes according to the CCDB material structure (layer/component stack).Stacking is done along the local Z direction (thickness).- Parameters:
sectorVolume-isector-iregion-dimSect-
-