Geant4.10
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions | Static Public Member Functions
LXeDetectorConstruction Class Reference

#include <LXeDetectorConstruction.hh>

Inheritance diagram for LXeDetectorConstruction:
G4VUserDetectorConstruction

Public Member Functions

 LXeDetectorConstruction ()
 
virtual ~LXeDetectorConstruction ()
 
virtual G4VPhysicalVolumeConstruct ()
 
virtual void ConstructSDandField ()
 
void SetDimensions (G4ThreeVector)
 
void SetHousingThickness (G4double)
 
void SetNX (G4int)
 
void SetNY (G4int)
 
void SetNZ (G4int)
 
void SetPMTRadius (G4double)
 
void SetDefaults ()
 
G4int GetNX ()
 
G4int GetNY ()
 
G4int GetNZ ()
 
G4double GetScintX ()
 
G4double GetScintY ()
 
G4double GetScintZ ()
 
G4double GetHousingThickness ()
 
G4double GetPMTRadius ()
 
G4double GetSlabZ ()
 
void SetSphereOn (G4bool)
 
void SetHousingReflectivity (G4double)
 
G4double GetHousingReflectivity ()
 
void SetWLSSlabOn (G4bool b)
 
G4bool GetWLSSlabOn ()
 
void SetMainVolumeOn (G4bool b)
 
G4bool GetMainVolumeOn ()
 
void SetNFibers (G4int n)
 
G4int GetNFibers ()
 
void SetMainScintYield (G4double)
 
void SetWLSScintYield (G4double)
 
- Public Member Functions inherited from G4VUserDetectorConstruction
 G4VUserDetectorConstruction ()
 
virtual ~G4VUserDetectorConstruction ()
 
virtual void CloneSD ()
 
virtual void CloneF ()
 
void RegisterParallelWorld (G4VUserParallelWorld *)
 
G4int ConstructParallelGeometries ()
 
void ConstructParallelSD ()
 
G4int GetNumberOfParallelWorld () const
 
G4VUserParallelWorldGetParallelWorld (G4int i) const
 

Static Public Member Functions

static G4bool GetSphereOn ()
 

Additional Inherited Members

- Protected Member Functions inherited from G4VUserDetectorConstruction
void SetSensitiveDetector (const G4String &logVolName, G4VSensitiveDetector *aSD, G4bool multi=false)
 
void SetSensitiveDetector (G4LogicalVolume *logVol, G4VSensitiveDetector *aSD)
 

Detailed Description

Definition at line 53 of file LXeDetectorConstruction.hh.

Constructor & Destructor Documentation

LXeDetectorConstruction::LXeDetectorConstruction ( )

Definition at line 68 of file LXeDetectorConstruction.cc.

References SetDefaults().

69 : fLXe_mt(NULL), fMPTPStyrene(NULL)
70 {
71  fExperimentalHall_box = NULL;
72  fExperimentalHall_log = NULL;
73  fExperimentalHall_phys = NULL;
74 
75  fLXe = fAl = fAir = fVacuum = fGlass = NULL;
76  fPstyrene = fPMMA = fPethylene1 = fPethylene2 = NULL;
77 
78  fN = fO = fC = fH = NULL;
79 
80  SetDefaults();
81 
82  fDetectorMessenger = new LXeDetectorMessenger(this);
83 }
LXeDetectorConstruction::~LXeDetectorConstruction ( )
virtual

Definition at line 87 of file LXeDetectorConstruction.cc.

87 {}

Member Function Documentation

G4VPhysicalVolume * LXeDetectorConstruction::Construct ( void  )
virtual

Implements G4VUserDetectorConstruction.

Definition at line 227 of file LXeDetectorConstruction.cc.

References G4PhysicalVolumeStore::Clean(), G4SolidStore::Clean(), G4LogicalVolumeStore::Clean(), G4LogicalSkinSurface::CleanSurfaceTable(), G4LogicalBorderSurface::CleanSurfaceTable(), G4SolidStore::GetInstance(), G4LogicalVolumeStore::GetInstance(), G4PhysicalVolumeStore::GetInstance(), G4GeometryManager::GetInstance(), and G4GeometryManager::OpenGeometry().

227  {
228 
229  if (fExperimentalHall_phys) {
236  }
237 
238  DefineMaterials();
239  return ConstructDetector();
240 }
static void Clean()
Definition: G4SolidStore.cc:79
static G4PhysicalVolumeStore * GetInstance()
static G4LogicalVolumeStore * GetInstance()
static G4SolidStore * GetInstance()
static G4GeometryManager * GetInstance()
void OpenGeometry(G4VPhysicalVolume *vol=0)
void LXeDetectorConstruction::ConstructSDandField ( )
virtual

