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

#include <Em10DetectorConstruction.hh>

Inheritance diagram for Em10DetectorConstruction:
G4VUserDetectorConstruction

Public Member Functions

 Em10DetectorConstruction ()
 
 ~Em10DetectorConstruction ()
 
void SetAbsorberMaterial (G4String)
 
void SetAbsorberThickness (G4double)
 
void SetAbsorberRadius (G4double)
 
void SetAbsorberZpos (G4double)
 
void SetRadiatorMaterial (G4String)
 
void SetRadiatorThickness (G4double)
 
void SetGasGapThickness (G4double)
 
void SetFoilNumber (G4int i)
 
void SetWorldMaterial (G4String)
 
void SetWorldSizeZ (G4double)
 
void SetWorldSizeR (G4double)
 
void SetDetectorSetUp (G4String s)
 
void SetMagField (G4double)
 
G4VPhysicalVolumeConstruct ()
 
void UpdateGeometry ()
 
void PrintGeometryParameters ()
 
G4MaterialGetWorldMaterial ()
 
G4double GetWorldSizeZ ()
 
G4double GetWorldSizeR ()
 
G4double GetAbsorberZpos ()
 
G4MaterialGetAbsorberMaterial ()
 
G4double GetAbsorberThickness ()
 
G4double GetAbsorberRadius ()
 
const G4VPhysicalVolumeGetphysiWorld ()
 
const G4VPhysicalVolumeGetAbsorber ()
 
G4LogicalVolumeGetLogicalAbsorber ()
 
G4LogicalVolumeGetLogicalRadiator ()
 
G4double GetFoilThick ()
 
G4double GetGasThick ()
 
G4int GetFoilNumber ()
 
G4MaterialGetFoilMaterial ()
 
G4MaterialGetGasMaterial ()
 
- Public Member Functions inherited from G4VUserDetectorConstruction
 G4VUserDetectorConstruction ()
 
virtual ~G4VUserDetectorConstruction ()
 
virtual void ConstructSDandField ()
 
virtual void CloneSD ()
 
virtual void CloneF ()
 
void RegisterParallelWorld (G4VUserParallelWorld *)
 
G4int ConstructParallelGeometries ()
 
void ConstructParallelSD ()
 
G4int GetNumberOfParallelWorld () const
 
G4VUserParallelWorldGetParallelWorld (G4int i) const
 

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 54 of file Em10DetectorConstruction.hh.

Constructor & Destructor Documentation

Em10DetectorConstruction::Em10DetectorConstruction ( )

Definition at line 66 of file Em10DetectorConstruction.cc.

68  fWorldChanged(false), fAbsorberMaterial(0), fGapMat(0), fSetUp("simpleALICE"),
69  fWorldMaterial(0), fSolidWorld(0), fLogicWorld(0), fPhysicsWorld(0),
70 // fSolidRadSlice(0), fLogicRadSlice(0), fPhysicRadSlice(0),
71  fSolidRadiator(0), fLogicRadiator(0), fPhysicsRadiator(0),
72  fRadiatorMat(0), fPipe(false), fPipeField(false),
73  fSolidAbsorber(0), fLogicAbsorber(0), fPhysicsAbsorber(0),
74  fMagField(0), fCalorimeterSD(0), fRegGasDet(0),
75  fRadRegion(0), fMat(0)
76 {
77  fDetectorMessenger = new Em10DetectorMessenger(this);
78  fMat = new Em10Materials();
79 }
Em10DetectorConstruction::~Em10DetectorConstruction ( )

Definition at line 83 of file Em10DetectorConstruction.cc.

84 {
85  delete fDetectorMessenger;
86  delete fMat;
87 }

Member Function Documentation

G4VPhysicalVolume * Em10DetectorConstruction::Construct ( void  )
virtual

Implements G4VUserDetectorConstruction.

Definition at line 91 of file Em10DetectorConstruction.cc.

Referenced by Em10DetectorMessenger::SetNewValue().

92 {
93  return ConstructDetectorXTR();
94 }
const G4VPhysicalVolume* Em10DetectorConstruction::GetAbsorber ( )
inline

Definition at line 102 of file Em10DetectorConstruction.hh.

Referenced by Em10CalorimeterSD::ProcessHits().

102 {return fPhysicsAbsorber;};
G4Material* Em10DetectorConstruction::GetAbsorberMaterial ( )
inline

