Import Geant4 10.4.0 source tree
This commit is contained in:
+32
-86
@@ -41,8 +41,6 @@
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
|
||||
G4FragmentingString::G4FragmentingString(const G4FragmentingString &old)
|
||||
{
|
||||
LeftParton=old.LeftParton;
|
||||
@@ -54,29 +52,23 @@ G4FragmentingString::G4FragmentingString(const G4FragmentingString &old)
|
||||
theStableParton=old.theStableParton;
|
||||
theDecayParton=old.theDecayParton;
|
||||
decaying=old.decaying;
|
||||
Pstring=old.Pstring;
|
||||
Pleft =old.Pleft;
|
||||
Pright =old.Pright;
|
||||
}
|
||||
|
||||
G4FragmentingString & G4FragmentingString::operator =(const G4FragmentingString &old)
|
||||
{
|
||||
if (this != &old)
|
||||
{
|
||||
LeftParton=old.LeftParton;
|
||||
RightParton=old.RightParton;
|
||||
Ptleft=old.Ptleft;
|
||||
Ptright=old.Ptright;
|
||||
Pplus=old.Pplus;
|
||||
Pminus=old.Pminus;
|
||||
theStableParton=old.theStableParton;
|
||||
theDecayParton=old.theDecayParton;
|
||||
decaying=old.decaying;
|
||||
Pstring=old.Pstring;
|
||||
Pleft =old.Pleft;
|
||||
Pright =old.Pright;
|
||||
}
|
||||
return *this;
|
||||
if (this != &old)
|
||||
{
|
||||
LeftParton=old.LeftParton;
|
||||
RightParton=old.RightParton;
|
||||
Ptleft=old.Ptleft;
|
||||
Ptright=old.Ptright;
|
||||
Pplus=old.Pplus;
|
||||
Pminus=old.Pminus;
|
||||
theStableParton=old.theStableParton;
|
||||
theDecayParton=old.theDecayParton;
|
||||
decaying=old.decaying;
|
||||
}
|
||||
return *this;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
@@ -94,13 +86,9 @@ G4FragmentingString::G4FragmentingString(const G4ExcitedString &excited)
|
||||
Pminus=P.e() - P.pz();
|
||||
theStableParton=0;
|
||||
theDecayParton=0;
|
||||
|
||||
//decaying=None;
|
||||
if(excited.GetDirection() > 0) {decaying=Left; }
|
||||
else {decaying=Right;}
|
||||
|
||||
Pleft = excited.GetLeftParton()->Get4Momentum();
|
||||
Pright = excited.GetRightParton()->Get4Momentum();
|
||||
Pstring= Pleft + Pright;
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
@@ -110,65 +98,38 @@ G4FragmentingString::G4FragmentingString(const G4FragmentingString &old,
|
||||
const G4LorentzVector *momentum)
|
||||
{
|
||||
decaying=None;
|
||||
G4LorentzVector Momentum = G4LorentzVector(momentum->vect(),momentum->e());
|
||||
// Momentum of produced hadron
|
||||
//G4cout<<"Had Mom "<<Momentum<<G4endl;
|
||||
//G4cout<<"Str Mom "<<old.Pstring<<G4endl;
|
||||
Pstring = old.Pstring - Momentum;
|
||||
//G4cout<<"New Str Mom "<<Pstring<<" "<<Pstring.mag()<<G4endl;
|
||||
|
||||
G4double StringMass = Pstring.mag();
|
||||
|
||||
G4LorentzRotation toLAB(Pstring.boostVector());
|
||||
|
||||
Pleft = toLAB*G4LorentzVector(0.,0., StringMass/2.,StringMass/2.);
|
||||
Pright = toLAB*G4LorentzVector(0.,0.,-StringMass/2.,StringMass/2.);
|
||||
|
||||
Ptleft =Pleft.vect(); Ptleft.setZ(0.);
|
||||
Ptright=Pright.vect(); Ptright.setZ(0.);
|
||||
|
||||
//G4cout<<"Pleft "<<Pleft<<G4endl;
|
||||
//G4cout<<"Pright "<<Pright<<G4endl;
|
||||
//G4cout<<"Pstring "<<Pstring<<G4endl;
|
||||
if ( old.decaying == Left )
|
||||
{
|
||||
RightParton= old.RightParton;
|
||||
// Ptright = old.Ptright;
|
||||
//Pright = old.Pright;
|
||||
|
||||
Ptright = old.Ptright;
|
||||
LeftParton = newdecay;
|
||||
// Ptleft = old.Ptleft - momentum->vect();
|
||||
// Ptleft.setZ(0.);
|
||||
//Pleft = old.Pleft - Momentum;
|
||||
//Pstring=Pleft + Pright;
|
||||
|
||||
Ptleft = old.Ptleft - momentum->vect();
|
||||
Ptleft.setZ(0.);
|
||||
theDecayParton=GetLeftParton();
|
||||
theStableParton=GetRightParton();
|
||||
decaying=Left;
|
||||
} else if ( old.decaying == Right )
|
||||
{
|
||||
RightParton = newdecay;
|
||||
// Ptright = old.Ptright - momentum->vect();
|
||||
// Ptright.setZ(0.);
|
||||
//Pright = old.Pright + Momentum;
|
||||
|
||||
Ptright = old.Ptright - momentum->vect();
|
||||
Ptright.setZ(0.);
|
||||
LeftParton = old.LeftParton;
|
||||
// Ptleft = old.Ptleft;
|
||||
//Pleft = old.Pleft;
|
||||
//Pstring=Pleft + Pright;
|
||||
|
||||
Ptleft = old.Ptleft;
|
||||
theDecayParton=GetRightParton();
|
||||
theStableParton=GetLeftParton();
|
||||
decaying=Right;
|
||||
} else
|
||||
{
|
||||
throw G4HadronicException(__FILE__, __LINE__, "G4FragmentingString::G4FragmentingString: no decay Direction defined");
|
||||
throw G4HadronicException(__FILE__, __LINE__,
|
||||
"G4FragmentingString::G4FragmentingString: no decay Direction defined");
|
||||
}
|
||||
Pplus = Pstring.plus(); //old.Pplus - (momentum->e() + momentum->pz());
|
||||
Pminus = Pstring.minus();//old.Pminus - (momentum->e() - momentum->pz());
|
||||
Pplus = old.Pplus - (momentum->e() + momentum->pz());
|
||||
Pminus = old.Pminus - (momentum->e() - momentum->pz());
|
||||
|
||||
//G4double Eold=0.5 * (old.Pplus + old.Pminus);
|
||||
//G4double Enew=0.5 * (Pplus + Pminus);
|
||||
}
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
|
||||
G4FragmentingString::G4FragmentingString(const G4FragmentingString &old,
|
||||
@@ -181,10 +142,6 @@ G4FragmentingString::G4FragmentingString(const G4FragmentingString &old,
|
||||
Pplus=0.; Pminus=0.;
|
||||
theStableParton=0; theDecayParton=0;
|
||||
|
||||
Pstring=G4LorentzVector(0.,0.,0.,0.);
|
||||
Pleft =G4LorentzVector(0.,0.,0.,0.);
|
||||
Pright =G4LorentzVector(0.,0.,0.,0.);
|
||||
|
||||
if ( old.decaying == Left )
|
||||
{
|
||||
RightParton= old.RightParton;
|
||||
@@ -197,17 +154,16 @@ Pright =G4LorentzVector(0.,0.,0.,0.);
|
||||
decaying=Right;
|
||||
} else
|
||||
{
|
||||
throw G4HadronicException(__FILE__, __LINE__, "G4FragmentingString::G4FragmentingString: no decay Direction defined");
|
||||
throw G4HadronicException(__FILE__, __LINE__,
|
||||
"G4FragmentingString::G4FragmentingString: no decay Direction defined");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
|
||||
G4FragmentingString::~G4FragmentingString()
|
||||
{}
|
||||
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
|
||||
void G4FragmentingString::SetLeftPartonStable()
|
||||
@@ -241,7 +197,7 @@ G4int G4FragmentingString::GetDecayDirection() const
|
||||
G4bool G4FragmentingString::FourQuarkString() const
|
||||
{
|
||||
return LeftParton->GetParticleSubType()== "di_quark"
|
||||
&& RightParton->GetParticleSubType()== "di_quark";
|
||||
&& RightParton->GetParticleSubType()== "di_quark";
|
||||
}
|
||||
|
||||
//---------------------------------------------------------------------------------
|
||||
@@ -305,14 +261,12 @@ G4LorentzVector G4FragmentingString::Get4Momentum() const
|
||||
|
||||
G4double G4FragmentingString::Mass2() const
|
||||
{
|
||||
// return Pplus*Pminus - (Ptleft+Ptright).mag2();
|
||||
return Pstring.mag2();
|
||||
return Pplus*Pminus - (Ptleft+Ptright).mag2();
|
||||
}
|
||||
|
||||
G4double G4FragmentingString::Mass() const
|
||||
{
|
||||
// return std::sqrt(this->Mass2());
|
||||
return Pstring.mag();
|
||||
return std::sqrt(this->Mass2());
|
||||
}
|
||||
|
||||
G4double G4FragmentingString::MassT2() const
|
||||
@@ -320,11 +274,3 @@ G4double G4FragmentingString::MassT2() const
|
||||
return Pplus*Pminus;
|
||||
}
|
||||
|
||||
G4LorentzVector G4FragmentingString::GetPstring()
|
||||
{return Pstring;}
|
||||
|
||||
G4LorentzVector G4FragmentingString::GetPleft()
|
||||
{return Pleft;}
|
||||
|
||||
G4LorentzVector G4FragmentingString::GetPright()
|
||||
{return Pright;}
|
||||
|
||||
Reference in New Issue
Block a user