66 ratio1(1),ratio2(1),delta(0)
93 G4double gamma = energy/electron_mass_c2;
94 G4double beta = std::sqrt((gamma - 1)*(gamma + 1))/gamma;
103 G4double ymax = 2*beta*(1 + beta)*gamma*gamma;
111 y = q*ymax/(1 + ymax*(1 - q));
115 if(gfun > gMax &&
nwarn >= 20) {
117 G4cout <<
"### WARNING in G4Generator2BS: Etot(MeV)= " << energy/
MeV
118 <<
" Egamma(MeV)" << (energy - final_energy)/
MeV
119 <<
" gMax= " << gMax <<
" < " << gfun
120 <<
" results are not reliable!"
123 G4cout <<
" WARNING in G4Generator2BS is closed" <<
G4endl;
131 G4double sint = std::sqrt((1 - cost)*(1 + cost));
143 G4cout <<
"Bremsstrahlung Angular Generator is 2BS Generator "
144 <<
"from 2BS Koch & Motz distribution (Rev Mod Phys 31(4), 920 (1959))" <<
G4endl;
145 G4cout <<
"Sampling algorithm adapted from PIRS-0203" <<
G4endl;
static G4Pow * GetInstance()
G4double RejectionFunction(G4double value) const
CLHEP::Hep3Vector G4ThreeVector
G4double GetTotalEnergy() const
void PrintGeneratorInformation() const
G4GLOB_DLL std::ostream G4cout
G4double Z13(G4int Z) const
const G4ThreeVector & GetMomentumDirection() const
static const double twopi
T max(const T t1, const T t2)
brief Return the largest of the two arguments
G4double energy(const ThreeVector &p, const G4double m)
G4ThreeVector fLocalDirection
G4Generator2BS(const G4String &name="")
virtual G4ThreeVector & SampleDirection(const G4DynamicParticle *dp, G4double out_energy, G4int Z, const G4Material *mat=0)
virtual ~G4Generator2BS()