Geant4-11
Public Member Functions | Private Attributes
G4HadFinalState Class Reference

#include <G4HadFinalState.hh>

Public Member Functions

void AddSecondaries (const G4HadFinalState &addHFS)
 
void AddSecondaries (const G4HadFinalState *addHFS)
 
void AddSecondaries (const std::vector< G4HadSecondary > &addSecs)
 
void AddSecondary (const G4HadSecondary &aHS)
 
void AddSecondary (G4DynamicParticle *aP, G4int mod=-1)
 
void Clear ()
 
void ClearSecondaries ()
 
 G4HadFinalState ()
 
G4double GetEnergyChange () const
 
G4double GetLocalEnergyDeposit () const
 
const G4ThreeVectorGetMomentumChange () const
 
std::size_t GetNumberOfSecondaries () const
 
G4HadSecondaryGetSecondary (size_t i)
 
const G4HadSecondaryGetSecondary (size_t i) const
 
G4HadFinalStateStatus GetStatusChange () const
 
const G4LorentzRotationGetTrafoToLab () const
 
G4double GetWeightChange () const
 
void SetEnergyChange (G4double anEnergy)
 
void SetLocalEnergyDeposit (G4double aE)
 
void SetMomentumChange (const G4ThreeVector &aV)
 
void SetMomentumChange (G4double x, G4double y, G4double z)
 
void SetStatusChange (G4HadFinalStateStatus aS)
 
void SetTrafoToLab (const G4LorentzRotation &aT)
 
void SetWeightChange (G4double aW)
 

Private Attributes

G4ThreeVector theDirection
 
G4double theEDep
 
G4double theEnergy
 
std::vector< G4HadSecondarytheSecs
 
G4HadFinalStateStatus theStat
 
G4LorentzRotation theT
 
G4double theW
 

Detailed Description

Definition at line 45 of file G4HadFinalState.hh.

Constructor & Destructor Documentation

◆ G4HadFinalState()

G4HadFinalState::G4HadFinalState ( )

Definition at line 35 of file G4HadFinalState.cc.

36 : theDirection(0,0,1), theEnergy(-1), theStat(isAlive),
37 theW(1.), theEDep(0.) {}
@ isAlive
G4HadFinalStateStatus theStat
G4ThreeVector theDirection

Member Function Documentation

◆ AddSecondaries() [1/3]

void G4HadFinalState::AddSecondaries ( const G4HadFinalState addHFS)
inline

Definition at line 92 of file G4HadFinalState.hh.

92 {
93 AddSecondaries(addHFS.theSecs);
94 }
void AddSecondaries(const std::vector< G4HadSecondary > &addSecs)
std::vector< G4HadSecondary > theSecs

References AddSecondaries(), and theSecs.

◆ AddSecondaries() [2/3]

void G4HadFinalState::AddSecondaries ( const G4HadFinalState addHFS)
inline

Definition at line 96 of file G4HadFinalState.hh.

96 {
97 if (addHFS) AddSecondaries(addHFS->theSecs);
98 }

References AddSecondaries(), and theSecs.

◆ AddSecondaries() [3/3]

void G4HadFinalState::AddSecondaries ( const std::vector< G4HadSecondary > &  addSecs)

◆ AddSecondary() [1/2]

void G4HadFinalState::AddSecondary ( const G4HadSecondary aHS)
inline

Definition at line 65 of file G4HadFinalState.hh.

65{ theSecs.push_back(aHS); }

References theSecs.

◆ AddSecondary() [2/2]

void G4HadFinalState::AddSecondary ( G4DynamicParticle aP,
G4int  mod = -1 
)
inline

Definition at line 61 of file G4HadFinalState.hh.

61 {
62 theSecs.push_back(G4HadSecondary(aP, theW, mod));
63 };

References theSecs, and theW.

