Geant4  9.6.p02
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
G4LETritonInelastic.cc
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 // Hadronic Process: Triton Inelastic Process
27 // J.L. Chuma, TRIUMF, 25-Feb-1997
28 // J.L. Chuma, 08-May-2001: Update original incident passed back in vec[0]
29 // from NuclearReaction
30 
31 #include "G4LETritonInelastic.hh"
32 #include "G4SystemOfUnits.hh"
33 #include "Randomize.hh"
34 #include "G4Electron.hh"
35 
37 {
38  outFile << "G4LETritonInelastic is one of the Low Energy Parameterized\n"
39  << "(LEP) models used to implement inelastic triton scattering\n"
40  << "from nuclei. It is a re-engineered version of the GHEISHA\n"
41  << "code of H. Fesefeldt. It divides the initial collision\n"
42  << "products into backward- and forward-going clusters which are\n"
43  << "then decayed into final state hadrons. The model does not\n"
44  << "conserve energy on an event-by-event basis. It may be\n"
45  << "applied to tritons with initial energies between 0 and 25\n"
46  << "GeV.\n";
47 }
48 
49 
52  G4Nucleus& targetNucleus)
53 {
54  G4bool triton_debug = false;
55  if (getenv("TritonLEDebug")) triton_debug = true;
57  const G4HadProjectile *originalIncident = &aTrack;
58  if (triton_debug) G4cout << "entering LETritonInelastic "
59  << originalIncident->GetKineticEnergy() << G4endl;
60  if (originalIncident->GetKineticEnergy() <= 0.1*MeV) {
64  return &theParticleChange;
65  }
66 
67  if (verboseLevel > 1) {
68  const G4Material *targetMaterial = aTrack.GetMaterial();
69  G4cout << "G4LETritonInelastic::ApplyYourself called" << G4endl;
70  G4cout << "kinetic energy = " << originalIncident->GetKineticEnergy()/MeV << "MeV, ";
71  G4cout << "target material = " << targetMaterial->GetName() << ", ";
72  }
73 
74  if (triton_debug) G4cout << "running LETritonInelastic 1" << G4endl;
75 
76  // Work-around for lack of model above 100 MeV
77  if (originalIncident->GetKineticEnergy()/MeV > 100. ||
78  originalIncident->GetKineticEnergy() <= 0.) {
82  return &theParticleChange;
83  }
84 
85  if (triton_debug) G4cout << "running LETritonInelastic 2" << G4endl;
86 
87  G4double A = targetNucleus.GetA_asInt();
88  G4double Z = targetNucleus.GetZ_asInt();
89  G4double theAtomicMass = targetNucleus.AtomicMass(A, Z);
90  G4double massVec[9];
91  massVec[0] = targetNucleus.AtomicMass( A+3.0, Z+1.0 );
92  massVec[1] = targetNucleus.AtomicMass( A+2.0, Z+1.0 );
93  massVec[2] = targetNucleus.AtomicMass( A+2.0, Z );
94  massVec[3] = targetNucleus.AtomicMass( A+1.0, Z );
95  massVec[4] = theAtomicMass;
96  massVec[5] = massVec[3]; //0.;
97  if (A > 1.0 && Z > 1.0) massVec[5] = targetNucleus.AtomicMass(A-1.0, Z-1.0);
98  massVec[6] = targetNucleus.AtomicMass(A+1.0, Z+1.0);
99  massVec[7] = massVec[3];
100  massVec[8] = massVec[2]; //0.;
101  if (Z > 1.0) massVec[8] = targetNucleus.AtomicMass(A+1.0, Z-1.0);
102 
103  G4FastVector<G4ReactionProduct,4> vec; // vec will contain the secondary particles
104  G4int vecLen = 0;
105  vec.Initialize(0);
106 
107  if (triton_debug) G4cout << "running LETritonInelastic 3" << G4endl;
108  theReactionDynamics.NuclearReaction(vec, vecLen, originalIncident,
109  targetNucleus, theAtomicMass, massVec);
110  if (triton_debug) G4cout << "running LETritonInelastic 4" << G4endl;
111 
112  G4double p = vec[0]->GetMomentum().mag();
113  theParticleChange.SetMomentumChange( vec[0]->GetMomentum()*(1./p) );
114  theParticleChange.SetEnergyChange( vec[0]->GetKineticEnergy() );
115  delete vec[0];
116 
117  if (vecLen <= 1) {
121  if (isotopeProduction) DoIsotopeCounting(originalIncident, targetNucleus);
122  return &theParticleChange;
123  }
124 
125  G4DynamicParticle *pd;
126  for (G4int i = 1; i < vecLen; ++i) {
127  pd = new G4DynamicParticle();
128  pd->SetDefinition( vec[i]->GetDefinition() );
129  pd->SetMomentum( vec[i]->GetMomentum() );
131  delete vec[i];
132  }
133 
134  if (isotopeProduction) DoIsotopeCounting(originalIncident, targetNucleus);
135 
136  if (triton_debug) G4cout << "leaving LETritonInelastic" << G4endl;
137  return &theParticleChange;
138 }
139 
140  /* end of file */
141