Import Geant4 10.5.0.beta source tree

This commit is contained in:
Gabriele Cosmo
2018-06-29 10:58:11 +02:00
parent fe81a77428
commit 6aa23be517
1581 changed files with 124288 additions and 83758 deletions
@@ -29,12 +29,10 @@
#define G4HadLeadBias_h
#include "G4VLeadingParticleBiasing.hh"
#include <vector>
#include "G4HadFinalState.hh"
class G4HadLeadBias : public G4VLeadingParticleBiasing
{
public:
public:
virtual G4HadFinalState * Bias(G4HadFinalState * result);
virtual ~G4HadLeadBias() {};
};
@@ -50,17 +50,19 @@ class G4HadronInelasticProcess : public G4HadronicProcess
public:
G4HadronInelasticProcess(const G4String &processName,
G4ParticleDefinition *aParticle );
G4ParticleDefinition*);
virtual ~G4HadronInelasticProcess();
~G4HadronInelasticProcess() override;
virtual G4bool IsApplicable(const G4ParticleDefinition& aParticleType);
G4bool IsApplicable(const G4ParticleDefinition&) override;
private:
G4ParticleDefinition* theParticle;
// hide assignment operator as private
G4HadronInelasticProcess& operator=
(const G4HadronInelasticProcess& right) = delete;
G4HadronInelasticProcess(const G4HadronInelasticProcess&) = delete;
};
#endif
@@ -23,7 +23,7 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4HadronicProcess.hh 104121 2017-05-11 13:49:37Z gcosmo $
// $Id: G4HadronicProcess.hh 110586 2018-05-31 12:01:42Z gcosmo $
//
// -------------------------------------------------------------------
//
@@ -53,18 +53,18 @@
#include "G4EnergyRangeManager.hh"
#include "G4Nucleus.hh"
#include "G4ReactionProduct.hh"
#include <vector>
#include "G4VCrossSectionDataSet.hh"
#include "G4VLeadingParticleBiasing.hh"
#include "G4CrossSectionDataStore.hh"
#include "G4HadronicProcessType.hh"
#include "G4CrossSectionDataStore.hh"
#include <vector>
class G4Track;
class G4Step;
class G4Element;
class G4ParticleChange;
class G4HadronicInteraction;
class G4HadronicProcessStore;
class G4VCrossSectionDataSet;
class G4VLeadingParticleBiasing;
class G4HadronicProcess : public G4VDiscreteProcess
{
@@ -76,7 +76,7 @@ public:
G4HadronicProcess(const G4String& processName,
G4HadronicProcessType subType);
virtual ~G4HadronicProcess();
~G4HadronicProcess() override;
// register generator of secondaries
void RegisterMe(G4HadronicInteraction* a);
@@ -94,30 +94,27 @@ public:
{ return GetElementCrossSection(part, elm, mat); }
// generic PostStepDoIt recommended for all derived classes
virtual G4VParticleChange* PostStepDoIt(const G4Track& aTrack,
const G4Step& aStep);
G4VParticleChange* PostStepDoIt(const G4Track& aTrack,
const G4Step& aStep) override;
// initialisation of physics tables and G4HadronicProcessStore
virtual void PreparePhysicsTable(const G4ParticleDefinition&);
void PreparePhysicsTable(const G4ParticleDefinition&) override;
// build physics tables and print out the configuration of the process
virtual void BuildPhysicsTable(const G4ParticleDefinition&);
void BuildPhysicsTable(const G4ParticleDefinition&) override;
// dump physics tables
inline void DumpPhysicsTable(const G4ParticleDefinition& p)
{ theCrossSectionDataStore->DumpPhysicsTable(p); }
void DumpPhysicsTable(const G4ParticleDefinition& p);
// add cross section data set
inline void AddDataSet(G4VCrossSectionDataSet * aDataSet)
{ theCrossSectionDataStore->AddDataSet(aDataSet);}
void AddDataSet(G4VCrossSectionDataSet * aDataSet);
// access to the list of hadronic interactions
std::vector<G4HadronicInteraction*>& GetHadronicInteractionList()
{ return theEnergyRangeManager.GetHadronicInteractionList(); }
std::vector<G4HadronicInteraction*>& GetHadronicInteractionList();
// get inverse cross section per volume
G4double GetMeanFreePath(const G4Track &aTrack, G4double,
G4ForceCondition *);
G4ForceCondition *) override;
// access to the target nucleus
inline const G4Nucleus* GetTargetNucleus() const
@@ -127,15 +124,15 @@ public:
inline const G4Isotope* GetTargetIsotope()
{ return targetNucleus.GetIsotope(); }
virtual void ProcessDescription(std::ostream& outFile) const;
void ProcessDescription(std::ostream& outFile) const override;
protected:
// generic method to choose secondary generator
// recommended for all derived classes
inline G4HadronicInteraction* ChooseHadronicInteraction(
const G4HadProjectile & aHadProjectile, G4Nucleus & aTargetNucleus,
G4Material* aMaterial, G4Element* anElement)
const G4HadProjectile & aHadProjectile, G4Nucleus& aTargetNucleus,
const G4Material* aMaterial, const G4Element* anElement)
{ return theEnergyRangeManager.GetHadronicInteraction(aHadProjectile,
aTargetNucleus,
aMaterial,anElement);
@@ -147,7 +144,11 @@ protected:
public:
// scale cross section
void BiasCrossSectionByFactor(G4double aScale);
void MultiplyCrossSectionBy(G4double factor);
inline G4double CrossSectionFactor() const
{ return aScaleFactor; }
// Integral option
inline void SetIntegral(G4bool val)
@@ -170,9 +171,6 @@ public:
inline G4CrossSectionDataStore* GetCrossSectionDataStore()
{return theCrossSectionDataStore;}
inline void MultiplyCrossSectionBy(G4double factor)
{ aScaleFactor = factor; }
protected:
void DumpState(const G4Track&, const G4String&, G4ExceptionDescription&);
@@ -216,6 +214,8 @@ protected:
G4ParticleChange* theTotalResult;
G4double fWeight;
G4int epReportLevel;
private:
@@ -244,7 +244,7 @@ private:
std::pair<G4double, G4double> epCheckLevels;
G4bool levelsSetByProcess;
std::vector<G4VLeadingParticleBiasing *> theBias;
std::vector<G4VLeadingParticleBiasing*> theBias;
G4double theInitialNumberOfInteractionLength;
@@ -23,7 +23,7 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4HadronicProcessStore.hh 90394 2015-05-27 12:14:48Z gcosmo $
// $Id: G4HadronicProcessStore.hh 110586 2018-05-31 12:01:42Z gcosmo $
//
//
// -------------------------------------------------------------------
@@ -82,7 +82,7 @@ public:
G4double kineticEnergy,
const G4VProcess* process,
const G4Element* element,
const G4Material* material=0);
const G4Material* material=nullptr);
G4double GetCrossSectionPerVolume(
const G4ParticleDefinition* particle,
@@ -98,7 +98,8 @@ public:
G4double GetInelasticCrossSectionPerAtom(
const G4ParticleDefinition *aParticle,
G4double kineticEnergy,
const G4Element *anElement, const G4Material* mat=0);
const G4Element *anElement,
const G4Material* mat=nullptr);
G4double GetInelasticCrossSectionPerIsotope(
const G4ParticleDefinition *aParticle,
@@ -128,7 +129,8 @@ public:
G4double GetCaptureCrossSectionPerAtom(
const G4ParticleDefinition *aParticle,
G4double kineticEnergy,
const G4Element *anElement, const G4Material* mat=0);
const G4Element *anElement,
const G4Material* mat=nullptr);
G4double GetCaptureCrossSectionPerIsotope(
const G4ParticleDefinition *aParticle,
@@ -143,7 +145,8 @@ public:
G4double GetFissionCrossSectionPerAtom(
const G4ParticleDefinition *aParticle,
G4double kineticEnergy,
const G4Element *anElement, const G4Material* mat=0);
const G4Element *anElement,
const G4Material* mat=nullptr);
G4double GetFissionCrossSectionPerIsotope(
const G4ParticleDefinition *aParticle,
@@ -158,7 +161,8 @@ public:
G4double GetChargeExchangeCrossSectionPerAtom(
const G4ParticleDefinition *aParticle,
G4double kineticEnergy,
const G4Element *anElement, const G4Material* mat=0);
const G4Element *anElement,
const G4Material* mat=nullptr);
G4double GetChargeExchangeCrossSectionPerIsotope(
const G4ParticleDefinition *aParticle,
@@ -184,6 +188,10 @@ public:
void DeRegisterExtraProcess(G4VProcess*);
void SetBuildXSTable(G4bool val);
G4bool GetBuildXSTable() const;
void PrintInfo(const G4ParticleDefinition*);
void Dump(G4int level);
@@ -243,6 +251,7 @@ private:
G4int verbose;
G4bool buildTableStart;
G4bool buildXSTable;
// cache
HP currentProcess;
@@ -23,18 +23,21 @@
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
// $Id: G4VLeadingParticleBiasing.hh 67989 2013-03-13 10:54:03Z gcosmo $
// $Id: G4VLeadingParticleBiasing.hh 110579 2018-05-30 15:03:30Z gcosmo $
//
// --------------------------------------------------------------------
#ifndef G4VLeadingParticleBiasing_h
#define G4VLeadingParticleBiasing_h
class G4HadFinalState;
#include "G4HadFinalState.hh"
class G4VLeadingParticleBiasing
{
public:
public:
explicit G4VLeadingParticleBiasing() {};
virtual ~G4VLeadingParticleBiasing() {};
virtual G4HadFinalState * Bias(G4HadFinalState * result) = 0;
};