BDSIM
BDSIM is a Geant4 extension toolkit for simulation of particle transport in accelerator beamlines.
Public Member Functions | Private Member Functions | Private Attributes
BDSParallelWorldImportance Class Reference

Class that constructs a parallel importance world. More...

#include <BDSParallelWorldImportance.hh>

Inheritance diagram for BDSParallelWorldImportance:
Inheritance graph
Collaboration diagram for BDSParallelWorldImportance:
Collaboration graph

Public Member Functions

 BDSParallelWorldImportance (G4String name, G4String importanceWorldGeometryFile, G4String importanceValuesFile)
 
void Construct ()
 
void BuildPhysicsBias ()
 Create biasing operations.
 
BDSExtent WorldExtent () const
 Public access to the world extent. More...
 
G4GeometryCell GetGeometryCell (G4int i) const
 Get geometry cell from store. More...
 
void AddIStore ()
 Create IStore for all importance sampling geometry cells. More...
 
virtual void ConstructSD ()
 
G4VPhysicalVolume * GetWorldVolume ()
 World volume getter required in parallel world utilities. More...
 

Private Member Functions

BDSParallelWorldImportanceoperator= (const BDSParallelWorldImportance &)
 assignment and copy constructor not implemented nor used
 
 BDSParallelWorldImportance (BDSParallelWorldImportance &)
 
void BuildWorld ()
 
G4double GetCellImportanceValue (const G4String &cellName)
 Get importance value of a given physical volume name. More...
 

Private Attributes

G4VPhysicalVolume * imWorldPV
 Importance sampling world volume. More...
 
BDSExtent worldExtent
 Record of the world extent. More...
 
BDSImportanceVolumeStore imVolumeStore
 Store of geometry cells for importance volumes. More...
 
std::map< G4String, G4double > imVolumesAndValues
 Container for all user placed physical volumes and corresponding importance values. More...
 
G4String imGeomFile
 
G4String imVolMap
 
const G4String componentName
 String preprended to geometry with preprocessGDML. More...
 
G4int verbosity
 Cached global constants values. More...
 
G4UserLimits * userLimits
 Cached global constants values. More...
 
G4VisAttributes * visAttr
 Cached global constants values. More...
 

Detailed Description

Class that constructs a parallel importance world.

Author
Will Shields

Definition at line 47 of file BDSParallelWorldImportance.hh.

Constructor & Destructor Documentation

◆ BDSParallelWorldImportance()

BDSParallelWorldImportance::BDSParallelWorldImportance ( G4String  name,
G4String  importanceWorldGeometryFile,
G4String  importanceValuesFile 
)

Definition at line 45 of file BDSParallelWorldImportance.cc.

◆ ~BDSParallelWorldImportance()

BDSParallelWorldImportance::~BDSParallelWorldImportance ( )
virtual

Definition at line 85 of file BDSParallelWorldImportance.cc.

Member Function Documentation

◆ AddIStore()

void BDSParallelWorldImportance::AddIStore ( )

Create IStore for all importance sampling geometry cells.

Definition at line 147 of file BDSParallelWorldImportance.cc.

References GetCellImportanceValue(), imVolumesAndValues, imVolumeStore, imWorldPV, and verbosity.

Referenced by BDS::AddIStore().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ BuildWorld()

void BDSParallelWorldImportance::BuildWorld ( )
private

Build the world volume using the extent of the BDSBeamline instance created in BuildBeamline()

Definition at line 88 of file BDSParallelWorldImportance.cc.

References BDSImportanceVolumeStore::AddPVolume(), BDSGeometryFactory::BuildGeometry(), componentName, BDSGeometryComponent::GetContainerLogicalVolume(), imVolumeStore, imWorldPV, BDSGeometryFactory::Instance(), userLimits, and visAttr.

Referenced by Construct().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ Construct()

void BDSParallelWorldImportance::Construct ( )

Overridden Geant4 method that must be implemented. Constructs the Geant4 geometry and returns the finished world physical volume.