Referenced by G4MuMinusCapturePrecompound::AddNewParticle(), G4MuonMinusBoundDecay::AddNewParticle(), G4EmCaptureCascade::AddNewParticle(), G4ParticleHPFinalState::adjust_final_state(), G4ParticleHPChannelList::ApplyYourself(), G4WilsonAbrasionModel::ApplyYourself(), G4EMDissociation::ApplyYourself(), G4LENDCapture::ApplyYourself(), G4LENDElastic::ApplyYourself(), G4LENDFission::ApplyYourself(), G4LENDInelastic::ApplyYourself(), G4LENDModel::ApplyYourself(), G4NeutrinoElectronNcModel::ApplyYourself(), G4NeutronElectronElModel::ApplyYourself(), G4LFission::ApplyYourself(), G4ANuElNucleusCcModel::ApplyYourself(), G4ANuElNucleusNcModel::ApplyYourself(), G4ANuMuNucleusCcModel::ApplyYourself(), G4ANuMuNucleusNcModel::ApplyYourself(), G4NeutrinoElectronCcModel::ApplyYourself(), G4NuElNucleusCcModel::ApplyYourself(), G4NuElNucleusNcModel::ApplyYourself(), G4NuMuNucleusCcModel::ApplyYourself(), G4NuMuNucleusNcModel::ApplyYourself(), G4QMDReaction::ApplyYourself(), G4NeutronRadCapture::ApplyYourself(), G4LowEGammaNuclearModel::ApplyYourself(), G4ChargeExchange::ApplyYourself(), G4HadronElastic::ApplyYourself(), G4LEHadronProtonElastic::ApplyYourself(), G4LEnp::ApplyYourself(), G4LEpp::ApplyYourself(), G4BinaryCascade::ApplyYourself(), G4BinaryLightIonReaction::ApplyYourself(), G4INCLXXInterface::ApplyYourself(), G4LMsdGenerator::ApplyYourself(), G4PreCompoundModel::ApplyYourself(), G4LowEIonFragmentation::ApplyYourself(), G4TheoFSGenerator::ApplyYourself(), G4FissionLibrary::ApplyYourself(), G4ParticleHPCaptureFS::ApplyYourself(), G4ParticleHPElasticFS::ApplyYourself(), G4ParticleHPFissionFS::ApplyYourself(), G4MuonMinusAtomicCapture::AtRestDoIt(), G4ParticleHPInelasticBaseFS::BaseApply(), G4NeutrinoNucleusModel::CoherentPion(), G4ParticleHPInelasticCompFS::CompositeApply(), G4CascadeInterface::copyOutputToHadronicResult(), G4NeutrinoNucleusModel::FinalBarion(), G4NeutrinoNucleusModel::FinalMeson(), G4WilsonAbrasionModel::GetAbradedNucleons(), G4NeutrinoNucleusModel::RecoilDeexcitation(), and G4ParticleHPInelasticCompFS::use_nresp71_model().

◆ Clear()

void G4HadFinalState::Clear ( )

Definition at line 67 of file G4HadFinalState.cc.

68{
69 theDirection.set(0,0,1);
70 theEnergy = -1;
72 theW = 1.;
73 theEDep = 0.;
75}
void set(double x, double y, double z)

References ClearSecondaries(), isAlive, CLHEP::Hep3Vector::set(), theDirection, theEDep, theEnergy, theStat, and theW.

Referenced by G4ParticleHPChannelList::ApplyYourself(), G4WilsonAbrasionModel::ApplyYourself(), G4EMDissociation::ApplyYourself(), G4LENDCapture::ApplyYourself(), G4LENDElastic::ApplyYourself(), G4LENDFission::ApplyYourself(), G4LENDInelastic::ApplyYourself(), G4ElectroVDNuclearModel::ApplyYourself(), G4NeutrinoElectronNcModel::ApplyYourself(), G4NeutronElectronElModel::ApplyYourself(), G4LFission::ApplyYourself(), G4ANuElNucleusCcModel::ApplyYourself(), G4ANuElNucleusNcModel::ApplyYourself(), G4ANuMuNucleusCcModel::ApplyYourself(), G4ANuMuNucleusNcModel::ApplyYourself(), G4MuonVDNuclearModel::ApplyYourself(), G4NeutrinoElectronCcModel::ApplyYourself(), G4NuElNucleusCcModel::ApplyYourself(), G4NuElNucleusNcModel::ApplyYourself(), G4NuMuNucleusCcModel::ApplyYourself(), G4NuMuNucleusNcModel::ApplyYourself(), G4QMDReaction::ApplyYourself(), G4EmCaptureCascade::ApplyYourself(), G4MuMinusCapturePrecompound::ApplyYourself(), G4MuonMinusBoundDecay::ApplyYourself(), G4NeutronRadCapture::ApplyYourself(), G4LowEGammaNuclearModel::ApplyYourself(), G4ChargeExchange::ApplyYourself(), G4HadronElastic::ApplyYourself(), G4LEHadronProtonElastic::ApplyYourself(), G4LEnp::ApplyYourself(), G4LEpp::ApplyYourself(), G4BinaryCascade::ApplyYourself(), G4BinaryLightIonReaction::ApplyYourself(), G4CascadeInterface::ApplyYourself(), G4INCLXXInterface::ApplyYourself(), G4LMsdGenerator::ApplyYourself(), G4PreCompoundModel::ApplyYourself(), G4LowEIonFragmentation::ApplyYourself(), G4TheoFSGenerator::ApplyYourself(), G4FissionLibrary::ApplyYourself(), G4ParticleHPCaptureFS::ApplyYourself(), G4ParticleHPElasticFS::ApplyYourself(), G4ParticleHPFissionFS::ApplyYourself(), G4HadronStoppingProcess::AtRestDoIt(), G4MuonMinusAtomicCapture::AtRestDoIt(), G4ParticleHPInelasticBaseFS::BaseApply(), G4HadronicProcess::CheckResult(), G4ParticleHPInelasticCompFS::CompositeApply(), G4HadronicProcess::FillResult(), G4MuonicAtomDecay::FillResult(), G4CascadeInterface::NoInteraction(), G4NeutrinoElectronProcess::PostStepDoIt(), G4ElNeutrinoNucleusProcess::PostStepDoIt(), G4HadronElasticProcess::PostStepDoIt(), G4MuNeutrinoNucleusProcess::PostStepDoIt(), G4CascadeInterface::Propagate(), G4LEHadronProtonElastic::~G4LEHadronProtonElastic(), G4LEnp::~G4LEnp(), G4LFission::~G4LFission(), G4LowEIonFragmentation::~G4LowEIonFragmentation(), G4MuMinusCapturePrecompound::~G4MuMinusCapturePrecompound(), and G4PreCompoundModel::~G4PreCompoundModel().

