Geant4  10.03.p02
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
G4eeToTwoPiModel Class Reference

#include <G4eeToTwoPiModel.hh>

Inheritance diagram for G4eeToTwoPiModel:
Collaboration diagram for G4eeToTwoPiModel:

Public Member Functions

 G4eeToTwoPiModel (G4eeCrossSections *, G4double, G4double)
 
virtual ~G4eeToTwoPiModel ()
 
virtual G4double PeakEnergy () const override
 
virtual G4double ComputeCrossSection (G4double) const override
 
virtual void SampleSecondaries (std::vector< G4DynamicParticle * > *, G4double, const G4ThreeVector &) override
 
- Public Member Functions inherited from G4Vee2hadrons
 G4Vee2hadrons (G4eeCrossSections *cr, G4double vlowEnergy, G4double vhighEnergy, G4double vdelta)
 
virtual ~G4Vee2hadrons ()
 
G4PhysicsVectorPhysicsVector () const
 
G4double LowEnergy () const
 
G4double HighEnergy () const
 

Additional Inherited Members

- Protected Attributes inherited from G4Vee2hadrons
G4eeCrossSectionscross
 

Detailed Description

Definition at line 59 of file G4eeToTwoPiModel.hh.

Constructor & Destructor Documentation

G4eeToTwoPiModel::G4eeToTwoPiModel ( G4eeCrossSections cr,
G4double  maxkinEnergy,
G4double  binWidth 
)
explicit

Definition at line 64 of file G4eeToTwoPiModel.cc.

67 : G4Vee2hadrons(cr,
68  2.0*G4PionPlus::PionPlus()->GetPDGMass(),
69  maxkinEnergy,
70  binWidth)
71 {
72  G4cout << "#####G4eeToTwoPiModel####" << G4endl;
73 
74  massPi = G4PionPlus::PionPlus()->GetPDGMass();
75  massRho = 775.5*MeV;
76 }
G4GLOB_DLL std::ostream G4cout
static G4PionPlus * PionPlus()
Definition: G4PionPlus.cc:98
G4Vee2hadrons(G4eeCrossSections *cr, G4double vlowEnergy, G4double vhighEnergy, G4double vdelta)
G4double GetPDGMass() const
#define G4endl
Definition: G4ios.hh:61
static constexpr double MeV
Definition: G4SIunits.hh:214

Here is the call graph for this function:

G4eeToTwoPiModel::~G4eeToTwoPiModel ( )
virtual

Definition at line 80 of file G4eeToTwoPiModel.cc.

81 {}

Member Function Documentation

G4double G4eeToTwoPiModel::ComputeCrossSection ( G4double  e) const
overridevirtual

Implements G4Vee2hadrons.

Definition at line 92 of file G4eeToTwoPiModel.cc.

93 {
94  return cross->CrossSection2pi(e);
95 }
G4double CrossSection2pi(G4double)
G4eeCrossSections * cross

Here is the call graph for this function:

G4double G4eeToTwoPiModel::PeakEnergy ( ) const
overridevirtual

Implements G4Vee2hadrons.

Definition at line 85 of file G4eeToTwoPiModel.cc.

86 {
87  return massRho;
88 }
void G4eeToTwoPiModel::SampleSecondaries ( std::vector< G4DynamicParticle * > *  newp,
G4double  e,
const G4ThreeVector direction 
)
overridevirtual

Implements G4Vee2hadrons.

Definition at line 99 of file G4eeToTwoPiModel.cc.

101 {
102 
103  G4double tkin = 0.5*e - massPi;
104  if(tkin < 0.0) tkin = 0.0;
105  G4double cost;
106  do {
107  cost = 2.0*G4UniformRand() - 1.0;
108  // Loop checking, 07-Aug-2015, Vladimir Ivanchenko
109  } while( G4UniformRand() > 1.0 - cost*cost );
110 
111  G4double sint = sqrt(1.0 - cost*cost);
112  G4double phi = twopi * G4UniformRand();
113 
114  G4ThreeVector dir(sint*cos(phi),sint*sin(phi), cost);
115  dir.rotateUz(direction);
116 
117  // create G4DynamicParticle objects
119  new G4DynamicParticle(G4PionPlus::PionPlus(),dir,tkin);
120  G4DynamicParticle* pin =
121  new G4DynamicParticle(G4PionMinus::PionMinus(),-dir,tkin);
122  newp->push_back(pip);
123  newp->push_back(pin);
124 }
static constexpr double twopi
Definition: G4SIunits.hh:76
#define G4UniformRand()
Definition: Randomize.hh:97
static G4PionPlus * PionPlus()
Definition: G4PionPlus.cc:98
static G4PionMinus * PionMinus()
Definition: G4PionMinus.cc:98
double G4double
Definition: G4Types.hh:76

Here is the call graph for this function:


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