Geant4.10
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Public Member Functions
G4FragmentingString Class Reference

#include <G4FragmentingString.hh>

Public Member Functions

 G4FragmentingString (const G4FragmentingString &right)
 
 G4FragmentingString (const G4ExcitedString &excited)
 
 G4FragmentingString (const G4FragmentingString &old, G4ParticleDefinition *newdecay, const G4LorentzVector *momentum)
 
 G4FragmentingString (const G4FragmentingString &old, G4ParticleDefinition *newdecay)
 
 ~G4FragmentingString ()
 
G4FragmentingStringoperator= (const G4FragmentingString &)
 
int operator== (const G4FragmentingString &right) const
 
int operator!= (const G4FragmentingString &right) const
 
G4LorentzVector Get4Momentum () const
 
G4ThreeVector StablePt ()
 
G4ThreeVector DecayPt ()
 
G4double LightConePlus ()
 
G4double LightConeMinus ()
 
G4double LightConeDecay ()
 
G4double Mass () const
 
G4double Mass2 () const
 
G4double MassT2 () const
 
G4ParticleDefinitionGetLeftParton (void) const
 
G4ParticleDefinitionGetRightParton (void) const
 
G4ParticleDefinitionGetStableParton () const
 
G4ParticleDefinitionGetDecayParton () const
 
void SetLeftPartonStable ()
 
void SetRightPartonStable ()
 
G4int GetDecayDirection () const
 
G4bool DecayIsQuark ()
 
G4bool StableIsQuark ()
 
G4bool FourQuarkString (void) const
 

Detailed Description

Definition at line 49 of file G4FragmentingString.hh.

Constructor & Destructor Documentation

G4FragmentingString::G4FragmentingString ( const G4FragmentingString right)

Definition at line 46 of file G4FragmentingString.cc.

47 {
48  LeftParton=old.LeftParton;
49  RightParton=old.RightParton;
50  Ptleft=old.Ptleft;
51  Ptright=old.Ptright;
52  Pplus=old.Pplus;
53  Pminus=old.Pminus;
54  theStableParton=old.theStableParton;
55  theDecayParton=old.theDecayParton;
56  decaying=old.decaying;
57 }
G4FragmentingString::G4FragmentingString ( const G4ExcitedString excited)

Definition at line 78 of file G4FragmentingString.cc.

References CLHEP::HepLorentzVector::e(), G4Parton::Get4Momentum(), G4ExcitedString::Get4Momentum(), G4Parton::GetDefinition(), G4ExcitedString::GetLeftParton(), G4ExcitedString::GetRightParton(), CLHEP::HepLorentzVector::pz(), CLHEP::Hep3Vector::setZ(), and CLHEP::HepLorentzVector::vect().

79 {
80  LeftParton=excited.GetLeftParton()->GetDefinition();
81  RightParton=excited.GetRightParton()->GetDefinition();
82  Ptleft=excited.GetLeftParton()->Get4Momentum().vect();
83  Ptleft.setZ(0.);
84  Ptright=excited.GetRightParton()->Get4Momentum().vect();
85  Ptright.setZ(0.);
86  G4LorentzVector P=excited.Get4Momentum();
87  Pplus =P.e() + P.pz();
88  Pminus=P.e() - P.pz();
89  theStableParton=0;
90  theDecayParton=0;
91  decaying=None;
92 }
const G4LorentzVector & Get4Momentum() const
Definition: G4Parton.hh:140
G4Parton * GetLeftParton(void) const
G4ParticleDefinition * GetDefinition()
Definition: G4Parton.hh:158
void setZ(double)
Hep3Vector vect() const
G4LorentzVector Get4Momentum() const
G4Parton * GetRightParton(void) const
double pz() const
G4FragmentingString::G4FragmentingString ( const G4FragmentingString old,
G4ParticleDefinition newdecay,
const G4LorentzVector momentum 
)

Definition at line 96 of file G4FragmentingString.cc.

References CLHEP::HepLorentzVector::e(), GetLeftParton(), GetRightParton(), CLHEP::HepLorentzVector::pz(), CLHEP::Hep3Vector::setZ(), and CLHEP::HepLorentzVector::vect().

