G4PhaseSpaceDecayChannel Class Reference

#include <G4PhaseSpaceDecayChannel.hh>

Inheritance diagram for G4PhaseSpaceDecayChannel:

G4VDecayChannel

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 G4DecayProductsDecayIt (G4double)

Static Public Member Functions

static G4double Pmx (G4double e, G4double p1, G4double p2)

Detailed Description

Definition at line 45 of file G4PhaseSpaceDecayChannel.hh.


Constructor & Destructor Documentation

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]

Definition at line 76 of file G4PhaseSpaceDecayChannel.cc.

00077 {
00078 }


Member Function Documentation

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 }

G4double G4PhaseSpaceDecayChannel::Pmx ( G4double  e,
G4double  p1,
G4double  p2 
) [static]

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 }


The documentation for this class was generated from the following files:
Generated on Mon May 27 17:52:53 2013 for Geant4 by  doxygen 1.4.7