Geant4 9.6.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4IonBinaryCascadePhysics.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// $Id$
27//
28//---------------------------------------------------------------------------
29//
30// ClassName: G4IonBinaryCascadePhysics
31//
32// Author: V.Ivanchenko 09.11.2005
33//
34// Modified:
35// 23.06.06 V.Ivanchenko set emaxLHEP=1 TeV
36// 24.06.06 V.Ivanchenko fix typo
37//
38//----------------------------------------------------------------------------
39//
40
42
43#include "G4SystemOfUnits.hh"
48
54
56#include "G4ParticleTable.hh"
57#include "G4ProcessManager.hh"
58
59// Nuclei
60#include "G4IonConstructor.hh"
61#include "G4BuilderType.hh"
62
63// factory
65//
67
68
70 : G4VPhysicsConstructor("IonBinaryCascade"), verbose(ver), wasActivated(false)
71{
72 fLEDModel = 0;
73 fLETModel = 0;
74 fLEAModel = 0;
75 fTripathi = 0;
76 fTripathiLight = 0;
77 fShen = 0;
78 fIonH = 0;
79 emax = 20.*GeV;
80 emaxLHEP = 1.*TeV;
81 eminBIC = 0.*MeV;
83 if(verbose > 1) G4cout << "### G4IonBinaryCascadePhysics" << G4endl;
84}
85
87 G4int ver)
88 : G4VPhysicsConstructor(name), verbose(ver), wasActivated(false)
89{
90 fLEDModel = 0;
91 fLETModel = 0;
92 fLEAModel = 0;
93 fTripathi = 0;
94 fTripathiLight = 0;
95 fShen = 0;
96 fIonH = 0;
97 emax = 20.*GeV;
98 emaxLHEP = 1.*TeV;
99 eminBIC = 0.*MeV;
101 if(verbose > 1) G4cout << "### G4IonBinaryCascadePhysics" << G4endl;
102}
103
105{
106 if(wasActivated) {
107 delete fTripathi;
108 delete fTripathiLight;
109 delete fShen;
110 delete fIonH;
111 delete fLEDModel;
112 delete fLETModel;
113 delete fLEAModel;
114 G4int i;
115 G4int n = p_list.size();
116 for(i=0; i<n; i++) {delete p_list[i];}
117 n = model_list.size();
118 for(i=0; i<n; i++) {delete model_list[i];}
119 }
120}
121
123{
124 if(wasActivated) { return; }
125 wasActivated = true;
126
128 model_list.push_back(fBC);
129 fShen = new G4IonsShenCrossSection;
130 //fTripathi = new G4TripathiCrossSection;
131 //fTripathiLight = new G4TripathiLightCrossSection;
132 fIonH = new G4IonProtonCrossSection;
133
134 fLEDModel = new G4LEDeuteronInelastic();
135 fLETModel = new G4LETritonInelastic();
136 fLEAModel = new G4LEAlphaInelastic();
137
138 AddProcess("dInelastic", G4Deuteron::Deuteron(), fBC, fLEDModel);
139 AddProcess("tInelastic",G4Triton::Triton(), fBC, fLETModel);
140 AddProcess("He3Inelastic",G4He3::He3(), fBC, 0);
141 AddProcess("alphaInelastic", G4Alpha::Alpha(), fBC, fLEAModel);
142 AddProcess("ionInelastic",G4GenericIon::GenericIon(), fBC, 0);
143
144}
145
146void G4IonBinaryCascadePhysics::AddProcess(const G4String& name,
148 G4HadronicInteraction* hmodel,
149 G4HadronicInteraction* lmodel)
150{
152 p_list.push_back(hadi);
153 G4ProcessManager* pManager = p->GetProcessManager();
154 pManager->AddDiscreteProcess(hadi);
155 hadi->AddDataSet(fShen);
156 //hadi->AddDataSet(fTripathi);
157 //hadi->AddDataSet(fTripathiLight);
158 if(p == G4GenericIon::GenericIon()) { hadi->AddDataSet(fIonH); }
159 hmodel->SetMinEnergy(eminBIC);
160 hmodel->SetMaxEnergy(emax);
161 hadi->RegisterMe(hmodel);
162 if(lmodel) {
163 lmodel->SetMinEnergy(emax - MeV);
164 lmodel->SetMaxEnergy(emaxLHEP);
165 hadi->RegisterMe(lmodel);
166 }
167 if(verbose > 1) {
168 G4cout << "Register " << hadi->GetProcessName()
169 << " for " << p->GetParticleName()
170 << " Binary Cascade for E(MeV)= " << eminBIC << " - " << emax;
171 if(lmodel) {
172 G4cout << " LHEP for E(MeV)= " << emax-MeV << " - " << emaxLHEP;
173 }
174 G4cout << G4endl;
175 }
176}
177
179{
180 // Construct light ions
181 G4IonConstructor pConstructor;
182 pConstructor.ConstructParticle();
183}
@ bIons
#define G4_DECLARE_PHYSCONSTR_FACTORY(physics_constructor)
int G4int
Definition: G4Types.hh:66
#define G4endl
Definition: G4ios.hh:52
G4DLLIMPORT std::ostream G4cout
static G4Alpha * Alpha()
Definition: G4Alpha.cc:89
static G4Deuteron * Deuteron()
Definition: G4Deuteron.cc:94
static G4GenericIon * GenericIon()
Definition: G4GenericIon.cc:92
void SetMinEnergy(G4double anEnergy)
void SetMaxEnergy(const G4double anEnergy)
void AddDataSet(G4VCrossSectionDataSet *aDataSet)
void RegisterMe(G4HadronicInteraction *a)
static G4He3 * He3()
Definition: G4He3.cc:94
static void ConstructParticle()
G4ProcessManager * GetProcessManager() const
const G4String & GetParticleName() const
G4int AddDiscreteProcess(G4VProcess *aProcess, G4int ord=ordDefault)
static G4Triton * Triton()
Definition: G4Triton.cc:95
const G4String & GetProcessName() const
Definition: G4VProcess.hh:379