G4NeutronHPFinalState.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 // 080721 Create adjust_final_state method by T. Koi  
00030 // 080801 Introduce theNDLDataA,Z which has A and Z of NDL data by T. Koi
00031 //
00032 #ifndef G4NeutronHPFinalState_h
00033 #define G4NeutronHPFinalState_h
00034 
00035 #include "G4Material.hh"
00036 #include "G4FastVector.hh"
00037 #include "G4HadFinalState.hh"
00038 #include "G4NeutronHPNames.hh"
00039 #include "G4NeutronHPVector.hh"
00040 #include "G4HadProjectile.hh"
00041 
00042 class G4NeutronHPFinalState
00043 {
00044 public:
00045 
00046   G4NeutronHPFinalState()
00047   { 
00048     hasFSData = true; 
00049     hasXsec = true;
00050     hasAnyData = true;
00051     theBaseZ = 0;
00052     theBaseA = 0;
00053     theBaseM = 0;
00054 
00055     theNDLDataZ = 0;
00056     theNDLDataA = 0;
00057 
00058      adjustResult = true;
00059      if ( getenv( "G4NEUTRONHP_DO_NOT_ADJUST_FINAL_STATE" ) ) adjustResult = false;
00060 
00061   };
00062   
00063   virtual ~G4NeutronHPFinalState(){};
00064 
00065   //virtual void Init (G4double A, G4double Z, G4String & dirName, G4String & aFSType) = 0;
00066   void Init (G4double A, G4double Z, G4String & dirName, G4String & aFSType) { G4int M = 0; Init ( A, Z, M, dirName, aFSType); };
00067   virtual void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType) =0;
00068   virtual G4HadFinalState * ApplyYourself(const G4HadProjectile & ) 
00069   {
00070     throw G4HadronicException(__FILE__, __LINE__, "G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack) needs implementation");
00071     return 0;
00072   };
00073   
00074   // of course this would better be Done templating G4NeutronHPChannel..., 
00075   // but due to peculiarities of the DEC compiler, this way it
00076   // is easier to maintain.
00077   virtual G4NeutronHPFinalState * New() = 0;
00078   
00079   G4bool HasXsec() {return hasXsec;};
00080   G4bool HasFSData() {return hasFSData;};
00081   G4bool HasAnyData() {return hasAnyData;};
00082   
00083   virtual G4double GetXsec(G4double ) { return 0; };
00084   virtual G4NeutronHPVector * GetXsec() { return 0; };
00085   
00086   void     SetA_Z(G4double anA, G4double aZ, G4int aM=0) {theBaseA = anA; theBaseZ = aZ; theBaseM=aM; };
00087   G4double GetZ() { return theBaseZ; };
00088   G4double GetN() { return theBaseA; };
00089   G4int GetM() { return theBaseM; };
00090   
00091   protected:
00092      void SetAZMs(G4double anA, G4double aZ, G4int aM, G4NeutronHPDataUsed used) 
00093      { theBaseA = anA; theBaseZ = aZ; theBaseM=aM; 
00094        theNDLDataA=(G4int)used.GetA(); theNDLDataZ=(G4int)used.GetZ(); theNDLDataM=used.GetM(); };
00095   
00096   G4bool hasXsec;
00097   G4bool hasFSData;
00098   G4bool hasAnyData;
00099   G4NeutronHPNames theNames;
00100   
00101   G4HadFinalState theResult;
00102   
00103   G4double theBaseA;
00104   G4double theBaseZ;
00105   G4int theBaseM;
00106 
00107 
00108 //080721
00109    protected:
00110       void adjust_final_state ( G4LorentzVector );
00111       G4int theNDLDataZ;
00112       G4int theNDLDataA;
00113       G4int theNDLDataM;
00114 
00115    private:
00116       G4bool adjustResult;
00117 
00118 
00119 };
00120 #endif

Generated on Mon May 27 17:49:01 2013 for Geant4 by  doxygen 1.4.7