Definition at line 97 of file Em10DetectorConstruction.hh.

97 {return fAbsorberMaterial;};
G4double Em10DetectorConstruction::GetAbsorberRadius ( )
inline

Definition at line 99 of file Em10DetectorConstruction.hh.

99 {return fAbsorberRadius;};
G4double Em10DetectorConstruction::GetAbsorberThickness ( )
inline

Definition at line 98 of file Em10DetectorConstruction.hh.

98 {return fAbsorberThickness;};
G4double Em10DetectorConstruction::GetAbsorberZpos ( )
inline

Definition at line 95 of file Em10DetectorConstruction.hh.

95 {return fAbsorberZ;};
G4Material* Em10DetectorConstruction::GetFoilMaterial ( )
inline

Definition at line 109 of file Em10DetectorConstruction.hh.

109 {return fFoilMat;};
G4int Em10DetectorConstruction::GetFoilNumber ( )
inline

Definition at line 108 of file Em10DetectorConstruction.hh.

108 {return fFoilNumber;};
G4double Em10DetectorConstruction::GetFoilThick ( )
inline

Definition at line 106 of file Em10DetectorConstruction.hh.

106 {return fRadThickness;};
G4Material* Em10DetectorConstruction::GetGasMaterial ( )
inline

Definition at line 110 of file Em10DetectorConstruction.hh.

110 {return fGasMat;};
G4double Em10DetectorConstruction::GetGasThick ( )
inline

Definition at line 107 of file Em10DetectorConstruction.hh.

107 {return fGasGap;};
G4LogicalVolume* Em10DetectorConstruction::GetLogicalAbsorber ( )
inline

Definition at line 103 of file Em10DetectorConstruction.hh.

103 {return fLogicAbsorber;};
G4LogicalVolume* Em10DetectorConstruction::GetLogicalRadiator ( )
inline

Definition at line 105 of file Em10DetectorConstruction.hh.

105 {return fLogicRadiator;};
const G4VPhysicalVolume* Em10DetectorConstruction::GetphysiWorld ( )
inline

Definition at line 101 of file Em10DetectorConstruction.hh.

101 {return fPhysicsWorld;};
G4Material* Em10DetectorConstruction::GetWorldMaterial ( )
inline

Definition at line 91 of file Em10DetectorConstruction.hh.

91 {return fWorldMaterial;};
G4double Em10DetectorConstruction::GetWorldSizeR ( )
inline

Definition at line 93 of file Em10DetectorConstruction.hh.

93 {return fWorldSizeR;};
G4double Em10DetectorConstruction::GetWorldSizeZ ( )
inline

Definition at line 92 of file Em10DetectorConstruction.hh.

92 {return fWorldSizeZ;};
void Em10DetectorConstruction::PrintGeometryParameters ( )

Definition at line 1529 of file Em10DetectorConstruction.cc.

References G4cout, G4endl, G4Material::GetName(), and python.hepunit::mm.

1530 {
1531  G4cout << "\n The WORLD is made of "
1532  << fWorldSizeZ/mm << "mm of " << fWorldMaterial->GetName();
1533  G4cout << ", the transverse size (R) of the world is " <<
1534  fWorldSizeR/mm << " mm. " << G4endl;
1535  G4cout << " The ABSORBER is made of "
1536  << fAbsorberThickness/mm << "mm of " << fAbsorberMaterial->GetName();
1537  G4cout << ", the transverse size (R) is " << fAbsorberRadius/mm <<
1538  " mm. " << G4endl;
1539  G4cout << " Z position of the (middle of the) absorber "
1540  << fAbsorberZ/mm << " mm." << G4endl;
1541 
1542  G4cout<<"fRadZ = "<<fRadZ/mm<<" mm"<<G4endl;
1543 
1544  G4cout<<"fStartZ = "<<fStartZ/mm<<" mm"<<G4endl;
1545 
1546  G4cout<<"fRadThick = "<<fRadThick/mm<<" mm"<<G4endl;
1547  G4cout<<"fFoilNumber = "<<fFoilNumber<<G4endl;
1548  G4cout<<"fRadiatorMat = "<<fRadiatorMat->GetName()<<G4endl;
1549  G4cout<<"WorldMaterial = "<<fWorldMaterial->GetName()<<G4endl;
1550  // G4cout<<"fAbsorberZ = "<<fAbsorberZ/mm<<" mm"<<G4endl;
1551  G4cout << G4endl;
1552 }
const G4String & GetName() const
Definition: G4Material.hh:176
G4GLOB_DLL std::ostream G4cout
#define G4endl
Definition: G4ios.hh:61
void Em10DetectorConstruction::SetAbsorberMaterial ( G4String  materialChoice)

