Geant4 11.2.2
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4IonPhysics.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//
27//---------------------------------------------------------------------------
28//
29// Class: G4IonPhysics
30//
31// Author: A.Ivanchenko 02.03.2011
32//
33// Modified:
34// 16.10.2012 A.Ribon: renamed G4IonFTFPBinaryCascadePhysics as G4IonPhysics
35//
36//---------------------------------------------------------------------------
37
38#include "G4IonPhysics.hh"
39#include "G4SystemOfUnits.hh"
41#include "G4ProcessManager.hh"
42#include "G4Deuteron.hh"
43#include "G4Triton.hh"
44#include "G4He3.hh"
45#include "G4Alpha.hh"
46#include "G4GenericIon.hh"
47#include "G4IonConstructor.hh"
48
53
54#include "G4PreCompoundModel.hh"
56#include "G4FTFBuilder.hh"
58#include "G4BuilderType.hh"
60
62
63using namespace std;
64
65// factory
67//
69
70//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
71
73 : G4IonPhysics("ionInelasticFTFP_BIC", ver)
74{}
75
76//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
77
79 : G4VPhysicsConstructor(nname),verbose(ver)
80{
82 if(verbose > 1) { G4cout << "### IonPhysics: " << nname << G4endl; }
83}
84
85//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
86
89
90//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
91
93{
94 // Construct ions
95 G4IonConstructor pConstructor;
96 pConstructor.ConstructParticle();
97}
98
99//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
100
102{
104
107 G4PreCompoundModel* thePreCompound = static_cast<G4PreCompoundModel*>(p);
108 if(!thePreCompound) { thePreCompound = new G4PreCompoundModel; }
109
110 // Binary Cascade
111 G4HadronicInteraction* theIonBC =
112 new G4BinaryLightIonReaction(thePreCompound);
113 theIonBC->SetMinEnergy( 0.0 );
114 theIonBC->SetMaxEnergy( G4HadronicParameters::Instance()->GetMaxEnergyTransitionFTF_Cascade() );
115
116 // FTFP
117 G4HadronicInteraction* theFTFP = nullptr;
118 if(emax > theIonBC->GetMaxEnergy()) {
119 G4FTFBuilder theBuilder("FTFP",thePreCompound);
120 theFTFP = theBuilder.GetModel();
121 theFTFP->SetMinEnergy( G4HadronicParameters::Instance()->GetMinEnergyTransitionFTF_Cascade() );
122 theFTFP->SetMaxEnergy( emax );
123 }
124
125 G4CrossSectionInelastic* theNuclNuclData =
127
128 AddProcess("dInelastic", G4Deuteron::Deuteron(),theIonBC,theFTFP,
129 theNuclNuclData);
130 AddProcess("tInelastic",G4Triton::Triton(),theIonBC,theFTFP,
131 theNuclNuclData);
132 AddProcess("He3Inelastic",G4He3::He3(),theIonBC,theFTFP,
133 theNuclNuclData);
134 AddProcess("alphaInelastic", G4Alpha::Alpha(),theIonBC,theFTFP,
135 theNuclNuclData);
136 AddProcess("ionInelastic",G4GenericIon::GenericIon(),theIonBC,theFTFP,
137 theNuclNuclData);
138
139 if(verbose > 1) {
140 G4cout << "G4IonPhysics::ConstructProcess done! "
141 << G4endl;
142 }
143}
144
145//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
146
147void G4IonPhysics::AddProcess(const G4String& name,
149 G4HadronicInteraction* theIonBC,
150 G4HadronicInteraction* theFTFP,
152{
154 G4ProcessManager* pManager = part->GetProcessManager();
155 pManager->AddDiscreteProcess(hadi);
156
157 hadi->AddDataSet(xs);
158
159 hadi->RegisterMe(theIonBC);
160 if(theFTFP) { hadi->RegisterMe(theFTFP); }
161}
162
163//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@ bIons
#define G4_DECLARE_PHYSCONSTR_FACTORY(physics_constructor)
double G4double
Definition G4Types.hh:83
int G4int
Definition G4Types.hh:85
#define G4endl
Definition G4ios.hh:67
G4GLOB_DLL std::ostream G4cout
static G4Alpha * Alpha()
Definition G4Alpha.cc:83
static G4Deuteron * Deuteron()
Definition G4Deuteron.cc:90
static G4GenericIon * GenericIon()
G4HadronicInteraction * FindModel(const G4String &name)
static G4HadronicInteractionRegistry * Instance()
void SetMinEnergy(G4double anEnergy)
void SetMaxEnergy(const G4double anEnergy)
static G4HadronicParameters * Instance()
void AddDataSet(G4VCrossSectionDataSet *aDataSet)
void RegisterMe(G4HadronicInteraction *a)
static G4He3 * He3()
Definition G4He3.cc:90
static void ConstructParticle()
~G4IonPhysics() override
void ConstructProcess() override
void ConstructParticle() override
G4IonPhysics(G4int ver=0)
G4ProcessManager * GetProcessManager() const
G4int AddDiscreteProcess(G4VProcess *aProcess, G4int ord=ordDefault)
static G4Triton * Triton()
Definition G4Triton.cc:90
G4HadronicInteraction * GetModel()