Import Geant4 10.7.0.beta source tree
This commit is contained in:
@@ -14,7 +14,11 @@ code and to keep track of all tags.
|
||||
* Please list in reverse chronological order (last date on top)
|
||||
---------------------------------------------------------------
|
||||
|
||||
07-Dec-2019 V. Ivanchenko (hadr-string-diff-V10-05-11)
|
||||
08-Mar-2020 V. Ivanchenko (hadr-string-diff-V10-06-01)
|
||||
- G4FTFModel, G4FTFParticipants - clean-up: removed unused methods, delete
|
||||
operators, use C++11 keywords
|
||||
|
||||
07-Dec-2019 V. Ivanchenko (hadr-string-diff-V10-06-00)
|
||||
- G4FTFParameters:
|
||||
o Fixed division by zero (Coverity report) due to wrong protection
|
||||
in previous MR 05-09
|
||||
|
||||
@@ -61,22 +61,25 @@ class G4ExcitedString;
|
||||
class G4FTFModel : public G4VPartonStringModel {
|
||||
public:
|
||||
G4FTFModel( const G4String& modelName = "FTF" );
|
||||
~G4FTFModel();
|
||||
~G4FTFModel() override;
|
||||
|
||||
void Init( const G4Nucleus& aNucleus, const G4DynamicParticle& aProjectile );
|
||||
G4ExcitedStringVector* GetStrings();
|
||||
G4V3DNucleus* GetWoundedNucleus() const;
|
||||
G4V3DNucleus* GetTargetNucleus() const;
|
||||
G4V3DNucleus* GetProjectileNucleus() const;
|
||||
G4V3DNucleus* GetWoundedNucleus() const override;
|
||||
G4V3DNucleus* GetProjectileNucleus() const override;
|
||||
|
||||
virtual void ModelDescription( std::ostream& ) const;
|
||||
void ModelDescription( std::ostream& ) const override;
|
||||
|
||||
G4FTFModel( const G4FTFModel& right ) = delete;
|
||||
const G4FTFModel& operator=( const G4FTFModel& right ) = delete;
|
||||
G4bool operator==( const G4FTFModel& right ) const = delete;
|
||||
G4bool operator!=( const G4FTFModel& right ) const = delete;
|
||||
|
||||
protected:
|
||||
void Init( const G4Nucleus& aNucleus,
|
||||
const G4DynamicParticle& aProjectile ) override;
|
||||
G4ExcitedStringVector* GetStrings() override;
|
||||
|
||||
private:
|
||||
G4FTFModel( const G4FTFModel& right );
|
||||
const G4FTFModel& operator=( const G4FTFModel& right );
|
||||
G4bool operator==( const G4FTFModel& right ) const;
|
||||
G4bool operator!=( const G4FTFModel& right ) const;
|
||||
|
||||
void StoreInvolvedNucleon();
|
||||
void ReggeonCascade();
|
||||
G4bool PutOnMassShell();
|
||||
@@ -187,17 +190,14 @@ class G4FTFModel : public G4VPartonStringModel {
|
||||
G4double TargetResidualExcitationEnergy;
|
||||
};
|
||||
|
||||
|
||||
inline G4V3DNucleus* G4FTFModel::GetWoundedNucleus() const {
|
||||
return theParticipants.GetWoundedNucleus();
|
||||
}
|
||||
|
||||
|
||||
inline G4V3DNucleus* G4FTFModel::GetTargetNucleus() const {
|
||||
return theParticipants.GetWoundedNucleus();
|
||||
}
|
||||
|
||||
|
||||
inline G4V3DNucleus* G4FTFModel::GetProjectileNucleus() const {
|
||||
return theParticipants.GetProjectileNucleus();
|
||||
}
|
||||
|
||||
+6
-8
@@ -50,10 +50,12 @@
|
||||
class G4FTFParticipants : public G4VParticipants {
|
||||
public:
|
||||
G4FTFParticipants();
|
||||
const G4FTFParticipants& operator=( const G4FTFParticipants& right );
|
||||
~G4FTFParticipants();
|
||||
G4bool operator==( const G4FTFParticipants& right ) const;
|
||||
G4bool operator!=( const G4FTFParticipants& right ) const;
|
||||
|
||||
const G4FTFParticipants& operator=( const G4FTFParticipants& right ) = delete;
|
||||
G4bool operator==( const G4FTFParticipants& right ) const = delete;
|
||||
G4bool operator!=( const G4FTFParticipants& right ) const = delete;
|
||||
G4FTFParticipants( const G4FTFParticipants& right ) = delete;
|
||||
|
||||
void GetList( const G4ReactionProduct& thePrimary, G4FTFParameters* theParameters );
|
||||
void StartLoop();
|
||||
@@ -62,24 +64,20 @@ class G4FTFParticipants : public G4VParticipants {
|
||||
void ShiftInteractionTime();
|
||||
G4InteractionContent& GetInteraction();
|
||||
void Clean();
|
||||
std::vector< G4InteractionContent* > theInteractions;
|
||||
|
||||
private:
|
||||
G4FTFParticipants( const G4FTFParticipants& right );
|
||||
std::vector< G4InteractionContent* > theInteractions;
|
||||
G4int currentInteraction;
|
||||
};
|
||||
|
||||
|
||||
inline void G4FTFParticipants::StartLoop() {
|
||||
currentInteraction = -1;
|
||||
}
|
||||
|
||||
|
||||
inline G4bool G4FTFParticipants::Next() {
|
||||
return ++currentInteraction < static_cast< G4int >( theInteractions.size() );
|
||||
}
|
||||
|
||||
|
||||
inline G4InteractionContent& G4FTFParticipants::GetInteraction() {
|
||||
return *theInteractions[ currentInteraction ];
|
||||
}
|
||||
|
||||
@@ -73,7 +73,6 @@ G4FTFModel::G4FTFModel( const G4String& modelName ) :
|
||||
theElastic( new G4ElasticHNScattering() ),
|
||||
theAnnihilation( new G4FTFAnnihilation() )
|
||||
{
|
||||
G4VPartonStringModel::SetThisPointer( this );
|
||||
// ---> JVY theParameters = 0;
|
||||
theParameters = new G4FTFParameters();
|
||||
//
|
||||
@@ -219,9 +218,9 @@ void G4FTFModel::Init( const G4Nucleus& aNucleus, const G4DynamicParticle& aProj
|
||||
theParticipants.InitProjectileNucleus(
|
||||
std::abs( theProjectile.GetDefinition()->GetBaryonNumber() ),
|
||||
std::abs( G4int( theProjectile.GetDefinition()->GetPDGCharge() ) ) );
|
||||
theParticipants.theProjectileNucleus->StartLoop();
|
||||
theParticipants.GetProjectileNucleus()->StartLoop();
|
||||
G4Nucleon* aNucleon;
|
||||
while ( ( aNucleon = theParticipants.theProjectileNucleus->GetNextNucleon() ) ) { /* Loop checking, 10.08.2015, A.Ribon */
|
||||
while ( ( aNucleon = theParticipants.GetProjectileNucleus()->GetNextNucleon() ) ) { /* Loop checking, 10.08.2015, A.Ribon */
|
||||
if ( aNucleon->GetDefinition() == G4Proton::Proton() ) {
|
||||
aNucleon->SetParticleType( G4AntiProton::AntiProton() );
|
||||
} else if ( aNucleon->GetDefinition() == G4Neutron::Neutron() ) {
|
||||
@@ -240,8 +239,8 @@ void G4FTFModel::Init( const G4Nucleus& aNucleus, const G4DynamicParticle& aProj
|
||||
}
|
||||
|
||||
G4ThreeVector BoostVector = theProjectile.GetMomentum() / theProjectile.GetTotalEnergy();
|
||||
theParticipants.theProjectileNucleus->DoLorentzBoost( BoostVector );
|
||||
theParticipants.theProjectileNucleus->DoLorentzContraction( BoostVector );
|
||||
theParticipants.GetProjectileNucleus()->DoLorentzBoost( BoostVector );
|
||||
theParticipants.GetProjectileNucleus()->DoLorentzContraction( BoostVector );
|
||||
ProjectileResidualExcitationEnergy = 0.0;
|
||||
//G4double ProjectileResidualMass = theProjectile.GetMass();
|
||||
ProjectileResidual4Momentum.setVect( theProjectile.GetMomentum() );
|
||||
|
||||
+1
-13
@@ -60,22 +60,10 @@
|
||||
|
||||
G4FTFParticipants::G4FTFParticipants() : currentInteraction( -1 ) {}
|
||||
|
||||
|
||||
//============================================================================
|
||||
|
||||
G4FTFParticipants::G4FTFParticipants( const G4FTFParticipants& ) :
|
||||
G4VParticipants(), currentInteraction( -1 )
|
||||
{
|
||||
G4Exception( "G4FTFParticipants::G4FTFParticipants()", "HAD_FTF_001",
|
||||
FatalException, " Must not use copy ctor()" );
|
||||
}
|
||||
|
||||
|
||||
//============================================================================
|
||||
|
||||
G4FTFParticipants::~G4FTFParticipants() {}
|
||||
|
||||
|
||||
//============================================================================
|
||||
|
||||
void G4FTFParticipants::GetList( const G4ReactionProduct& thePrimary,
|
||||
@@ -96,7 +84,7 @@ void G4FTFParticipants::GetList( const G4ReactionProduct& thePrimary,
|
||||
|
||||
G4double deltaxy = 2.0 * fermi; // Extra nuclear radius
|
||||
|
||||
if ( theProjectileNucleus == 0 ) { // Hadron-nucleus or anti-baryon-nucleus interactions
|
||||
if ( theProjectileNucleus == nullptr ) { // Hadron-nucleus or anti-baryon-nucleus interactions
|
||||
|
||||
G4double impactX( 0.0 ), impactY( 0.0 );
|
||||
|
||||
|
||||
@@ -14,10 +14,30 @@ code and to keep track of all tags.
|
||||
* Please list in reverse chronological order (last date on top)
|
||||
---------------------------------------------------------------
|
||||
|
||||
26-Apr-2020 V. Ivanchenko (had-hadronization-V10-05-05)
|
||||
- G4QGSMFragmentation, G4LundStringFragmentation - fixed Coverity warnings
|
||||
if fragmentation at low energy is not possible always return flag
|
||||
"false"; initialise with nullptr and not NULL
|
||||
10-Jun-2020 A. Ribon (had-hadronization-V10-06-02)
|
||||
- Improved treatment of antibaryon interactions in QGS
|
||||
(made by Vladimir Uzhinsky):
|
||||
1. G4QGSMFragmentation : corrected the treatment of low mass
|
||||
diquark-antidiquark strings. In addition to this, the Mt distribution
|
||||
of produced hadrons has been introduced.
|
||||
2. G4VLongitudinalStringDecay : introduced in the method
|
||||
SetMinimalStringMass a check that the strings are of allowed type:
|
||||
quark-antiquark, diquark-antidiquark, quark-diquark and
|
||||
antiquark-antidiquark. Introduced also for diquark-antidiquark strings
|
||||
a special algorithm (already present for the other types of allowed
|
||||
strings) for treating low-mass strings with masses below known hadrons.
|
||||
|
||||
23-Apr-2020 V. Ivanchenko (had-hadronization-V10-06-01)
|
||||
- G4VLongitudinalStringDecay, G4QGSMFragmentation
|
||||
G4LundStringFragmentation - fixed Coverity warnings - if fragmentation
|
||||
at low energy is not possible always return flag "false"; initialise
|
||||
with nullptr and not NULL
|
||||
|
||||
24-Feb-2020 V. Ivanchenko (had-hadronization-V10-06-00)
|
||||
- G4VLongitudinalStringDecay, G4ExcitedStringDecay,
|
||||
G4LundStringFragmentation - inherit from G4HadronicInteraction
|
||||
destruction of these models end of run by hadron model store;
|
||||
removed implementations of private operators.
|
||||
|
||||
19-Nov-2019 A. Ribon (had-hadronization-V10-05-04)
|
||||
- G4ExcitedStringDecay : protection in the sampling of resonance masses
|
||||
|
||||
+3
-3
@@ -32,13 +32,13 @@
|
||||
#include "G4VStringFragmentation.hh"
|
||||
#include "G4ExcitedStringVector.hh"
|
||||
#include "G4KineticTrackVector.hh"
|
||||
#include "G4LundStringFragmentation.hh"
|
||||
|
||||
class G4VLongitudinalStringDecay;
|
||||
|
||||
class G4ExcitedStringDecay: public G4VStringFragmentation
|
||||
{
|
||||
public:
|
||||
G4ExcitedStringDecay();
|
||||
G4ExcitedStringDecay(G4VLongitudinalStringDecay * aStringDecay);
|
||||
G4ExcitedStringDecay(G4VLongitudinalStringDecay* aStringDecay = nullptr);
|
||||
virtual ~G4ExcitedStringDecay();
|
||||
|
||||
private:
|
||||
|
||||
+2
-2
@@ -36,7 +36,7 @@
|
||||
|
||||
#include "G4VLongitudinalStringDecay.hh"
|
||||
|
||||
//**************************************************************************************************************
|
||||
//******************************************************************************
|
||||
|
||||
class G4LundStringFragmentation: public G4VLongitudinalStringDecay
|
||||
{
|
||||
@@ -109,7 +109,7 @@ class G4LundStringFragmentation: public G4VLongitudinalStringDecay
|
||||
G4int SampleState(void);
|
||||
};
|
||||
|
||||
//**************************************************************************************************************
|
||||
//******************************************************************************
|
||||
// Class G4LundStringFragmentation
|
||||
|
||||
#endif
|
||||
|
||||
+10
-5
@@ -31,6 +31,7 @@
|
||||
#ifndef G4VLongitudinalStringDecay_h
|
||||
#define G4VLongitudinalStringDecay_h 1
|
||||
|
||||
#include "G4HadronicInteraction.hh"
|
||||
#include "G4VStringFragmentation.hh"
|
||||
#include "G4DynamicParticle.hh"
|
||||
#include "G4KineticTrack.hh"
|
||||
@@ -38,15 +39,19 @@
|
||||
#include "G4HadronBuilder.hh"
|
||||
#include <vector>
|
||||
|
||||
class G4FragmentingString;
|
||||
//**************************************************************************************
|
||||
//*****************************************************************************
|
||||
|
||||
class G4VLongitudinalStringDecay
|
||||
class G4FragmentingString;
|
||||
|
||||
class G4VLongitudinalStringDecay : public G4HadronicInteraction
|
||||
{
|
||||
public:
|
||||
G4VLongitudinalStringDecay();
|
||||
|
||||
G4VLongitudinalStringDecay(const G4String& name = "StringDecay");
|
||||
virtual ~G4VLongitudinalStringDecay();
|
||||
|
||||
G4HadFinalState *ApplyYourself(const G4HadProjectile&, G4Nucleus&) final;
|
||||
|
||||
private:
|
||||
// not implemented to protect/forbid use
|
||||
G4VLongitudinalStringDecay(const G4VLongitudinalStringDecay &right);
|
||||
@@ -248,7 +253,7 @@ class G4VLongitudinalStringDecay
|
||||
G4int NumberOf_FS;
|
||||
};
|
||||
|
||||
//*************************************************************************************
|
||||
//******************************************************************************
|
||||
// Class G4VLongitudinalStringDecay
|
||||
|
||||
#endif
|
||||
|
||||
+14
-42
@@ -28,62 +28,34 @@
|
||||
#include "G4ExcitedStringDecay.hh"
|
||||
#include "G4SystemOfUnits.hh"
|
||||
#include "G4KineticTrack.hh"
|
||||
#include "G4LundStringFragmentation.hh"
|
||||
#include "G4HadronicInteractionRegistry.hh"
|
||||
|
||||
#include "G4SampleResonance.hh"
|
||||
|
||||
//#define debug_G4ExcitedStringDecay
|
||||
//#define debug_G4ExcitedStringCorr
|
||||
|
||||
|
||||
G4ExcitedStringDecay::G4ExcitedStringDecay() : G4VStringFragmentation(),theStringDecay(0)
|
||||
{}
|
||||
|
||||
|
||||
G4ExcitedStringDecay::G4ExcitedStringDecay(G4VLongitudinalStringDecay * aStringDecay)
|
||||
: G4VStringFragmentation(),
|
||||
theStringDecay(aStringDecay)
|
||||
{}
|
||||
|
||||
|
||||
G4ExcitedStringDecay::G4ExcitedStringDecay(const G4ExcitedStringDecay &)
|
||||
: G4VStringFragmentation(),
|
||||
theStringDecay(0)
|
||||
G4ExcitedStringDecay::G4ExcitedStringDecay(G4VLongitudinalStringDecay* ptr)
|
||||
: G4VStringFragmentation(), theStringDecay(ptr)
|
||||
{
|
||||
throw G4HadronicException(__FILE__, __LINE__, "G4ExcitedStringDecay::copy ctor not accessible");
|
||||
}
|
||||
|
||||
if(!ptr) {
|
||||
G4HadronicInteraction* p =
|
||||
G4HadronicInteractionRegistry::Instance()->FindModel("LundStringFragmentation");
|
||||
theStringDecay = static_cast<G4VLongitudinalStringDecay*>(p);
|
||||
if(!theStringDecay) { theStringDecay = new G4LundStringFragmentation(); }
|
||||
}
|
||||
SetModelName(theStringDecay->GetModelName());
|
||||
}
|
||||
|
||||
G4ExcitedStringDecay::~G4ExcitedStringDecay()
|
||||
{
|
||||
}
|
||||
|
||||
|
||||
const G4ExcitedStringDecay & G4ExcitedStringDecay::operator=(const G4ExcitedStringDecay &)
|
||||
{
|
||||
throw G4HadronicException(__FILE__, __LINE__, "G4ExcitedStringDecay::operator= meant to not be accessable");
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
G4bool G4ExcitedStringDecay::operator==(const G4ExcitedStringDecay &) const
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
G4bool G4ExcitedStringDecay::operator!=(const G4ExcitedStringDecay &) const
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
{}
|
||||
|
||||
G4KineticTrackVector *G4ExcitedStringDecay::FragmentString(const G4ExcitedString &theString)
|
||||
{
|
||||
if ( theStringDecay == NULL ) theStringDecay=new G4LundStringFragmentation();
|
||||
return theStringDecay->FragmentString(theString);
|
||||
return theStringDecay->FragmentString(theString);
|
||||
}
|
||||
|
||||
|
||||
G4KineticTrackVector *G4ExcitedStringDecay::FragmentStrings(const G4ExcitedStringVector * theStrings)
|
||||
{
|
||||
G4LorentzVector KTsum(0.,0.,0.,0.);
|
||||
|
||||
+21
-20
@@ -47,6 +47,7 @@
|
||||
//*************************************************************************************
|
||||
|
||||
G4LundStringFragmentation::G4LundStringFragmentation()
|
||||
: G4VLongitudinalStringDecay("LundStringFragmentation")
|
||||
{
|
||||
SetMassCut(210.*MeV); // Mpi + Delta
|
||||
// For ProduceOneHadron it is required
|
||||
@@ -787,8 +788,8 @@ Diquark_AntiDiquark_belowThreshold_lastSplitting(G4FragmentingString * & string,
|
||||
{
|
||||
G4double StringMass = string->Mass();
|
||||
|
||||
G4int cClusterInterrupt = 0;
|
||||
G4bool isOK = false;
|
||||
G4int cClusterInterrupt = 0;
|
||||
do
|
||||
{
|
||||
G4int LeftQuark1= string->GetLeftParton()->GetPDGEncoding()/1000;
|
||||
@@ -801,26 +802,26 @@ Diquark_AntiDiquark_belowThreshold_lastSplitting(G4FragmentingString * & string,
|
||||
{
|
||||
LeftHadron =hadronizer->Build(FindParticle( LeftQuark1),
|
||||
FindParticle(RightQuark1));
|
||||
RightHadron= (LeftHadron == nullptr) ? nullptr :
|
||||
hadronizer->Build(FindParticle( LeftQuark2),
|
||||
FindParticle(RightQuark2));
|
||||
} else
|
||||
{
|
||||
LeftHadron =hadronizer->Build(FindParticle( LeftQuark1),
|
||||
FindParticle(RightQuark2));
|
||||
RightHadron=(LeftHadron == nullptr) ? nullptr :
|
||||
hadronizer->Build(FindParticle( LeftQuark2),
|
||||
FindParticle(RightQuark1));
|
||||
}
|
||||
RightHadron= (LeftHadron == nullptr) ? nullptr :
|
||||
hadronizer->Build(FindParticle( LeftQuark2),
|
||||
FindParticle(RightQuark2));
|
||||
} else
|
||||
{
|
||||
LeftHadron =hadronizer->Build(FindParticle( LeftQuark1),
|
||||
FindParticle(RightQuark2));
|
||||
RightHadron=(LeftHadron == nullptr) ? nullptr :
|
||||
hadronizer->Build(FindParticle( LeftQuark2),
|
||||
FindParticle(RightQuark1));
|
||||
}
|
||||
|
||||
isOK = (LeftHadron != nullptr) && (RightHadron != nullptr);
|
||||
if(isOK) { isOK = (StringMass > LeftHadron->GetPDGMass() + RightHadron->GetPDGMass()); }
|
||||
++cClusterInterrupt;
|
||||
//... repeat procedure, if mass of cluster is too low to produce hadrons
|
||||
//... ClusterMassCut = 0.15*GeV model parameter
|
||||
}
|
||||
while (isOK == false || cClusterInterrupt < ClusterLoopInterrupt);
|
||||
/* Loop checking, 07.08.2015, A.Ribon */
|
||||
isOK = (LeftHadron != nullptr) && (RightHadron != nullptr);
|
||||
if(isOK) { isOK = (StringMass > LeftHadron->GetPDGMass() + RightHadron->GetPDGMass()); }
|
||||
++cClusterInterrupt;
|
||||
//... repeat procedure, if mass of cluster is too low to produce hadrons
|
||||
//... ClusterMassCut = 0.15*GeV model parameter
|
||||
}
|
||||
while (isOK == false || cClusterInterrupt < ClusterLoopInterrupt);
|
||||
/* Loop checking, 07.08.2015, A.Ribon */
|
||||
return isOK;
|
||||
}
|
||||
|
||||
|
||||
+73
-34
@@ -48,16 +48,18 @@
|
||||
|
||||
G4QGSMFragmentation::G4QGSMFragmentation()
|
||||
{
|
||||
SigmaQT = 0.45 * GeV; // Uzhi June 2020
|
||||
|
||||
MassCut = 0.35*GeV;
|
||||
|
||||
SetStrangenessSuppression((1.0 - 0.16)/2.);
|
||||
SetStrangenessSuppression((1.0 - 0.12)/2.); // Uzhi June 2020 0.16 -> 0.12
|
||||
|
||||
// For the time being, set to 0.0 the probabilities for c-cbar and b-bbar creation.
|
||||
SetProbCCbar(0.0); //(0.0033); // According to O.I. Piskunova Yad. Fiz. 56 (1993) 1094
|
||||
SetProbBBbar(0.0); //(5.0e-5); // According to O.I. Piskunova Yad. Fiz. 56 (1993) 1094
|
||||
|
||||
SetDiquarkSuppression(0.32);
|
||||
SetDiquarkBreakProbability(0.7);
|
||||
SetDiquarkSuppression(0.195); // Uzhi June 2020 0.32 -> 0.195
|
||||
SetDiquarkBreakProbability(0.0); // Uzhi June 2020 0.7 -> 0.0
|
||||
|
||||
SetMinMasses();
|
||||
|
||||
@@ -208,7 +210,11 @@ G4KineticTrackVector* G4QGSMFragmentation::FragmentString(const G4ExcitedString&
|
||||
|
||||
// Split current string into 2 final Hadrons
|
||||
#ifdef debug_QGSMfragmentation
|
||||
G4cout<<"Split remaining string into 2 final hadrons."<<G4endl;
|
||||
if( inner_sucess ) { // Uzhi June 2020
|
||||
G4cout<<"Split remaining string into 2 final hadrons."<<G4endl;
|
||||
} else {
|
||||
G4cout<<" New attempt to fragment string"<<G4endl;
|
||||
} // Uzhi June 2020
|
||||
#endif
|
||||
// To the close production of hadrons at last string decay
|
||||
if ( inner_sucess &&
|
||||
@@ -261,7 +267,8 @@ G4KineticTrackVector* G4QGSMFragmentation::FragmentString(const G4ExcitedString&
|
||||
|
||||
G4bool G4QGSMFragmentation::IsItFragmentable(const G4FragmentingString * const string)
|
||||
{
|
||||
return sqr( PossibleHadronMass(string) + MassCut ) < string->Mass2();
|
||||
//Uzhi June 2020 return sqr( PossibleHadronMass(string) + MassCut ) < string->Mass2();
|
||||
return sqr( MinimalStringMass + MassCut ) < string->Mass2(); // Uzhi June 2020
|
||||
}
|
||||
|
||||
//----------------------------------------------------------------------------------------------------------
|
||||
@@ -401,7 +408,7 @@ G4ParticleDefinition *G4QGSMFragmentation::DiQuarkSplitup( G4ParticleDefinition*
|
||||
G4int IsParticle=(decayQuarkEncoding>0) ? -1 : +1; // if we have a quark, we need antiquark
|
||||
|
||||
G4double StrSup=GetStrangeSuppress();
|
||||
SetStrangenessSuppression((1.0 - 0.07)/2.);
|
||||
SetStrangenessSuppression((1.0 - 0.07)/2.); // Prob qq->K qq' 0.07
|
||||
pDefPair QuarkPair = CreatePartonPair(IsParticle,false); // no diquarks wanted
|
||||
SetStrangenessSuppression(StrSup);
|
||||
|
||||
@@ -411,12 +418,13 @@ G4ParticleDefinition *G4QGSMFragmentation::DiQuarkSplitup( G4ParticleDefinition*
|
||||
G4int i20 = std::min(std::abs(QuarkEncoding), std::abs(stableQuarkEncoding));
|
||||
G4int spin = (i10 != i20 && G4UniformRand() <= 0.5)? 1 : 3;
|
||||
G4int NewDecayEncoding = -1*IsParticle*(i10 * 1000 + i20 * 100 + spin);
|
||||
|
||||
created = FindParticle(NewDecayEncoding);
|
||||
G4ParticleDefinition * decayQuark=FindParticle(decayQuarkEncoding);
|
||||
G4ParticleDefinition * had=hadronizer->Build(QuarkPair.first, decayQuark);
|
||||
|
||||
DecayQuark = decayQuarkEncoding;
|
||||
NewQuark = QuarkPair.first->GetPDGEncoding();
|
||||
DecayQuark = decay->GetPDGEncoding(); //Uzhi June 2020 decayQuarkEncoding;
|
||||
NewQuark = NewDecayEncoding; //Uzhi June 2020 QuarkPair.first->GetPDGEncoding();
|
||||
|
||||
return had;
|
||||
|
||||
@@ -476,13 +484,21 @@ G4LorentzVector * G4QGSMFragmentation::SplitEandP(G4ParticleDefinition * pHadron
|
||||
G4ThreeVector HadronPt , RemSysPt;
|
||||
G4double HadronMassT2, ResidualMassT2;
|
||||
|
||||
//Uzhi June 2020 Mt distribution is implemented
|
||||
G4double HadronMt, Pt, Pt2, phi; // Uzhi June 2020
|
||||
|
||||
//... sample Pt of the hadron
|
||||
G4int attempt=0;
|
||||
do
|
||||
{
|
||||
attempt++; if (attempt > StringLoopInterrupt) return 0;
|
||||
|
||||
HadronPt =SampleQuarkPt() + string->DecayPt();
|
||||
HadronMt = HadronMass - 200.0*G4Log(G4UniformRand()); // Uzhi June 2020, 200.0 must be tuned
|
||||
Pt2 = sqr(HadronMt)-sqr(HadronMass); Pt=std::sqrt(Pt2); // Uzhi June 2020
|
||||
phi = 2.*pi*G4UniformRand();
|
||||
G4ThreeVector SampleQuarkPtw= G4ThreeVector(Pt*std::cos(phi), Pt*std::sin(phi), 0);
|
||||
HadronPt =SampleQuarkPtw + string->DecayPt(); // Uzhi June 2020
|
||||
//Uzhi June 2020 HadronPt =SampleQuarkPt() + string->DecayPt(); // Save this for possible return
|
||||
HadronPt.setZ(0);
|
||||
RemSysPt = StringPt - HadronPt;
|
||||
|
||||
@@ -534,12 +550,14 @@ G4LorentzVector * G4QGSMFragmentation::SplitEandP(G4ParticleDefinition * pHadron
|
||||
|
||||
//----------------------------------------------------------------------------------------------------------
|
||||
|
||||
G4double G4QGSMFragmentation::GetLightConeZ(G4double zmin, G4double zmax, G4int /* PartonEncoding */,
|
||||
G4ParticleDefinition* /* pHadron */, G4double , G4double )
|
||||
G4double G4QGSMFragmentation::GetLightConeZ(G4double zmin, G4double zmax, G4int /* PartonEncoding */ ,
|
||||
G4ParticleDefinition* /* pHadron */, G4double ptx , G4double pty)
|
||||
{
|
||||
G4double lambda = 2.0*(sqr(ptx)+sqr(pty))/sqr(GeV); // Uzhi June 2020
|
||||
|
||||
#ifdef debug_QGSMfragmentation
|
||||
G4cout<<"GetLightConeZ zmin zmax Parton pHadron "<<zmin<<" "<<zmax<<" "<< /* PartonEncoding */
|
||||
<<" "<</* pHadron->GetParticleName() */ <<G4endl;
|
||||
G4cout<<"GetLightConeZ zmin zmax Parton pHadron "<<zmin<<" "<<zmax<<" "/*<< PartonEncoding */
|
||||
<<" "/*<< pHadron->GetParticleName() */ <<G4endl;
|
||||
#endif
|
||||
|
||||
G4double z(0.);
|
||||
@@ -575,6 +593,7 @@ G4double G4QGSMFragmentation::GetLightConeZ(G4double zmin, G4double zmax, G4int
|
||||
d1 = FFqq2qq[DiQold][absNewQuarkCode-1][0]; d2 = FFqq2qq[DiQold][absNewQuarkCode-1][1];
|
||||
}
|
||||
|
||||
d2 +=lambda; // Uzhi June 2020
|
||||
d1+=1.0; d2+=1.0;
|
||||
|
||||
invD1=1./d1; invD2=1./d2;
|
||||
@@ -615,15 +634,16 @@ G4bool G4QGSMFragmentation::SplitLast(G4FragmentingString * string,
|
||||
<<string->GetRightParton()->GetParticleName()<<G4endl;
|
||||
#endif
|
||||
|
||||
G4int cClusterInterrupt = 0;
|
||||
G4ParticleDefinition *LeftHadron = nullptr;
|
||||
G4ParticleDefinition *RightHadron = nullptr;
|
||||
const G4int maxNumberOfLoops = 1000;
|
||||
G4int loopCounter = 0;
|
||||
G4bool isOK = false;
|
||||
|
||||
G4double LeftHadronMass(0.); G4double RightHadronMass(0.);
|
||||
do
|
||||
{
|
||||
if (cClusterInterrupt++ >= ClusterLoopInterrupt) return false; // Uzhi June 2020
|
||||
LeftHadronMass = -MaxMass; RightHadronMass = -MaxMass;
|
||||
|
||||
G4ParticleDefinition * quark = nullptr;
|
||||
@@ -640,8 +660,12 @@ G4bool G4QGSMFragmentation::SplitLast(G4FragmentingString * string,
|
||||
quark = QuarkPair.second;
|
||||
|
||||
LeftHadron= hadronizer->BuildLowSpin(QuarkPair.first, string->GetLeftParton());
|
||||
} else {
|
||||
//... there is a Diquark on cluster ends
|
||||
if ( LeftHadron == NULL ) continue; // Uzhi June 2020
|
||||
RightHadron = hadronizer->BuildLowSpin(string->GetRightParton(), quark); // Uzhi June 2020
|
||||
if ( RightHadron == NULL ) continue; // Uzhi June 2020
|
||||
} else if( (!string->DecayIsQuark() && string->StableIsQuark() ) || // Uzhi June 2020
|
||||
( string->DecayIsQuark() && !string->StableIsQuark() ) ) { // Uzhi June 2020
|
||||
//... there is a Diquark on one of cluster ends
|
||||
G4int IsParticle;
|
||||
if ( string->StableIsQuark() ) {
|
||||
IsParticle=(string->GetLeftParton()->GetPDGEncoding()>0) ? -1 : +1;
|
||||
@@ -657,27 +681,36 @@ G4bool G4QGSMFragmentation::SplitLast(G4FragmentingString * string,
|
||||
//SetStrangenessSuppression((1.0-ProbSaS)/2.0);
|
||||
quark = QuarkPair.second;
|
||||
LeftHadron=hadronizer->BuildLowSpin(QuarkPair.first, string->GetLeftParton());
|
||||
}
|
||||
|
||||
if ( LeftHadron != nullptr ) {
|
||||
RightHadron = hadronizer->BuildLowSpin(string->GetRightParton(), quark);
|
||||
|
||||
if ( RightHadron != nullptr ) {
|
||||
|
||||
LeftHadronMass = LeftHadron->GetPDGMass();
|
||||
RightHadronMass = RightHadron->GetPDGMass();
|
||||
isOK = (ResidualMass > LeftHadronMass + RightHadronMass);
|
||||
if ( LeftHadron == NULL ) continue; // Uzhi June 2020
|
||||
RightHadron = hadronizer->BuildLowSpin(string->GetRightParton(), quark); // Uzhi June 2020
|
||||
if ( RightHadron == NULL ) continue; // Uzhi June 2020
|
||||
} else { // Diquark and anti-diquark are on the string ends // Uzhi June 2020
|
||||
//+++++++++++++++++++++++++++++++ Inserted from FTF // Uzhi June 2020
|
||||
// Uzhi G4double StringMass = string->Mass();
|
||||
if (cClusterInterrupt++ >= ClusterLoopInterrupt) return false;
|
||||
G4int LeftQuark1= string->GetLeftParton()->GetPDGEncoding()/1000;
|
||||
G4int LeftQuark2=(string->GetLeftParton()->GetPDGEncoding()/100)%10;
|
||||
G4int RightQuark1= string->GetRightParton()->GetPDGEncoding()/1000;
|
||||
G4int RightQuark2=(string->GetRightParton()->GetPDGEncoding()/100)%10;
|
||||
if (G4UniformRand()<0.5) {
|
||||
LeftHadron =hadronizer->Build(FindParticle( LeftQuark1), FindParticle(RightQuark1));
|
||||
RightHadron =hadronizer->Build(FindParticle( LeftQuark2), FindParticle(RightQuark2));
|
||||
} else {
|
||||
LeftHadron =hadronizer->Build(FindParticle( LeftQuark1), FindParticle(RightQuark2));
|
||||
RightHadron =hadronizer->Build(FindParticle( LeftQuark2), FindParticle(RightQuark1));
|
||||
}
|
||||
if ( (LeftHadron == NULL) || (RightHadron == NULL) ) continue;
|
||||
// End of inserting from FTF Uzhi June 2020
|
||||
}
|
||||
++loopCounter;
|
||||
if ( loopCounter >= maxNumberOfLoops ) {
|
||||
return false;
|
||||
}
|
||||
//... repeat procedure, if mass of cluster is too low to produce hadrons
|
||||
//... ClusterMassCut = 0.15*GeV model parameter
|
||||
LeftHadronMass = LeftHadron->GetPDGMass();
|
||||
RightHadronMass = RightHadron->GetPDGMass();
|
||||
//... repeat procedure, if mass of cluster is too low to produce hadrons
|
||||
} while ( ( ResidualMass <= LeftHadronMass + RightHadronMass )
|
||||
&& ++loopCounter < maxNumberOfLoops ); /* Loop checking, 07.08.2015, A.Ribon */
|
||||
|
||||
if ( loopCounter >= maxNumberOfLoops ) {
|
||||
return false;
|
||||
}
|
||||
while (isOK == false);
|
||||
/* Loop checking, 07.08.2015, A.Ribon */
|
||||
|
||||
//... compute hadron momenta and energies
|
||||
G4LorentzVector LeftMom, RightMom;
|
||||
@@ -704,6 +737,12 @@ G4bool G4QGSMFragmentation::SplitLast(G4FragmentingString * string,
|
||||
void G4QGSMFragmentation::Sample4Momentum(G4LorentzVector* Mom , G4double Mass ,
|
||||
G4LorentzVector* AntiMom, G4double AntiMass, G4double InitialMass)
|
||||
{
|
||||
#ifdef debug_QGSMfragmentation // Uzhi June 2020
|
||||
G4cout<<"Sample4Momentum Last-----------------------------------------"<<G4endl;
|
||||
G4cout<<" StrMass "<<InitialMass<<" Mass1 "<<Mass<<" Mass2 "<<AntiMass<<G4endl;
|
||||
G4cout<<" SumMass "<<Mass+AntiMass<<G4endl;
|
||||
#endif
|
||||
|
||||
G4double r_val = sqr(InitialMass*InitialMass - Mass*Mass - AntiMass*AntiMass) - sqr(2.*Mass*AntiMass);
|
||||
G4double Pabs = (r_val > 0.)? std::sqrt(r_val)/(2.*InitialMass) : 0;
|
||||
|
||||
|
||||
+97
-56
@@ -55,13 +55,16 @@
|
||||
#include "G4Exp.hh"
|
||||
#include "G4Log.hh"
|
||||
|
||||
#include "G4HadronicException.hh"
|
||||
|
||||
//------------------------debug switches
|
||||
//#define debug_VStringDecay
|
||||
|
||||
//********************************************************************************
|
||||
//******************************************************************************
|
||||
// Constructors
|
||||
|
||||
G4VLongitudinalStringDecay::G4VLongitudinalStringDecay() : ProbCCbar(0.0), ProbBBbar(0.0)
|
||||
G4VLongitudinalStringDecay::G4VLongitudinalStringDecay(const G4String& name)
|
||||
: G4HadronicInteraction(name), ProbCCbar(0.0), ProbBBbar(0.0)
|
||||
{
|
||||
MassCut = 210.0*MeV; // Mpi + Delta
|
||||
|
||||
@@ -117,38 +120,24 @@ G4VLongitudinalStringDecay::G4VLongitudinalStringDecay() : ProbCCbar(0.0), ProbB
|
||||
SetMinMasses(); // Re-calculation of minimal mass of strings and weights of particles in 2-part. decays
|
||||
|
||||
Kappa = 1.0 * GeV/fermi;
|
||||
DecayQuark = NewQuark = 0;
|
||||
}
|
||||
|
||||
|
||||
G4VLongitudinalStringDecay::~G4VLongitudinalStringDecay()
|
||||
{
|
||||
delete hadronizer;
|
||||
}
|
||||
|
||||
G4HadFinalState*
|
||||
G4VLongitudinalStringDecay::ApplyYourself(const G4HadProjectile&, G4Nucleus&)
|
||||
{
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
//=============================================================================
|
||||
|
||||
// Operators
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
G4bool G4VLongitudinalStringDecay::operator==(const G4VLongitudinalStringDecay &) const
|
||||
{
|
||||
throw G4HadronicException(__FILE__, __LINE__, "G4VLongitudinalStringDecay::operator== forbidden");
|
||||
return false;
|
||||
}
|
||||
|
||||
//-------------------------------------------------------------------------------------
|
||||
|
||||
G4bool G4VLongitudinalStringDecay::operator!=(const G4VLongitudinalStringDecay &) const
|
||||
{
|
||||
throw G4HadronicException(__FILE__, __LINE__, "G4VLongitudinalStringDecay::operator!= forbidden");
|
||||
return true;
|
||||
}
|
||||
|
||||
//***********************************************************************************
|
||||
|
||||
// For changing Mass Cut used for selection of very small mass strings
|
||||
void G4VLongitudinalStringDecay::SetMassCut(G4double aValue){ MassCut=aValue; }
|
||||
void G4VLongitudinalStringDecay::SetMassCut(G4double aValue){ MassCut=aValue; }
|
||||
G4double G4VLongitudinalStringDecay::GetMassCut() { return MassCut; }
|
||||
|
||||
//-----------------------------------------------------------------------------
|
||||
@@ -167,15 +156,15 @@ G4KineticTrackVector* G4VLongitudinalStringDecay::ProduceOneHadron(const G4Excit
|
||||
#ifdef debug_VStringDecay
|
||||
G4cout<<"G4VLongitudinalStringDecay::ProduceOneHadron: PossibleHmass StrMass "
|
||||
<<aString.Mass()<<" MassCut "<<MassCut<<G4endl;
|
||||
G4cout<<"G4VLongitudinalStringDecay::ProduceOneHadron: PossibleHmass StrMass WWW "
|
||||
<<aString.Mass()<<G4endl;
|
||||
#endif
|
||||
|
||||
|
||||
SetMinimalStringMass(&aString); // Uzhi June 2020
|
||||
|
||||
if ( sqr(PossibleHadronMass(&aString,0,&hadrons)+MassCut) < aString.Mass2()) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
// The string mass has low mass---------------------------
|
||||
// The string mass has low value
|
||||
|
||||
result=new G4KineticTrackVector;
|
||||
|
||||
@@ -184,7 +173,7 @@ G4KineticTrackVector* G4VLongitudinalStringDecay::ProduceOneHadron(const G4Excit
|
||||
// Substitute string by light hadron, Note that Energy is not conserved here!
|
||||
|
||||
#ifdef debug_VStringDecay
|
||||
G4cout << "VlongSF Warning replacing string by single hadron (G4VLongitudinalStringDecay)" <<G4endl;
|
||||
G4cout << "VlongSD Warning replacing string by single hadron (G4VLongitudinalStringDecay)" <<G4endl;
|
||||
G4cout << hadrons.first->GetParticleName()<<G4endl
|
||||
<< "string .. " << string->Get4Momentum() << " "
|
||||
<< string->Get4Momentum().m() << G4endl;
|
||||
@@ -195,11 +184,10 @@ G4KineticTrackVector* G4VLongitudinalStringDecay::ProduceOneHadron(const G4Excit
|
||||
result->push_back( new G4KineticTrack( hadrons.first, 0, string->GetPosition(), Mom ) );
|
||||
} else
|
||||
{
|
||||
// I do not know if this part work?
|
||||
//... string was qq--qqbar type: Build two stable hadrons,
|
||||
|
||||
#ifdef debug_VStringDecay
|
||||
G4cout << "VlongSF Warning replacing qq-qqbar string by TWO hadrons (G4VLongitudinalStringDecay)"
|
||||
G4cout << "VlongSD Warning replacing qq-qqbar string by TWO hadrons (G4VLongitudinalStringDecay)"
|
||||
<< hadrons.first->GetParticleName() << " / "
|
||||
<< hadrons.second->GetParticleName()
|
||||
<< "string .. " << string->Get4Momentum() << " "
|
||||
@@ -230,7 +218,8 @@ G4double G4VLongitudinalStringDecay::PossibleHadronMass( const G4FragmentingStri
|
||||
|
||||
if ( build==0 ) build=&G4HadronBuilder::BuildLowSpin;
|
||||
|
||||
G4ParticleDefinition *Hadron1, *Hadron2=0;
|
||||
G4ParticleDefinition* Hadron1 = nullptr;
|
||||
G4ParticleDefinition* Hadron2 = nullptr;
|
||||
|
||||
if (!string->IsAFourQuarkString() )
|
||||
{
|
||||
@@ -238,24 +227,26 @@ G4double G4VLongitudinalStringDecay::PossibleHadronMass( const G4FragmentingStri
|
||||
|
||||
Hadron1 = (hadronizer->*build)(string->GetLeftParton(), string->GetRightParton());
|
||||
#ifdef debug_VStringDecay
|
||||
G4cout<<"VlongSF Quarks at the string ends "<<string->GetLeftParton()->GetParticleName()
|
||||
G4cout<<"VlongSD PossibleHadronMass"<<G4endl;
|
||||
G4cout<<"VlongSD Quarks at the string ends "<<string->GetLeftParton()->GetParticleName()
|
||||
<<" "<<string->GetRightParton()->GetParticleName()<<G4endl;
|
||||
if ( Hadron1 != NULL) {
|
||||
if ( Hadron1 != nullptr) {
|
||||
G4cout<<"(G4VLongitudinalStringDecay) Hadron "<<Hadron1->GetParticleName()
|
||||
<<" "<<Hadron1->GetPDGMass()<<G4endl;
|
||||
}
|
||||
#endif
|
||||
if ( Hadron1 != NULL) { mass = (Hadron1)->GetPDGMass();}
|
||||
if ( Hadron1 != nullptr) { mass = (Hadron1)->GetPDGMass();}
|
||||
else { mass = MaxMass;}
|
||||
} else
|
||||
{
|
||||
//... string is qq--qqbar: Build two stable hadrons,
|
||||
//... with extra uubar or ddbar quark pair
|
||||
|
||||
#ifdef debug_VStringDecay
|
||||
G4cout<<"VlongSF string is qq--qqbar: Build two stable hadrons"<<G4endl;
|
||||
G4cout<<"VlongSD PossibleHadronMass"<<G4endl;
|
||||
G4cout<<"VlongSD string is qq--qqbar: Build two stable hadrons"<<G4endl;
|
||||
#endif
|
||||
|
||||
/* // Uzhi June 2020
|
||||
G4int iflc = (G4UniformRand() < 0.5)? 1 : 2;
|
||||
if (string->GetLeftParton()->GetPDGEncoding() < 0) iflc = -iflc;
|
||||
|
||||
@@ -263,12 +254,43 @@ G4double G4VLongitudinalStringDecay::PossibleHadronMass( const G4FragmentingStri
|
||||
Hadron1 = (hadronizer->*build)(string->GetLeftParton(), FindParticle(iflc));
|
||||
Hadron2 = (hadronizer->*build)(string->GetRightParton(), FindParticle(-iflc));
|
||||
|
||||
if ( (Hadron1 != NULL) && (Hadron2 != NULL) ) { mass = (Hadron1)->GetPDGMass() + (Hadron2)->GetPDGMass();}
|
||||
if ( (Hadron1 != nullptr) && (Hadron2 != nullptr) ) { mass = (Hadron1)->GetPDGMass() + (Hadron2)->GetPDGMass();}
|
||||
else { mass = MaxMass;}
|
||||
return mass;
|
||||
*/ // Uzhi June 2020
|
||||
//+++++++++++++++++++++++++++++++ // Uzhi June 2020 Start
|
||||
G4double StringMass = string->Mass();
|
||||
G4int cClusterInterrupt = 0;
|
||||
do
|
||||
{
|
||||
if (cClusterInterrupt++ >= ClusterLoopInterrupt) return false;
|
||||
|
||||
G4int LeftQuark1= string->GetLeftParton()->GetPDGEncoding()/1000;
|
||||
G4int LeftQuark2=(string->GetLeftParton()->GetPDGEncoding()/100)%10;
|
||||
|
||||
G4int RightQuark1= string->GetRightParton()->GetPDGEncoding()/1000;
|
||||
G4int RightQuark2=(string->GetRightParton()->GetPDGEncoding()/100)%10;
|
||||
|
||||
if (G4UniformRand()<0.5) {
|
||||
Hadron1 =hadronizer->Build(FindParticle(LeftQuark1), FindParticle(RightQuark1));
|
||||
Hadron2 =hadronizer->Build(FindParticle(LeftQuark2), FindParticle(RightQuark2));
|
||||
} else {
|
||||
Hadron1 =hadronizer->Build(FindParticle(LeftQuark1), FindParticle(RightQuark2));
|
||||
Hadron2 =hadronizer->Build(FindParticle(LeftQuark2), FindParticle(RightQuark1));
|
||||
}
|
||||
if ( (Hadron1 == nullptr) || (Hadron2 == nullptr) ) continue;
|
||||
|
||||
//... repeat procedure, if mass of cluster is too low to produce hadrons
|
||||
//... ClusterMassCut = 0.15*GeV model parameter
|
||||
}
|
||||
while ((StringMass <= Hadron1->GetPDGMass() + Hadron2->GetPDGMass()));
|
||||
|
||||
mass = (Hadron1)->GetPDGMass() + (Hadron2)->GetPDGMass();
|
||||
//+++++++++++++++++++++++++++++++ // Uzhi June 2020 End
|
||||
}
|
||||
|
||||
#ifdef debug_VStringDecay
|
||||
G4cout<<"VlongSF *Hadrons 1 and 2, proposed mass "<<Hadron1<<" "<<Hadron2<<" "<<mass<<G4endl;
|
||||
G4cout<<"VlongSD *Hadrons 1 and 2, proposed mass "<<Hadron1<<" "<<Hadron2<<" "<<mass<<G4endl;
|
||||
#endif
|
||||
|
||||
if ( pdefs != 0 )
|
||||
@@ -301,7 +323,7 @@ G4ParticleDefinition* G4VLongitudinalStringDecay::FindParticle(G4int Encoding)
|
||||
|
||||
G4ParticleDefinition* ptr = G4ParticleTable::GetParticleTable()->FindParticle(Encoding);
|
||||
|
||||
if (ptr == NULL)
|
||||
if (ptr == nullptr)
|
||||
{
|
||||
for (size_t i=0; i < NewParticles.size(); i++)
|
||||
{
|
||||
@@ -341,7 +363,7 @@ G4ParticleDefinition * G4VLongitudinalStringDecay::QuarkSplitup( G4ParticleDefin
|
||||
G4ParticleDefinition *&created )
|
||||
{
|
||||
#ifdef debug_VStringDecay
|
||||
G4cout<<"VlongSF QuarkSplitup: quark ID "<<decay->GetPDGEncoding()<<G4endl;
|
||||
G4cout<<"VlongSD QuarkSplitup: quark ID "<<decay->GetPDGEncoding()<<G4endl;
|
||||
#endif
|
||||
|
||||
G4int IsParticle=(decay->GetPDGEncoding()>0) ? -1 : +1; // if we have a quark, we need antiquark (or diquark)
|
||||
@@ -353,7 +375,7 @@ G4ParticleDefinition * G4VLongitudinalStringDecay::QuarkSplitup( G4ParticleDefin
|
||||
NewQuark = created->GetPDGEncoding();
|
||||
|
||||
#ifdef debug_VStringDecay
|
||||
G4cout<<"VlongSF QuarkSplitup: "<<decay->GetPDGEncoding()<<" -> "<<QuarkPair.second->GetPDGEncoding()<<G4endl;
|
||||
G4cout<<"VlongSD QuarkSplitup: "<<decay->GetPDGEncoding()<<" -> "<<QuarkPair.second->GetPDGEncoding()<<G4endl;
|
||||
G4cout<<"hadronizer->Build(QuarkPair.first, decay)"<<G4endl;
|
||||
#endif
|
||||
return hadronizer->Build(QuarkPair.first, decay);
|
||||
@@ -369,7 +391,7 @@ CreatePartonPair(G4int NeedParticle,G4bool AllowDiquarks)
|
||||
{
|
||||
// Create a Diquark - AntiDiquark pair , first in pair is anti to IsParticle
|
||||
#ifdef debug_VStringDecay
|
||||
G4cout<<"VlongSF Create a Diquark - AntiDiquark pair"<<G4endl;
|
||||
G4cout<<"VlongSD Create a Diquark - AntiDiquark pair"<<G4endl;
|
||||
#endif
|
||||
G4int q1(0), q2(0), spin(0), PDGcode(0);
|
||||
|
||||
@@ -385,7 +407,7 @@ CreatePartonPair(G4int NeedParticle,G4bool AllowDiquarks)
|
||||
} else {
|
||||
// Create a Quark - AntiQuark pair, first in pair IsParticle
|
||||
#ifdef debug_VStringDecay
|
||||
G4cout<<"VlongSF Create a Quark - AntiQuark pair"<<G4endl;
|
||||
G4cout<<"VlongSD Create a Quark - AntiQuark pair"<<G4endl;
|
||||
#endif
|
||||
G4int PDGcode=SampleQuarkFlavor()*NeedParticle;
|
||||
return pDefPair (FindParticle(PDGcode),FindParticle(-PDGcode));
|
||||
@@ -405,7 +427,7 @@ G4int G4VLongitudinalStringDecay::SampleQuarkFlavor(void)
|
||||
quark = 1 + (int)(G4UniformRand()/StrangeSuppress);
|
||||
}
|
||||
#ifdef debug_VStringDecay
|
||||
G4cout<<"VlongSF SampleQuarkFlavor "<<quark<<" (ProbCB ProbCCbar ProbBBbar "<<ProbCB
|
||||
G4cout<<"VlongSD SampleQuarkFlavor "<<quark<<" (ProbCB ProbCCbar ProbBBbar "<<ProbCB
|
||||
<<" "<<ProbCCbar<<" "<<ProbBBbar<<" )"<<G4endl;
|
||||
#endif
|
||||
return quark;
|
||||
@@ -620,11 +642,11 @@ void G4VLongitudinalStringDecay::SetMinMasses()
|
||||
Code1 = 100*i + 10*1 + 1;
|
||||
hadron1 = FindParticle(Code1);
|
||||
|
||||
if (hadron1 != NULL) {
|
||||
if (hadron1 != nullptr) {
|
||||
for (G4int j=1; j < 6; j++) {
|
||||
Code2 = 100*j + 10*1 + 1;
|
||||
hadron2 = FindParticle(Code2);
|
||||
if (hadron2 != NULL) {
|
||||
if (hadron2 != nullptr) {
|
||||
minMassQQbarStr[i-1][j-1] = hadron1->GetPDGMass() + hadron2->GetPDGMass() + 70.0 * MeV;
|
||||
}
|
||||
}
|
||||
@@ -653,15 +675,15 @@ void G4VLongitudinalStringDecay::SetMinMasses()
|
||||
hadron2 = G4ParticleTable::GetParticleTable()->FindParticle(Code2);
|
||||
hadron3 = G4ParticleTable::GetParticleTable()->FindParticle(Code2 + 2);
|
||||
|
||||
if ((hadron2 == NULL) && (hadron3 == NULL)) {minMassQDiQStr[i-1][j-1][k-1] = MaxMass; continue;};
|
||||
if ((hadron2 == nullptr) && (hadron3 == nullptr)) {minMassQDiQStr[i-1][j-1][k-1] = MaxMass; continue;};
|
||||
|
||||
if ((hadron2 != NULL) && (hadron3 != NULL)) {
|
||||
if ((hadron2 != nullptr) && (hadron3 != nullptr)) {
|
||||
if (hadron2->GetPDGMass() > hadron3->GetPDGMass() ) { hadron2 = hadron3; }
|
||||
};
|
||||
|
||||
if ((hadron2 != NULL) && (hadron3 == NULL)) {};
|
||||
if ((hadron2 != nullptr) && (hadron3 == nullptr)) {};
|
||||
|
||||
if ((hadron2 == NULL) && (hadron3 != NULL)) {hadron2 = hadron3;};
|
||||
if ((hadron2 == nullptr) && (hadron3 != nullptr)) {hadron2 = hadron3;};
|
||||
|
||||
minMassQDiQStr[i-1][j-1][k-1] = hadron1->GetPDGMass() + hadron2->GetPDGMass() + 70.0 * MeV;
|
||||
}
|
||||
@@ -917,12 +939,12 @@ void G4VLongitudinalStringDecay::SetMinMasses()
|
||||
G4ParticleTable::GetParticleTable()->FindParticle(Baryon[i][j][k][l]);
|
||||
/*
|
||||
G4cout<<i<<" "<<j<<" "<<k<<" "<<l<<" "<<Baryon[i][j][k][l]<<" "<<TestHadron<<" "<<BaryonWeight[i][j][k][l];
|
||||
if (TestHadron != NULL) G4cout<<" "<<TestHadron->GetParticleName();
|
||||
if ((TestHadron == NULL)&&(Baryon[i][j][k][l] != 0)) G4cout<<" *****";
|
||||
if ((TestHadron == NULL)&&(Baryon[i][j][k][l] == 0)) G4cout<<" ---------------";
|
||||
if (TestHadron != nullptr) G4cout<<" "<<TestHadron->GetParticleName();
|
||||
if ((TestHadron == nullptr)&&(Baryon[i][j][k][l] != 0)) G4cout<<" *****";
|
||||
if ((TestHadron == nullptr)&&(Baryon[i][j][k][l] == 0)) G4cout<<" ---------------";
|
||||
G4cout<<G4endl;
|
||||
*/
|
||||
if ((TestHadron == NULL)&&(Baryon[i][j][k][l] != 0)) Baryon[i][j][k][l] = 0;
|
||||
if ((TestHadron == nullptr)&&(Baryon[i][j][k][l] != 0)) Baryon[i][j][k][l] = 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -950,8 +972,27 @@ void G4VLongitudinalStringDecay::SetMinMasses()
|
||||
void G4VLongitudinalStringDecay::SetMinimalStringMass(const G4FragmentingString * const string)
|
||||
{
|
||||
//MaxMass = -350.0*GeV;
|
||||
G4double EstimatedMass=0.;
|
||||
G4double EstimatedMass=MaxMass; // Uzhi June 2020 0.->MaxMass;
|
||||
|
||||
// Uzhi June 2020 Start
|
||||
G4ParticleDefinition* LeftParton = string->GetLeftParton();
|
||||
G4ParticleDefinition* RightParton = string->GetRightParton();
|
||||
if( LeftParton->GetParticleSubType() == RightParton->GetParticleSubType() ) { // q qbar, qq qqbar
|
||||
if( LeftParton->GetPDGEncoding() * RightParton->GetPDGEncoding() > 0 ) {
|
||||
// Not allowed combination of the partons
|
||||
throw G4HadronicException(__FILE__, __LINE__,
|
||||
"G4VLongitudinalStringDecay::SetMinimalStringMass: Illegal quark content as input");
|
||||
}
|
||||
}
|
||||
if( LeftParton->GetParticleSubType() != RightParton->GetParticleSubType() ) { // q qq, qbar qqbar
|
||||
if( LeftParton->GetPDGEncoding() * RightParton->GetPDGEncoding() < 0 ) {
|
||||
// Not allowed combination of the partons
|
||||
throw G4HadronicException(__FILE__, __LINE__,
|
||||
"G4VLongitudinalStringDecay::SetMinimalStringMass: Illegal quark content as input");
|
||||
}
|
||||
}
|
||||
// Uzhi June 2020 End
|
||||
|
||||
G4int Qleft =std::abs(string->GetLeftParton()->GetPDGEncoding());
|
||||
G4int Qright=std::abs(string->GetRightParton()->GetPDGEncoding());
|
||||
|
||||
|
||||
@@ -14,6 +14,15 @@ code and to keep track of all tags.
|
||||
* Please list in reverse chronological order (last date on top)
|
||||
---------------------------------------------------------------
|
||||
|
||||
08-Mar-2020 V. Ivanchenko hadr-partonstring-mgt-V10-06-01
|
||||
- G4VParticipants, G4VPartonStringModel, G4VStringFragmentation,
|
||||
G4StringModel - clean-up: removed unused methods, delete
|
||||
operators, use C++11 keywords
|
||||
|
||||
24-Feb-2020 V. Ivanchenko hadr-partonstring-mgt-V10-06-00
|
||||
- G4VStringFragmentation : use inheritance from G4HadronicInteraction;
|
||||
removed implementations of private operators.
|
||||
|
||||
28-Nov-2019 A. Ribon hadr-partonstring-mgt-V10-05-02
|
||||
- G4VPartonStringModel : fixed bug (use of "=" instead of "==" in
|
||||
if-statement, found by Coverity) in the Scatter method.
|
||||
|
||||
@@ -39,42 +39,26 @@ class G4StringModel : public G4VHighEnergyGenerator
|
||||
{
|
||||
public:
|
||||
G4StringModel();
|
||||
~G4StringModel();
|
||||
~G4StringModel() override;
|
||||
|
||||
private:
|
||||
G4StringModel(const G4StringModel &right);
|
||||
const G4StringModel & operator=(const G4StringModel &right);
|
||||
G4bool operator==(const G4StringModel &right) const;
|
||||
G4bool operator!=(const G4StringModel &right) const;
|
||||
G4StringModel(const G4StringModel &right) = delete;
|
||||
const G4StringModel & operator=(const G4StringModel &right) = delete;
|
||||
G4bool operator==(const G4StringModel &right) const = delete;
|
||||
G4bool operator!=(const G4StringModel &right) const = delete;
|
||||
|
||||
public:
|
||||
void Set3DNucleus(G4V3DNucleus *const value);
|
||||
void SetStringFragmentationModel(G4VStringFragmentation *const value);
|
||||
|
||||
private:
|
||||
const G4V3DNucleus * Get3DNucleus() const;
|
||||
const G4VStringFragmentation * GetStringFragmentationModel() const;
|
||||
|
||||
private:
|
||||
G4V3DNucleus *the3DNucleus;
|
||||
G4VStringFragmentation *theStringFragmentationModel;
|
||||
};
|
||||
|
||||
inline const G4V3DNucleus * G4StringModel::Get3DNucleus() const
|
||||
{
|
||||
return the3DNucleus;
|
||||
}
|
||||
|
||||
inline void G4StringModel::Set3DNucleus(G4V3DNucleus *const value)
|
||||
{
|
||||
the3DNucleus = value;
|
||||
}
|
||||
|
||||
inline const G4VStringFragmentation * G4StringModel::GetStringFragmentationModel() const
|
||||
{
|
||||
return theStringFragmentationModel;
|
||||
}
|
||||
|
||||
inline void G4StringModel::SetStringFragmentationModel(G4VStringFragmentation *const value)
|
||||
{
|
||||
theStringFragmentationModel = value;
|
||||
|
||||
+6
-8
@@ -43,17 +43,16 @@
|
||||
|
||||
class G4V3DNucleus;
|
||||
|
||||
|
||||
class G4VParticipants
|
||||
{
|
||||
public:
|
||||
G4VParticipants();
|
||||
G4VParticipants(const G4VParticipants &right);
|
||||
virtual ~G4VParticipants();
|
||||
|
||||
const G4VParticipants & operator=(const G4VParticipants &right);
|
||||
G4bool operator==(const G4VParticipants &right) const;
|
||||
G4bool operator!=(const G4VParticipants &right) const;
|
||||
G4VParticipants(const G4VParticipants &right) = delete;
|
||||
const G4VParticipants & operator=(const G4VParticipants &right) = delete;
|
||||
G4bool operator==(const G4VParticipants &right) const = delete;
|
||||
G4bool operator!=(const G4VParticipants &right) const = delete;
|
||||
|
||||
virtual void Init(G4int theZ, G4int theA);
|
||||
virtual void SetNucleus(G4V3DNucleus* aNucleus);
|
||||
@@ -63,10 +62,9 @@ class G4VParticipants
|
||||
virtual void SetProjectileNucleus(G4V3DNucleus* aNucleus);
|
||||
virtual G4V3DNucleus* GetProjectileNucleus() const;
|
||||
|
||||
protected:
|
||||
G4V3DNucleus* theNucleus;
|
||||
G4V3DNucleus* theProjectileNucleus;
|
||||
private:
|
||||
|
||||
G4V3DNucleus* theProjectileNucleus;
|
||||
};
|
||||
|
||||
// Class G4VParticipants
|
||||
|
||||
+13
-19
@@ -51,41 +51,35 @@ class G4VPartonStringModel : public G4VHighEnergyGenerator
|
||||
{
|
||||
public:
|
||||
G4VPartonStringModel(const G4String& modelName = "Parton String Model");
|
||||
virtual ~G4VPartonStringModel();
|
||||
~G4VPartonStringModel() override;
|
||||
|
||||
private:
|
||||
G4VPartonStringModel(const G4VPartonStringModel &right);
|
||||
const G4VPartonStringModel & operator=(const G4VPartonStringModel &right);
|
||||
G4bool operator==(const G4VPartonStringModel &right) const;
|
||||
G4bool operator!=(const G4VPartonStringModel &right) const;
|
||||
G4VPartonStringModel(const G4VPartonStringModel &right) = delete;
|
||||
const G4VPartonStringModel & operator=
|
||||
(const G4VPartonStringModel &right) = delete;
|
||||
G4bool operator==(const G4VPartonStringModel &right) const = delete;
|
||||
G4bool operator!=(const G4VPartonStringModel &right) const = delete;
|
||||
|
||||
public:
|
||||
void SetFragmentationModel(G4VStringFragmentation * aModel);
|
||||
G4KineticTrackVector * Scatter(const G4Nucleus &theNucleus, const G4DynamicParticle &thePrimary);
|
||||
virtual G4V3DNucleus * GetWoundedNucleus() const = 0;
|
||||
virtual void ModelDescription(std::ostream& outFile) const;
|
||||
virtual G4V3DNucleus * GetProjectileNucleus() const;
|
||||
G4KineticTrackVector * Scatter(const G4Nucleus &theNucleus,
|
||||
const G4DynamicParticle &thePrimary) override;
|
||||
void ModelDescription(std::ostream& outFile) const override;
|
||||
G4V3DNucleus * GetProjectileNucleus() const override;
|
||||
|
||||
protected:
|
||||
virtual void Init(const G4Nucleus &theNucleus, const G4DynamicParticle &thePrimary) = 0;
|
||||
virtual G4ExcitedStringVector * GetStrings() = 0;
|
||||
void SetThisPointer(G4VPartonStringModel * aPointer);
|
||||
|
||||
G4bool EnergyAndMomentumCorrector(G4KineticTrackVector* Output, G4LorentzVector& TotalCollisionMomentum);
|
||||
|
||||
private:
|
||||
G4VStringFragmentation * stringFragmentationModel;
|
||||
G4VPartonStringModel * theThis;
|
||||
};
|
||||
|
||||
inline void G4VPartonStringModel::SetFragmentationModel(G4VStringFragmentation * aModel)
|
||||
{
|
||||
stringFragmentationModel = aModel;
|
||||
}
|
||||
|
||||
inline void G4VPartonStringModel::SetThisPointer(G4VPartonStringModel * aPointer)
|
||||
{
|
||||
theThis=aPointer;
|
||||
if(aModel != stringFragmentationModel) {
|
||||
stringFragmentationModel = aModel;
|
||||
}
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
+9
-11
@@ -28,27 +28,25 @@
|
||||
#ifndef G4VStringFragmentation_h
|
||||
#define G4VStringFragmentation_h 1
|
||||
|
||||
#include "G4HadronicInteraction.hh"
|
||||
#include "G4ExcitedStringVector.hh"
|
||||
|
||||
class G4KineticTrackVector;
|
||||
|
||||
class G4VStringFragmentation
|
||||
class G4VStringFragmentation : public G4HadronicInteraction
|
||||
{
|
||||
public:
|
||||
G4VStringFragmentation();
|
||||
virtual ~G4VStringFragmentation();
|
||||
G4VStringFragmentation(const G4String& name = "StringFragmentation");
|
||||
~G4VStringFragmentation() override;
|
||||
|
||||
private:
|
||||
G4VStringFragmentation(const G4VStringFragmentation &right);
|
||||
const G4VStringFragmentation & operator=(const G4VStringFragmentation &right);
|
||||
G4bool operator==(const G4VStringFragmentation &right) const;
|
||||
G4bool operator!=(const G4VStringFragmentation &right) const;
|
||||
G4VStringFragmentation(const G4VStringFragmentation &right) = delete;
|
||||
const G4VStringFragmentation & operator=
|
||||
(const G4VStringFragmentation &right) = delete;
|
||||
G4bool operator==(const G4VStringFragmentation &right) const = delete;
|
||||
G4bool operator!=(const G4VStringFragmentation &right) const = delete;
|
||||
|
||||
public:
|
||||
virtual G4KineticTrackVector * FragmentStrings(const G4ExcitedStringVector * theStrings)=0;
|
||||
|
||||
private:
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
#include "G4StringModel.hh"
|
||||
|
||||
G4StringModel::G4StringModel() : G4VHighEnergyGenerator(),
|
||||
the3DNucleus(0), theStringFragmentationModel(0)
|
||||
the3DNucleus(nullptr), theStringFragmentationModel(nullptr)
|
||||
{
|
||||
}
|
||||
|
||||
@@ -37,27 +37,4 @@ G4StringModel::~G4StringModel()
|
||||
{
|
||||
}
|
||||
|
||||
// private:
|
||||
G4StringModel::G4StringModel(const G4StringModel &) : G4VHighEnergyGenerator(),
|
||||
the3DNucleus(0), theStringFragmentationModel(0)
|
||||
{
|
||||
}
|
||||
|
||||
const G4StringModel & G4StringModel::operator=(const G4StringModel &)
|
||||
{
|
||||
throw G4HadronicException(__FILE__, __LINE__,
|
||||
"G4StringModel::operator= meant to not be accessable");
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
||||
G4bool G4StringModel::operator==(const G4StringModel &) const
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
G4bool G4StringModel::operator!=(const G4StringModel &) const
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
@@ -40,44 +40,42 @@
|
||||
#include "G4Fancy3DNucleus.hh"
|
||||
|
||||
|
||||
G4VParticipants::G4VParticipants() : theNucleus(NULL),
|
||||
theProjectileNucleus(NULL)
|
||||
G4VParticipants::G4VParticipants() : theNucleus(nullptr),
|
||||
theProjectileNucleus(nullptr)
|
||||
{}
|
||||
|
||||
|
||||
G4VParticipants::~G4VParticipants()
|
||||
{
|
||||
// G4cout << "G4VParticipants::~G4VParticipants()" << G4endl;
|
||||
if ( theNucleus != NULL ) delete theNucleus;
|
||||
if ( theProjectileNucleus != NULL ) delete theProjectileNucleus;
|
||||
if ( theNucleus != nullptr ) delete theNucleus;
|
||||
if ( theProjectileNucleus != nullptr ) delete theProjectileNucleus;
|
||||
}
|
||||
|
||||
|
||||
void G4VParticipants::Init(G4int theA, G4int theZ)
|
||||
{
|
||||
if ( theNucleus == NULL ) theNucleus = new G4Fancy3DNucleus();
|
||||
if ( theNucleus == nullptr ) theNucleus = new G4Fancy3DNucleus();
|
||||
theNucleus->Init(theA, theZ);
|
||||
theNucleus->SortNucleonsIncZ();
|
||||
}
|
||||
|
||||
|
||||
void G4VParticipants::SetNucleus(G4V3DNucleus * aNucleus)
|
||||
{
|
||||
if (theNucleus != NULL) delete theNucleus;
|
||||
if (theNucleus != nullptr) delete theNucleus;
|
||||
theNucleus = aNucleus;
|
||||
}
|
||||
|
||||
void G4VParticipants::InitProjectileNucleus(G4int theA, G4int theZ)
|
||||
{
|
||||
if ( theProjectileNucleus == NULL ) theProjectileNucleus = new G4Fancy3DNucleus();
|
||||
if ( theProjectileNucleus == nullptr )
|
||||
theProjectileNucleus = new G4Fancy3DNucleus();
|
||||
|
||||
theProjectileNucleus->Init(theA, theZ);
|
||||
theProjectileNucleus->SortNucleonsDecZ();
|
||||
}
|
||||
|
||||
|
||||
void G4VParticipants::SetProjectileNucleus(G4V3DNucleus * aNucleus)
|
||||
{
|
||||
if (theProjectileNucleus != NULL) delete theProjectileNucleus;
|
||||
if (theProjectileNucleus != nullptr) delete theProjectileNucleus;
|
||||
theProjectileNucleus = aNucleus;
|
||||
}
|
||||
|
||||
|
||||
+22
-20
@@ -45,12 +45,14 @@
|
||||
|
||||
G4VPartonStringModel::G4VPartonStringModel(const G4String& modelName)
|
||||
: G4VHighEnergyGenerator(modelName),
|
||||
stringFragmentationModel(0),
|
||||
theThis(0)
|
||||
stringFragmentationModel(nullptr)
|
||||
{
|
||||
// Make shure Shotrylived particles are constructed.
|
||||
// Make shure Shotrylived particles are constructed.
|
||||
// VI: should not instantiate particles by any model
|
||||
/*
|
||||
G4ShortLivedConstructor ShortLived;
|
||||
ShortLived.ConstructParticle();
|
||||
*/
|
||||
}
|
||||
|
||||
G4VPartonStringModel::~G4VPartonStringModel()
|
||||
@@ -60,11 +62,11 @@ G4VPartonStringModel::~G4VPartonStringModel()
|
||||
G4KineticTrackVector * G4VPartonStringModel::Scatter(const G4Nucleus &theNucleus,
|
||||
const G4DynamicParticle &aPrimary)
|
||||
{
|
||||
G4ExcitedStringVector * strings = NULL;
|
||||
G4ExcitedStringVector * strings = nullptr;
|
||||
G4DynamicParticle thePrimary=aPrimary;
|
||||
G4LorentzVector SumStringMom(0.,0.,0.,0.);
|
||||
G4KineticTrackVector * theResult = 0;
|
||||
G4Nucleon * theNuclNucleon(0);
|
||||
G4Nucleon * theNuclNucleon(nullptr);
|
||||
|
||||
#ifdef debug_PartonStringModel
|
||||
G4cout<<G4endl;
|
||||
@@ -80,7 +82,7 @@ G4KineticTrackVector * G4VPartonStringModel::Scatter(const G4Nucleus &theNucleus
|
||||
G4cout<<"Initial charge "<<Qsum<<G4endl;
|
||||
G4cout<<"-------------- Parton-String model: Generation of strings -------"<<G4endl<<G4endl;
|
||||
Bsum -= theNucleus.GetA_asInt(); Qsum -= theNucleus.GetZ_asInt();
|
||||
if(theThis->GetProjectileNucleus()) {
|
||||
if(GetProjectileNucleus()) {
|
||||
Bsum -= thePrimary.GetDefinition()->GetBaryonNumber();
|
||||
Qsum -= thePrimary.GetDefinition()->GetPDGCharge();
|
||||
}
|
||||
@@ -101,20 +103,20 @@ G4KineticTrackVector * G4VPartonStringModel::Scatter(const G4Nucleus &theNucleus
|
||||
{
|
||||
if (attempts++ > maxAttempts )
|
||||
{
|
||||
theThis->Init(theNucleus,thePrimary); // To put a nucleus into ground state
|
||||
Init(theNucleus,thePrimary); // To put a nucleus into ground state
|
||||
// But marks of hitted nucleons are left. They must be erased.
|
||||
G4V3DNucleus * ResNucleus=theThis->GetWoundedNucleus();
|
||||
theNuclNucleon = ResNucleus->StartLoop() ? ResNucleus->GetNextNucleon() : NULL;
|
||||
G4V3DNucleus * ResNucleus = GetWoundedNucleus();
|
||||
theNuclNucleon = ResNucleus->StartLoop() ? ResNucleus->GetNextNucleon() : nullptr;
|
||||
while( theNuclNucleon )
|
||||
{
|
||||
if(theNuclNucleon->AreYouHit()) theNuclNucleon->Hit(nullptr);
|
||||
theNuclNucleon = ResNucleus->GetNextNucleon();
|
||||
}
|
||||
|
||||
G4V3DNucleus * ProjResNucleus=theThis->GetProjectileNucleus();
|
||||
G4V3DNucleus * ProjResNucleus = GetProjectileNucleus();
|
||||
if(ProjResNucleus != 0)
|
||||
{
|
||||
theNuclNucleon = ProjResNucleus->StartLoop() ? ProjResNucleus->GetNextNucleon() : NULL;
|
||||
theNuclNucleon = ProjResNucleus->StartLoop() ? ProjResNucleus->GetNextNucleon() : nullptr;
|
||||
while( theNuclNucleon )
|
||||
{
|
||||
if(theNuclNucleon->AreYouHit()) theNuclNucleon->Hit(nullptr);
|
||||
@@ -135,18 +137,18 @@ G4KineticTrackVector * G4VPartonStringModel::Scatter(const G4Nucleus &theNucleus
|
||||
G4ThreeVector Position(0.,0.,2*ResNucleus->GetOuterRadius());
|
||||
G4KineticTrack* Hadron = new G4KineticTrack(aPrimary.GetParticleDefinition(), 0.,
|
||||
Position, aPrimary.Get4Momentum());
|
||||
if(theResult == 0) theResult = new G4KineticTrackVector();
|
||||
if(theResult == nullptr) theResult = new G4KineticTrackVector();
|
||||
theResult->push_back(Hadron);
|
||||
return theResult;
|
||||
}
|
||||
|
||||
Success=true;
|
||||
|
||||
theThis->Init(theNucleus,thePrimary);
|
||||
Init(theNucleus,thePrimary);
|
||||
|
||||
strings = GetStrings();
|
||||
|
||||
if (strings->size() == 0) { Success=false; continue; }
|
||||
if (strings->empty()) { Success=false; continue; }
|
||||
|
||||
G4double stringEnergy(0);
|
||||
SumStringMom=G4LorentzVector(0.,0.,0.,0.);
|
||||
@@ -194,12 +196,12 @@ G4KineticTrackVector * G4VPartonStringModel::Scatter(const G4Nucleus &theNucleus
|
||||
G4double ExcitationEt(0.), ExcitationEp(0.);
|
||||
#endif
|
||||
|
||||
G4V3DNucleus * ProjResNucleus=theThis->GetProjectileNucleus();
|
||||
G4V3DNucleus * ProjResNucleus = GetProjectileNucleus();
|
||||
|
||||
G4int numberProtonProjectileResidual( 0 ), numberNeutronProjectileResidual( 0 );
|
||||
if(ProjResNucleus != 0)
|
||||
{
|
||||
theNuclNucleon = ProjResNucleus->StartLoop() ? ProjResNucleus->GetNextNucleon() : NULL;
|
||||
theNuclNucleon = ProjResNucleus->StartLoop() ? ProjResNucleus->GetNextNucleon() : nullptr;
|
||||
G4int numberProtonProjectileHits( 0 ), numberNeutronProjectileHits( 0 );
|
||||
while( theNuclNucleon )
|
||||
{
|
||||
@@ -230,10 +232,10 @@ G4KineticTrackVector * G4VPartonStringModel::Scatter(const G4Nucleus &theNucleus
|
||||
- thePrimary.GetDefinition()->GetPDGCharge() - numberNeutronProjectileHits;
|
||||
}
|
||||
|
||||
G4V3DNucleus * ResNucleus=theThis->GetWoundedNucleus();
|
||||
G4V3DNucleus * ResNucleus = GetWoundedNucleus();
|
||||
|
||||
// loop over wounded nucleus
|
||||
theNuclNucleon = ResNucleus->StartLoop() ? ResNucleus->GetNextNucleon() : NULL;
|
||||
theNuclNucleon = ResNucleus->StartLoop() ? ResNucleus->GetNextNucleon() : nullptr;
|
||||
G4int numberProtonTargetHits( 0 ), numberNeutronTargetHits( 0 );
|
||||
while( theNuclNucleon )
|
||||
{
|
||||
@@ -305,7 +307,7 @@ G4KineticTrackVector * G4VPartonStringModel::Scatter(const G4Nucleus &theNucleus
|
||||
SumPsecondr=G4LorentzVector(0.,0.,0.,0.);
|
||||
#endif
|
||||
|
||||
if(theResult != 0)
|
||||
if(theResult != nullptr)
|
||||
{
|
||||
std::for_each(theResult->begin(), theResult->end(), DeleteKineticTrack());
|
||||
delete theResult;
|
||||
@@ -375,5 +377,5 @@ void G4VPartonStringModel::ModelDescription(std::ostream& outFile) const
|
||||
}
|
||||
|
||||
G4V3DNucleus * G4VPartonStringModel::GetProjectileNucleus() const
|
||||
{ return 0; }
|
||||
{ return nullptr; }
|
||||
|
||||
|
||||
+4
-27
@@ -28,32 +28,9 @@
|
||||
// G4VStringFragmentation
|
||||
#include "G4VStringFragmentation.hh"
|
||||
|
||||
G4VStringFragmentation::G4VStringFragmentation()
|
||||
{
|
||||
}
|
||||
|
||||
G4VStringFragmentation::G4VStringFragmentation(const G4VStringFragmentation &)
|
||||
{
|
||||
}
|
||||
G4VStringFragmentation::G4VStringFragmentation(const G4String& name)
|
||||
: G4HadronicInteraction(name)
|
||||
{}
|
||||
|
||||
G4VStringFragmentation::~G4VStringFragmentation()
|
||||
{
|
||||
}
|
||||
|
||||
const G4VStringFragmentation & G4VStringFragmentation::operator=(const G4VStringFragmentation &)
|
||||
{
|
||||
throw G4HadronicException(__FILE__, __LINE__,
|
||||
"G4VStringFragmentation::operator= meant to not be accessable");
|
||||
return *this;
|
||||
}
|
||||
|
||||
G4bool G4VStringFragmentation::operator==(const G4VStringFragmentation &) const
|
||||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
G4bool G4VStringFragmentation::operator!=(const G4VStringFragmentation &) const
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
{}
|
||||
|
||||
@@ -14,6 +14,27 @@ code and to keep track of all tags.
|
||||
* Please list in reverse chronological order (last date on top)
|
||||
---------------------------------------------------------------
|
||||
|
||||
10-Jun-2020 A. Ribon (hadr-qgsm-V10-06-02)
|
||||
- Improved treatment of antibaryon interactions in QGS
|
||||
(made by Vladimir Uzhinsky):
|
||||
1. G4QGSParticipants : the average transverse momentum of partons
|
||||
in a hadron is set to zero (according to the study of transverse
|
||||
momentum distributions of hadrons produced in hadronic
|
||||
interactions, in particular the study of Xf - Pt correlations
|
||||
presented by the NA49 Collaboration).
|
||||
2. G4QuarkExchange : the reggeon exchanges are now treated as
|
||||
annihilation and creation of quark-antiquark pairs (to reflect
|
||||
in inelastic processes the non-vacuum reggeon exchanges present
|
||||
in antiparticle-particle elastic scattering amplitudes).
|
||||
|
||||
08-Mar-2020 V.Ivanchenko (hadr-qgsm-V10-06-01)
|
||||
- G4QGSModel - clean-up: removed unused methods, delete
|
||||
operators, use C++11 keywords, moved icc implementation to src
|
||||
|
||||
16-Jan-2020 A. Ribon (hadr-qgsm-V10-06-00)
|
||||
- G4SPBaryonTable : changed the return type of the method 'length()' from
|
||||
'double' to 'size_t' (to avoid warnings seen on Windows).
|
||||
|
||||
19-Nov-2019 A. Ribon (hadr-qgsm-V10-05-02)
|
||||
- G4VAnnihilationCrossSection, G4AnnihilationCrossSection,
|
||||
G4GammaAnnCrossSection, G4ASCCrossSection, G4QGSMParameters :
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
#include "G4SoftStringBuilder.hh"
|
||||
#include "G4PartonPair.hh"
|
||||
|
||||
//*****************************************************************************************
|
||||
//***************************************************************************
|
||||
|
||||
template<class ParticipantType>
|
||||
class G4QGSModel : public G4VPartonStringModel
|
||||
@@ -53,15 +53,19 @@ class G4QGSModel : public G4VPartonStringModel
|
||||
public:
|
||||
G4QGSModel();
|
||||
virtual ~G4QGSModel();
|
||||
G4QGSModel(const G4QGSModel &right);
|
||||
G4QGSModel& operator=(const G4QGSModel &right);
|
||||
|
||||
public:
|
||||
virtual G4V3DNucleus* GetWoundedNucleus() const;
|
||||
virtual G4V3DNucleus* GetProjectileNucleus() const;
|
||||
virtual void Init(const G4Nucleus& Nucleus, const G4DynamicParticle& Projectile);
|
||||
virtual G4ExcitedStringVector * GetStrings();
|
||||
virtual void ModelDescription(std::ostream& outFile) const;
|
||||
G4QGSModel(const G4QGSModel &right) = delete;
|
||||
G4QGSModel& operator=(const G4QGSModel &right) = delete;
|
||||
G4bool operator==(const G4QGSModel &right) const = delete;
|
||||
G4bool operator!=(const G4QGSModel &right) const = delete;
|
||||
|
||||
G4V3DNucleus* GetWoundedNucleus() const override;
|
||||
G4V3DNucleus* GetProjectileNucleus() const override;
|
||||
void ModelDescription(std::ostream& outFile) const override;
|
||||
|
||||
protected:
|
||||
void Init(const G4Nucleus& Nucleus, const G4DynamicParticle& dyn) override;
|
||||
G4ExcitedStringVector * GetStrings() override;
|
||||
|
||||
private:
|
||||
ParticipantType theParticipants;
|
||||
@@ -69,7 +73,7 @@ class G4QGSModel : public G4VPartonStringModel
|
||||
G4SoftStringBuilder theSoftStringBuilder;
|
||||
};
|
||||
|
||||
//*****************************************************************************************
|
||||
//***************************************************************************
|
||||
|
||||
#include "G4QGSModel.icc"
|
||||
|
||||
|
||||
@@ -23,57 +23,40 @@
|
||||
// * acceptance of all terms of the Geant4 Software license. *
|
||||
// ********************************************************************
|
||||
//
|
||||
//****************************************************************************
|
||||
|
||||
//************************************************************************************************
|
||||
template<class ParticipantType>
|
||||
G4QGSModel<ParticipantType>::G4QGSModel()
|
||||
{
|
||||
G4VPartonStringModel::SetThisPointer(this);
|
||||
SetEnergyMomentumCheckLevels(2*CLHEP::perCent, 150*CLHEP::MeV);
|
||||
}
|
||||
template<class ParticipantType>
|
||||
G4QGSModel<ParticipantType>::G4QGSModel(const G4QGSModel &right)
|
||||
{
|
||||
G4VPartonStringModel::SetThisPointer(this);
|
||||
std::pair<G4double, G4double> levels=right.GetEnergyMomentumCheckLevels();
|
||||
SetEnergyMomentumCheckLevels(levels.first, levels.second);
|
||||
}
|
||||
{
|
||||
SetEnergyMomentumCheckLevels(2*CLHEP::perCent, 150*CLHEP::MeV);
|
||||
}
|
||||
|
||||
template<class ParticipantType>
|
||||
G4QGSModel<ParticipantType>& G4QGSModel<ParticipantType>::operator=(const G4QGSModel &right)
|
||||
{
|
||||
if (this != &right )
|
||||
{
|
||||
G4VPartonStringModel::SetThisPointer(this);
|
||||
std::pair<G4double, G4double> levels=right.GetEnergyMomentumCheckLevels();
|
||||
SetEnergyMomentumCheckLevels(levels.first, levels.second);
|
||||
}
|
||||
}
|
||||
template<class ParticipantType>
|
||||
G4QGSModel<ParticipantType>::~G4QGSModel()
|
||||
{
|
||||
}
|
||||
{}
|
||||
|
||||
template<class ParticipantType>
|
||||
void G4QGSModel<ParticipantType>::Init(const G4Nucleus & aNucleus, const G4DynamicParticle & aProjectile)
|
||||
{
|
||||
// It is assumed that target nucleus is at rest.
|
||||
void G4QGSModel<ParticipantType>::Init(const G4Nucleus & aNucleus,
|
||||
const G4DynamicParticle & aProjectile)
|
||||
{
|
||||
// It is assumed that target nucleus is at rest.
|
||||
theParticipants.Init(aNucleus.GetA_asInt(),aNucleus.GetZ_asInt());
|
||||
|
||||
theParticipants.Init(aNucleus.GetA_asInt(),aNucleus.GetZ_asInt()); // Init of a target nucleus
|
||||
G4LorentzVector Mom = aProjectile.Get4Momentum();
|
||||
|
||||
G4LorentzVector Mom = aProjectile.Get4Momentum(); // Momentum of a projectile
|
||||
G4ReactionProduct theProjectile;
|
||||
theProjectile.SetDefinition(aProjectile.GetDefinition());
|
||||
theProjectile.SetTotalEnergy(Mom.e());
|
||||
theProjectile.SetMomentum(Mom.vect());
|
||||
|
||||
G4ReactionProduct theProjectile;
|
||||
theProjectile.SetDefinition(aProjectile.GetDefinition());
|
||||
theProjectile.SetTotalEnergy(Mom.e());
|
||||
theProjectile.SetMomentum(Mom.vect());
|
||||
|
||||
theParticipants.BuildInteractions(theProjectile); // Creation of strings and nuclear remnant
|
||||
}
|
||||
// Creation of strings and nuclear remnant
|
||||
theParticipants.BuildInteractions(theProjectile);
|
||||
}
|
||||
|
||||
template<class ParticipantType>
|
||||
G4ExcitedStringVector * G4QGSModel<ParticipantType>::GetStrings()
|
||||
{ // The strings are produced at theParticipants.BuildInteractions(theProjectile)
|
||||
{
|
||||
// The strings are produced at theParticipants.BuildInteractions(theProjectile)
|
||||
|
||||
G4PartonPair* aPair;
|
||||
G4ExcitedStringVector* theStrings = new G4ExcitedStringVector;
|
||||
@@ -89,7 +72,7 @@ G4ExcitedStringVector * G4QGSModel<ParticipantType>::GetStrings()
|
||||
aString = theSoftStringBuilder.BuildString(aPair);
|
||||
}
|
||||
|
||||
// aString->Boost(theCurrentVelocity);
|
||||
// aString->Boost(theCurrentVelocity);
|
||||
theStrings->push_back(aString);
|
||||
delete aPair;
|
||||
}
|
||||
@@ -106,7 +89,7 @@ G4V3DNucleus* G4QGSModel<ParticipantType>::GetWoundedNucleus() const
|
||||
template<class ParticipantType>
|
||||
G4V3DNucleus* G4QGSModel<ParticipantType>::GetProjectileNucleus() const
|
||||
{
|
||||
return 0;
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
template<class ParticipantType>
|
||||
@@ -119,5 +102,5 @@ void G4QGSModel<ParticipantType>::ModelDescription(std::ostream& outFile) const
|
||||
<< "into quarks and di-quarks, the formation and excitation of\n"
|
||||
<< "quark-gluon strings, string hadronization and diffractive dissociation.\n";
|
||||
}
|
||||
//************************************************************************************************
|
||||
//****************************************************************************
|
||||
|
||||
|
||||
@@ -61,6 +61,8 @@ class G4QuarkExchange
|
||||
const G4QuarkExchange & operator=(const G4QuarkExchange &right);
|
||||
G4bool operator==(const G4QuarkExchange &right) const;
|
||||
G4bool operator!=(const G4QuarkExchange &right) const;
|
||||
|
||||
G4double StrangeSuppress; // Uzhi June 2020
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -36,7 +36,7 @@ class G4SPBaryonTable
|
||||
|
||||
~G4SPBaryonTable() {std::for_each(theBaryons.begin(), theBaryons.end(), G4SPBaryonTable::DeleteSPBaryon());}
|
||||
void insert(G4SPBaryon * aBaryon) { theBaryons.push_back(aBaryon);}
|
||||
G4double length() {return theBaryons.size();}
|
||||
std::size_t length() {return theBaryons.size();}
|
||||
|
||||
const G4SPBaryon * GetBaryon(G4ParticleDefinition * aDefinition);
|
||||
|
||||
|
||||
@@ -58,8 +58,7 @@ G4QGSParticipants::G4QGSParticipants() : theDiffExcitaton(),
|
||||
SetPt2ofNuclearDestruction( 0.075*GeV*GeV );
|
||||
SetMaxPt2ofNuclearDestruction( 1.0*GeV*GeV );
|
||||
SetExcitationEnergyPerWoundedNucleon( 40.0*MeV );
|
||||
|
||||
sigmaPt=0.25*sqr(GeV);
|
||||
sigmaPt=0.0; // Uzhi June 2020 : sigmaPt=0.25*sqrt(GeV);
|
||||
}
|
||||
|
||||
G4QGSParticipants::G4QGSParticipants(const G4QGSParticipants &right)
|
||||
|
||||
@@ -45,12 +45,18 @@
|
||||
#include "G4VSplitableHadron.hh"
|
||||
#include "G4ExcitedString.hh"
|
||||
|
||||
#include "G4ParticleTable.hh" // Uzhi June 2020
|
||||
|
||||
#include "G4Log.hh"
|
||||
#include "G4Pow.hh"
|
||||
|
||||
//#define debugQuarkExchange
|
||||
|
||||
G4QuarkExchange::G4QuarkExchange(){}
|
||||
G4QuarkExchange::G4QuarkExchange()
|
||||
{
|
||||
StrangeSuppress = (1.0-0.04)/2.0; // Uzhi June 2020 : suppression of strange quark pair prodution,
|
||||
// i.e. u:d:s=1:1:0.04 . Need to be tuned!
|
||||
}
|
||||
|
||||
G4QuarkExchange::~G4QuarkExchange(){}
|
||||
|
||||
@@ -135,6 +141,8 @@ ExciteParticipants(G4VSplitableHadron *projectile, G4VSplitableHadron *target) c
|
||||
if ( (absPDGcode == 321) || (absPDGcode == 311) ||
|
||||
( PDGcode == 130) || ( PDGcode == 310) ) { ProjectileDiffraction = G4UniformRand() <= 0.5; }
|
||||
|
||||
//G4cout<<"ProjectileDiffr "<<ProjectileDiffraction<<G4endl;
|
||||
|
||||
if ( ProjectileDiffraction ) {
|
||||
if ( absPDGcode > 1000 ) //------Projectile is baryon --------
|
||||
{
|
||||
@@ -354,12 +362,32 @@ ExciteParticipants(G4VSplitableHadron *projectile, G4VSplitableHadron *target) c
|
||||
projectile->SplitUp();
|
||||
target->SplitUp();
|
||||
|
||||
G4Parton* PrQuark = projectile->GetNextParton();
|
||||
G4Parton* TrQuark = target->GetNextParton();
|
||||
G4Parton* PrQuark = nullptr;
|
||||
G4Parton* TrQuark = nullptr;
|
||||
|
||||
G4ParticleDefinition * Tmp = PrQuark->GetDefinition();
|
||||
PrQuark->SetDefinition(TrQuark->GetDefinition());
|
||||
TrQuark->SetDefinition(Tmp);
|
||||
if( projectile->GetDefinition()->GetBaryonNumber() >= 0 ) { // Uzhi June 2020
|
||||
// Quark exchange ----
|
||||
PrQuark = projectile->GetNextParton();
|
||||
TrQuark = target->GetNextParton();
|
||||
G4ParticleDefinition * Tmp = PrQuark->GetDefinition();
|
||||
PrQuark->SetDefinition(TrQuark->GetDefinition());
|
||||
TrQuark->SetDefinition(Tmp);
|
||||
return true;
|
||||
}
|
||||
|
||||
// Quark exchage for projectile anti-baryon (annihilation and new Q pair creation ---
|
||||
// This part added by Uzhi June 2020
|
||||
PrQuark = projectile->GetNextAntiParton();
|
||||
TrQuark = target->GetNextParton();
|
||||
if( -PrQuark->GetDefinition()->GetPDGEncoding() == TrQuark->GetDefinition()->GetPDGEncoding() ){
|
||||
G4int QuarkCode = 1 + (int)(G4UniformRand()/StrangeSuppress);
|
||||
G4ParticleDefinition* AQpr = G4ParticleTable::GetParticleTable()->FindParticle(-QuarkCode);
|
||||
G4ParticleDefinition* Qtr = G4ParticleTable::GetParticleTable()->FindParticle( QuarkCode);
|
||||
if( (AQpr != nullptr) && (Qtr != nullptr) ) {
|
||||
PrQuark->SetDefinition(AQpr);
|
||||
TrQuark->SetDefinition( Qtr);
|
||||
}
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user