Geant4  9.6.p02
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
G4Quasmon.hh
Go to the documentation of this file.
1 //
2 // ********************************************************************
3 // * License and Disclaimer *
4 // * *
5 // * The Geant4 software is copyright of the Copyright Holders of *
6 // * the Geant4 Collaboration. It is provided under the terms and *
7 // * conditions of the Geant4 Software License, included in the file *
8 // * LICENSE and available at http://cern.ch/geant4/license . These *
9 // * include a list of copyright holders. *
10 // * *
11 // * Neither the authors of this software system, nor their employing *
12 // * institutes,nor the agencies providing financial support for this *
13 // * work make any representation or warranty, express or implied, *
14 // * regarding this software system or assume any liability for its *
15 // * use. Please see the license in the file LICENSE and URL above *
16 // * for the full disclaimer and the limitation of liability. *
17 // * *
18 // * This code implementation is the result of the scientific and *
19 // * technical work of the GEANT4 collaboration. *
20 // * By using, copying, modifying or distributing the software (or *
21 // * any work based on the software) you agree to acknowledge its *
22 // * use in resulting scientific publications, and indicate your *
23 // * acceptance of all terms of the Geant4 Software license. *
24 // ********************************************************************
25 //
26 //
27 // $Id$
28 //
29 // ---------------- G4Quasmon ----------------
30 // by Mikhail Kossov, July 1999.
31 // class for a Quasmon used by the CHIPS Model
32 // ------------------------------------------------------------
33 // Short description: If partons from the G4QPartonPair are close in
34 // rapidity, they create Quasmons, but if they are far in the rapidity
35 // space, they can not interact directly. Say the bottom parton (quark)
36 // has rapidity 0, and the top parton (antiquark) has rapidity 8, then
37 // the top quark splits in two by radiating gluon, and each part has
38 // rapidity 4, then the gluon splits in quark-antiquark pair (rapidity
39 // 2 each), and then the quark gadiates anothe gluon and reachs rapidity
40 // 1. Now it can interact with the bottom antiquark, creating a Quasmon
41 // or a hadron. The intermediate partons is the string ladder.
42 // ---------------------------------------------------------------------
43 
44 #ifndef G4Quasmon_h
45 #define G4Quasmon_h 1
46 
47 // Standard G4-headers
48 #include "G4ios.hh"
49 #include "globals.hh"
50 #include "G4ThreeVector.hh"
51 #include "G4LorentzVector.hh"
52 #include "G4LorentzRotation.hh"
53 //CHIPS-headers
54 #include "G4QCHIPSWorld.hh"
55 #include "G4QChipolino.hh"
56 #include "G4QHadronVector.hh"
57 #include "G4QNucleus.hh"
58 
59 class G4Quasmon
60 {
61 public:
62  G4Quasmon(G4QContent qQCont = G4QContent(0,0,0,0,0,0),
63  G4LorentzVector q4M = G4LorentzVector(0.,0.,0.,0.),
64  G4LorentzVector ph4M = G4LorentzVector(0.,0.,0.,0.));// Direct Constructor
65  G4Quasmon(const G4Quasmon& right); // Copy Quasmon by object
66  G4Quasmon(G4Quasmon* right); // Copy Quasmon by pointer
67 
68  ~G4Quasmon(); // Public Destructor
69 
70  // Overloaded Operators
71  const G4Quasmon& operator=(const G4Quasmon& right);
72  G4bool operator==(const G4Quasmon &right) const;
73  G4bool operator!=(const G4Quasmon &right) const;
74 
75  // Static functions
76  static void SetParameters(G4double temper=180., G4double ssin2g=.3, G4double etaetap=.3);
77  static void SetTemper(G4double temperature);
78  static void SetSOverU(G4double ssin2g);
79  static void SetEtaSup(G4double etaetap);
80  static void OpenElectromagneticDecays();
81  static void CloseElectromagneticDecays();
82 
83  //Selectors
84  G4double GetTemper() const;
85  G4double GetSOverU() const;
86  G4double GetEtaSup() const;
88  G4QContent GetQC() const;
89  G4QPDGCode GetQPDG() const;
90  G4int GetStatus() const;
91  G4int GetCharge() const;
92  G4int GetBaryonNumber() const;
93  G4int GetStrangeness() const;
94 
95  //Modifiers
96  void Set4Momentum(G4LorentzVector Q4M) {q4Mom=Q4M;} // Set new value for the Quasmon 4mom
97  void SetQC(G4QContent QQC) {valQ=QQC;} // Set new Quark Cont for the Quasmon
98  void Boost(const G4LorentzVector& theBoost); // Boosts hadron's 4Momentum using 4M
99  void Boost(const G4ThreeVector& B){q4Mom.boost(B);} // Boosts 4-Momentum using v/c
100  // Public wrapper for HadronizeQuasmon(,)
101  G4QHadronVector* Fragment(G4QNucleus& nucEnviron, G4int nQ = 1);
102  G4QHadronVector* DecayQuasmon(); // Decay Quasmon if it's Res or Chipo
103  G4QHadronVector* DecayQHadron(G4QHadron* hadron); // Decay QHadron if it's Res or Chipo
104  void ClearOutput(); // Clear but not destroy the output
105  void InitQuasmon(const G4QContent& qQCont, const G4LorentzVector& q4M);
106  void IncreaseBy(const G4Quasmon* pQuasm); // as operator+= but by pointer
107  void IncreaseBy(G4QContent& qQCont, const G4LorentzVector& q4M);
108  void ClearQuasmon(); // Clear Quasmon (status=0)
109  void KillQuasmon(); // Kill Quasmon (status=0)
111 
112 private:
113  G4QHadronVector HadronizeQuasmon(G4QNucleus& qEnv, G4int nQ=1); // + new Neuclear Envir
114  G4double GetRandomMass(G4int PDGCode, G4double maxM);
115  void ModifyInMatterCandidates();
116  void CalculateHadronizationProbabilities(G4double excE, G4double kQ,
117  G4LorentzVector k4M, G4bool piF,
118  G4bool gaF, G4bool first=false);
119  void FillHadronVector(G4QHadron* qHadron);
120  G4int RandomPoisson(G4double meanValue);
121  G4double GetQPartonMomentum(G4double mMinResidual2, G4double mCandidate2);
122  G4bool CheckGroundState(G4bool corFlag=false); // Forbid correction by default
123  void KillEnvironment(); // Kill Environment (Z,N,S=0,LV=0)
124 
125 // Body
126 private:
127  // Static Parameters
128  static G4double Temperature; // Quasmon Temperature
129  static G4double SSin2Gluons; // Percent of ssbar sea in a constituen gluon
130  static G4double EtaEtaprime; // Part of eta-prime in all etas
131  static G4bool WeakDecays; // Flag for opening WeakDecays (notUsed: allAreClosed)
132  static G4bool ElMaDecays; // Flag for opening ElectroMagDecays (true by default)
133  // Hadronic input
134  G4LorentzVector q4Mom; // 4-momentum of the Quasmon +++++
135  G4QContent valQ; // Quark Content of the Quasmon +++++
136  G4QNucleus theEnvironment;// Nuclear (or Vacuum) Environment around the Quasmon
137  // Output
138  G4int status; // -1-Panic,0-Done,1-FilledSomething,2-DidNothing,3-StopedByCB,4-JustBorn
139  G4QHadronVector theQHadrons; // Vector of generated secondary hadrons +++++
140  // Internal working objects (@@ it is possible to sacrifice some of them in future)
141  G4QCHIPSWorld* theWorld; // Pointer to the CHIPS World
142  G4LorentzVector phot4M; // Gamma 4-momentum for interaction with a quark-parton
143  G4int nBarClust; // Maximum barion number of clusters in the Environment
144  G4int nOfQ; // a#of quark-partons in theQuasmon (to accelerate)
145  G4QCandidateVector theQCandidates;// Vector of possible secondary hadrons/clusters(*del*)
146  G4double f2all; // Ratio of free nucleons to free+freeInDense nucleons
147  G4double rEP; // E+p for the Residual Coloured Quasmon im LS +++++
148  G4double rMo; // p for the Residual Coloured Quasmon im LS +++++
149  G4double totMass; // Mass of totalCompoundSys: curQuasmon+curEnvironment
150  G4int bEn; // BaryoNumber of the Limit Active Nuclear Environment
151  G4double mbEn; // Mass of the LimActNucEnv
152  G4LorentzVector bEn4M; // 4-momentum of the LimitActiveNuclearEnviron
153  G4QContent bEnQC; // QuarkContent of the LimitActiveNuclEnv
154 };
155 
156 inline G4bool G4Quasmon::operator==(const G4Quasmon &rhs) const {return this == &rhs;}
157 inline G4bool G4Quasmon::operator!=(const G4Quasmon &rhs) const {return this != &rhs;}
158 inline G4double G4Quasmon::GetTemper() const {return Temperature;}
159 inline G4double G4Quasmon::GetSOverU() const {return SSin2Gluons;}
160 inline G4double G4Quasmon::GetEtaSup() const {return EtaEtaprime;}
161 inline G4LorentzVector G4Quasmon::Get4Momentum() const {return q4Mom;}
162 inline G4QContent G4Quasmon::GetQC() const {return valQ;}
163 inline G4int G4Quasmon::GetCharge() const{return valQ.GetCharge();}
164 inline G4int G4Quasmon::GetBaryonNumber() const{return valQ.GetBaryonNumber();}
165 inline G4int G4Quasmon::GetStrangeness() const{return valQ.GetStrangeness();}
166 inline G4QPDGCode G4Quasmon::GetQPDG() const {return G4QPDGCode(valQ);}
167 inline G4int G4Quasmon::GetStatus() const {return status;}
169  {std::for_each(theQHadrons.begin(), theQHadrons.end(), DeleteQHadron());
170  theQHadrons.clear();
171  }
172 inline void G4Quasmon::KillEnvironment()
173  {theEnvironment=G4QNucleus(0,0,0,G4LorentzVector(0.,0.,0.,0.));}
174 inline G4double G4Quasmon::GetRandomMass(G4int PDG, G4double maxM)
175 {
176  G4QParticle* part = theWorld->GetQParticle(PDG);
177  return G4QHadron(part, maxM).GetMass();
178 }
179 
180 inline void G4Quasmon::IncreaseBy(const G4Quasmon* pQuasm)
181 {
182  valQ += pQuasm->GetQC();
183  q4Mom += pQuasm->Get4Momentum();
184  status= 3;
185 }
186 inline void G4Quasmon::IncreaseBy(G4QContent& qQCont, const G4LorentzVector& q4M)
187 {
188  valQ += qQCont;
189  q4Mom += q4M;
190  status= 3;
191 }
192 
193 inline void G4Quasmon::InitQuasmon(const G4QContent& qQCont, const G4LorentzVector& q4M)
194 {
195  valQ = qQCont;
196  q4Mom = q4M;
197  status= 3;
198 }
199 
201 {
202  static const G4QContent zeroQC(0,0,0,0,0,0);
203  static const G4LorentzVector nothing(0.,0.,0.,0.);
204  phot4M= nothing;
205  valQ = zeroQC;
206  q4Mom = nothing;
207  status= 0;
208  std::for_each(theQCandidates.begin(), theQCandidates.end(), DeleteQCandidate());
209  theQCandidates.clear();
210 
211 }
212 
214 {
215  ClearQuasmon();
216  ClearOutput();
217 }
218 
219 #endif
220 
221 
222 
223 
224