44 : loopMax(100), parentMass(pMass), mDaughter0(dMass0), mDaughter1(dMass1),
45 mDaughter2(dMass2), pDaughter0(0.), pDaughter1(0.), pDaughter2(0.) {;}
75 energy = rndm2*availableE;
81 energy = (1.-rndm1)*availableE;
87 energy = (rndm1-rndm2)*availableE;
88 pDaughter2 = std::sqrt(energy*energy + 2.0*energy*mDaughter2);
93 }
while ((momentummax > momentumsum - momentummax) && status);
102 std::vector<G4ThreeVector> pVect;
108 G4double sintheta = std::sqrt((1.0-costheta)*(1.0+costheta));
112 G4ThreeVector direction0(sintheta*cosphi, sintheta*sinphi, costheta);
116 G4double sinthetan = std::sqrt((1.0-costhetan)*(1.0+costhetan));
121 direction2.setX(sinthetan*cosphin*costheta*cosphi -
122 sinthetan*sinphin*sinphi + costhetan*sintheta*cosphi);
123 direction2.setY(sinthetan*cosphin*costheta*sinphi +
124 sinthetan*sinphin*cosphi + costhetan*sintheta*sinphi);
125 direction2.setZ(-sinthetan*cosphin*sintheta + costhetan*costheta);
128 pVect.push_back(pDaughter0*direction0);
129 pVect.push_back(-direction0*pDaughter0 - direction2*
pDaughter2);
130 pVect.push_back(pDaughter2*direction2);
134 <<
" or more loops in momentum magnitude calculation " <<
G4endl;
std::vector< G4ThreeVector > GetThreeBodyMomenta()
CLHEP::Hep3Vector G4ThreeVector
G4bool CalculateMomentumMagnitudes()
G4double energy(const ThreeVector &p, const G4double m)
G4GLOB_DLL std::ostream G4cerr