◆ ClearSecondaries()

void G4HadFinalState::ClearSecondaries ( )
inline

Definition at line 87 of file G4HadFinalState.hh.

87{ theSecs.clear(); }

References theSecs.

Referenced by G4HadLeadBias::Bias(), and Clear().

◆ GetEnergyChange()

G4double G4HadFinalState::GetEnergyChange ( ) const
inline

◆ GetLocalEnergyDeposit()

G4double G4HadFinalState::GetLocalEnergyDeposit ( ) const
inline

◆ GetMomentumChange()

const G4ThreeVector & G4HadFinalState::GetMomentumChange ( ) const
inline

◆ GetNumberOfSecondaries()

std::size_t G4HadFinalState::GetNumberOfSecondaries ( ) const
inline

◆ GetSecondary() [1/2]

G4HadSecondary * G4HadFinalState::GetSecondary ( size_t  i)

◆ GetSecondary() [2/2]

const G4HadSecondary * G4HadFinalState::GetSecondary ( size_t  i) const

Definition at line 88 of file G4HadFinalState.cc.

89{
90 if(i>theSecs.size()) {
91 throw G4HadronicException(__FILE__, __LINE__,
92 "Trying direct access to secondary beyond end of list");
93 }
94 return &theSecs[i];
95}

References theSecs.

◆ GetStatusChange()

G4HadFinalStateStatus G4HadFinalState::GetStatusChange ( ) const
inline

◆ GetTrafoToLab()

const G4LorentzRotation & G4HadFinalState::GetTrafoToLab ( ) const
inline

Definition at line 72 of file G4HadFinalState.hh.

72{ return theT; }
G4LorentzRotation theT

References theT.

Referenced by G4MuonicAtomDecay::FillResult().

◆ GetWeightChange()

G4double G4HadFinalState::GetWeightChange ( ) const
inline

Definition at line 78 of file G4HadFinalState.hh.

78{ return theW; }

References theW.

Referenced by G4BinaryCascade::DebugEpConservation(), and G4BinaryCascade::DebugFinalEpConservation().

◆ SetEnergyChange()

void G4HadFinalState::SetEnergyChange ( G4double  anEnergy)

Definition at line 39 of file G4HadFinalState.cc.

40{
41 theEnergy=anEnergy;
42 if(theEnergy<0)
43 {
44 G4cout << "Final state energy was: E = "<<theEnergy<<G4endl;
45 throw G4HadronicException(__FILE__, __LINE__,
46 "G4HadFinalState: fatal - negative energy");
47 }
48}
#define G4endl
Definition: G4ios.hh:57
G4GLOB_DLL std::ostream G4cout

References G4cout, G4endl, and theEnergy.

