Main Page | Namespace List | Class Hierarchy | Class List | Directories | File List | Class Members | File Members

MaGeGeometryGermaniumArrayHole.cc

Go to the documentation of this file.
00001 //---------------------------------------------------------------------------//
00002 //bb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nu//
00003 //                                                                           //
00004 //                         MAJORANA Simulation                               //
00005 //                                                                           //
00006 //      This code implementation is the intellectual property of the         //
00007 //      MAJORANA Collaboration. It is based on Geant4, an intellectual       //
00008 //      property of the RD44 GEANT4 collaboration.                           //
00009 //                                                                           //
00010 //                        *********************                              //
00011 //                                                                           //
00012 //    Neither the authors of this software system, nor their employing       //
00013 //    institutes, nor the agencies providing financial support for this      //
00014 //    work  make  any representation or  warranty, express or implied,       //
00015 //    regarding this software system or assume any liability for its use.    //
00016 //    By copying, distributing or modifying the Program (or any work based   //
00017 //    on on the Program) you indicate your acceptance of this statement,     //
00018 //    and all its terms.                                                     //
00019 //                                                                           //
00020 //bb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nubb0nu//
00021 //---------------------------------------------------------------------------//
00022 //                                                          
00023 // $Id: MaGeGeometryGermaniumArrayHole.cc,v 1.1 2004/11/26 09:46:10 pandola Exp $ 
00024 //      
00025 // CLASS IMPLEMENTATION:  @CLASS_NAME@.cc
00026 //
00027 //---------------------------------------------------------------------------//
00034 // 
00035 //---------------------------------------------------------------------------//
00067 //---------------------------------------------------------------------------//
00068 //
00069 // G4 includes
00070 #include "G4Element.hh"
00071 #include "G4Material.hh"
00072 #include "G4Box.hh"
00073 #include "G4Tubs.hh"
00074 #include "G4Sphere.hh"
00075 #include "G4SubtractionSolid.hh"
00076 #include "G4LogicalVolume.hh"
00077 #include "G4ThreeVector.hh"
00078 #include "G4PVPlacement.hh"
00079 #include "G4PVParameterised.hh"
00080 #include "globals.hh"
00081 #include "G4UnitsTable.hh"
00082 #include "G4Transform3D.hh"
00083 #include "G4RotationMatrix.hh"
00084 #include "G4SDManager.hh"
00085 #include "G4VisAttributes.hh"
00086 #include "G4Colour.hh"
00087 
00088 // MJ include
00089 #include "io/MJLogger.hh"
00090 
00091 // Gerda include
00092 #include "gerdageometry/MaGeGeometryGermaniumCrystalHole.hh"
00093 #include "gerdageometry/MaGeGeometryGermaniumArrayHoleMessenger.hh"
00094 
00095 #include "gerdageometry/MaGeGeometryGermaniumArrayHole.hh"
00096 
00097 //---------------------------------------------------------------------------//
00098 
00099 
00100 //---------------------------------------------------------------------------//
00101 
00102 MaGeGeometryGermaniumArrayHole::MaGeGeometryGermaniumArrayHole() :
00103 GeCrystalInnerRadius(1.0*cm),
00104 GeCrystalOuterRadius(4.0*cm),
00105 GeCrystalHeight(8.0*cm),
00106 GeCrystalDeadlayer(0.01*cm),
00107 GeDetectorHorizontalGap(1.0*cm),
00108 GeDetectorVerticalGap(5.0*cm)
00109 {
00110 
00111     theCrystal = new MaGeGeometryGermaniumCrystalHole();
00112     fMessenger = new MaGeGeometryGermaniumArrayHoleMessenger(this);
00113 }
00114 
00115 MaGeGeometryGermaniumArrayHole::~MaGeGeometryGermaniumArrayHole()
00116 {
00117 }
00118 
00119 void MaGeGeometryGermaniumArrayHole::ConstructArrayPositions()
00120 {
00121 
00122 // --- position crystal inside liquid nitrogen --- //
00123     GeCrystalOuterRadius = theCrystal->GetOuterRadius();
00124     GeCrystalInnerRadius = theCrystal->GetInnerRadius();
00125     GeCrystalHeight      = theCrystal->GetHeight();
00126     GeCrystalDeadlayer   = theCrystal->GetDeadLayer();
00127 
00128     float xpos[GeCrystalNumColumn];
00129     float ypos[GeCrystalNumColumn];
00130     float zpos[GeCrystalNumLayer];
00131 
00132     xpos[0]=0.0;
00133     ypos[0]=0.0;
00134     float angleinxyplane;
00135     for (G4int i=0; i<(GeCrystalNumColumn-1); i++) {
00136       angleinxyplane=(float(i)*60.0/180.0)*pi*rad;
00137       xpos[i+1]=(2.0*GeCrystalOuterRadius+GeDetectorHorizontalGap)
00138              *cos(angleinxyplane);
00139       ypos[i+1]=(2.0*GeCrystalOuterRadius+GeDetectorHorizontalGap)
00140              *sin(angleinxyplane);
00141     }
00142     zpos[0]=0.0;
00143     zpos[1]=GeCrystalHeight+GeDetectorVerticalGap;
00144     zpos[2]=0.0-GeCrystalHeight-GeDetectorVerticalGap;
00145 
00146     G4int iGe=0;
00147     for (G4int i=0; i<GeCrystalNumLayer; i++) {    // for the moment 3 layers
00148       for (G4int j=0; j<GeCrystalNumColumn; j++) { // 7 detectors in each layer
00149 //        sprintf(name_ge[iGe],"Ge_det_%d",iGe);
00150         position_ge[iGe].setX(xpos[j]);
00151         position_ge[iGe].setY(ypos[j]);
00152         position_ge[iGe].setZ(zpos[i]);
00153         iGe++;
00154       }
00155     }
00156 
00157     theCrystal->ConstructCrystal();
00158 
00159 }

Generated on Mon Nov 29 16:58:52 2004 for Majorana Simulation by  doxygen 1.3.9.1