Geant4 10.7.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
G4DecayStrongResonances Class Reference

#include <G4DecayStrongResonances.hh>

Public Member Functions

 G4DecayStrongResonances ()
 
 ~G4DecayStrongResonances ()
 
G4ReactionProductVectorPropagate (G4KineticTrackVector *theSecondaries, G4V3DNucleus *)
 

Detailed Description

Definition at line 45 of file G4DecayStrongResonances.hh.

Constructor & Destructor Documentation

◆ G4DecayStrongResonances()

G4DecayStrongResonances::G4DecayStrongResonances ( )

Definition at line 44 of file G4DecayStrongResonances.cc.

44{}

◆ ~G4DecayStrongResonances()

G4DecayStrongResonances::~G4DecayStrongResonances ( )

Definition at line 46 of file G4DecayStrongResonances.cc.

46{}

Member Function Documentation

◆ Propagate()

G4ReactionProductVector * G4DecayStrongResonances::Propagate ( G4KineticTrackVector theSecondaries,
G4V3DNucleus  
)

Definition at line 49 of file G4DecayStrongResonances.cc.

50 {
51 G4DecayKineticTracks decay(theSecondaries); // Changes input list in situ
52
53 // translate to ReactionProducts
54 G4ReactionProductVector * theResult;
55 try { theResult = new G4ReactionProductVector; }
56 catch(...) {
57 throw G4HadronicException(__FILE__, __LINE__, "DecayStrongRes: out of memory ");
58 }
59
60 G4ReactionProduct * it = NULL;
61
62 G4KineticTrackVector::iterator secIter = theSecondaries->begin();
63 for(; secIter != theSecondaries->end(); ++secIter) {
64 G4KineticTrack* aSecondary = *secIter;
65 if (!aSecondary) continue; // Skip null pointers
66
67 try { it = new G4ReactionProduct(); }
68 catch(...) {
69 throw G4HadronicException(__FILE__, __LINE__, "DecayStrongRes: out of memory ");
70 }
71
72 it->SetDefinition(aSecondary->GetDefinition());
73 it->SetMass(aSecondary->GetDefinition()->GetPDGMass());
74 it->SetTotalEnergy(aSecondary->Get4Momentum().t());
75 it->SetMomentum(aSecondary->Get4Momentum().vect());
76 delete aSecondary;
77 try { theResult->push_back(it); }
78 catch(...){
79 throw G4HadronicException(__FILE__, __LINE__, "DecayStrongRes: push to result failed - out of mem.");
80 }
81 }
82 delete theSecondaries;
83
84 return theResult;
85}
std::vector< G4ReactionProduct * > G4ReactionProductVector
Hep3Vector vect() const
const G4ParticleDefinition * GetDefinition() const
const G4LorentzVector & Get4Momentum() const
void SetMomentum(const G4double x, const G4double y, const G4double z)
void SetTotalEnergy(const G4double en)
void SetDefinition(const G4ParticleDefinition *aParticleDefinition)
void SetMass(const G4double mas)
ParticleList decay(Cluster *const c)
Carries out a cluster decay.

Referenced by G4TheoFSGenerator::ApplyYourself().


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