Definition at line 62 of file BDSParallelWorldImportance.cc.

References BuildWorld(), BDS::GetFullPath(), and imVolumesAndValues.

Here is the call graph for this function:

◆ ConstructSD()

void BDSParallelWorldImportance::ConstructSD ( )
virtual

Definition at line 236 of file BDSParallelWorldImportance.cc.

◆ GetCellImportanceValue()

G4double BDSParallelWorldImportance::GetCellImportanceValue ( const G4String &  cellName)
private

Get importance value of a given physical volume name.

Definition at line 184 of file BDSParallelWorldImportance.cc.

References componentName, imVolumesAndValues, BDS::IsFinite(), and BDS::StrContains().

Referenced by AddIStore().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetGeometryCell()

G4GeometryCell BDSParallelWorldImportance::GetGeometryCell ( G4int  i) const

Get geometry cell from store.

Definition at line 135 of file BDSParallelWorldImportance.cc.

References BDSImportanceVolumeStore::GetPVolume(), imVolumeStore, and imWorldPV.

Here is the call graph for this function:

◆ GetWorldVolume()

G4VPhysicalVolume * BDSParallelWorldImportance::GetWorldVolume ( )
inline

World volume getter required in parallel world utilities.

Definition at line 74 of file BDSParallelWorldImportance.hh.

References imWorldPV.

Referenced by BDS::RegisterImportanceBiasing().

Here is the caller graph for this function:

◆ WorldExtent()

BDSExtent BDSParallelWorldImportance::WorldExtent ( ) const
inline

Public access to the world extent.

Definition at line 63 of file BDSParallelWorldImportance.hh.

References worldExtent.

Field Documentation

◆ componentName

const G4String BDSParallelWorldImportance::componentName
private

String preprended to geometry with preprocessGDML.

Definition at line 98 of file BDSParallelWorldImportance.hh.

Referenced by BuildWorld(), and GetCellImportanceValue().

◆ imGeomFile

G4String BDSParallelWorldImportance::imGeomFile
private

Definition at line 96 of file BDSParallelWorldImportance.hh.

◆ imVolMap

G4String BDSParallelWorldImportance::imVolMap
private

Definition at line 97 of file BDSParallelWorldImportance.hh.

◆ imVolumesAndValues

std::map<G4String, G4double> BDSParallelWorldImportance::imVolumesAndValues
private

Container for all user placed physical volumes and corresponding importance values.

Definition at line 94 of file BDSParallelWorldImportance.hh.

Referenced by AddIStore(), Construct(), and GetCellImportanceValue().

◆ imVolumeStore

BDSImportanceVolumeStore BDSParallelWorldImportance::imVolumeStore
private

Store of geometry cells for importance volumes.

Definition at line 91 of file BDSParallelWorldImportance.hh.

Referenced by AddIStore(), BuildWorld(), and GetGeometryCell().

◆ imWorldPV

G4VPhysicalVolume* BDSParallelWorldImportance::imWorldPV
private

Importance sampling world volume.

Definition at line 86 of file BDSParallelWorldImportance.hh.

Referenced by AddIStore(), BuildWorld(), GetGeometryCell(), and GetWorldVolume().

◆ userLimits

G4UserLimits* BDSParallelWorldImportance::userLimits
private

Cached global constants values.

Definition at line 102 of file BDSParallelWorldImportance.hh.

Referenced by BuildWorld().

◆ verbosity

G4int BDSParallelWorldImportance::verbosity
private

Cached global constants values.

Definition at line 101 of file BDSParallelWorldImportance.hh.

Referenced by AddIStore().

◆ visAttr

G4VisAttributes* BDSParallelWorldImportance::visAttr
private

Cached global constants values.

Definition at line 103 of file BDSParallelWorldImportance.hh.

Referenced by BuildWorld().

◆ worldExtent

BDSExtent BDSParallelWorldImportance::worldExtent
private

Record of the world extent.

Definition at line 88 of file BDSParallelWorldImportance.hh.

Referenced by WorldExtent().


The documentation for this class was generated from the following files: