Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2026-09-12 08:30:04

0001 //
0002 // ********************************************************************
0003 // * License and Disclaimer                                           *
0004 // *                                                                  *
0005 // * The  Geant4 software  is  copyright of the Copyright Holders  of *
0006 // * the Geant4 Collaboration.  It is provided  under  the terms  and *
0007 // * conditions of the Geant4 Software License,  included in the file *
0008 // * LICENSE and available at  http://cern.ch/geant4/license .  These *
0009 // * include a list of copyright holders.                             *
0010 // *                                                                  *
0011 // * Neither the authors of this software system, nor their employing *
0012 // * institutes,nor the agencies providing financial support for this *
0013 // * work  make  any representation or  warranty, express or implied, *
0014 // * regarding  this  software system or assume any liability for its *
0015 // * use.  Please see the license in the file  LICENSE  and URL above *
0016 // * for the full disclaimer and the limitation of liability.         *
0017 // *                                                                  *
0018 // * This  code  implementation is the result of  the  scientific and *
0019 // * technical work of the GEANT4 collaboration.                      *
0020 // * By using,  copying,  modifying or  distributing the software (or *
0021 // * any work based  on the software)  you  agree  to acknowledge its *
0022 // * use  in  resulting  scientific  publications,  and indicate your *
0023 // * acceptance of all terms of the Geant4 Software license.          *
0024 // ********************************************************************
0025 //
0026 /// \file DetectorConstruction.hh
0027 /// \brief Definition of the DetectorConstruction class
0028 
0029 #ifndef DetectorConstruction_H
0030 #define DetectorConstruction_H 1
0031 
0032 #include "G4VUserDetectorConstruction.hh"
0033 #include "globals.hh"
0034 
0035 class G4LogicalVolume;
0036 class G4VPhysicalVolume;
0037 class G4Material;
0038 class DetectorMessenger;
0039 
0040 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
0041 
0042 class DetectorConstruction : public G4VUserDetectorConstruction
0043 {
0044   public:
0045     DetectorConstruction();
0046     ~DetectorConstruction();
0047 
0048     G4VPhysicalVolume* Construct();
0049 
0050     void SetMaterialTracker(const G4String name);
0051     inline G4Material* GetMaterialTracker() const;
0052     void SetMaterialEmCalo(const G4String name);
0053     inline G4Material* GetMaterialEmCalo() const;
0054     void SetMaterialHadCalo(const G4String name);
0055     inline G4Material* GetMaterialHadCalo() const;
0056 
0057     inline void SetInnerRadiusTracker(const G4double value);
0058     inline G4double GetInnerRadiusTracker() const;
0059     inline void SetOuterRadiusTracker(const G4double value);
0060     inline G4double GetOuterRadiusTracker() const;
0061     inline void SetInnerRadiusEmCalo(const G4double value);
0062     inline G4double GetInnerRadiusEmCalo() const;
0063     inline void SetOuterRadiusEmCalo(const G4double value);
0064     inline G4double GetOuterRadiusEmCalo() const;
0065     inline void SetInnerRadiusHadCalo(const G4double value);
0066     inline G4double GetInnerRadiusHadCalo() const;
0067     inline void SetOuterRadiusHadCalo(const G4double value);
0068     inline G4double GetOuterRadiusHadCalo() const;
0069     inline G4double GetScoringThickness() const;
0070 
0071     void UpdateGeometry();
0072 
0073   private:
0074     G4VPhysicalVolume* ConstructDetector();  // To be invoked each time the geometry needs
0075                                              // to be updated.
0076     void PrintParameters();
0077     G4Material* fMaterialTracker;
0078     G4Material* fMaterialEmCalo;
0079     G4Material* fMaterialHadCalo;
0080     G4LogicalVolume* fExperimentalHall_log;
0081     G4VPhysicalVolume* fExperimentalHall_phys;
0082     G4LogicalVolume* fLogicTrackerShell;
0083     G4VPhysicalVolume* fPhysiTrackerShell;
0084     G4LogicalVolume* fLogicEmCaloShell;
0085     G4VPhysicalVolume* fPhysiEmCaloShell;
0086     G4LogicalVolume* fLogicHadCaloShell;
0087     G4VPhysicalVolume* fPhysiHadCaloShell;
0088     G4LogicalVolume* fLogicScoringTrackerShell;
0089     G4VPhysicalVolume* fPhysiScoringTrackerShell;
0090     G4LogicalVolume* fLogicScoringEmCaloShell;
0091     G4VPhysicalVolume* fPhysiScoringEmCaloShell;
0092     G4LogicalVolume* fLogicScoringHadCaloShell;
0093     G4VPhysicalVolume* fPhysiScoringHadCaloShell;
0094     DetectorMessenger* fDetectorMessenger;
0095     G4double fInnerRadiusTracker;
0096     G4double fOuterRadiusTracker;
0097     G4double fInnerRadiusEmCalo;
0098     G4double fOuterRadiusEmCalo;
0099     G4double fInnerRadiusHadCalo;
0100     G4double fOuterRadiusHadCalo;
0101     const G4double fScoringThickness = 10.0;  //***LOOKHERE*** thickness of the scoring shell
0102 };
0103 
0104 inline G4Material* DetectorConstruction::GetMaterialTracker() const
0105 {
0106   return fMaterialTracker;
0107 }
0108 
0109 inline G4Material* DetectorConstruction::GetMaterialEmCalo() const
0110 {
0111   return fMaterialEmCalo;
0112 }
0113 
0114 inline G4Material* DetectorConstruction::GetMaterialHadCalo() const
0115 {
0116   return fMaterialHadCalo;
0117 }
0118 
0119 inline G4double DetectorConstruction::GetInnerRadiusTracker() const
0120 {
0121   return fInnerRadiusTracker;
0122 }
0123 
0124 inline void DetectorConstruction::SetInnerRadiusTracker(const G4double value)
0125 {
0126   fInnerRadiusTracker = value;
0127 }
0128 
0129 inline G4double DetectorConstruction::GetOuterRadiusTracker() const
0130 {
0131   return fOuterRadiusTracker;
0132 }
0133 
0134 inline void DetectorConstruction::SetOuterRadiusTracker(const G4double value)
0135 {
0136   fOuterRadiusTracker = value;
0137 }
0138 
0139 inline G4double DetectorConstruction::GetInnerRadiusEmCalo() const
0140 {
0141   return fInnerRadiusEmCalo;
0142 }
0143 
0144 inline void DetectorConstruction::SetInnerRadiusEmCalo(const G4double value)
0145 {
0146   fInnerRadiusEmCalo = value;
0147 }
0148 
0149 inline G4double DetectorConstruction::GetOuterRadiusEmCalo() const
0150 {
0151   return fOuterRadiusEmCalo;
0152 }
0153 
0154 inline void DetectorConstruction::SetOuterRadiusEmCalo(const G4double value)
0155 {
0156   fOuterRadiusEmCalo = value;
0157 }
0158 
0159 inline G4double DetectorConstruction::GetInnerRadiusHadCalo() const
0160 {
0161   return fInnerRadiusHadCalo;
0162 }
0163 
0164 inline void DetectorConstruction::SetInnerRadiusHadCalo(const G4double value)
0165 {
0166   fInnerRadiusHadCalo = value;
0167 }
0168 
0169 inline G4double DetectorConstruction::GetOuterRadiusHadCalo() const
0170 {
0171   return fOuterRadiusHadCalo;
0172 }
0173 
0174 inline void DetectorConstruction::SetOuterRadiusHadCalo(const G4double value)
0175 {
0176   fOuterRadiusHadCalo = value;
0177 }
0178 
0179 inline G4double DetectorConstruction::GetScoringThickness() const
0180 {
0181   return fScoringThickness;
0182 }
0183 
0184 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
0185 
0186 #endif