30#include "DetectorConstruction.hh"
33#include "G4GeometryManager.hh"
34#include "G4LogicalVolume.hh"
35#include "G4LogicalVolumeStore.hh"
36#include "G4Material.hh"
37#include "G4NistManager.hh"
38#include "G4PVPlacement.hh"
39#include "G4PhysicalVolumeStore.hh"
40#include "G4RunManager.hh"
41#include "G4SolidStore.hh"
42#include "G4SystemOfUnits.hh"
43#include "G4UnitsTable.hh"
45#include "DetectorMessenger.hh"
93 G4GeometryManager::GetInstance()->OpenGeometry();
94 G4PhysicalVolumeStore::GetInstance()->Clean();
95 G4LogicalVolumeStore::GetInstance()->Clean();
96 G4SolidStore::GetInstance()->Clean();
130 G4cout <<
"\n The Box dimensions are: " << G4endl <<
"x: " <<
G4BestUnit(
fBoxSizeX,
"Length")
134 G4cout <<
"And its volume therefore is: "
135 <<
fPBox->GetLogicalVolume()->GetSolid()->GetCubicVolume() / m3 <<
" m3" << G4endl;
143 G4Material* pttoMaterial = G4NistManager::Instance()->FindOrBuildMaterial(materialChoice);
149 fLBox->SetMaterial(pttoMaterial);
151 G4RunManager::GetRunManager()->PhysicsHasBeenModified();
156 std::stringstream sstr;
157 sstr <<
"material " << +materialChoice <<
" does not exist, keeping material "
160 G4Exception(
"DetectorConstruction::SetMaterial",
"NoWorldMat", JustWarning, sstr.str().c_str());
Definition of the RadioBio::VoxelizedSensitiveDetector class.
G4VPhysicalVolume * fPBox
G4VPhysicalVolume * Construct() override
Method overriding pure virtual G4VUserDetectorConstruction one.
void PrintParameters()
Prints on screen some parameters for this class.
G4VPhysicalVolume * ConstructVolumes()
Private method to construct geometry.
DetectorMessenger * fDetectorMessenger
void SetSizeY(G4double y)
Method to set the Y width of the world volume.
void SetSize(G4double)
Method to set the world volume to be cubical with given side.
void SetSizeZ(G4double z)
Method to set the Z width of the world volume.
void SetSizeX(G4double x)
Method to set the X width of the world volume.
void ConstructSDandField() override
Method overriding pure virtual G4VUserDetectorConstruction one.
void SetMaterial(G4String mat)
Method to set the world material.
void InitializeWorldPtr(G4VPhysicalVolume *pWorld)
Method to properly initialize the pointer to the World physical volume.
static VoxelizedSensitiveDetector * GetInstance()
Static method to retrieve a pointer to the only object existing in the simulation.
void ConstructSD()
Method to make the proper volume sensitive to allow scoring.
static VoxelizedSensitiveDetector * CreateInstance(DetectorConstruction *det, double xWidth, double yWidth, double zWidth)
Static method to create the pointer to the only object existing in the simulation.
void Construct()
Method to construct all the volumes for the voxelization of the geometry.