#include <G4ReactionProduct.hh>
Definition at line 51 of file G4ReactionProduct.hh.
G4ReactionProduct::G4ReactionProduct | ( | ) |
Definition at line 36 of file G4ReactionProduct.cc.
References SetMomentum(), and SetPositionInNucleus().
00036 : 00037 theParticleDefinition(NULL), 00038 formationTime(0.0), 00039 hasInitialStateParton(false), 00040 mass(0.0), 00041 totalEnergy(0.0), 00042 kineticEnergy(0.0), 00043 timeOfFlight(0.0), 00044 side(0), 00045 NewlyAdded(false), 00046 MayBeKilled(true) 00047 { 00048 SetMomentum( 0.0, 0.0, 0.0 ); 00049 SetPositionInNucleus( 0.0, 0.0, 0.0 ); 00050 }
G4ReactionProduct::G4ReactionProduct | ( | G4ParticleDefinition * | aParticleDefinition | ) |
Definition at line 52 of file G4ReactionProduct.cc.
References G4ParticleDefinition::GetPDGEncoding(), G4ParticleDefinition::GetPDGMass(), SetMomentum(), and SetPositionInNucleus().
00054 { 00055 SetMomentum( 0.0, 0.0, 0.0 ); 00056 SetPositionInNucleus( 0.0, 0.0, 0.0 ); 00057 formationTime = 0.0; 00058 hasInitialStateParton = false; 00059 theParticleDefinition = aParticleDefinition; 00060 mass = aParticleDefinition->GetPDGMass(); 00061 totalEnergy = mass; 00062 kineticEnergy = 0.0; 00063 (aParticleDefinition->GetPDGEncoding()<0) ? timeOfFlight=-1.0 : timeOfFlight=1.0; 00064 side = 0; 00065 NewlyAdded = false; 00066 MayBeKilled = true; 00067 }
G4ReactionProduct::~G4ReactionProduct | ( | ) | [inline] |
G4ReactionProduct::G4ReactionProduct | ( | const G4ReactionProduct & | right | ) |
Definition at line 69 of file G4ReactionProduct.cc.
References formationTime, hasInitialStateParton, kineticEnergy, mass, MayBeKilled, momentum, NewlyAdded, positionInNucleus, side, theParticleDefinition, timeOfFlight, and totalEnergy.
00071 { 00072 theParticleDefinition = right.theParticleDefinition; 00073 positionInNucleus = right.positionInNucleus; 00074 formationTime = right.formationTime; 00075 hasInitialStateParton = right.hasInitialStateParton; 00076 momentum = right.momentum; 00077 mass = right.mass; 00078 totalEnergy = right.totalEnergy; 00079 kineticEnergy = right.kineticEnergy; 00080 timeOfFlight = right.timeOfFlight; 00081 side = right.side; 00082 NewlyAdded = right.NewlyAdded; 00083 MayBeKilled = right.MayBeKilled; 00084 }
G4double G4ReactionProduct::Angle | ( | const G4ReactionProduct & | p | ) | const |
Definition at line 219 of file G4ReactionProduct.cc.
References momentum.
00221 { 00222 G4ThreeVector tM = momentum; 00223 G4ThreeVector pM = p.momentum; 00224 G4double tx = tM.x(); G4double ty = tM.y(); G4double tz = tM.z(); 00225 G4double px = pM.x(); G4double py = pM.y(); G4double pz = pM.z(); 00226 G4double a = std::sqrt( ( px*px + py*py + pz*pz ) * ( tx*tx + ty*ty + tz*tz ) ); 00227 if( a == 0.0 ) { 00228 return 0.0; 00229 } else { 00230 a = ( tx*px + ty*py + tz*pz ) / a; 00231 if( std::fabs(a) > 1.0 ) { a<0.0 ? a=-1.0 : a=1.0; } 00232 return std::acos( a ); 00233 } 00234 }
G4ParticleDefinition* G4ReactionProduct::GetDefinition | ( | ) | const [inline] |
Definition at line 104 of file G4ReactionProduct.hh.
Referenced by G4NeutronHPInelasticBaseFS::BaseApply(), G4RPGInelastic::CheckQnums(), G4NeutronHPInelasticCompFS::CompositeApply(), G4VSplitableHadron::G4VSplitableHadron(), G4ReactionDynamics::GenerateXandPt(), G4FTFModel::GetStrings(), G4FTFModel::Init(), G4RPGInelastic::MarkLeadingStrangeParticle(), G4InelasticInteraction::MarkLeadingStrangeParticle(), G4RPGReaction::NuclearReaction(), G4ReactionDynamics::NuclearReaction(), G4ReactionDynamics::ProduceStrangeParticlePairs(), G4RPGTwoCluster::ReactionStage(), G4RPGTwoBody::ReactionStage(), G4RPGStrangeProduction::ReactionStage(), G4RPGPionSuppression::ReactionStage(), G4RPGFragmentation::ReactionStage(), G4RPGReaction::Rotate(), G4QGSParticipants::SelectInteractions(), G4RPGInelastic::SetUpChange(), G4InelasticInteraction::SetUpChange(), G4ReactionDynamics::SuppressChargedPions(), G4ReactionDynamics::TwoBody(), and G4ReactionDynamics::TwoCluster().
G4double G4ReactionProduct::GetFormationTime | ( | ) | const [inline] |
G4double G4ReactionProduct::GetKineticEnergy | ( | ) | const [inline] |
Definition at line 135 of file G4ReactionProduct.hh.
Referenced by G4RPGReaction::AddBlackTrackParticles(), G4RPGXiZeroInelastic::ApplyYourself(), G4RPGXiMinusInelastic::ApplyYourself(), G4RPGSigmaPlusInelastic::ApplyYourself(), G4RPGProtonInelastic::ApplyYourself(), G4RPGOmegaMinusInelastic::ApplyYourself(), G4RPGNeutronInelastic::ApplyYourself(), G4RPGLambdaInelastic::ApplyYourself(), G4RPGKZeroInelastic::ApplyYourself(), G4RPGKPlusInelastic::ApplyYourself(), G4RPGKMinusInelastic::ApplyYourself(), G4RPGAntiXiZeroInelastic::ApplyYourself(), G4RPGAntiXiMinusInelastic::ApplyYourself(), G4RPGAntiSigmaPlusInelastic::ApplyYourself(), G4RPGAntiSigmaMinusInelastic::ApplyYourself(), G4RPGAntiProtonInelastic::ApplyYourself(), G4RPGAntiOmegaMinusInelastic::ApplyYourself(), G4RPGAntiNeutronInelastic::ApplyYourself(), G4RPGAntiKZeroInelastic::ApplyYourself(), G4NeutronHPFSFissionFS::ApplyYourself(), G4NeutronHPFissionFS::ApplyYourself(), G4NeutronHPFissionBaseFS::ApplyYourself(), G4NeutronHPElasticFS::ApplyYourself(), G4NeutronHPCaptureFS::ApplyYourself(), G4LEXiZeroInelastic::ApplyYourself(), G4LEXiMinusInelastic::ApplyYourself(), G4LESigmaPlusInelastic::ApplyYourself(), G4LEProtonInelastic::ApplyYourself(), G4LEPionPlusInelastic::ApplyYourself(), G4LEPionMinusInelastic::ApplyYourself(), G4LEOmegaMinusInelastic::ApplyYourself(), G4LENeutronInelastic::ApplyYourself(), G4LENDModel::ApplyYourself(), G4LENDElastic::ApplyYourself(), G4LELambdaInelastic::ApplyYourself(), G4LEKaonZeroInelastic::ApplyYourself(), G4LEKaonPlusInelastic::ApplyYourself(), G4LEKaonMinusInelastic::ApplyYourself(), G4LEAntiXiZeroInelastic::ApplyYourself(), G4LEAntiXiMinusInelastic::ApplyYourself(), G4LEAntiSigmaPlusInelastic::ApplyYourself(), G4LEAntiSigmaMinusInelastic::ApplyYourself(), G4LEAntiProtonInelastic::ApplyYourself(), G4LEAntiOmegaMinusInelastic::ApplyYourself(), G4LEAntiNeutronInelastic::ApplyYourself(), G4LEAntiKaonZeroInelastic::ApplyYourself(), G4FissionLibrary::ApplyYourself(), G4NeutronHPInelasticBaseFS::BaseApply(), G4RPGInelastic::CalculateMomenta(), G4InelasticInteraction::CalculateMomenta(), G4NeutronHPInelasticCompFS::CompositeApply(), G4ReactionDynamics::GenerateXandPt(), G4NeutronHPorLFissionData::GetCrossSection(), G4NeutronHPorLElasticData::GetCrossSection(), G4NeutronHPorLEInelasticData::GetCrossSection(), G4NeutronHPorLCaptureData::GetCrossSection(), G4NeutronHPInelasticData::GetCrossSection(), G4NeutronHPFissionData::GetCrossSection(), G4NeutronHPElasticData::GetCrossSection(), G4NeutronHPCaptureData::GetCrossSection(), G4NeutronHPFSFissionFS::GetPhotons(), G4NeutronHPThermalBoost::GetThermalEnergy(), G4RPGReaction::NuclearReaction(), G4ReactionDynamics::NuclearReaction(), G4RPGTwoCluster::ReactionStage(), G4RPGTwoBody::ReactionStage(), G4RPGFragmentation::ReactionStage(), G4RPGReaction::Rotate(), G4NeutronHPEnAngCorrelation::Sample(), G4NeutronHPAngular::SampleAndUpdate(), G4QGSParticipants::SelectInteractions(), SetDefinitionAndUpdateE(), G4RPGInelastic::SetUpChange(), G4InelasticInteraction::SetUpChange(), G4ReactionDynamics::TwoBody(), and G4ReactionDynamics::TwoCluster().
G4double G4ReactionProduct::GetMass | ( | ) | const [inline] |
Definition at line 147 of file G4ReactionProduct.hh.
Referenced by G4NeutronHPElasticFS::ApplyYourself(), G4LENDModel::ApplyYourself(), G4LENDElastic::ApplyYourself(), G4NeutronHPInelasticBaseFS::BaseApply(), G4RPGInelastic::CalculateMomenta(), G4InelasticInteraction::CalculateMomenta(), G4NeutronHPInelasticCompFS::CompositeApply(), G4ReactionDynamics::GenerateXandPt(), G4Nucleus::GetBiasedThermalNucleus(), G4NeutronHPorLFissionData::GetCrossSection(), G4NeutronHPorLElasticData::GetCrossSection(), G4NeutronHPorLEInelasticData::GetCrossSection(), G4NeutronHPorLCaptureData::GetCrossSection(), G4NeutronHPInelasticData::GetCrossSection(), G4NeutronHPFissionData::GetCrossSection(), G4NeutronHPElasticData::GetCrossSection(), G4NeutronHPCaptureData::GetCrossSection(), G4Nucleus::GetThermalNucleus(), G4RPGInelastic::MarkLeadingStrangeParticle(), G4InelasticInteraction::MarkLeadingStrangeParticle(), G4RPGReaction::MomentumCheck(), G4RPGReaction::NuclearReaction(), G4ReactionDynamics::NuclearReaction(), G4ReactionDynamics::ProduceStrangeParticlePairs(), G4RPGTwoCluster::ReactionStage(), G4RPGTwoBody::ReactionStage(), G4RPGStrangeProduction::ReactionStage(), G4RPGPionSuppression::ReactionStage(), G4RPGFragmentation::ReactionStage(), G4NeutronHPNBodyPhaseSpace::Sample(), G4NeutronHPDiscreteTwoBody::Sample(), G4NeutronHPContEnergyAngular::Sample(), G4NeutronHPContAngularPar::Sample(), G4NeutronHPAngular::SampleAndUpdate(), G4QGSParticipants::SelectInteractions(), SetDefinitionAndUpdateE(), G4RPGInelastic::SetUpChange(), G4InelasticInteraction::SetUpChange(), G4ReactionDynamics::SuppressChargedPions(), G4ReactionDynamics::TwoBody(), and G4ReactionDynamics::TwoCluster().
G4bool G4ReactionProduct::GetMayBeKilled | ( | ) | const [inline] |
G4ThreeVector G4ReactionProduct::GetMomentum | ( | void | ) | const [inline] |
Definition at line 120 of file G4ReactionProduct.hh.
Referenced by G4RPGXiZeroInelastic::ApplyYourself(), G4RPGXiMinusInelastic::ApplyYourself(), G4RPGSigmaPlusInelastic::ApplyYourself(), G4RPGSigmaMinusInelastic::ApplyYourself(), G4RPGProtonInelastic::ApplyYourself(), G4RPGOmegaMinusInelastic::ApplyYourself(), G4RPGNeutronInelastic::ApplyYourself(), G4RPGLambdaInelastic::ApplyYourself(), G4RPGKZeroInelastic::ApplyYourself(), G4RPGKPlusInelastic::ApplyYourself(), G4RPGKMinusInelastic::ApplyYourself(), G4RPGAntiXiZeroInelastic::ApplyYourself(), G4RPGAntiXiMinusInelastic::ApplyYourself(), G4RPGAntiSigmaPlusInelastic::ApplyYourself(), G4RPGAntiSigmaMinusInelastic::ApplyYourself(), G4RPGAntiProtonInelastic::ApplyYourself(), G4RPGAntiOmegaMinusInelastic::ApplyYourself(), G4RPGAntiNeutronInelastic::ApplyYourself(), G4RPGAntiLambdaInelastic::ApplyYourself(), G4RPGAntiKZeroInelastic::ApplyYourself(), G4NeutronHPFissionFS::ApplyYourself(), G4NeutronHPElasticFS::ApplyYourself(), G4NeutronHPCaptureFS::ApplyYourself(), G4LEXiZeroInelastic::ApplyYourself(), G4LEXiMinusInelastic::ApplyYourself(), G4LESigmaPlusInelastic::ApplyYourself(), G4LESigmaMinusInelastic::ApplyYourself(), G4LEProtonInelastic::ApplyYourself(), G4LEPionPlusInelastic::ApplyYourself(), G4LEPionMinusInelastic::ApplyYourself(), G4LEOmegaMinusInelastic::ApplyYourself(), G4LENeutronInelastic::ApplyYourself(), G4LENDModel::ApplyYourself(), G4LENDElastic::ApplyYourself(), G4LELambdaInelastic::ApplyYourself(), G4LEKaonZeroInelastic::ApplyYourself(), G4LEKaonPlusInelastic::ApplyYourself(), G4LEKaonMinusInelastic::ApplyYourself(), G4LEAntiXiZeroInelastic::ApplyYourself(), G4LEAntiXiMinusInelastic::ApplyYourself(), G4LEAntiSigmaPlusInelastic::ApplyYourself(), G4LEAntiSigmaMinusInelastic::ApplyYourself(), G4LEAntiProtonInelastic::ApplyYourself(), G4LEAntiOmegaMinusInelastic::ApplyYourself(), G4LEAntiNeutronInelastic::ApplyYourself(), G4LEAntiLambdaInelastic::ApplyYourself(), G4LEAntiKaonZeroInelastic::ApplyYourself(), G4FissionLibrary::ApplyYourself(), G4NeutronHPInelasticBaseFS::BaseApply(), G4RPGInelastic::CalculateMomenta(), G4InelasticInteraction::CalculateMomenta(), G4NeutronHPInelasticCompFS::CompositeApply(), G4RPGReaction::Defs1(), G4VSplitableHadron::G4VSplitableHadron(), G4ReactionDynamics::GenerateXandPt(), G4Nucleus::GetBiasedThermalNucleus(), G4NeutronHPorLFissionData::GetCrossSection(), G4NeutronHPorLElasticData::GetCrossSection(), G4NeutronHPorLEInelasticData::GetCrossSection(), G4NeutronHPorLCaptureData::GetCrossSection(), G4NeutronHPInelasticData::GetCrossSection(), G4NeutronHPFissionData::GetCrossSection(), G4NeutronHPElasticData::GetCrossSection(), G4NeutronHPCaptureData::GetCrossSection(), G4NeutronHPThermalBoost::GetThermalEnergy(), G4FTFModel::Init(), G4RPGReaction::MomentumCheck(), G4RPGReaction::NuclearReaction(), G4ReactionDynamics::NuclearReaction(), ReactionProduct4Mom::operator()(), G4RPGTwoCluster::ReactionStage(), G4RPGTwoBody::ReactionStage(), G4RPGFragmentation::ReactionStage(), G4RPGReaction::Rotate(), G4NeutronHPEnAngCorrelation::Sample(), G4NeutronHPAngular::SampleAndUpdate(), G4QGSParticipants::SelectInteractions(), SetDefinitionAndUpdateE(), G4RPGInelastic::SetUpChange(), G4InelasticInteraction::SetUpChange(), G4ReactionDynamics::TwoBody(), and G4ReactionDynamics::TwoCluster().
G4bool G4ReactionProduct::GetNewlyAdded | ( | ) | const [inline] |
G4ThreeVector G4ReactionProduct::GetPositionInNucleus | ( | ) | const [inline] |
G4int G4ReactionProduct::GetSide | ( | ) | const [inline] |
Definition at line 159 of file G4ReactionProduct.hh.
Referenced by G4ReactionDynamics::GenerateXandPt(), G4RPGTwoCluster::ReactionStage(), G4RPGFragmentation::ReactionStage(), and G4ReactionDynamics::TwoCluster().
G4double G4ReactionProduct::GetTOF | ( | ) | const [inline] |
G4double G4ReactionProduct::GetTotalEnergy | ( | void | ) | const [inline] |
Definition at line 126 of file G4ReactionProduct.hh.
Referenced by G4NeutronHPElasticFS::ApplyYourself(), G4NeutronHPCaptureFS::ApplyYourself(), G4LENDModel::ApplyYourself(), G4LENDElastic::ApplyYourself(), G4NeutronHPInelasticBaseFS::BaseApply(), G4NeutronHPInelasticCompFS::CompositeApply(), G4VSplitableHadron::G4VSplitableHadron(), G4ReactionDynamics::GenerateXandPt(), G4NeutronHPPhotonDist::GetPhotons(), G4FTFModel::Init(), ReactionProduct4Mom::operator()(), G4ReactionDynamics::ProduceStrangeParticlePairs(), G4RPGTwoCluster::ReactionStage(), G4RPGTwoBody::ReactionStage(), G4RPGStrangeProduction::ReactionStage(), G4RPGPionSuppression::ReactionStage(), G4RPGFragmentation::ReactionStage(), G4NeutronHPEnAngCorrelation::Sample(), G4NeutronHPAngular::SampleAndUpdate(), G4QGSParticipants::SelectInteractions(), G4ReactionDynamics::SuppressChargedPions(), G4ReactionDynamics::TwoBody(), and G4ReactionDynamics::TwoCluster().
G4double G4ReactionProduct::GetTotalMomentum | ( | ) | const [inline] |
Definition at line 123 of file G4ReactionProduct.hh.
Referenced by G4RPGAntiXiZeroInelastic::ApplyYourself(), G4RPGAntiXiMinusInelastic::ApplyYourself(), G4RPGAntiSigmaPlusInelastic::ApplyYourself(), G4RPGAntiSigmaMinusInelastic::ApplyYourself(), G4RPGAntiOmegaMinusInelastic::ApplyYourself(), G4RPGAntiNeutronInelastic::ApplyYourself(), G4RPGAntiLambdaInelastic::ApplyYourself(), G4NeutronHPElasticFS::ApplyYourself(), G4LENDModel::ApplyYourself(), G4LENDElastic::ApplyYourself(), G4LEAntiXiZeroInelastic::ApplyYourself(), G4LEAntiXiMinusInelastic::ApplyYourself(), G4LEAntiSigmaPlusInelastic::ApplyYourself(), G4LEAntiSigmaMinusInelastic::ApplyYourself(), G4LEAntiOmegaMinusInelastic::ApplyYourself(), G4LEAntiNeutronInelastic::ApplyYourself(), G4LEAntiLambdaInelastic::ApplyYourself(), G4RPGInelastic::CalculateMomenta(), G4InelasticInteraction::CalculateMomenta(), G4NeutronHPInelasticCompFS::CompositeApply(), G4ReactionDynamics::GenerateXandPt(), G4NeutronHPDeExGammas::GetDecayGammas(), G4NeutronHPPhotonDist::GetPhotons(), G4FTFModel::GetStrings(), G4RPGReaction::MomentumCheck(), G4RPGReaction::NuclearReaction(), G4ReactionDynamics::NuclearReaction(), G4RPGTwoCluster::ReactionStage(), G4RPGTwoBody::ReactionStage(), G4RPGPionSuppression::ReactionStage(), G4RPGFragmentation::ReactionStage(), G4RPGReaction::Rotate(), G4NeutronHPNBodyPhaseSpace::Sample(), G4NeutronHPLabAngularEnergy::Sample(), G4NeutronHPIsotropic::Sample(), G4NeutronHPDiscreteTwoBody::Sample(), G4NeutronHPContAngularPar::Sample(), G4NeutronHPAngular::SampleAndUpdate(), G4ReactionDynamics::SuppressChargedPions(), G4ReactionDynamics::TwoBody(), and G4ReactionDynamics::TwoCluster().
G4double G4ReactionProduct::GetXPositionInNucleus | ( | ) | const [inline] |
G4double G4ReactionProduct::GetYPositionInNucleus | ( | ) | const [inline] |
G4double G4ReactionProduct::GetZPositionInNucleus | ( | ) | const [inline] |
G4bool G4ReactionProduct::HasInitialStateParton | ( | ) | const [inline] |
void G4ReactionProduct::HasInitialStateParton | ( | G4bool | aFlag | ) | [inline] |
void G4ReactionProduct::Lorentz | ( | const G4ReactionProduct & | p1, | |
const G4ReactionProduct & | p2 | |||
) |
Definition at line 200 of file G4ReactionProduct.cc.
References mass, momentum, SetMass(), SetMomentum(), SetTotalEnergy(), and totalEnergy.
Referenced by G4NeutronHPFSFissionFS::ApplyYourself(), G4NeutronHPFissionFS::ApplyYourself(), G4NeutronHPFissionBaseFS::ApplyYourself(), G4NeutronHPElasticFS::ApplyYourself(), G4NeutronHPCaptureFS::ApplyYourself(), G4LENDModel::ApplyYourself(), G4LENDElastic::ApplyYourself(), G4FissionLibrary::ApplyYourself(), G4NeutronHPInelasticBaseFS::BaseApply(), G4NeutronHPInelasticCompFS::CompositeApply(), G4ReactionDynamics::GenerateXandPt(), G4NeutronHPorLFissionData::GetCrossSection(), G4NeutronHPorLElasticData::GetCrossSection(), G4NeutronHPorLEInelasticData::GetCrossSection(), G4NeutronHPorLCaptureData::GetCrossSection(), G4NeutronHPInelasticData::GetCrossSection(), G4NeutronHPFissionData::GetCrossSection(), G4NeutronHPElasticData::GetCrossSection(), G4NeutronHPCaptureData::GetCrossSection(), G4NeutronHPFSFissionFS::GetPhotons(), G4NeutronHPThermalBoost::GetThermalEnergy(), G4RPGReaction::NuclearReaction(), G4ReactionDynamics::NuclearReaction(), G4RPGTwoCluster::ReactionStage(), G4RPGTwoBody::ReactionStage(), G4RPGFragmentation::ReactionStage(), G4NeutronHPNBodyPhaseSpace::Sample(), G4NeutronHPEnAngCorrelation::Sample(), G4NeutronHPAngular::SampleAndUpdate(), G4ReactionDynamics::TwoBody(), and G4ReactionDynamics::TwoCluster().
00202 { 00203 G4ThreeVector p1M = p1.momentum; 00204 G4ThreeVector p2M = p2.momentum; 00205 G4double p1x = p1M.x(); G4double p1y = p1M.y(); G4double p1z = p1M.z(); 00206 G4double p2x = p2M.x(); G4double p2y = p2M.y(); G4double p2z = p2M.z(); 00207 G4double a = ( (p1x*p2x+p1y*p2y+p1z*p2z)/(p2.totalEnergy+p2.mass) - 00208 p1.totalEnergy ) / p2.mass; 00209 G4double x = p1x+a*p2x; 00210 G4double y = p1y+a*p2y; 00211 G4double z = p1z+a*p2z; 00212 G4double p = std::sqrt(x*x+y*y+z*z); 00213 SetMass( p1.mass ); 00214 SetTotalEnergy( std::sqrt( (p1.mass+p)*(p1.mass+p) - 2.*p1.mass*p ) ); 00215 //SetTotalEnergy( std::sqrt( p1.mass*p1.mass + x*x + y*y + z*z ) ); 00216 SetMomentum( x, y, z ); 00217 }
void G4ReactionProduct::operator delete | ( | void * | aReactionProduct | ) | [inline] |
Definition at line 88 of file G4ReactionProduct.hh.
References aRPAllocator.
00088 { 00089 aRPAllocator.FreeSingle((G4ReactionProduct*)aReactionProduct); 00090 }
void* G4ReactionProduct::operator new | ( | size_t | ) | [inline] |
Definition at line 80 of file G4ReactionProduct.hh.
References aRPAllocator.
00080 { 00081 return (void *)aRPAllocator.MallocSingle(); 00082 }
G4bool G4ReactionProduct::operator!= | ( | const G4ReactionProduct & | right | ) | const [inline] |
Definition at line 101 of file G4ReactionProduct.hh.
00102 { return ( this != (G4ReactionProduct*) &right ); }
G4ReactionProduct & G4ReactionProduct::operator= | ( | const G4HadProjectile & | right | ) |
Definition at line 124 of file G4ReactionProduct.cc.
References G4HadProjectile::Get4Momentum(), G4HadProjectile::GetDefinition(), G4HadProjectile::GetKineticEnergy(), G4ParticleDefinition::GetPDGEncoding(), G4ParticleDefinition::GetPDGMass(), and SetPositionInNucleus().
00126 { 00127 theParticleDefinition = const_cast<G4ParticleDefinition *>(right.GetDefinition()); 00128 SetPositionInNucleus( 0.0, 0.0, 0.0 ); 00129 formationTime = 0.0; 00130 hasInitialStateParton = false; 00131 momentum = right.Get4Momentum().vect(); 00132 mass = right.GetDefinition()->GetPDGMass(); 00133 totalEnergy = right.Get4Momentum().e(); 00134 kineticEnergy = right.GetKineticEnergy(); 00135 (right.GetDefinition()->GetPDGEncoding()<0) ? timeOfFlight=-1.0 : timeOfFlight=1.0; 00136 side = 0; 00137 NewlyAdded = false; 00138 MayBeKilled = true; 00139 return *this; 00140 }
G4ReactionProduct & G4ReactionProduct::operator= | ( | const G4DynamicParticle & | right | ) |
Definition at line 106 of file G4ReactionProduct.cc.
References G4DynamicParticle::GetDefinition(), G4DynamicParticle::GetKineticEnergy(), G4DynamicParticle::GetMomentum(), G4ParticleDefinition::GetPDGEncoding(), G4ParticleDefinition::GetPDGMass(), G4DynamicParticle::GetTotalEnergy(), and SetPositionInNucleus().
00108 { 00109 theParticleDefinition = right.GetDefinition(); 00110 SetPositionInNucleus( 0.0, 0.0, 0.0 ); 00111 formationTime = 0.0; 00112 hasInitialStateParton = false; 00113 momentum = right.GetMomentum(); 00114 mass = right.GetDefinition()->GetPDGMass(); 00115 totalEnergy = right.GetTotalEnergy(); 00116 kineticEnergy = right.GetKineticEnergy(); 00117 (right.GetDefinition()->GetPDGEncoding()<0) ? timeOfFlight=-1.0 : timeOfFlight=1.0; 00118 side = 0; 00119 NewlyAdded = false; 00120 MayBeKilled = true; 00121 return *this; 00122 }
G4ReactionProduct & G4ReactionProduct::operator= | ( | const G4ReactionProduct & | right | ) |
Definition at line 86 of file G4ReactionProduct.cc.
References formationTime, hasInitialStateParton, kineticEnergy, mass, MayBeKilled, momentum, NewlyAdded, positionInNucleus, side, theParticleDefinition, timeOfFlight, and totalEnergy.
00088 { 00089 if( this != &right ) { 00090 theParticleDefinition = right.theParticleDefinition; 00091 positionInNucleus = right.positionInNucleus; 00092 formationTime = right.formationTime; 00093 hasInitialStateParton = right.hasInitialStateParton; 00094 momentum = right.momentum; 00095 mass = right.mass; 00096 totalEnergy = right.totalEnergy; 00097 kineticEnergy = right.kineticEnergy; 00098 timeOfFlight = right.timeOfFlight; 00099 side = right.side; 00100 NewlyAdded = right.NewlyAdded; 00101 MayBeKilled = right.MayBeKilled; 00102 } 00103 return *this; 00104 }
G4bool G4ReactionProduct::operator== | ( | const G4ReactionProduct & | right | ) | const [inline] |
Definition at line 98 of file G4ReactionProduct.hh.
00099 { return ( this == (G4ReactionProduct*) &right ); }
void G4ReactionProduct::SetDefinition | ( | G4ParticleDefinition * | aParticleDefinition | ) |
Definition at line 155 of file G4ReactionProduct.cc.
References G4ParticleDefinition::GetPDGEncoding(), and G4ParticleDefinition::GetPDGMass().
Referenced by G4NeutronHPCaptureFS::ApplyYourself(), G4NeutronHPInelasticBaseFS::BaseApply(), G4NeutronHPInelasticCompFS::CompositeApply(), G4NeutronHPPhotonDist::GetPhotons(), G4QGSModel< ParticipantType >::Init(), G4RPGReaction::NuclearReaction(), G4ReactionDynamics::NuclearReaction(), G4ReactionDynamics::ProduceStrangeParticlePairs(), G4DecayStrongResonances::Propagate(), G4RPGTwoCluster::ReactionStage(), G4RPGStrangeProduction::ReactionStage(), G4NeutronHPNBodyPhaseSpace::Sample(), G4NeutronHPLabAngularEnergy::Sample(), G4NeutronHPIsotropic::Sample(), G4NeutronHPDiscreteTwoBody::Sample(), G4NeutronHPContAngularPar::Sample(), SetDefinitionAndUpdateE(), G4InelasticInteraction::SetUpChange(), G4RPGInelastic::SetUpPions(), G4InelasticInteraction::SetUpPions(), and G4ReactionDynamics::TwoCluster().
00157 { 00158 theParticleDefinition = aParticleDefinition; 00159 mass = aParticleDefinition->GetPDGMass(); 00160 totalEnergy = mass; 00161 kineticEnergy = 0.0; 00162 (aParticleDefinition->GetPDGEncoding()<0) ? 00163 timeOfFlight=-1.0 : timeOfFlight=1.0; 00164 }
void G4ReactionProduct::SetDefinitionAndUpdateE | ( | G4ParticleDefinition * | aParticleDefinition | ) |
Definition at line 142 of file G4ReactionProduct.cc.
References DBL_MIN, GetKineticEnergy(), GetMass(), GetMomentum(), G4InuclParticleNames::pp, SetDefinition(), SetKineticEnergy(), and SetMomentum().
Referenced by G4ReactionDynamics::GenerateXandPt(), G4ReactionDynamics::ProduceStrangeParticlePairs(), G4RPGStrangeProduction::ReactionStage(), G4RPGPionSuppression::ReactionStage(), G4RPGFragmentation::ReactionStage(), G4RPGInelastic::SetUpChange(), and G4ReactionDynamics::SuppressChargedPions().
00144 { 00145 G4double aKineticEnergy = GetKineticEnergy(); 00146 G4double pp = GetMomentum().mag(); 00147 G4ThreeVector aMomentum = GetMomentum(); 00148 SetDefinition( aParticleDefinition ); 00149 SetKineticEnergy( aKineticEnergy ); 00150 if( pp > DBL_MIN ) 00151 SetMomentum( aMomentum * (std::sqrt(aKineticEnergy*aKineticEnergy + 00152 2*aKineticEnergy*GetMass())/pp) ); 00153 }
void G4ReactionProduct::SetFormationTime | ( | G4double | aTime | ) | [inline] |
Definition at line 197 of file G4ReactionProduct.hh.
Referenced by G4ExcitationHandler::BreakItUp(), operator+(), and operator-().
void G4ReactionProduct::SetKineticEnergy | ( | const G4double | en | ) | [inline] |
Definition at line 129 of file G4ReactionProduct.hh.
Referenced by G4RPGXiZeroInelastic::ApplyYourself(), G4RPGXiMinusInelastic::ApplyYourself(), G4RPGSigmaPlusInelastic::ApplyYourself(), G4RPGSigmaMinusInelastic::ApplyYourself(), G4RPGProtonInelastic::ApplyYourself(), G4RPGOmegaMinusInelastic::ApplyYourself(), G4RPGNeutronInelastic::ApplyYourself(), G4RPGLambdaInelastic::ApplyYourself(), G4RPGKZeroInelastic::ApplyYourself(), G4RPGKPlusInelastic::ApplyYourself(), G4RPGKMinusInelastic::ApplyYourself(), G4RPGAntiXiZeroInelastic::ApplyYourself(), G4RPGAntiXiMinusInelastic::ApplyYourself(), G4RPGAntiSigmaPlusInelastic::ApplyYourself(), G4RPGAntiSigmaMinusInelastic::ApplyYourself(), G4RPGAntiProtonInelastic::ApplyYourself(), G4RPGAntiOmegaMinusInelastic::ApplyYourself(), G4RPGAntiNeutronInelastic::ApplyYourself(), G4RPGAntiLambdaInelastic::ApplyYourself(), G4RPGAntiKZeroInelastic::ApplyYourself(), G4NeutronHPFSFissionFS::ApplyYourself(), G4NeutronHPFissionFS::ApplyYourself(), G4NeutronHPElasticFS::ApplyYourself(), G4NeutronHPCaptureFS::ApplyYourself(), G4LEXiZeroInelastic::ApplyYourself(), G4LEXiMinusInelastic::ApplyYourself(), G4LESigmaPlusInelastic::ApplyYourself(), G4LESigmaMinusInelastic::ApplyYourself(), G4LEProtonInelastic::ApplyYourself(), G4LEPionPlusInelastic::ApplyYourself(), G4LEPionMinusInelastic::ApplyYourself(), G4LEOmegaMinusInelastic::ApplyYourself(), G4LENeutronInelastic::ApplyYourself(), G4LENDModel::ApplyYourself(), G4LENDElastic::ApplyYourself(), G4LELambdaInelastic::ApplyYourself(), G4LEKaonZeroInelastic::ApplyYourself(), G4LEKaonPlusInelastic::ApplyYourself(), G4LEKaonMinusInelastic::ApplyYourself(), G4LEAntiXiZeroInelastic::ApplyYourself(), G4LEAntiXiMinusInelastic::ApplyYourself(), G4LEAntiSigmaPlusInelastic::ApplyYourself(), G4LEAntiSigmaMinusInelastic::ApplyYourself(), G4LEAntiProtonInelastic::ApplyYourself(), G4LEAntiOmegaMinusInelastic::ApplyYourself(), G4LEAntiNeutronInelastic::ApplyYourself(), G4LEAntiLambdaInelastic::ApplyYourself(), G4LEAntiKaonZeroInelastic::ApplyYourself(), G4FissionLibrary::ApplyYourself(), G4NeutronHPInelasticBaseFS::BaseApply(), G4RPGInelastic::CalculateMomenta(), G4InelasticInteraction::CalculateMomenta(), G4NeutronHPInelasticCompFS::CompositeApply(), G4ReactionDynamics::GenerateXandPt(), G4NeutronHPThermalBoost::GetThermalEnergy(), G4Nucleus::GetThermalNucleus(), G4RPGReaction::NuclearReaction(), G4ReactionDynamics::NuclearReaction(), G4RPGTwoCluster::ReactionStage(), G4RPGTwoBody::ReactionStage(), G4RPGFragmentation::ReactionStage(), G4RPGReaction::Rotate(), G4NeutronHPNBodyPhaseSpace::Sample(), G4NeutronHPLabAngularEnergy::Sample(), G4NeutronHPIsotropic::Sample(), G4NeutronHPDiscreteTwoBody::Sample(), G4NeutronHPContAngularPar::Sample(), G4NeutronHPAngular::SampleAndUpdate(), SetDefinitionAndUpdateE(), G4ReactionDynamics::TwoBody(), and G4ReactionDynamics::TwoCluster().
void G4ReactionProduct::SetMass | ( | const G4double | mas | ) | [inline] |
Definition at line 144 of file G4ReactionProduct.hh.
Referenced by G4NeutronHPElasticFS::ApplyYourself(), G4LENDModel::ApplyYourself(), G4LENDElastic::ApplyYourself(), G4ReactionDynamics::GenerateXandPt(), G4Nucleus::GetThermalNucleus(), Lorentz(), G4RPGReaction::NuclearReaction(), G4ReactionDynamics::NuclearReaction(), operator+(), operator-(), G4DecayStrongResonances::Propagate(), G4RPGTwoCluster::ReactionStage(), G4RPGTwoBody::ReactionStage(), G4RPGFragmentation::ReactionStage(), G4NeutronHPEnAngCorrelation::Sample(), G4NeutronHPAngular::SampleAndUpdate(), G4ReactionDynamics::TwoBody(), and G4ReactionDynamics::TwoCluster().
void G4ReactionProduct::SetMayBeKilled | ( | const G4bool | f | ) | [inline] |
Definition at line 168 of file G4ReactionProduct.hh.
Referenced by G4ReactionDynamics::ProduceStrangeParticlePairs(), and G4RPGStrangeProduction::ReactionStage().
void G4ReactionProduct::SetMomentum | ( | const G4ThreeVector & | mom | ) | [inline] |
void G4ReactionProduct::SetMomentum | ( | const G4double | z | ) |
Definition at line 166 of file G4ReactionProduct.cc.
Referenced by G4RPGXiZeroInelastic::ApplyYourself(), G4RPGXiMinusInelastic::ApplyYourself(), G4RPGSigmaPlusInelastic::ApplyYourself(), G4RPGSigmaMinusInelastic::ApplyYourself(), G4RPGProtonInelastic::ApplyYourself(), G4RPGOmegaMinusInelastic::ApplyYourself(), G4RPGNeutronInelastic::ApplyYourself(), G4RPGLambdaInelastic::ApplyYourself(), G4RPGKZeroInelastic::ApplyYourself(), G4RPGKPlusInelastic::ApplyYourself(), G4RPGKMinusInelastic::ApplyYourself(), G4RPGAntiXiZeroInelastic::ApplyYourself(), G4RPGAntiXiMinusInelastic::ApplyYourself(), G4RPGAntiSigmaPlusInelastic::ApplyYourself(), G4RPGAntiSigmaMinusInelastic::ApplyYourself(), G4RPGAntiProtonInelastic::ApplyYourself(), G4RPGAntiOmegaMinusInelastic::ApplyYourself(), G4RPGAntiNeutronInelastic::ApplyYourself(), G4RPGAntiLambdaInelastic::ApplyYourself(), G4RPGAntiKZeroInelastic::ApplyYourself(), G4NeutronHPFissionFS::ApplyYourself(), G4NeutronHPElasticFS::ApplyYourself(), G4NeutronHPCaptureFS::ApplyYourself(), G4LEXiZeroInelastic::ApplyYourself(), G4LEXiMinusInelastic::ApplyYourself(), G4LESigmaPlusInelastic::ApplyYourself(), G4LESigmaMinusInelastic::ApplyYourself(), G4LEProtonInelastic::ApplyYourself(), G4LEPionPlusInelastic::ApplyYourself(), G4LEPionMinusInelastic::ApplyYourself(), G4LEOmegaMinusInelastic::ApplyYourself(), G4LENeutronInelastic::ApplyYourself(), G4LENDModel::ApplyYourself(), G4LENDElastic::ApplyYourself(), G4LELambdaInelastic::ApplyYourself(), G4LEKaonZeroInelastic::ApplyYourself(), G4LEKaonPlusInelastic::ApplyYourself(), G4LEKaonMinusInelastic::ApplyYourself(), G4LEAntiXiZeroInelastic::ApplyYourself(), G4LEAntiXiMinusInelastic::ApplyYourself(), G4LEAntiSigmaPlusInelastic::ApplyYourself(), G4LEAntiSigmaMinusInelastic::ApplyYourself(), G4LEAntiProtonInelastic::ApplyYourself(), G4LEAntiOmegaMinusInelastic::ApplyYourself(), G4LEAntiNeutronInelastic::ApplyYourself(), G4LEAntiLambdaInelastic::ApplyYourself(), G4LEAntiKaonZeroInelastic::ApplyYourself(), G4FissionLibrary::ApplyYourself(), G4NeutronHPInelasticBaseFS::BaseApply(), G4ExcitationHandler::BreakItUp(), G4RPGInelastic::CalculateMomenta(), G4InelasticInteraction::CalculateMomenta(), G4NeutronHPInelasticCompFS::CompositeApply(), G4RPGReaction::Defs1(), G4ReactionProduct(), G4ReactionDynamics::GenerateXandPt(), G4NeutronHPDeExGammas::GetDecayGammas(), G4NeutronHPPhotonDist::GetPhotons(), G4VPreCompoundFragment::GetReactionProduct(), G4NeutronHPThermalBoost::GetThermalEnergy(), G4Nucleus::GetThermalNucleus(), G4QGSModel< ParticipantType >::Init(), Lorentz(), G4RPGReaction::MomentumCheck(), G4RPGReaction::NuclearReaction(), G4ReactionDynamics::NuclearReaction(), operator+(), operator-(), G4StringChipsParticleLevelInterface::Propagate(), G4StringChipsInterface::Propagate(), G4QStringChipsParticleLevelInterface::Propagate(), G4GeneratorPrecompoundInterface::Propagate(), G4DecayStrongResonances::Propagate(), G4RPGTwoCluster::ReactionStage(), G4RPGTwoBody::ReactionStage(), G4RPGFragmentation::ReactionStage(), G4RPGReaction::Rotate(), G4NeutronHPNBodyPhaseSpace::Sample(), G4NeutronHPLabAngularEnergy::Sample(), G4NeutronHPIsotropic::Sample(), G4NeutronHPEnAngCorrelation::Sample(), G4NeutronHPDiscreteTwoBody::Sample(), G4NeutronHPContAngularPar::Sample(), G4NeutronHPAngular::SampleAndUpdate(), SetDefinitionAndUpdateE(), SetZero(), G4ReactionDynamics::TwoBody(), and G4ReactionDynamics::TwoCluster().
void G4ReactionProduct::SetNewlyAdded | ( | const G4bool | f | ) | [inline] |
void G4ReactionProduct::SetPositionInNucleus | ( | G4ThreeVector & | aPosition | ) | [inline] |
Definition at line 180 of file G4ReactionProduct.hh.
Referenced by G4ReactionProduct(), operator+(), operator-(), operator=(), and SetZero().
00181 { 00182 positionInNucleus.setX(x); 00183 positionInNucleus.setY(y); 00184 positionInNucleus.setZ(z); 00185 }
void G4ReactionProduct::SetSide | ( | const G4int | sid | ) | [inline] |
Definition at line 156 of file G4ReactionProduct.hh.
Referenced by G4RPGXiZeroInelastic::ApplyYourself(), G4RPGXiMinusInelastic::ApplyYourself(), G4RPGSigmaPlusInelastic::ApplyYourself(), G4RPGSigmaMinusInelastic::ApplyYourself(), G4RPGProtonInelastic::ApplyYourself(), G4RPGOmegaMinusInelastic::ApplyYourself(), G4RPGNeutronInelastic::ApplyYourself(), G4RPGLambdaInelastic::ApplyYourself(), G4RPGKZeroInelastic::ApplyYourself(), G4RPGKPlusInelastic::ApplyYourself(), G4RPGKMinusInelastic::ApplyYourself(), G4RPGAntiXiZeroInelastic::ApplyYourself(), G4RPGAntiXiMinusInelastic::ApplyYourself(), G4RPGAntiSigmaPlusInelastic::ApplyYourself(), G4RPGAntiSigmaMinusInelastic::ApplyYourself(), G4RPGAntiProtonInelastic::ApplyYourself(), G4RPGAntiOmegaMinusInelastic::ApplyYourself(), G4RPGAntiNeutronInelastic::ApplyYourself(), G4RPGAntiLambdaInelastic::ApplyYourself(), G4RPGAntiKZeroInelastic::ApplyYourself(), G4LEXiZeroInelastic::ApplyYourself(), G4LEXiMinusInelastic::ApplyYourself(), G4LESigmaPlusInelastic::ApplyYourself(), G4LESigmaMinusInelastic::ApplyYourself(), G4LEProtonInelastic::ApplyYourself(), G4LEPionPlusInelastic::ApplyYourself(), G4LEPionMinusInelastic::ApplyYourself(), G4LEOmegaMinusInelastic::ApplyYourself(), G4LENeutronInelastic::ApplyYourself(), G4LELambdaInelastic::ApplyYourself(), G4LEKaonZeroInelastic::ApplyYourself(), G4LEKaonPlusInelastic::ApplyYourself(), G4LEKaonMinusInelastic::ApplyYourself(), G4LEAntiXiZeroInelastic::ApplyYourself(), G4LEAntiXiMinusInelastic::ApplyYourself(), G4LEAntiSigmaPlusInelastic::ApplyYourself(), G4LEAntiSigmaMinusInelastic::ApplyYourself(), G4LEAntiProtonInelastic::ApplyYourself(), G4LEAntiOmegaMinusInelastic::ApplyYourself(), G4LEAntiNeutronInelastic::ApplyYourself(), G4LEAntiLambdaInelastic::ApplyYourself(), G4LEAntiKaonZeroInelastic::ApplyYourself(), G4ReactionDynamics::GenerateXandPt(), G4ReactionDynamics::ProduceStrangeParticlePairs(), G4RPGTwoCluster::ReactionStage(), G4RPGStrangeProduction::ReactionStage(), G4RPGFragmentation::ReactionStage(), G4RPGInelastic::SetUpPions(), G4InelasticInteraction::SetUpPions(), and G4ReactionDynamics::TwoCluster().
void G4ReactionProduct::SetTOF | ( | const G4double | t | ) | [inline] |
Definition at line 150 of file G4ReactionProduct.hh.
Referenced by G4RPGTwoBody::ReactionStage(), and G4ReactionDynamics::TwoBody().
void G4ReactionProduct::SetTotalEnergy | ( | const G4double | en | ) | [inline] |
Definition at line 138 of file G4ReactionProduct.hh.
Referenced by G4NeutronHPElasticFS::ApplyYourself(), G4LENDModel::ApplyYourself(), G4LENDElastic::ApplyYourself(), G4NeutronHPInelasticBaseFS::BaseApply(), G4ExcitationHandler::BreakItUp(), G4ReactionDynamics::GenerateXandPt(), G4NeutronHPPhotonDist::GetPhotons(), G4VPreCompoundFragment::GetReactionProduct(), G4Nucleus::GetThermalNucleus(), G4QGSModel< ParticipantType >::Init(), Lorentz(), G4RPGReaction::MomentumCheck(), G4RPGReaction::NuclearReaction(), G4ReactionDynamics::NuclearReaction(), operator+(), operator-(), G4StringChipsParticleLevelInterface::Propagate(), G4StringChipsInterface::Propagate(), G4QStringChipsParticleLevelInterface::Propagate(), G4GeneratorPrecompoundInterface::Propagate(), G4DecayStrongResonances::Propagate(), G4RPGTwoCluster::ReactionStage(), G4RPGTwoBody::ReactionStage(), G4RPGFragmentation::ReactionStage(), G4NeutronHPEnAngCorrelation::Sample(), G4NeutronHPAngular::SampleAndUpdate(), G4ReactionDynamics::TwoBody(), and G4ReactionDynamics::TwoCluster().
void G4ReactionProduct::SetZero | ( | ) |
Definition at line 186 of file G4ReactionProduct.cc.
References SetMomentum(), and SetPositionInNucleus().
Referenced by G4ReactionDynamics::GenerateXandPt().
00187 { 00188 SetMomentum( 0.0, 0.0, 0.0 ); 00189 totalEnergy = 0.0; 00190 kineticEnergy = 0.0; 00191 mass = 0.0; 00192 timeOfFlight = 0.0; 00193 side = 0; 00194 NewlyAdded = false; 00195 SetPositionInNucleus( 0.0, 0.0, 0.0 ); 00196 formationTime = 0.0; 00197 hasInitialStateParton = false; 00198 }
G4ReactionProduct operator * | ( | const G4double | aDouble, | |
const G4ReactionProduct & | p2 | |||
) | [friend] |
Definition at line 59 of file G4ReactionProduct.hh.
00061 { 00062 G4ReactionProduct result; 00063 result.SetMomentum(aDouble*p2.GetMomentum()); 00064 result.SetMass(p2.GetMass()); 00065 result.SetTotalEnergy(std::sqrt(result.GetMass()*result.GetMass()+ 00066 result.GetMomentum()*result.GetMomentum())); 00067 return result; 00068 }
G4ReactionProduct operator+ | ( | const G4ReactionProduct & | p1, | |
const G4ReactionProduct & | p2 | |||
) | [friend] |
Definition at line 236 of file G4ReactionProduct.cc.
00238 { 00239 G4double totEnergy = p1.totalEnergy + p2.totalEnergy; 00240 G4double x = p1.momentum.x() + p2.momentum.x(); 00241 G4double y = p1.momentum.y() + p2.momentum.y(); 00242 G4double z = p1.momentum.z() + p2.momentum.z(); 00243 G4double newMass = totEnergy*totEnergy - ( x*x + y*y + z*z ); 00244 if( newMass < 0.0 ) 00245 newMass = -1. * std::sqrt( -newMass ); 00246 else 00247 newMass = std::sqrt( newMass ); 00248 G4ReactionProduct result; 00249 result.SetMass( newMass ); 00250 result.SetMomentum( x, y, z ); 00251 result.SetTotalEnergy( totEnergy ); 00252 result.SetPositionInNucleus( 0.0, 0.0, 0.0 ); 00253 result.SetFormationTime(0.0); 00254 result.HasInitialStateParton(false); 00255 return result; 00256 }
G4ReactionProduct operator- | ( | const G4ReactionProduct & | p1, | |
const G4ReactionProduct & | p2 | |||
) | [friend] |
Definition at line 258 of file G4ReactionProduct.cc.
00260 { 00261 G4double totEnergy = p1.totalEnergy - p2.totalEnergy; 00262 G4double x = p1.momentum.x() - p2.momentum.x(); 00263 G4double y = p1.momentum.y() - p2.momentum.y(); 00264 G4double z = p1.momentum.z() - p2.momentum.z(); 00265 G4double newMass = totEnergy*totEnergy - ( x*x + y*y + z*z ); 00266 if( newMass < 0.0 ) 00267 newMass = -1. * std::sqrt( -newMass ); 00268 else 00269 newMass = std::sqrt( newMass ); 00270 G4ReactionProduct result; 00271 result.SetMass( newMass ); 00272 result.SetMomentum( x, y, z ); 00273 result.SetTotalEnergy( totEnergy ); 00274 result.SetPositionInNucleus( 0.0, 0.0, 0.0 ); 00275 result.SetFormationTime(0.0); 00276 result.HasInitialStateParton(false); 00277 return result; 00278 }