#include <G4PhaseSpaceDecayChannel.hh>
Inheritance diagram for G4PhaseSpaceDecayChannel:
Public Member Functions | |
G4PhaseSpaceDecayChannel (G4int Verbose=1) | |
G4PhaseSpaceDecayChannel (const G4String &theParentName, G4double theBR, G4int theNumberOfDaughters, const G4String &theDaughterName1, const G4String &theDaughterName2="", const G4String &theDaughterName3="", const G4String &theDaughterName4="") | |
virtual | ~G4PhaseSpaceDecayChannel () |
virtual G4DecayProducts * | DecayIt (G4double) |
Static Public Member Functions | |
static G4double | Pmx (G4double e, G4double p1, G4double p2) |
Definition at line 45 of file G4PhaseSpaceDecayChannel.hh.
G4PhaseSpaceDecayChannel::G4PhaseSpaceDecayChannel | ( | G4int | Verbose = 1 |
) |
Definition at line 50 of file G4PhaseSpaceDecayChannel.cc.
00051 :G4VDecayChannel("Phase Space", Verbose) 00052 { 00053 00054 }
G4PhaseSpaceDecayChannel::G4PhaseSpaceDecayChannel | ( | const G4String & | theParentName, | |
G4double | theBR, | |||
G4int | theNumberOfDaughters, | |||
const G4String & | theDaughterName1, | |||
const G4String & | theDaughterName2 = "" , |
|||
const G4String & | theDaughterName3 = "" , |
|||
const G4String & | theDaughterName4 = "" | |||
) |
Definition at line 56 of file G4PhaseSpaceDecayChannel.cc.
00064 :G4VDecayChannel("Phase Space", 00065 theParentName,theBR, 00066 theNumberOfDaughters, 00067 theDaughterName1, 00068 theDaughterName2, 00069 theDaughterName3, 00070 theDaughterName4), 00071 current_parent_mass(0.0) 00072 { 00073 00074 }
G4PhaseSpaceDecayChannel::~G4PhaseSpaceDecayChannel | ( | ) | [virtual] |
G4DecayProducts * G4PhaseSpaceDecayChannel::DecayIt | ( | G4double | ) | [virtual] |
Implements G4VDecayChannel.
Definition at line 80 of file G4PhaseSpaceDecayChannel.cc.
References G4VDecayChannel::daughters, G4VDecayChannel::DumpInfo(), G4VDecayChannel::FillDaughters(), G4VDecayChannel::FillParent(), G4cout, G4endl, G4VDecayChannel::GetVerboseLevel(), G4VDecayChannel::numberOfDaughters, G4VDecayChannel::parent, G4VDecayChannel::parent_mass, and G4VDecayChannel::parent_name.
00081 { 00082 #ifdef G4VERBOSE 00083 if (GetVerboseLevel()>1) G4cout << "G4PhaseSpaceDecayChannel::DecayIt "; 00084 #endif 00085 00086 G4DecayProducts * products = 0; 00087 00088 if (parent == 0) FillParent(); 00089 if (daughters == 0) FillDaughters(); 00090 00091 if (parentMass >0.0) current_parent_mass = parentMass; 00092 else current_parent_mass = parent_mass; 00093 00094 switch (numberOfDaughters){ 00095 case 0: 00096 #ifdef G4VERBOSE 00097 if (GetVerboseLevel()>0) { 00098 G4cout << "G4PhaseSpaceDecayChannel::DecayIt "; 00099 G4cout << " daughters not defined " <<G4endl; 00100 } 00101 #endif 00102 break; 00103 case 1: 00104 products = OneBodyDecayIt(); 00105 break; 00106 case 2: 00107 products = TwoBodyDecayIt(); 00108 break; 00109 case 3: 00110 products = ThreeBodyDecayIt(); 00111 break; 00112 default: 00113 products = ManyBodyDecayIt(); 00114 break; 00115 } 00116 #ifdef G4VERBOSE 00117 if ((products == 0) && (GetVerboseLevel()>0)) { 00118 G4cout << "G4PhaseSpaceDecayChannel::DecayIt "; 00119 G4cout << *parent_name << " can not decay " << G4endl; 00120 DumpInfo(); 00121 } 00122 #endif 00123 return products; 00124 }
Definition at line 563 of file G4PhaseSpaceDecayChannel.cc.
Referenced by G4DalitzDecayChannel::DecayIt().
00564 { 00565 // calcurate momentum of daughter particles in two-body decay 00566 G4double ppp = (e+p1+p2)*(e+p1-p2)*(e-p1+p2)*(e-p1-p2)/(4.0*e*e); 00567 if (ppp>0) return std::sqrt(ppp); 00568 else return -1.; 00569 }