Geant4  10.03.p01
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
G4StatMFMicroCanonical.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 // $Id: G4StatMFMicroCanonical.hh 67983 2013-03-13 10:42:03Z gcosmo $
28 //
29 // Hadronic Process: Nuclear De-excitations
30 // by V. Lara
31 
32 #ifndef G4StatMFMicroCanonical_h
33 #define G4StatMFMicroCanonical_h 1
34 
35 #include <vector>
36 
37 #include "G4VStatMFEnsemble.hh"
39 #include "G4StatMFMicroManager.hh"
40 #include "G4StatMFParameters.hh"
41 #include "G4StatMFChannel.hh"
42 
43 #include "G4Fragment.hh"
44 #include "Randomize.hh"
45 
46 
48 
49 public:
50 
51  // G4StatMFMicroCanonical class must be initialized with a G4Fragment.
52  G4StatMFMicroCanonical(const G4Fragment & theFragment);
53 
54  // destructor
56 
57 private:
58  // default constructor
60 
61 
62  // copy constructor
64 
65 
66  // operators
67  G4StatMFMicroCanonical & operator=(const G4StatMFMicroCanonical & right);
68  G4bool operator==(const G4StatMFMicroCanonical & right) const;
69  G4bool operator!=(const G4StatMFMicroCanonical & right) const;
70 
71 
72 public:
73 
74  // Choice of fragment atomic numbers and charges.
75  G4StatMFChannel * ChooseAandZ(const G4Fragment & theFragment);
76 
78 
79 private:
80 
81  // Initailization method
82  void Initialize(const G4Fragment & theFragment);
83 
84  // Calculate Entropy of Compound Nucleus
85  G4double CalcEntropyOfCompoundNucleus(const G4Fragment & theFragment, G4double & TConf);
86 
87  G4double CalcFreeInternalEnergy(const G4Fragment & theFragment, G4double T);
88 
89  G4double CalcInvLevelDensity(G4int anA);
90 
91 
92 // Data members
93 private:
94 
95  // This is a vector of partitions managers for partitions of different
96  // multiplicities:
97 
98  std::vector<G4StatMFMicroManager*> _ThePartitionManagerVector;
99 
100  // Statistical weight of compound nucleus
101  G4double _WCompoundNucleus;
102 
103 
104  struct DeleteFragment
105  {
106  template<typename T>
107  void operator()(const T* ptr) const
108  {
109  delete ptr;
110  }
111  };
112 
113  class SumProbabilities : public std::binary_function<G4double,G4double,G4double>
114  {
115  public:
116  SumProbabilities() : total(0.0) {}
117  G4double operator() (G4double& /* probSoFar*/, G4StatMFMicroManager*& manager)
118  {
119  total += manager->GetProbability();
120  return total;
121  }
122 
123  G4double GetTotal() { return total; }
124  public:
125  G4double total;
126 
127  };
128 
129 
130 };
131 
132 #endif
G4StatMFChannel * ChooseAandZ(const G4Fragment &theFragment)
int G4int
Definition: G4Types.hh:78
bool G4bool
Definition: G4Types.hh:79
G4double GetProbability(void) const
G4double total(Particle const *const p1, Particle const *const p2)
double G4double
Definition: G4Types.hh:76