Definition at line 1556 of file Em10DetectorConstruction.cc.

References G4Material::GetMaterialTable(), G4Material::GetName(), and G4LogicalVolume::SetMaterial().

Referenced by Em10DetectorMessenger::SetNewValue().

1557 {
1558  // get the pointer to the material table
1559  const G4MaterialTable* theMaterialTable = G4Material::GetMaterialTable();
1560 
1561  // search the material by its name
1562  G4Material* pttoMaterial;
1563 
1564  for (size_t J=0 ; J<theMaterialTable->size() ; J++)
1565  {
1566  pttoMaterial = (*theMaterialTable)[J];
1567 
1568  if(pttoMaterial->GetName() == materialChoice)
1569  {
1570  fAbsorberMaterial = pttoMaterial;
1571  fLogicAbsorber->SetMaterial(pttoMaterial);
1572  // PrintCalorParameters();
1573  }
1574  }
1575 }
const G4String & GetName() const
Definition: G4Material.hh:176
static G4MaterialTable * GetMaterialTable()
Definition: G4Material.cc:564
std::vector< G4Material * > G4MaterialTable
void SetMaterial(G4Material *pMaterial)
void Em10DetectorConstruction::SetAbsorberRadius ( G4double  val)

Definition at line 1653 of file Em10DetectorConstruction.cc.

Referenced by Em10DetectorMessenger::SetNewValue().

1654 {
1655  // change the transverse size and recompute the calorimeter parameters
1656  fAbsorberRadius = val;
1657  // ComputeCalorParameters();
1658 }
void Em10DetectorConstruction::SetAbsorberThickness ( G4double  val)

Definition at line 1626 of file Em10DetectorConstruction.cc.

Referenced by Em10DetectorMessenger::SetNewValue().

1627 {
1628  // change Absorber thickness and recompute the calorimeter parameters
1629  fAbsorberThickness = val;
1630  // ComputeCalorParameters();
1631 }
void Em10DetectorConstruction::SetAbsorberZpos ( G4double  val)

Definition at line 1680 of file Em10DetectorConstruction.cc.

Referenced by Em10DetectorMessenger::SetNewValue().

1681 {
1682  fAbsorberZ = val;
1683  // ComputeCalorParameters();
1684 }
void Em10DetectorConstruction::SetDetectorSetUp ( G4String  s)
inline

Definition at line 78 of file Em10DetectorConstruction.hh.

Referenced by Em10DetectorMessenger::SetNewValue().

78 {fSetUp = s;};
const XML_Char * s
void Em10DetectorConstruction::SetFoilNumber ( G4int  i)
inline

Definition at line 73 of file Em10DetectorConstruction.hh.

Referenced by Em10DetectorMessenger::SetNewValue().

73 {fFoilNumber = i; };
void Em10DetectorConstruction::SetGasGapThickness ( G4double  val)

Definition at line 1644 of file Em10DetectorConstruction.cc.

Referenced by Em10DetectorMessenger::SetNewValue().

1645 {
1646  // change XTR gas gap thickness and recompute the calorimeter parameters
1647  fGasGap = val;
1648  // ComputeCalorParameters();
1649 }
void Em10DetectorConstruction::SetMagField ( G4double  )

Definition at line 1688 of file Em10DetectorConstruction.cc.

Referenced by Em10DetectorMessenger::SetNewValue().

1689 {
1690  //apply a global uniform magnetic field along X axis
1691 
1692  /* *********************************************************
1693 
1694  G4FieldManager* fieldMgr
1695  = G4TransportationManager::GetTransportationManager()->GetFieldManager();
1696 
1697  if(magField) delete magField; //delete the existing magn field
1698 
1699  if(fieldValue!=0.) // create a new one if non null
1700  {
1701  magField = new G4UniformMagField(G4ThreeVector(fieldValue,0.,0.));
1702  fieldMgr->SetDetectorField(magField);
1703  fieldMgr->CreateChordFinder(magField);
1704  }
1705  else
1706  {
1707  magField = 0;
1708  fieldMgr->SetDetectorField(magField);
1709  }
1710 
1711  *************************************************************** */
1712 
1713 }
void Em10DetectorConstruction::SetRadiatorMaterial ( G4String  materialChoice)

