G3Division.hh

Go to the documentation of this file.
00001 //
00002 // ********************************************************************
00003 // * License and Disclaimer                                           *
00004 // *                                                                  *
00005 // * The  Geant4 software  is  copyright of the Copyright Holders  of *
00006 // * the Geant4 Collaboration.  It is provided  under  the terms  and *
00007 // * conditions of the Geant4 Software License,  included in the file *
00008 // * LICENSE and available at  http://cern.ch/geant4/license .  These *
00009 // * include a list of copyright holders.                             *
00010 // *                                                                  *
00011 // * Neither the authors of this software system, nor their employing *
00012 // * institutes,nor the agencies providing financial support for this *
00013 // * work  make  any representation or  warranty, express or implied, *
00014 // * regarding  this  software system or assume any liability for its *
00015 // * use.  Please see the license in the file  LICENSE  and URL above *
00016 // * for the full disclaimer and the limitation of liability.         *
00017 // *                                                                  *
00018 // * This  code  implementation is the result of  the  scientific and *
00019 // * technical work of the GEANT4 collaboration.                      *
00020 // * By using,  copying,  modifying or  distributing the software (or *
00021 // * any work based  on the software)  you  agree  to acknowledge its *
00022 // * use  in  resulting  scientific  publications,  and indicate your *
00023 // * acceptance of all terms of the Geant4 Software license.          *
00024 // ********************************************************************
00025 //
00026 //
00027 // $Id$
00028 //
00029 // ----------------------
00030 // Class description:
00031 //
00032 // This class tranforms G3 divided volumes to G4 replicated volumes. 
00033 // UpdateVTE() method checks parameters of mother volume
00034 // and in case they are complete the solid that will be replicated 
00035 // is created. In case of division with offset an additinal envelope 
00036 // VTE (G3VolTableEntry instance) is created.
00037 // CreatePVReplica() methods creates the G4PVReplica instance.
00038 
00039 // ----------------------
00040 //
00041 // by I.Hrivnacova, V.Berejnoi, 27 Sep 99
00042 
00043 #ifndef G3DIVISION_HH
00044 #define G3DIVISION_HH 1
00045 
00046 #include "globals.hh"
00047 #include "geomdefs.hh"
00048 
00049 class G3VolTableEntry;
00050 class G4VPhysicalVolume;
00051 class G4LogicalVolume;
00052 
00053 enum G3DivType { kDvn, kDvn2, kDvt, kDvt2 };
00054 
00055 class G3Division 
00056 {
00057   public: // with description
00058 
00059     G3Division(G3DivType type, G3VolTableEntry* vte, G3VolTableEntry* mvte, 
00060                G4int nofDivision, G4int iaxis, G4int nmed, G4double c0, 
00061                G4double step);
00062     G3Division(G3VolTableEntry* vte, G3VolTableEntry* mvte,
00063                const G3Division& division);
00064     virtual ~G3Division();
00065     
00066     // methods
00067     void UpdateVTE();
00068     void CreatePVReplica();   
00069     
00070   private:
00071 
00072     // methods
00073     void SetRangeAndAxis();
00074     void CreateSolid(G4String shape, G4double par[], G4int npar);
00075     G3VolTableEntry* CreateEnvelope(G4String shape, G4double hi, G4double lo, 
00076                        G4double par[], G4int npar);
00077     G3VolTableEntry* Dvn ();
00078     G3VolTableEntry* Dvn2();
00079     G3VolTableEntry* Dvt ();
00080     G3VolTableEntry* Dvt2();
00081     void Exception(G4String where, G4String what);
00082     
00083     // data members 
00084     G3DivType         fType;
00085     G3VolTableEntry*  fVTE;    
00086     G3VolTableEntry*  fMVTE;    
00087     G4int             fNofDivisions;  // ndiv/ndvmx    
00088     G4int             fIAxis;
00089     G4int             fNmed;
00090     G4double          fC0;
00091     G4double          fStep;
00092     G4double          fLowRange;  
00093     G4double          fHighRange;
00094     G4double          fWidth;
00095     G4double          fOffset;
00096     EAxis             fAxis;
00097 };
00098 
00099 #endif //G3_DIVISION_H

Generated on Mon May 27 17:47:35 2013 for Geant4 by  doxygen 1.4.7