99 {
100  decaying=None;
101  if ( old.decaying == Left )
102  {
103  RightParton= old.RightParton;
104  Ptright = old.Ptright;
105  LeftParton = newdecay;
106  Ptleft = old.Ptleft - momentum->vect();
107  Ptleft.setZ(0.);
108  theDecayParton=GetLeftParton();
109  theStableParton=GetRightParton();
110  } else if ( old.decaying == Right )
111  {
112  RightParton = newdecay;
113  Ptright = old.Ptright - momentum->vect();
114  Ptright.setZ(0.);
115  LeftParton = old.LeftParton;
116  Ptleft = old.Ptleft;
117  theDecayParton=GetRightParton();
118  theStableParton=GetLeftParton();
119  } else
120  {
121  throw G4HadronicException(__FILE__, __LINE__, "G4FragmentingString::G4FragmentingString: no decay Direction defined");
122  }
123  Pplus = old.Pplus - (momentum->e() + momentum->pz());
124  Pminus = old.Pminus - (momentum->e() - momentum->pz());
125 
126  //G4double Eold=0.5 * (old.Pplus + old.Pminus);
127  //G4double Enew=0.5 * (Pplus + Pminus);
128 }
G4ParticleDefinition * GetRightParton(void) const
void setZ(double)
G4ParticleDefinition * GetLeftParton(void) const
Hep3Vector vect() const
double pz() const
G4FragmentingString::G4FragmentingString ( const G4FragmentingString old,
G4ParticleDefinition newdecay 
)

Definition at line 133 of file G4FragmentingString.cc.

References CLHEP::Hep3Vector::setX(), CLHEP::Hep3Vector::setY(), and CLHEP::Hep3Vector::setZ().

135 {
136  decaying=None;
137 
138  Ptleft.setX(0.); Ptleft.setY(0.); Ptleft.setZ(0.); // Uzhi 25.02.2011
139  Ptright.setX(0.); Ptright.setY(0.); Ptright.setZ(0.); // Uzhi 25.02.2011
140  Pplus=0.; Pminus=0.; // Uzhi 25.02.2011
141  theStableParton=0; theDecayParton=0; // Uzhi 25.02.2011
142 
143  if ( old.decaying == Left )
144  {
145  RightParton= old.RightParton;
146  LeftParton = newdecay;
147  } else if ( old.decaying == Right )
148  {
149  RightParton = newdecay;
150  LeftParton = old.LeftParton;
151  } else
152  {
153  throw G4HadronicException(__FILE__, __LINE__, "G4FragmentingString::G4FragmentingString: no decay Direction defined");
154  }
155 }
void setY(double)
void setZ(double)
void setX(double)
G4FragmentingString::~G4FragmentingString ( )

Definition at line 160 of file G4FragmentingString.cc.

161 {}

Member Function Documentation

G4bool G4FragmentingString::DecayIsQuark ( )

Definition at line 202 of file G4FragmentingString.cc.

References G4ParticleDefinition::GetParticleSubType().

Referenced by G4VLongitudinalStringDecay::Splitup().

203 {
204  return theDecayParton->GetParticleSubType()== "quark";
205 }
const G4String & GetParticleSubType() const
G4ThreeVector G4FragmentingString::DecayPt ( )

Definition at line 222 of file G4FragmentingString.cc.

223 {
224  if (decaying == Left ) return Ptleft;
225  else if (decaying == Right ) return Ptright;
226  else throw G4HadronicException(__FILE__, __LINE__, "G4FragmentingString::DecayPt: decay side UNdefined!");
227  return G4ThreeVector();
228 }
CLHEP::Hep3Vector G4ThreeVector
G4bool G4FragmentingString::FourQuarkString ( void  ) const

Definition at line 194 of file G4FragmentingString.cc.

References G4ParticleDefinition::GetParticleSubType().

Referenced by G4VLongitudinalStringDecay::FragmentationMass().

195 {
196  return LeftParton->GetParticleSubType()== "di_quark"
197  && RightParton->GetParticleSubType()== "di_quark";
198 }
const G4String & GetParticleSubType() const
G4LorentzVector G4FragmentingString::Get4Momentum ( ) const

Definition at line 252 of file G4FragmentingString.cc.

References CLHEP::HepLorentzVector::setE(), and CLHEP::HepLorentzVector::setPz().

253 {
254  G4LorentzVector momentum(Ptleft+Ptright,0);
255  momentum.setPz(0.5*(Pplus-Pminus));
256  momentum.setE(0.5*(Pplus+Pminus));
257  return momentum;
258 }
G4int G4FragmentingString::GetDecayDirection ( ) const

Definition at line 184 of file G4FragmentingString.cc.

Referenced by G4QGSMFragmentation::FragmentString().

185 {
186  if (decaying == Left ) return +1;
187  else if (decaying == Right) return -1;
188  else throw G4HadronicException(__FILE__, __LINE__, "G4FragmentingString::GetDecayDirection: decay side UNdefined!");
189  return 0;
190 }
G4ParticleDefinition * G4FragmentingString::GetDecayParton ( ) const
inline

Definition at line 131 of file G4FragmentingString.hh.

Referenced by G4VLongitudinalStringDecay::Splitup().

132 {
133  return theDecayParton;
134 }
G4ParticleDefinition * G4FragmentingString::GetLeftParton ( void  ) const
inline

