Import Geant4 10.7.0.beta source tree

This commit is contained in:
Gabriele Cosmo
2020-06-26 10:23:25 +02:00
parent c02c370437
commit 67ba86d073
1871 changed files with 174422 additions and 131884 deletions
@@ -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);