Geant4 9.6.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
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
32#include "G4SystemOfUnits.hh"
33#include "Randomize.hh"
34#include "G4Electron.hh"
35
36void G4LETritonInelastic::ModelDescription(std::ostream& outFile) const
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
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
@ isAlive
double G4double
Definition: G4Types.hh:64
int G4int
Definition: G4Types.hh:66
bool G4bool
Definition: G4Types.hh:67
#define G4endl
Definition: G4ios.hh:52
G4DLLIMPORT std::ostream G4cout
Hep3Vector unit() const
Hep3Vector vect() const
void SetDefinition(const G4ParticleDefinition *aParticleDefinition)
void SetMomentum(const G4ThreeVector &momentum)
void Initialize(G4int items)
Definition: G4FastVector.hh:63
void SetStatusChange(G4HadFinalStateStatus aS)
void AddSecondary(G4DynamicParticle *aP)
void SetEnergyChange(G4double anEnergy)
void SetMomentumChange(const G4ThreeVector &aV)
const G4Material * GetMaterial() const
G4double GetKineticEnergy() const
const G4LorentzVector & Get4Momentum() const
G4ReactionDynamics theReactionDynamics
void DoIsotopeCounting(const G4HadProjectile *theProjectile, const G4Nucleus &aNucleus)
virtual void ModelDescription(std::ostream &outFile) const
G4HadFinalState * ApplyYourself(const G4HadProjectile &aTrack, G4Nucleus &targetNucleus)
const G4String & GetName() const
Definition: G4Material.hh:177
G4int GetA_asInt() const
Definition: G4Nucleus.hh:109
G4int GetZ_asInt() const
Definition: G4Nucleus.hh:115
G4double AtomicMass(const G4double A, const G4double Z) const
Definition: G4Nucleus.cc:240
void NuclearReaction(G4FastVector< G4ReactionProduct, 4 > &vec, G4int &vecLen, const G4HadProjectile *originalIncident, const G4Nucleus &aNucleus, const G4double theAtomicMass, const G4double *massVec)