Definition at line 137 of file G4FragmentingString.hh.

Referenced by G4VLongitudinalStringDecay::FragmentationMass(), G4FragmentingString(), SetLeftPartonStable(), and SetRightPartonStable().

138  {
139  return LeftParton;
140  }
G4ParticleDefinition * G4FragmentingString::GetRightParton ( void  ) const
inline

Definition at line 143 of file G4FragmentingString.hh.

Referenced by G4VLongitudinalStringDecay::FragmentationMass(), G4FragmentingString(), SetLeftPartonStable(), and SetRightPartonStable().

144  {
145  return RightParton;
146  }
G4ParticleDefinition * G4FragmentingString::GetStableParton ( ) const
inline

Definition at line 125 of file G4FragmentingString.hh.

126 {
127  return theStableParton;
128 }
G4double G4FragmentingString::LightConeDecay ( )

Definition at line 242 of file G4FragmentingString.cc.

243 {
244  if (decaying == Left ) return Pplus;
245  else if (decaying == Right ) return Pminus;
246  else throw G4HadronicException(__FILE__, __LINE__, "G4FragmentingString::DecayPt: decay side UNdefined!");
247  return 0;
248 }
G4double G4FragmentingString::LightConeMinus ( )

Definition at line 237 of file G4FragmentingString.cc.

238 {
239  return Pminus;
240 }
G4double G4FragmentingString::LightConePlus ( )

Definition at line 232 of file G4FragmentingString.cc.

233 {
234  return Pplus;
235 }
G4double G4FragmentingString::Mass ( ) const

Definition at line 265 of file G4FragmentingString.cc.

References Mass2().

266 {
267  return std::sqrt(this->Mass2());
268 }
G4double Mass2() const
G4double G4FragmentingString::Mass2 ( ) const

Definition at line 260 of file G4FragmentingString.cc.

Referenced by G4VLongitudinalStringDecay::LightFragmentationTest(), and Mass().

261 {
262  return Pplus*Pminus - (Ptleft+Ptright).mag2();
263 }
G4double G4FragmentingString::MassT2 ( ) const

Definition at line 270 of file G4FragmentingString.cc.

271 {
272  return Pplus*Pminus;
273 }
int G4FragmentingString::operator!= ( const G4FragmentingString right) const
inline

Definition at line 118 of file G4FragmentingString.hh.

References right.

119 {
120  return this != &right;
121 }
G4FragmentingString & G4FragmentingString::operator= ( const G4FragmentingString old)

Definition at line 59 of file G4FragmentingString.cc.

60 {
61  if (this != &old)
62  {
63  LeftParton=old.LeftParton;
64  RightParton=old.RightParton;
65  Ptleft=old.Ptleft;
66  Ptright=old.Ptright;
67  Pplus=old.Pplus;
68  Pminus=old.Pminus;
69  theStableParton=old.theStableParton;
70  theDecayParton=old.theDecayParton;
71  decaying=old.decaying;
72  }
73  return *this;
74 }
int G4FragmentingString::operator== ( const G4FragmentingString right) const
inline

Definition at line 112 of file G4FragmentingString.hh.

References right.

113 {
114  return this == &right;
115 }
void G4FragmentingString::SetLeftPartonStable ( )

Definition at line 166 of file G4FragmentingString.cc.

References GetLeftParton(), and GetRightParton().

167 {
168  theStableParton=GetLeftParton();
169  theDecayParton=GetRightParton();
170  decaying=Right;
171 }
G4ParticleDefinition * GetRightParton(void) const
G4ParticleDefinition * GetLeftParton(void) const
void G4FragmentingString::SetRightPartonStable ( )

Definition at line 175 of file G4FragmentingString.cc.

References GetLeftParton(), and GetRightParton().

176 {
177  theStableParton=GetRightParton();
178  theDecayParton=GetLeftParton();
179  decaying=Left;
180 }
G4ParticleDefinition * GetRightParton(void) const
G4ParticleDefinition * GetLeftParton(void) const
G4bool G4FragmentingString::StableIsQuark ( )

Definition at line 207 of file G4FragmentingString.cc.

References G4ParticleDefinition::GetParticleSubType().

208 {
209  return theStableParton->GetParticleSubType()== "quark";
210 }
const G4String & GetParticleSubType() const
G4ThreeVector G4FragmentingString::StablePt ( )

Definition at line 214 of file G4FragmentingString.cc.

215 {
216  if (decaying == Left ) return Ptright;
217  else if (decaying == Right ) return Ptleft;
218  else throw G4HadronicException(__FILE__, __LINE__, "G4FragmentingString::DecayPt: decay side UNdefined!");
219  return G4ThreeVector();
220 }
CLHEP::Hep3Vector G4ThreeVector

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