Back to home page

EIC code displayed by LXR

 
 

    


File indexing completed on 2025-01-18 09:17:03

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 //
0027 //
0028 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
0029 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
0030 
0031 #ifndef DetectorConstruction_h
0032 #define DetectorConstruction_h 1
0033 
0034 #include "G4Cache.hh"
0035 #include "G4LogicalVolume.hh"
0036 #include "G4VUserDetectorConstruction.hh"
0037 #include "globals.hh"
0038 
0039 class G4Box;
0040 class G4Ellipsoid;
0041 class G4Sphere;
0042 class G4VPhysicalVolume;
0043 class G4Material;
0044 class DetectorMessenger;
0045 class G4GlobalMagFieldMessenger;
0046 
0047 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
0048 
0049 class DetectorConstruction : public G4VUserDetectorConstruction
0050 {
0051 public:
0052   DetectorConstruction();
0053   ~DetectorConstruction() override;
0054 
0055   void SetAbsorberMaterial(const G4String&);
0056   void SetAbsorberThickness(G4double);
0057   void SetAbsorberSizeYZ(G4double);
0058 
0059   void SetAbsorberXpos(G4double);
0060 
0061   void SetWorldMaterial(const G4String&);
0062   void SetWorldSizeX(G4double);
0063   void SetWorldSizeYZ(G4double);
0064   void SetPhantomType(G4int value);
0065 
0066   G4VPhysicalVolume* Construct() override;
0067   void ConstructSDandField() override;
0068 
0069   void PrintGeomParameters();
0070 
0071 private:
0072   void DefineMaterials();
0073   void ComputeGeomParameters();
0074   void ChangeGeometry();
0075   void Construct_Phantom1();
0076   void Construct_Phantom2();
0077   void Construct_Phantom3();
0078 
0079   G4int phantom_type;
0080 
0081   G4Material* fAbsorberMaterial;
0082   G4double fAbsorberThickness;
0083   G4double fAbsorberSizeYZ;
0084 
0085   G4double fXposAbs;
0086   G4double fXstartAbs, fXendAbs;
0087 
0088   G4Material* fWorldMaterial;
0089   G4double fWorldSizeX;
0090   G4double fWorldSizeYZ;
0091 
0092   G4Box* fSolidWorld;
0093   G4LogicalVolume* fLogicWorld;
0094   G4VPhysicalVolume* fPhysiWorld;
0095 
0096   G4Box* fSolidAbsorber;
0097   G4LogicalVolume* fLogicAbsorber;
0098   G4VPhysicalVolume* fPhysiAbsorber;
0099 
0100   G4Material* material1;
0101   G4Material* material2;
0102   G4Material* material3;
0103   G4Material* material4;
0104   G4Material* material5;
0105   G4Material* material6;
0106   G4Material* material_GDP;
0107 
0108   G4Ellipsoid* ellipse1;
0109   G4LogicalVolume* logicEllipse1;
0110   G4VPhysicalVolume* physiEllipse1;
0111 
0112   G4Ellipsoid* ellipse2;
0113   G4LogicalVolume* logicEllipse2;
0114   G4VPhysicalVolume* physiEllipse2;
0115 
0116   G4Ellipsoid* ellipse3;
0117   G4LogicalVolume* logicEllipse3;
0118   G4VPhysicalVolume* physiEllipse3;
0119 
0120   G4Ellipsoid* ellipse4;
0121   G4LogicalVolume* logicEllipse4;
0122   G4VPhysicalVolume* physiEllipse4;
0123 
0124   G4Ellipsoid* ellipse5;
0125   G4LogicalVolume* logicEllipse5;
0126   G4VPhysicalVolume* physiEllipse5;
0127 
0128   G4Ellipsoid* ellipse6;
0129   G4LogicalVolume* logicEllipse6;
0130   G4VPhysicalVolume* physiEllipse6;
0131 
0132   // Ge-doped glow discharge polymer (GDP)
0133   G4Sphere* solid_GDP;
0134   G4LogicalVolume* logic_GDP;
0135   G4VPhysicalVolume* physi_GDP;
0136 
0137   DetectorMessenger* fDetectorMessenger;
0138   G4Cache<G4GlobalMagFieldMessenger*> fFieldMessenger;
0139 };
0140 
0141 //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
0142 
0143 #endif