Reimplemented from G4VUserDetectorConstruction.

Definition at line 304 of file LXeDetectorConstruction.cc.

References G4cout, G4endl, G4Cache< VALTYPE >::Get(), LXeMainVolume::GetLogPhotoCath(), LXeMainVolume::GetLogScint(), LXeMainVolume::GetPmtPositions(), LXePMTSD::InitPMTs(), G4Cache< VALTYPE >::Put(), LXePMTSD::SetPmtPositions(), and G4VUserDetectorConstruction::SetSensitiveDetector().

304  {
305 
306  if (!fMainVolume) return;
307 
308  // PMT SD
309 
310  if (!fPmt_SD.Get()) {
311  //Created here so it exists as pmts are being placed
312  G4cout << "Construction /LXeDet/pmtSD" << G4endl;
313  LXePMTSD* pmt_SD = new LXePMTSD("/LXeDet/pmtSD");
314  fPmt_SD.Put(pmt_SD);
315 
316  pmt_SD->InitPMTs((fNx*fNy+fNx*fNz+fNy*fNz)*2); //let pmtSD know # of pmts
317  pmt_SD->SetPmtPositions(fMainVolume->GetPmtPositions());
318  }
319 
320  //sensitive detector is not actually on the photocathode.
321  //processHits gets done manually by the stepping action.
322  //It is used to detect when photons hit and get absorbed&detected at the
323  //boundary to the photocathode (which doesnt get done by attaching it to a
324  //logical volume.
325  //It does however need to be attached to something or else it doesnt get
326  //reset at the begining of events
327 
328  SetSensitiveDetector(fMainVolume->GetLogPhotoCath(), fPmt_SD.Get());
329 
330  // Scint SD
331 
332  if (!fScint_SD.Get()) {
333  G4cout << "Construction /LXeDet/scintSD" << G4endl;
334  LXeScintSD* scint_SD = new LXeScintSD("/LXeDet/scintSD");
335  fScint_SD.Put(scint_SD);
336  }
337  SetSensitiveDetector(fMainVolume->GetLogScint(), fScint_SD.Get());
338 }
value_type & Get() const
Definition: G4Cache.hh:253
std::vector< G4ThreeVector > GetPmtPositions()
G4LogicalVolume * GetLogPhotoCath()
G4LogicalVolume * GetLogScint()
G4GLOB_DLL std::ostream G4cout
void SetSensitiveDetector(const G4String &logVolName, G4VSensitiveDetector *aSD, G4bool multi=false)
void SetPmtPositions(const std::vector< G4ThreeVector > &positions)
Definition: LXePMTSD.cc:62
void InitPMTs(G4int nPMTs)
Definition: LXePMTSD.hh:64
#define G4endl
Definition: G4ios.hh:61
void Put(const value_type &val) const
Definition: G4Cache.hh:257
G4double LXeDetectorConstruction::GetHousingReflectivity ( )
inline

Definition at line 87 of file LXeDetectorConstruction.hh.

87 {return fRefl;}
G4double LXeDetectorConstruction::GetHousingThickness ( )
inline

Definition at line 79 of file LXeDetectorConstruction.hh.

79 {return fD_mtl;}
G4bool LXeDetectorConstruction::GetMainVolumeOn ( )
inline

Definition at line 93 of file LXeDetectorConstruction.hh.

93 {return fMainVolumeOn;}
G4int LXeDetectorConstruction::GetNFibers ( )
inline

Definition at line 96 of file LXeDetectorConstruction.hh.

96 {return fNfibers;}
G4int LXeDetectorConstruction::GetNX ( )
inline

Definition at line 73 of file LXeDetectorConstruction.hh.

73 {return fNx;}
G4int LXeDetectorConstruction::GetNY ( )
inline

Definition at line 74 of file LXeDetectorConstruction.hh.

74 {return fNy;}
G4int LXeDetectorConstruction::GetNZ ( )
inline

Definition at line 75 of file LXeDetectorConstruction.hh.

75 {return fNz;}
G4double LXeDetectorConstruction::GetPMTRadius ( )
inline

Definition at line 80 of file LXeDetectorConstruction.hh.

80 {return fOuterRadius_pmt;}
G4double LXeDetectorConstruction::GetScintX ( )
inline

Definition at line 76 of file LXeDetectorConstruction.hh.

