Geant4 11.2.2
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4ParticleHPFinalState.hh
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// 080721 Create adjust_final_state method by T. Koi
28// 080801 Introduce theNDLDataA,Z which has A and Z of NDL data by T. Koi
29//
30// P. Arce, June-2014 Conversion neutron_hp to particle_hp
31// V. Ivanchenko, July-2023 Basic revision of particle HP classes
32//
33
34#ifndef G4ParticleHPFinalState_h
35#define G4ParticleHPFinalState_h
36
37#include "G4Cache.hh"
38#include "G4HadFinalState.hh"
39#include "G4HadProjectile.hh"
40#include "G4Material.hh"
41#include "G4Neutron.hh"
42#include "G4IonTable.hh"
44#include "G4ParticleHPNames.hh"
45#include "G4ParticleHPVector.hh"
46
48
50{
51 public:
54
55 void Init(G4double A, G4double Z, G4String& dirName, G4String& aFSType,
57 {
58 theProjectile = p;
59 Init(A, Z, 0, dirName, aFSType, p);
60 }
61 virtual void Init(G4double A, G4double Z, G4int M, G4String& dirName, G4String& aFSType,
63
65 {
67 __FILE__, __LINE__,
68 "G4ParticleHPFinalState::ApplyYourself(..) needs implementation");
69 return nullptr;
70 }
71
72 // this would better be done templating G4ParticleHPChannel...,
73 //
75
76 G4bool HasXsec() { return hasXsec; }
79
80 virtual G4double GetXsec(G4double) { return 0; }
81 virtual G4ParticleHPVector* GetXsec() { return nullptr; }
82
83 void SetA_Z(G4double anA, G4double aZ, G4int aM = 0)
84 {
85 theBaseA = G4lrint(anA);
86 theBaseZ = G4lrint(aZ);
87 theBaseM = aM;
88 }
89 G4double GetZ() { return theBaseZ; }
90 G4double GetN() { return theBaseA; }
91 G4double GetA() { return theBaseA; }
92 G4int GetM() { return theBaseM; }
93
95 {
96 theNDLDataA = G4lrint(used.GetA());
97 theNDLDataZ = G4lrint(used.GetZ());
98 theNDLDataM = used.GetM();
99 }
100
102 {
103 theBaseA = G4lrint(anA);
104 theBaseZ = G4lrint(aZ);
105 theBaseM = aM;
106 theNDLDataA = G4lrint(used.GetA());
107 theNDLDataZ = G4lrint(used.GetZ());
108 theNDLDataM = used.GetM();
109 }
110
111 void SetProjectile(G4ParticleDefinition* projectile) { theProjectile = projectile; }
112
114 (const G4ParticleHPFinalState& right) = delete;
116
117 protected:
119
123
130
132 // Creator model ID for the secondaries created by this class or derived ones
133
138
140
141};
142#endif
#define M(row, col)
double G4double
Definition G4Types.hh:83
bool G4bool
Definition G4Types.hh:86
int G4int
Definition G4Types.hh:85
const G4double A[17]
virtual G4double GetXsec(G4double)
G4ParticleHPFinalState(const G4ParticleHPFinalState &)=delete
virtual G4HadFinalState * ApplyYourself(const G4HadProjectile &)
virtual void Init(G4double A, G4double Z, G4int M, G4String &dirName, G4String &aFSType, G4ParticleDefinition *)=0
void SetA_Z(G4double anA, G4double aZ, G4int aM=0)
G4ParticleHPManager * fManager
void SetAZMs(G4double anA, G4double aZ, G4int aM, G4ParticleHPDataUsed used)
virtual G4ParticleHPFinalState * New()=0
G4ParticleDefinition * theProjectile
G4Cache< G4HadFinalState * > theResult
void SetAZMs(G4ParticleHPDataUsed used)
void SetProjectile(G4ParticleDefinition *projectile)
void adjust_final_state(G4LorentzVector)
virtual G4ParticleHPVector * GetXsec()
void Init(G4double A, G4double Z, G4String &dirName, G4String &aFSType, G4ParticleDefinition *p)
int G4lrint(double ad)
Definition templates.hh:134