Analysis Software
Documentation for sPHENIX simulation software
|
#include <coresoftware/blob/master/simulation/g4simulation/g4micromegas/PHG4MicromegasDetector.h>
Public Member Functions | |
PHG4MicromegasDetector (PHG4Subsystem *, PHCompositeNode *, PHParameters *, const std::string &) | |
constructor | |
void | ConstructMe (G4LogicalVolume *) override |
construct | |
void | Print (const std::string &what="ALL") const override |
void | set_first_layer (int layer) |
set first layer number | |
int | get_first_layer () const |
get first layer number | |
int | IsInDetector (G4VPhysicalVolume *) const |
returns true if passed volume is an active volume of this detector | |
int | get_layer (G4VPhysicalVolume *) const |
return layer associated to a given volume, or -1 if invalid | |
int | get_tileid (G4VPhysicalVolume *) const |
return tile id associated to a given volume, or -1 if invalid | |
void | SuperDetector (const std::string &name) |
super detector name | |
const std::string | SuperDetector () const |
super detector name | |
PHG4MicromegasDisplayAction * | GetDisplayAction () |
access the display action | |
Public Member Functions inherited from PHG4Detector | |
PHG4Detector ()=delete | |
constructor | |
PHG4Detector (PHG4Subsystem *subsys, PHCompositeNode *Node, const std::string &nam) | |
virtual | ~PHG4Detector (void) |
destructor | |
virtual void | Construct (G4LogicalVolume *world) final |
construct method | |
virtual void | PostConstruction () |
Optional PostConstruction call after all geometry is constructed. | |
virtual void | Verbosity (const int v) |
virtual int | Verbosity () const |
virtual G4UserSteppingAction * | GetSteppingAction () |
virtual std::string | GetName () const |
virtual void | OverlapCheck (const bool chk) |
virtual bool | OverlapCheck () const |
virtual int | DisplayVolume (G4VSolid *volume, G4LogicalVolume *logvol, G4RotationMatrix *rotm=nullptr) |
virtual int | DisplayVolume (G4LogicalVolume *checksolid, G4LogicalVolume *logvol, G4RotationMatrix *rotm=nullptr) |
virtual PHCompositeNode * | topNode () |
virtual PHG4Subsystem * | GetMySubsystem () |
Private Member Functions | |
void | setup_tiles () |
setup tiles | |
void | create_materials () const |
create needed material | |
void | construct_micromegas (G4LogicalVolume *) |
construct | |
G4LogicalVolume * | construct_micromegas_tile (int tileid, MicromegasDefs::SegmentationType) |
create a micromegas detector of given type | |
G4LogicalVolume * | construct_fee_board (int id) |
construct FEE board | |
void | add_geometry_node () |
add geometry node | |
Private Attributes | |
PHG4MicromegasDisplayAction * | m_DisplayAction {nullptr} |
vis attribute handling (save memory in batch) | |
PHParameters * | m_Params {nullptr} |
detector parameters | |
int | m_FirstLayer {0} |
first layer number | |
bool | m_ActiveFlag {false} |
cache active setting | |
bool | m_SupportActiveFlag {false} |
cache support active setting | |
std::map< int, double > | m_layer_radius |
map layer index to radius (cm) | |
std::map< int, double > | m_layer_thickness |
map layer index to thickness (cm) | |
std::map< G4VPhysicalVolume *, int > | m_activeVolumes |
active volumes, and mapping to layer | |
std::map< G4VPhysicalVolume *, int > | m_tiles_map |
map active volumes to tile number | |
std::set< G4VPhysicalVolume * > | m_passiveVolumes |
also store passive volumes | |
std::string | m_SuperDetector |
super detector name | |
MicromegasTile::List | m_tiles |
micromegas tiles | |
Additional Inherited Members | |
Static Public Member Functions inherited from PHG4Detector | |
static G4Material * | GetDetectorMaterial (const std::string &name, const bool quit=true) |
static G4Element * | GetDetectorElement (const std::string &name, const bool quit=true) |
Definition at line 26 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 26 of file PHG4MicromegasDetector.h
PHG4MicromegasDetector::PHG4MicromegasDetector | ( | PHG4Subsystem * | subsys, |
PHCompositeNode * | Node, | ||
PHParameters * | parameters, | ||
const std::string & | dnam | ||
) |
constructor
Definition at line 64 of file PHG4MicromegasDetector.cc.
View newest version in sPHENIX GitHub at line 64 of file PHG4MicromegasDetector.cc
References setup_tiles().
|
private |
add geometry node
this handles the internal (module/strips) segmentation, needed for tracking
Definition at line 674 of file PHG4MicromegasDetector.cc.
View newest version in sPHENIX GitHub at line 674 of file PHG4MicromegasDetector.cc
References PHNodeIterator::findFirst(), PHParameters::get_int_param(), G4PLUGDOOR::length, m_layer_radius, m_layer_thickness, m_Params, m_SuperDetector, m_tiles, PHG4InttDefs::SEGMENTATION_PHI, PHG4InttDefs::SEGMENTATION_Z, and PHG4Detector::topNode().
Referenced by ConstructMe().
|
private |
construct FEE board
Definition at line 579 of file PHG4MicromegasDetector.cc.
View newest version in sPHENIX GitHub at line 579 of file PHG4MicromegasDetector.cc
References PHG4MicromegasDisplayAction::AddVolume(), Acts::UnitConstants::cm, color, Acts::UnitConstants::e, PHG4Detector::GetDetectorMaterial(), GetDisplayAction(), PHG4Detector::GetName(), recoConsts::instance(), layer, m_name(), m_passiveVolumes, material, Acts::UnitConstants::mm, perf_headwind::name, PHG4Detector::OverlapCheck(), thickness, to_string(), and value.
Referenced by construct_micromegas_tile().
|
private |
construct
Definition at line 240 of file PHG4MicromegasDetector.cc.
View newest version in sPHENIX GitHub at line 240 of file PHG4MicromegasDetector.cc
References Acts::UnitConstants::cm, construct_micromegas_tile(), QAG4Util::get_r(), PHG4MicromegasSurvey::get_transformation(), PHG4Detector::GetName(), G4CEMCALBEDO::inner_radius, m_activeVolumes, m_FirstLayer, m_layer_radius, m_tiles, PHG4Detector::OverlapCheck(), PHG4InttDefs::SEGMENTATION_PHI, PHG4InttDefs::SEGMENTATION_Z, tile(), to_string(), Acts::Test::transform, translation(), and PHG4Detector::Verbosity().
Referenced by ConstructMe().
|
private |
create a micromegas detector of given type
returns the master logical volume that can then be placed inside the world logical volume
Definition at line 362 of file PHG4MicromegasDetector.cc.
View newest version in sPHENIX GitHub at line 362 of file PHG4MicromegasDetector.cc
References PHG4MicromegasDisplayAction::AddVolume(), Acts::UnitConstants::cm, color, construct_fee_board(), dy, dz, PHG4Detector::GetDetectorMaterial(), GetDisplayAction(), PHG4Detector::GetName(), recoConsts::instance(), layer, m_activeVolumes, m_FirstLayer, m_layer_radius, m_layer_thickness, m_passiveVolumes, m_tiles_map, std::tr1::make_tuple(), material, Acts::UnitConstants::mm, perf_headwind::name, PHG4Detector::OverlapCheck(), PHG4InttDefs::SEGMENTATION_Z, thickness, to_string(), parse_cmake_options::type, value, and G4MVTXAlignment::z_offset.
Referenced by construct_micromegas().
|
overridevirtual |
construct
Implements PHG4Detector.
Definition at line 109 of file PHG4MicromegasDetector.cc.
View newest version in sPHENIX GitHub at line 109 of file PHG4MicromegasDetector.cc
References add_geometry_node(), construct_micromegas(), and create_materials().
|
private |
create needed material
Definition at line 165 of file PHG4MicromegasDetector.cc.
View newest version in sPHENIX GitHub at line 165 of file PHG4MicromegasDetector.cc
References Acts::UnitConstants::cm3, Acts::UnitConstants::g, and PHG4Detector::GetDetectorMaterial().
Referenced by ConstructMe().
|
inline |
get first layer number
Definition at line 41 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 41 of file PHG4MicromegasDetector.h
References m_FirstLayer.
int PHG4MicromegasDetector::get_layer | ( | G4VPhysicalVolume * | volume | ) | const |
return layer associated to a given volume, or -1 if invalid
Definition at line 95 of file PHG4MicromegasDetector.cc.
View newest version in sPHENIX GitHub at line 95 of file PHG4MicromegasDetector.cc
References m_activeVolumes.
Referenced by PHG4MicromegasSteppingAction::UserSteppingAction().
int PHG4MicromegasDetector::get_tileid | ( | G4VPhysicalVolume * | volume | ) | const |
return tile id associated to a given volume, or -1 if invalid
Definition at line 102 of file PHG4MicromegasDetector.cc.
View newest version in sPHENIX GitHub at line 102 of file PHG4MicromegasDetector.cc
References m_tiles_map.
Referenced by PHG4MicromegasSteppingAction::UserSteppingAction().
|
inline |
access the display action
Definition at line 59 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 59 of file PHG4MicromegasDetector.h
References m_DisplayAction.
Referenced by construct_fee_board(), and construct_micromegas_tile().
int PHG4MicromegasDetector::IsInDetector | ( | G4VPhysicalVolume * | volume | ) | const |
returns true if passed volume is an active volume of this detector
Definition at line 75 of file PHG4MicromegasDetector.cc.
View newest version in sPHENIX GitHub at line 75 of file PHG4MicromegasDetector.cc
References m_ActiveFlag, m_activeVolumes, m_passiveVolumes, and m_SupportActiveFlag.
Referenced by PHG4MicromegasSteppingAction::UserSteppingAction().
|
overridevirtual |
Reimplemented from PHG4Detector.
Definition at line 117 of file PHG4MicromegasDetector.cc.
View newest version in sPHENIX GitHub at line 117 of file PHG4MicromegasDetector.cc
References m_Params, and PHParameters::Print().
Referenced by PHG4MicromegasSubsystem::Print().
|
inline |
set first layer number
Definition at line 38 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 38 of file PHG4MicromegasDetector.h
References layer, and m_FirstLayer.
Referenced by PHG4MicromegasSubsystem::InitRunSubsystem().
|
private |
setup tiles
the method is now private because tiles are now hard coded
Definition at line 130 of file PHG4MicromegasDetector.cc.
View newest version in sPHENIX GitHub at line 130 of file PHG4MicromegasDetector.cc
References m_tiles, ActsTests::PropagationDatasets::phi, and CylinderGeomMicromegas::reference_radius.
Referenced by PHG4MicromegasDetector().
|
inline |
super detector name
Definition at line 53 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 53 of file PHG4MicromegasDetector.h
References m_SuperDetector, and perf_headwind::name.
Referenced by PHG4MicromegasSubsystem::InitRunSubsystem().
|
inline |
super detector name
Definition at line 56 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 56 of file PHG4MicromegasDetector.h
References m_SuperDetector.
|
private |
cache active setting
Definition at line 94 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 94 of file PHG4MicromegasDetector.h
Referenced by IsInDetector().
|
private |
active volumes, and mapping to layer
it is needed in the stepping action to map a volume to a given layer
Definition at line 109 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 109 of file PHG4MicromegasDetector.h
Referenced by construct_micromegas(), construct_micromegas_tile(), get_layer(), and IsInDetector().
|
private |
vis attribute handling (save memory in batch)
Definition at line 84 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 84 of file PHG4MicromegasDetector.h
Referenced by GetDisplayAction().
|
private |
first layer number
Definition at line 91 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 91 of file PHG4MicromegasDetector.h
Referenced by construct_micromegas(), construct_micromegas_tile(), get_first_layer(), and set_first_layer().
|
private |
map layer index to radius (cm)
it is filled while creating G4 volumes
Definition at line 101 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 101 of file PHG4MicromegasDetector.h
Referenced by add_geometry_node(), construct_micromegas(), and construct_micromegas_tile().
|
private |
map layer index to thickness (cm)
it is filled while creating G4 volumes
Definition at line 105 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 105 of file PHG4MicromegasDetector.h
Referenced by add_geometry_node(), and construct_micromegas_tile().
|
private |
detector parameters
Definition at line 87 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 87 of file PHG4MicromegasDetector.h
Referenced by add_geometry_node(), and Print().
|
private |
also store passive volumes
Definition at line 116 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 116 of file PHG4MicromegasDetector.h
Referenced by construct_fee_board(), construct_micromegas_tile(), and IsInDetector().
|
private |
super detector name
Definition at line 119 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 119 of file PHG4MicromegasDetector.h
Referenced by add_geometry_node(), and SuperDetector().
|
private |
cache support active setting
Definition at line 97 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 97 of file PHG4MicromegasDetector.h
Referenced by IsInDetector().
|
private |
micromegas tiles
Definition at line 122 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 122 of file PHG4MicromegasDetector.h
Referenced by add_geometry_node(), construct_micromegas(), and setup_tiles().
|
private |
map active volumes to tile number
it is needed in the stepping action to map a volume to a given tile id
Definition at line 113 of file PHG4MicromegasDetector.h.
View newest version in sPHENIX GitHub at line 113 of file PHG4MicromegasDetector.h
Referenced by construct_micromegas_tile(), and get_tileid().