76 {return fScint_x;}
G4double LXeDetectorConstruction::GetScintY ( )
inline

Definition at line 77 of file LXeDetectorConstruction.hh.

77 {return fScint_y;}
G4double LXeDetectorConstruction::GetScintZ ( )
inline

Definition at line 78 of file LXeDetectorConstruction.hh.

78 {return fScint_z;}
G4double LXeDetectorConstruction::GetSlabZ ( )
inline

Definition at line 81 of file LXeDetectorConstruction.hh.

81 {return fSlab_z;}
static G4bool LXeDetectorConstruction::GetSphereOn ( )
inlinestatic

Definition at line 84 of file LXeDetectorConstruction.hh.

Referenced by LXeTrackingAction::PostUserTrackingAction(), and LXePMTSD::ProcessHits_constStep().

84 {return fSphereOn;}
G4bool LXeDetectorConstruction::GetWLSSlabOn ( )
inline

Definition at line 90 of file LXeDetectorConstruction.hh.

90 {return fWLSslab;}
void LXeDetectorConstruction::SetDefaults ( )

Definition at line 386 of file LXeDetectorConstruction.cc.

References G4MaterialPropertiesTable::AddConstProperty(), G4UImanager::ApplyCommand(), python.hepunit::cm, G4RunManager::GetRunManager(), G4UImanager::GetUIpointer(), python.hepunit::keV, python.hepunit::MeV, python.hepunit::mm, and G4RunManager::ReinitializeGeometry().

Referenced by LXeDetectorConstruction(), and LXeDetectorMessenger::SetNewValue().

386  {
387 
388  //Resets to default values
389  fD_mtl=0.0635*cm;
390 
391  fScint_x = 17.8*cm;
392  fScint_y = 17.8*cm;
393  fScint_z = 22.6*cm;
394 
395  fNx = 2;
396  fNy = 2;
397  fNz = 3;
398 
399  fOuterRadius_pmt = 2.3*cm;
400 
401  fSphereOn = true;
402  fRefl=1.0;
403 
404  fNfibers=15;
405  fWLSslab=false;
406  fMainVolumeOn=true;
407  fMainVolume=NULL;
408  fSlab_z=2.5*mm;
409 
411  ->ApplyCommand("/LXe/detector/scintYieldFactor 1.");
412 
413  if(fLXe_mt)fLXe_mt->AddConstProperty("SCINTILLATIONYIELD",12000./MeV);
414  if(fMPTPStyrene)fMPTPStyrene->AddConstProperty("SCINTILLATIONYIELD",10./keV);
415 
417 }
static G4UImanager * GetUIpointer()
Definition: G4UImanager.cc:58
void AddConstProperty(const char *key, G4double PropertyValue)
void ReinitializeGeometry(G4bool destroyFirst=false, G4bool prop=true)
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:74
G4int ApplyCommand(const char *aCommand)
Definition: G4UImanager.cc:419
void LXeDetectorConstruction::SetDimensions ( G4ThreeVector  dims)

Definition at line 342 of file LXeDetectorConstruction.cc.

References G4RunManager::GetRunManager(), and G4RunManager::ReinitializeGeometry().

Referenced by LXeDetectorMessenger::SetNewValue().

342  {
343  this->fScint_x=dims[0];
344  this->fScint_y=dims[1];
345  this->fScint_z=dims[2];
347 }
void ReinitializeGeometry(G4bool destroyFirst=false, G4bool prop=true)
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:74
void LXeDetectorConstruction::SetHousingReflectivity ( G4double  r)

Definition at line 428 of file LXeDetectorConstruction.cc.

References G4RunManager::GetRunManager(), and G4RunManager::ReinitializeGeometry().

Referenced by LXeDetectorMessenger::SetNewValue().

428  {
429  fRefl=r;
431 }
void ReinitializeGeometry(G4bool destroyFirst=false, G4bool prop=true)
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:74
void LXeDetectorConstruction::SetHousingThickness ( G4double  d_mtl)

Definition at line 351 of file LXeDetectorConstruction.cc.

References G4RunManager::GetRunManager(), and G4RunManager::ReinitializeGeometry().

Referenced by LXeDetectorMessenger::SetNewValue().

351  {
352  this->fD_mtl=d_mtl;
354 }
void ReinitializeGeometry(G4bool destroyFirst=false, G4bool prop=true)
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:74
void LXeDetectorConstruction::SetMainScintYield ( G4double  y)

Definition at line 456 of file LXeDetectorConstruction.cc.

