00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031
00032
00033
00034
00035
00036
00037
00038
00039
00040
00041
00042
00043
00044 #include <numeric>
00045
00046 #include "G4InuclEvaporation.hh"
00047 #include "globals.hh"
00048 #include "G4SystemOfUnits.hh"
00049 #include "G4IonTable.hh"
00050 #include "G4V3DNucleus.hh"
00051 #include "G4DynamicParticleVector.hh"
00052 #include "G4EvaporationInuclCollider.hh"
00053 #include "G4InuclNuclei.hh"
00054 #include "G4Track.hh"
00055 #include "G4Nucleus.hh"
00056 #include "G4Nucleon.hh"
00057 #include "G4NucleiModel.hh"
00058 #include "G4HadronicException.hh"
00059 #include "G4LorentzVector.hh"
00060 #include "G4EquilibriumEvaporator.hh"
00061 #include "G4InuclElementaryParticle.hh"
00062 #include "G4InuclParticle.hh"
00063 #include "G4CollisionOutput.hh"
00064 #include "G4InuclParticleNames.hh"
00065
00066 using namespace G4InuclParticleNames;
00067
00068 typedef std::vector<G4InuclElementaryParticle>::const_iterator particleIterator;
00069 typedef std::vector<G4InuclNuclei>::const_iterator nucleiIterator;
00070
00071
00072 G4InuclEvaporation::G4InuclEvaporation()
00073 : verboseLevel(0), evaporator(new G4EvaporationInuclCollider) {}
00074
00075 G4InuclEvaporation::G4InuclEvaporation(const G4InuclEvaporation &) : G4VEvaporation() {
00076 throw G4HadronicException(__FILE__, __LINE__, "G4InuclEvaporation::copy_constructor meant to not be accessable.");
00077 }
00078
00079 G4InuclEvaporation::~G4InuclEvaporation() {
00080 delete evaporator;
00081 }
00082
00083 const G4InuclEvaporation & G4InuclEvaporation::operator=(const G4InuclEvaporation &) {
00084 throw G4HadronicException(__FILE__, __LINE__, "G4InuclEvaporation::operator= meant to not be accessable.");
00085 }
00086
00087
00088 G4bool G4InuclEvaporation::operator==(const G4InuclEvaporation &) const {
00089 return false;
00090 }
00091
00092 G4bool G4InuclEvaporation::operator!=(const G4InuclEvaporation &) const {
00093 return true;
00094 }
00095
00096 void G4InuclEvaporation::setVerboseLevel( const G4int verbose ) {
00097 verboseLevel = verbose;
00098 }
00099
00100 G4FragmentVector* G4InuclEvaporation::BreakItUp(const G4Fragment &theNucleus) {
00101 G4FragmentVector* theResult = new G4FragmentVector;
00102
00103 if (theNucleus.GetExcitationEnergy() <= 0.0) {
00104 theResult->push_back(new G4Fragment(theNucleus));
00105 return theResult;
00106 }
00107
00108 G4int A = theNucleus.GetA_asInt();
00109 G4int Z = theNucleus.GetZ_asInt();
00110 G4double mTar = G4NucleiProperties::GetNuclearMass(A, Z);
00111
00112 G4ThreeVector momentum = theNucleus.GetMomentum().vect();
00113 G4double exitationE = theNucleus.GetExcitationEnergy();
00114
00115 G4double mass = mTar;
00116 G4ThreeVector boostToLab( momentum/mass );
00117
00118 if ( verboseLevel > 2 )
00119 G4cout << " G4InuclEvaporation : initial kinematics : boostToLab vector = " << boostToLab << G4endl
00120 << " excitation energy : " << exitationE << G4endl;
00121
00122 if (verboseLevel > 2) {
00123 G4cout << "G4InuclEvaporation::BreakItUp >>> A: " << A << " Z: " << Z
00124 << " exitation E: " << exitationE << " mass: " << mTar/GeV << " GeV"
00125 << G4endl;
00126 };
00127
00128 G4InuclNuclei* nucleus = new G4InuclNuclei(A, Z);
00129 nucleus->setExitationEnergy(exitationE);
00130
00131 G4CollisionOutput output;
00132 evaporator->collide(0, nucleus, output);
00133
00134 const std::vector<G4InuclNuclei>& outgoingNuclei = output.getOutgoingNuclei();
00135 const std::vector<G4InuclElementaryParticle>& particles = output.getOutgoingParticles();
00136
00137 G4double eTot=0.0;
00138 G4int i=1;
00139
00140 if (!particles.empty()) {
00141 G4int outgoingType;
00142 particleIterator ipart = particles.begin();
00143 for (; ipart != particles.end(); ipart++) {
00144 outgoingType = ipart->type();
00145
00146 if (verboseLevel > 2) {
00147 G4cout << "Evaporated particle: " << i << " of type: "
00148 << outgoingType << G4endl;
00149 i++;
00150 }
00151
00152 eTot += ipart->getEnergy();
00153
00154 G4LorentzVector vlab = ipart->getMomentum().boost(boostToLab);
00155
00156 theResult->push_back( new G4Fragment(vlab, ipart->getDefinition()) );
00157 }
00158 }
00159
00160
00161 if (!outgoingNuclei.empty()) {
00162 nucleiIterator ifrag = outgoingNuclei.begin();
00163 for (i=1; ifrag != outgoingNuclei.end(); ifrag++) {
00164 if (verboseLevel > 2) {
00165 G4cout << " Nuclei fragment: " << i << G4endl; i++;
00166 }
00167
00168 eTot += ifrag->getEnergy();
00169
00170 G4LorentzVector vlab = ifrag->getMomentum().boost(boostToLab);
00171
00172 G4int fragA = ifrag->getA();
00173 G4int fragZ = ifrag->getZ();
00174 if (verboseLevel > 2) {
00175 G4cout << "boosted v" << vlab << G4endl;
00176 }
00177 theResult->push_back( new G4Fragment(fragA, fragZ, vlab) );
00178 }
00179 }
00180
00181
00182 return theResult;
00183 }