Geant4.10
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
G4NeutronHPFinalState.hh
Go to the documentation of this file.
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 //
27 //
28 // 080721 Create adjust_final_state method by T. Koi
29 // 080801 Introduce theNDLDataA,Z which has A and Z of NDL data by T. Koi
30 //
31 #ifndef G4NeutronHPFinalState_h
32 #define G4NeutronHPFinalState_h
33 
34 #include "G4Material.hh"
35 #include "G4FastVector.hh"
36 #include "G4HadFinalState.hh"
37 #include "G4NeutronHPNames.hh"
38 #include "G4NeutronHPVector.hh"
39 #include "G4HadProjectile.hh"
40 
42 {
43 public:
44 
46  {
47  hasFSData = true;
48  hasXsec = true;
49  hasAnyData = true;
50  theBaseZ = 0;
51  theBaseA = 0;
52  theBaseM = 0;
53 
54  theNDLDataZ = 0;
55  theNDLDataA = 0;
56 
57  adjustResult = true;
58  if ( getenv( "G4NEUTRONHP_DO_NOT_ADJUST_FINAL_STATE" ) ) adjustResult = false;
59 
60  };
61 
63 
64  //virtual void Init (G4double A, G4double Z, G4String & dirName, G4String & aFSType) = 0;
65  void Init (G4double A, G4double Z, G4String & dirName, G4String & aFSType) { G4int M = 0; Init ( A, Z, M, dirName, aFSType); };
66  virtual void Init (G4double A, G4double Z, G4int M, G4String & dirName, G4String & aFSType) =0;
68  {
69  throw G4HadronicException(__FILE__, __LINE__, "G4HadFinalState * ApplyYourself(const G4HadProjectile & theTrack) needs implementation");
70  return 0;
71  };
72 
73  // of course this would better be Done templating G4NeutronHPChannel...,
74  // but due to peculiarities of the DEC compiler, this way it
75  // is easier to maintain.
76  virtual G4NeutronHPFinalState * New() = 0;
77 
78  G4bool HasXsec() {return hasXsec;};
79  G4bool HasFSData() {return hasFSData;};
81 
82  virtual G4double GetXsec(G4double ) { return 0; };
83  virtual G4NeutronHPVector * GetXsec() { return 0; };
84 
85  void SetA_Z(G4double anA, G4double aZ, G4int aM=0) {theBaseA = anA; theBaseZ = aZ; theBaseM=aM; };
86  G4double GetZ() { return theBaseZ; };
87  G4double GetN() { return theBaseA; };
88  G4int GetM() { return theBaseM; };
89 
90  protected:
92  { theBaseA = anA; theBaseZ = aZ; theBaseM=aM;
93  theNDLDataA=(G4int)used.GetA(); theNDLDataZ=(G4int)used.GetZ(); theNDLDataM=used.GetM(); };
94 
99 
101 
105 
106 
107 //080721
108  protected:
110  G4bool DoNotAdjustFinalState(){ return adjustResult; };
114 
115  private:
116  G4bool adjustResult;
117 
118 
119 };
120 #endif
virtual G4NeutronHPFinalState * New()=0
virtual G4NeutronHPVector * GetXsec()
int G4int
Definition: G4Types.hh:78
bool G4bool
Definition: G4Types.hh:79
void SetA_Z(G4double anA, G4double aZ, G4int aM=0)
virtual G4HadFinalState * ApplyYourself(const G4HadProjectile &)
void Init(G4double A, G4double Z, G4String &dirName, G4String &aFSType)
void SetAZMs(G4double anA, G4double aZ, G4int aM, G4NeutronHPDataUsed used)
double G4double
Definition: G4Types.hh:76
void adjust_final_state(G4LorentzVector)
virtual G4double GetXsec(G4double)