References G4MaterialPropertiesTable::AddConstProperty(), and python.hepunit::MeV.

Referenced by LXeDetectorMessenger::SetNewValue().

456  {
457  fLXe_mt->AddConstProperty("SCINTILLATIONYIELD",y/MeV);
458 }
void AddConstProperty(const char *key, G4double PropertyValue)
void LXeDetectorConstruction::SetMainVolumeOn ( G4bool  b)

Definition at line 442 of file LXeDetectorConstruction.cc.

References test::b, G4RunManager::GetRunManager(), and G4RunManager::ReinitializeGeometry().

Referenced by LXeDetectorMessenger::SetNewValue().

442  {
443  fMainVolumeOn=b;
445 }
void ReinitializeGeometry(G4bool destroyFirst=false, G4bool prop=true)
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:74
void LXeDetectorConstruction::SetNFibers ( G4int  n)

Definition at line 449 of file LXeDetectorConstruction.cc.

References G4RunManager::GetRunManager(), n, and G4RunManager::ReinitializeGeometry().

Referenced by LXeDetectorMessenger::SetNewValue().

449  {
450  fNfibers=n;
452 }
const G4int n
void ReinitializeGeometry(G4bool destroyFirst=false, G4bool prop=true)
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:74
void LXeDetectorConstruction::SetNX ( G4int  nx)

Definition at line 358 of file LXeDetectorConstruction.cc.

References G4RunManager::GetRunManager(), and G4RunManager::ReinitializeGeometry().

Referenced by LXeDetectorMessenger::SetNewValue().

358  {
359  this->fNx=nx;
361 }
void ReinitializeGeometry(G4bool destroyFirst=false, G4bool prop=true)
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:74
void LXeDetectorConstruction::SetNY ( G4int  ny)

Definition at line 365 of file LXeDetectorConstruction.cc.

References G4RunManager::GetRunManager(), and G4RunManager::ReinitializeGeometry().

Referenced by LXeDetectorMessenger::SetNewValue().

365  {
366  this->fNy=ny;
368 }
void ReinitializeGeometry(G4bool destroyFirst=false, G4bool prop=true)
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:74
void LXeDetectorConstruction::SetNZ ( G4int  nz)

Definition at line 372 of file LXeDetectorConstruction.cc.

References G4RunManager::GetRunManager(), and G4RunManager::ReinitializeGeometry().

Referenced by LXeDetectorMessenger::SetNewValue().

372  {
373  this->fNz=nz;
375 }
void ReinitializeGeometry(G4bool destroyFirst=false, G4bool prop=true)
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:74
void LXeDetectorConstruction::SetPMTRadius ( G4double  outerRadius_pmt)

Definition at line 379 of file LXeDetectorConstruction.cc.

References G4RunManager::GetRunManager(), and G4RunManager::ReinitializeGeometry().

Referenced by LXeDetectorMessenger::SetNewValue().

379  {
380  this->fOuterRadius_pmt=outerRadius_pmt;
382 }
void ReinitializeGeometry(G4bool destroyFirst=false, G4bool prop=true)
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:74
void LXeDetectorConstruction::SetSphereOn ( G4bool  b)

Definition at line 421 of file LXeDetectorConstruction.cc.

References test::b, G4RunManager::GetRunManager(), and G4RunManager::ReinitializeGeometry().

Referenced by LXeDetectorMessenger::SetNewValue().

421  {
422  fSphereOn=b;
424 }
void ReinitializeGeometry(G4bool destroyFirst=false, G4bool prop=true)
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:74
void LXeDetectorConstruction::SetWLSScintYield ( G4double  y)

Definition at line 462 of file LXeDetectorConstruction.cc.

References G4MaterialPropertiesTable::AddConstProperty(), and python.hepunit::MeV.

Referenced by LXeDetectorMessenger::SetNewValue().

462  {
463  fMPTPStyrene->AddConstProperty("SCINTILLATIONYIELD",y/MeV);
464 }
void AddConstProperty(const char *key, G4double PropertyValue)
void LXeDetectorConstruction::SetWLSSlabOn ( G4bool  b)

Definition at line 435 of file LXeDetectorConstruction.cc.

References test::b, G4RunManager::GetRunManager(), and G4RunManager::ReinitializeGeometry().

Referenced by LXeDetectorMessenger::SetNewValue().

435  {
436  fWLSslab=b;
438 }
void ReinitializeGeometry(G4bool destroyFirst=false, G4bool prop=true)
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:74

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