Definition at line 1579 of file Em10DetectorConstruction.cc.

References G4Material::GetMaterialTable(), and G4Material::GetName().

Referenced by Em10DetectorMessenger::SetNewValue().

1580 {
1581  // get the pointer to the material table
1582 
1583  const G4MaterialTable* theMaterialTable = G4Material::GetMaterialTable();
1584 
1585  // search the material by its name
1586 
1587  G4Material* pttoMaterial;
1588  for (size_t J=0 ; J<theMaterialTable->size() ; J++)
1589  {
1590  pttoMaterial = (*theMaterialTable)[J];
1591 
1592  if(pttoMaterial->GetName() == materialChoice)
1593  {
1594  fRadiatorMat = pttoMaterial;
1595 // fLogicRadSlice->SetMaterial(pttoMaterial);
1596  // PrintCalorParameters();
1597  }
1598  }
1599 }
const G4String & GetName() const
Definition: G4Material.hh:176
static G4MaterialTable * GetMaterialTable()
Definition: G4Material.cc:564
std::vector< G4Material * > G4MaterialTable
void Em10DetectorConstruction::SetRadiatorThickness ( G4double  val)

Definition at line 1635 of file Em10DetectorConstruction.cc.

Referenced by Em10DetectorMessenger::SetNewValue().

1636 {
1637  // change XTR radiator thickness and recompute the calorimeter parameters
1638  fRadThickness = val;
1639  // ComputeCalorParameters();
1640 }
void Em10DetectorConstruction::SetWorldMaterial ( G4String  materialChoice)

Definition at line 1603 of file Em10DetectorConstruction.cc.

References G4Material::GetMaterialTable(), G4Material::GetName(), and G4LogicalVolume::SetMaterial().

Referenced by Em10DetectorMessenger::SetNewValue().

1604 {
1605  // get the pointer to the material table
1606  const G4MaterialTable* theMaterialTable = G4Material::GetMaterialTable();
1607 
1608  // search the material by its name
1609  G4Material* pttoMaterial;
1610 
1611  for (size_t J=0 ; J<theMaterialTable->size() ; J++)
1612  {
1613  pttoMaterial = (*theMaterialTable)[J];
1614 
1615  if(pttoMaterial->GetName() == materialChoice)
1616  {
1617  fWorldMaterial = pttoMaterial;
1618  fLogicWorld->SetMaterial(pttoMaterial);
1619  // PrintCalorParameters();
1620  }
1621  }
1622 }
const G4String & GetName() const
Definition: G4Material.hh:176
static G4MaterialTable * GetMaterialTable()
Definition: G4Material.cc:564
std::vector< G4Material * > G4MaterialTable
void SetMaterial(G4Material *pMaterial)
void Em10DetectorConstruction::SetWorldSizeR ( G4double  val)

Definition at line 1671 of file Em10DetectorConstruction.cc.

Referenced by Em10DetectorMessenger::SetNewValue().

1672 {
1673  fWorldChanged=true;
1674  fWorldSizeR = val;
1675  // ComputeCalorParameters();
1676 }
void Em10DetectorConstruction::SetWorldSizeZ ( G4double  val)

Definition at line 1662 of file Em10DetectorConstruction.cc.

Referenced by Em10DetectorMessenger::SetNewValue().

1663 {
1664  fWorldChanged=true;
1665  fWorldSizeZ = val;
1666  // ComputeCalorParameters();
1667 }
void Em10DetectorConstruction::UpdateGeometry ( )

Definition at line 1717 of file Em10DetectorConstruction.cc.

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

Referenced by Em10DetectorMessenger::SetNewValue().

1718 {
1719  G4RunManager::GetRunManager()->DefineWorldVolume(ConstructDetectorXTR());
1720 }
virtual void DefineWorldVolume(G4VPhysicalVolume *worldVol, G4bool topologyIsChanged=true)
static G4RunManager * GetRunManager()
Definition: G4RunManager.cc:74

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