Referenced by G4ParticleHPChannelList::ApplyYourself(), G4WilsonAbrasionModel::ApplyYourself(), G4LENDElastic::ApplyYourself(), G4LENDInelastic::ApplyYourself(), G4LENDModel::ApplyYourself(), G4ElectroVDNuclearModel::ApplyYourself(), G4ParticleHPThermalScattering::ApplyYourself(), G4NeutrinoElectronNcModel::ApplyYourself(), G4NeutronElectronElModel::ApplyYourself(), G4ANuElNucleusCcModel::ApplyYourself(), G4ANuElNucleusNcModel::ApplyYourself(), G4ANuMuNucleusCcModel::ApplyYourself(), G4ANuMuNucleusNcModel::ApplyYourself(), G4MuonVDNuclearModel::ApplyYourself(), G4NeutrinoElectronCcModel::ApplyYourself(), G4NuElNucleusCcModel::ApplyYourself(), G4NuElNucleusNcModel::ApplyYourself(), G4NuMuNucleusCcModel::ApplyYourself(), G4NuMuNucleusNcModel::ApplyYourself(), G4ChargeExchange::ApplyYourself(), G4HadronElastic::ApplyYourself(), G4LEHadronProtonElastic::ApplyYourself(), G4LEnp::ApplyYourself(), G4LEpp::ApplyYourself(), G4BinaryCascade::ApplyYourself(), G4BinaryLightIonReaction::ApplyYourself(), G4INCLXXInterface::ApplyYourself(), G4LMsdGenerator::ApplyYourself(), G4LowEIonFragmentation::ApplyYourself(), G4TheoFSGenerator::ApplyYourself(), G4ParticleHPElasticFS::ApplyYourself(), G4ElectroVDNuclearModel::CalculateEMVertex(), G4MuonVDNuclearModel::CalculateEMVertex(), G4CascadeInterface::copyOutputToHadronicResult(), G4CascadeInterface::NoInteraction(), and G4LENDModel::returnUnchanged().

◆ SetLocalEnergyDeposit()

void G4HadFinalState::SetLocalEnergyDeposit ( G4double  aE)
inline

◆ SetMomentumChange() [1/2]

void G4HadFinalState::SetMomentumChange ( const G4ThreeVector aV)
inline

◆ SetMomentumChange() [2/2]

void G4HadFinalState::SetMomentumChange ( G4double  x,
G4double  y,
G4double  z 
)

Definition at line 50 of file G4HadFinalState.cc.

51{
52 theDirection.set(x,y,z);
53 if(std::abs(x*x + y*y + z*z - 1.0)>0.001) {
54 G4cout <<"We have negative theDirection.mag() = "<<theDirection.mag()
55 <<G4endl;
56 throw G4HadronicException(__FILE__, __LINE__,
57 "G4HadFinalState: fatal - negative direction.mag().");
58 }
59}
double mag() const

References G4cout, G4endl, CLHEP::Hep3Vector::mag(), CLHEP::Hep3Vector::set(), and theDirection.

◆ SetStatusChange()

void G4HadFinalState::SetStatusChange ( G4HadFinalStateStatus  aS)
inline

◆ SetTrafoToLab()

void G4HadFinalState::SetTrafoToLab ( const G4LorentzRotation aT)
inline

◆ SetWeightChange()

void G4HadFinalState::SetWeightChange ( G4double  aW)
inline

Definition at line 76 of file G4HadFinalState.hh.

76{ theW=aW; }

References theW.

Field Documentation

◆ theDirection

G4ThreeVector G4HadFinalState::theDirection
private

Definition at line 101 of file G4HadFinalState.hh.

Referenced by Clear(), GetMomentumChange(), and SetMomentumChange().

◆ theEDep

G4double G4HadFinalState::theEDep
private

Definition at line 107 of file G4HadFinalState.hh.

Referenced by Clear(), GetLocalEnergyDeposit(), and SetLocalEnergyDeposit().

◆ theEnergy

G4double G4HadFinalState::theEnergy
private

Definition at line 102 of file G4HadFinalState.hh.

Referenced by Clear(), GetEnergyChange(), and SetEnergyChange().

◆ theSecs

std::vector<G4HadSecondary> G4HadFinalState::theSecs
private

◆ theStat

G4HadFinalStateStatus G4HadFinalState::theStat
private

Definition at line 104 of file G4HadFinalState.hh.

Referenced by Clear(), GetStatusChange(), and SetStatusChange().

◆ theT

G4LorentzRotation G4HadFinalState::theT
private

Definition at line 105 of file G4HadFinalState.hh.

Referenced by GetTrafoToLab(), and SetTrafoToLab().

◆ theW

G4double G4HadFinalState::theW
private

Definition at line 106 of file G4HadFinalState.hh.

Referenced by AddSecondary(), Clear(), GetWeightChange(), and SetWeightChange().


The documentation for this class was generated from the following files: