Skip to content
Snippets Groups Projects
Commit 5ea6389d authored by Dmitry Popov's avatar Dmitry Popov
Browse files

Merge branch 'v104r1-release' into 'Sim10'

Release of v104r1

See merge request lhcb/Geant4!33
parents c3a2e22a 112e88a0
Branches
Tags v104r1
No related merge requests found
Showing
with 1321 additions and 46 deletions
...@@ -5,8 +5,8 @@ CMAKE_MINIMUM_REQUIRED(VERSION 2.8.5) ...@@ -5,8 +5,8 @@ CMAKE_MINIMUM_REQUIRED(VERSION 2.8.5)
set(GEANT4_SRCS_REPOSITORY https://gitlab.cern.ch/lhcb/Geant4-srcs.git CACHE STRING "Repository for Geant4 sources") set(GEANT4_SRCS_REPOSITORY https://gitlab.cern.ch/lhcb/Geant4-srcs.git CACHE STRING "Repository for Geant4 sources")
find_package(GaudiProject) find_package(GaudiProject)
gaudi_project(Geant4 v103r3 gaudi_project(Geant4 v104r1
DATA Geant4Files VERSION v103r1) DATA Geant4Files VERSION v104r0)
# FIXME: hack for compatibility with CMT build # FIXME: hack for compatibility with CMT build
file(WRITE ${CMAKE_BINARY_DIR}/dummy.cpp "") file(WRITE ${CMAKE_BINARY_DIR}/dummy.cpp "")
......
...@@ -30,7 +30,7 @@ if (NOT GEANT4_TAG) ...@@ -30,7 +30,7 @@ if (NOT GEANT4_TAG)
elseif(CMAKE_PROJECT_VERSION STREQUAL "HEAD") elseif(CMAKE_PROJECT_VERSION STREQUAL "HEAD")
# Special mapping of version HEAD # Special mapping of version HEAD
# WARNING this must be kept up to date manually # WARNING this must be kept up to date manually
set(GEANT4_TAG "lhcb/v10.3.3-branch") set(GEANT4_TAG "lhcb/v10.4.1-branch")
else() else()
set(GEANT4_TAG lhcb/${CMAKE_PROJECT_VERSION}) set(GEANT4_TAG lhcb/${CMAKE_PROJECT_VERSION})
endif() endif()
......
...@@ -23,11 +23,11 @@ ...@@ -23,11 +23,11 @@
// * acceptance of all terms of the Geant4 Software license. * // * acceptance of all terms of the Geant4 Software license. *
// ******************************************************************** // ********************************************************************
// //
// $Id$ // $Id: G4EmStandardPhysics_option1.hh 98736 2016-08-09 10:55:12Z gcosmo $
// //
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
// //
// ClassName: G4EmStandardPhysics_option1NoApplyCuts // ClassName: G4EmStandardPhysics_option1
// //
// Author: V.Ivanchenko 09.11.2005 // Author: V.Ivanchenko 09.11.2005
// //
...@@ -55,15 +55,12 @@ class G4EmStandardPhysics_option1NoApplyCuts : public G4VPhysicsConstructor ...@@ -55,15 +55,12 @@ class G4EmStandardPhysics_option1NoApplyCuts : public G4VPhysicsConstructor
{ {
public: public:
G4EmStandardPhysics_option1NoApplyCuts(G4int ver = 1); explicit G4EmStandardPhysics_option1NoApplyCuts(G4int ver=1, const G4String& name="");
// obsolete
G4EmStandardPhysics_option1NoApplyCuts(G4int ver, const G4String& name);
virtual ~G4EmStandardPhysics_option1NoApplyCuts(); virtual ~G4EmStandardPhysics_option1NoApplyCuts();
void ConstructParticle() override; virtual void ConstructParticle() override;
void ConstructProcess() override; virtual void ConstructProcess() override;
private: private:
G4int verbose; G4int verbose;
......
...@@ -23,11 +23,11 @@ ...@@ -23,11 +23,11 @@
// * acceptance of all terms of the Geant4 Software license. * // * acceptance of all terms of the Geant4 Software license. *
// ******************************************************************** // ********************************************************************
// //
// $Id$ // $Id: G4EmStandardPhysics_option1.cc 99938 2016-10-12 08:06:52Z gcosmo $
// //
//--------------------------------------------------------------------------- //---------------------------------------------------------------------------
// //
// ClassName: G4EmStandardPhysics_option1NoApplyCuts // ClassName: G4EmStandardPhysics_option1
// //
// Author: V.Ivanchenko 09.11.2005 // Author: V.Ivanchenko 09.11.2005
// //
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
#include "Geant4/G4SystemOfUnits.hh" #include "Geant4/G4SystemOfUnits.hh"
#include "Geant4/G4ParticleDefinition.hh" #include "Geant4/G4ParticleDefinition.hh"
#include "Geant4/G4LossTableManager.hh" #include "Geant4/G4LossTableManager.hh"
#include "Geant4/G4EmProcessOptions.hh" #include "Geant4/G4EmParameters.hh"
#include "Geant4/G4ComptonScattering.hh" #include "Geant4/G4ComptonScattering.hh"
#include "Geant4/G4GammaConversion.hh" #include "Geant4/G4GammaConversion.hh"
...@@ -102,9 +102,9 @@ ...@@ -102,9 +102,9 @@
#include "Geant4/G4Alpha.hh" #include "Geant4/G4Alpha.hh"
#include "Geant4/G4GenericIon.hh" #include "Geant4/G4GenericIon.hh"
#include "Geant4/G4VUserPhysicsList.hh"
#include "Geant4/G4PhysicsListHelper.hh" #include "Geant4/G4PhysicsListHelper.hh"
#include "Geant4/G4BuilderType.hh" #include "Geant4/G4BuilderType.hh"
#include "Geant4/G4EmModelActivator.hh"
// factory // factory
#include "Geant4/G4PhysicsConstructorFactory.hh" #include "Geant4/G4PhysicsConstructorFactory.hh"
...@@ -113,20 +113,16 @@ G4_DECLARE_PHYSCONSTR_FACTORY(G4EmStandardPhysics_option1NoApplyCuts); ...@@ -113,20 +113,16 @@ G4_DECLARE_PHYSCONSTR_FACTORY(G4EmStandardPhysics_option1NoApplyCuts);
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
G4EmStandardPhysics_option1NoApplyCuts::G4EmStandardPhysics_option1NoApplyCuts(G4int ver) G4EmStandardPhysics_option1NoApplyCuts::G4EmStandardPhysics_option1NoApplyCuts(G4int ver,
const G4String&)
: G4VPhysicsConstructor("G4EmStandard_opt1"), verbose(ver) : G4VPhysicsConstructor("G4EmStandard_opt1"), verbose(ver)
{ {
G4LossTableManager::Instance(); G4EmParameters* param = G4EmParameters::Instance();
SetPhysicsType(bElectromagnetic); param->SetDefaults();
// std::cout<<"This is the v9.6 option 1 physics list with ApplyCuts option commented out"<<std::endl; param->SetVerbose(verbose);
} param->SetApplyCuts(false); //LHCb Specific modification, don't apply prodcution cuts for specific processes
param->SetMscRangeFactor(0.2);
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... param->SetMscStepLimitType(fMinimal);
G4EmStandardPhysics_option1NoApplyCuts::G4EmStandardPhysics_option1NoApplyCuts(G4int ver, const G4String&)
: G4VPhysicsConstructor("G4EmStandard_opt1"), verbose(ver)
{
G4LossTableManager::Instance();
SetPhysicsType(bElectromagnetic); SetPhysicsType(bElectromagnetic);
} }
...@@ -139,26 +135,26 @@ G4EmStandardPhysics_option1NoApplyCuts::~G4EmStandardPhysics_option1NoApplyCuts( ...@@ -139,26 +135,26 @@ G4EmStandardPhysics_option1NoApplyCuts::~G4EmStandardPhysics_option1NoApplyCuts(
void G4EmStandardPhysics_option1NoApplyCuts::ConstructParticle() void G4EmStandardPhysics_option1NoApplyCuts::ConstructParticle()
{ {
// gamma // gamma
G4Gamma::Gamma(); G4Gamma::Gamma();
// leptons // leptons
G4Electron::Electron(); G4Electron::Electron();
G4Positron::Positron(); G4Positron::Positron();
G4MuonPlus::MuonPlus(); G4MuonPlus::MuonPlus();
G4MuonMinus::MuonMinus(); G4MuonMinus::MuonMinus();
// mesons // mesons
G4PionPlus::PionPlusDefinition(); G4PionPlus::PionPlusDefinition();
G4PionMinus::PionMinusDefinition(); G4PionMinus::PionMinusDefinition();
G4KaonPlus::KaonPlusDefinition(); G4KaonPlus::KaonPlusDefinition();
G4KaonMinus::KaonMinusDefinition(); G4KaonMinus::KaonMinusDefinition();
// barions // barions
G4Proton::Proton(); G4Proton::Proton();
G4AntiProton::AntiProton(); G4AntiProton::AntiProton();
// ions // ions
G4Deuteron::Deuteron(); G4Deuteron::Deuteron();
G4Triton::Triton(); G4Triton::Triton();
G4He3::He3(); G4He3::He3();
...@@ -170,6 +166,9 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructParticle() ...@@ -170,6 +166,9 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructParticle()
void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess() void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess()
{ {
if(verbose > 1) {
G4cout << "### " << GetPhysicsName() << " Construct Processes " << G4endl;
}
G4PhysicsListHelper* ph = G4PhysicsListHelper::GetPhysicsListHelper(); G4PhysicsListHelper* ph = G4PhysicsListHelper::GetPhysicsListHelper();
// muon & hadron bremsstrahlung and pair production // muon & hadron bremsstrahlung and pair production
...@@ -185,26 +184,31 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess() ...@@ -185,26 +184,31 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess()
// muon & hadron multiple scattering // muon & hadron multiple scattering
G4MuMultipleScattering* mumsc = new G4MuMultipleScattering(); G4MuMultipleScattering* mumsc = new G4MuMultipleScattering();
mumsc->AddEmModel(0, new G4WentzelVIModel()); mumsc->AddEmModel(0, new G4WentzelVIModel());
G4CoulombScattering* muss = new G4CoulombScattering();
G4MuMultipleScattering* pimsc = new G4MuMultipleScattering(); G4MuMultipleScattering* pimsc = new G4MuMultipleScattering();
pimsc->AddEmModel(0, new G4WentzelVIModel()); pimsc->AddEmModel(0, new G4WentzelVIModel());
G4CoulombScattering* piss = new G4CoulombScattering();
G4MuMultipleScattering* kmsc = new G4MuMultipleScattering(); G4MuMultipleScattering* kmsc = new G4MuMultipleScattering();
kmsc->AddEmModel(0, new G4WentzelVIModel()); kmsc->AddEmModel(0, new G4WentzelVIModel());
G4CoulombScattering* kss = new G4CoulombScattering();
G4MuMultipleScattering* pmsc = new G4MuMultipleScattering(); G4MuMultipleScattering* pmsc = new G4MuMultipleScattering();
pmsc->AddEmModel(0, new G4WentzelVIModel()); pmsc->AddEmModel(0, new G4WentzelVIModel());
G4CoulombScattering* pss = new G4CoulombScattering();
G4hMultipleScattering* hmsc = new G4hMultipleScattering("ionmsc"); G4hMultipleScattering* hmsc = new G4hMultipleScattering("ionmsc");
// high energy limit for e+- scattering models and bremsstrahlung // high energy limit for e+- scattering models and bremsstrahlung
G4double highEnergyLimit = 100*MeV; G4double highEnergyLimit = 100*MeV;
// Add standard EM Processes // Add standard EM Processes
auto particleIterator = GetParticleIterator(); auto myParticleIterator=GetParticleIterator();
particleIterator->reset(); myParticleIterator->reset();
while( (*particleIterator)() ){ while( (*myParticleIterator)() ){
G4ParticleDefinition* particle = particleIterator->value(); G4ParticleDefinition* particle = myParticleIterator->value();
G4String particleName = particle->GetParticleName(); G4String particleName = particle->GetParticleName();
if(verbose > 1)
G4cout << "### " << GetPhysicsName() << " instantiates for "
<< particleName << G4endl;
if (particleName == "gamma") { if (particleName == "gamma") {
...@@ -218,9 +222,9 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess() ...@@ -218,9 +222,9 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess()
eioni->SetStepFunction(0.8, 1.0*mm); eioni->SetStepFunction(0.8, 1.0*mm);
G4eMultipleScattering* msc = new G4eMultipleScattering; G4eMultipleScattering* msc = new G4eMultipleScattering;
msc->SetStepLimitType(fMinimal);
G4UrbanMscModel* msc1 = new G4UrbanMscModel(); G4UrbanMscModel* msc1 = new G4UrbanMscModel();
G4WentzelVIModel* msc2 = new G4WentzelVIModel(); G4WentzelVIModel* msc2 = new G4WentzelVIModel();
msc1->SetLateralDisplasmentFlag(false);
msc1->SetHighEnergyLimit(highEnergyLimit); msc1->SetHighEnergyLimit(highEnergyLimit);
msc2->SetLowEnergyLimit(highEnergyLimit); msc2->SetLowEnergyLimit(highEnergyLimit);
msc->AddEmModel(0, msc1); msc->AddEmModel(0, msc1);
...@@ -244,9 +248,9 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess() ...@@ -244,9 +248,9 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess()
eioni->SetStepFunction(0.8, 1.0*mm); eioni->SetStepFunction(0.8, 1.0*mm);
G4eMultipleScattering* msc = new G4eMultipleScattering; G4eMultipleScattering* msc = new G4eMultipleScattering;
msc->SetStepLimitType(fMinimal);
G4UrbanMscModel* msc1 = new G4UrbanMscModel(); G4UrbanMscModel* msc1 = new G4UrbanMscModel();
G4WentzelVIModel* msc2 = new G4WentzelVIModel(); G4WentzelVIModel* msc2 = new G4WentzelVIModel();
msc1->SetLateralDisplasmentFlag(false);
msc1->SetHighEnergyLimit(highEnergyLimit); msc1->SetHighEnergyLimit(highEnergyLimit);
msc2->SetLowEnergyLimit(highEnergyLimit); msc2->SetLowEnergyLimit(highEnergyLimit);
msc->AddEmModel(0, msc1); msc->AddEmModel(0, msc1);
...@@ -272,7 +276,7 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess() ...@@ -272,7 +276,7 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess()
ph->RegisterProcess(new G4MuIonisation(), particle); ph->RegisterProcess(new G4MuIonisation(), particle);
ph->RegisterProcess(mub, particle); ph->RegisterProcess(mub, particle);
ph->RegisterProcess(mup, particle); ph->RegisterProcess(mup, particle);
ph->RegisterProcess(new G4CoulombScattering(), particle); ph->RegisterProcess(muss, particle);
} else if (particleName == "alpha" || } else if (particleName == "alpha" ||
particleName == "He3" ) { particleName == "He3" ) {
...@@ -294,6 +298,7 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess() ...@@ -294,6 +298,7 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess()
ph->RegisterProcess(new G4hIonisation(), particle); ph->RegisterProcess(new G4hIonisation(), particle);
ph->RegisterProcess(pib, particle); ph->RegisterProcess(pib, particle);
ph->RegisterProcess(pip, particle); ph->RegisterProcess(pip, particle);
ph->RegisterProcess(piss, particle);
} else if (particleName == "kaon+" || } else if (particleName == "kaon+" ||
particleName == "kaon-" ) { particleName == "kaon-" ) {
...@@ -303,6 +308,7 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess() ...@@ -303,6 +308,7 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess()
ph->RegisterProcess(new G4hIonisation(), particle); ph->RegisterProcess(new G4hIonisation(), particle);
ph->RegisterProcess(kb, particle); ph->RegisterProcess(kb, particle);
ph->RegisterProcess(kp, particle); ph->RegisterProcess(kp, particle);
ph->RegisterProcess(kss, particle);
// } else if (particleName == "proton" ) { // } else if (particleName == "proton" ) {
} else if (particleName == "proton" || } else if (particleName == "proton" ||
...@@ -313,6 +319,7 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess() ...@@ -313,6 +319,7 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess()
ph->RegisterProcess(new G4hIonisation(), particle); ph->RegisterProcess(new G4hIonisation(), particle);
ph->RegisterProcess(pb, particle); ph->RegisterProcess(pb, particle);
ph->RegisterProcess(pp, particle); ph->RegisterProcess(pp, particle);
ph->RegisterProcess(pss, particle);
} else if (particleName == "B+" || } else if (particleName == "B+" ||
particleName == "B-" || particleName == "B-" ||
...@@ -349,15 +356,13 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess() ...@@ -349,15 +356,13 @@ void G4EmStandardPhysics_option1NoApplyCuts::ConstructProcess()
ph->RegisterProcess(new G4hIonisation(), particle); ph->RegisterProcess(new G4hIonisation(), particle);
} }
} }
G4EmProcessOptions opt;
opt.SetVerbose(verbose);
opt.SetPolarAngleLimit(CLHEP::pi);
//opt.SetApplyCuts(true);
// Deexcitation // Deexcitation
// //
G4VAtomDeexcitation* de = new G4UAtomicDeexcitation(); G4VAtomDeexcitation* de = new G4UAtomicDeexcitation();
G4LossTableManager::Instance()->SetAtomDeexcitation(de); G4LossTableManager::Instance()->SetAtomDeexcitation(de);
G4EmModelActivator mact(GetPhysicsName());
} }
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo...... //....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
gaudi_subdir(G4GammaToDiLeptonConversionTest v1r0)
gaudi_depends_on_subdirs(Geant4/G4config)
gaudi_depends_on_subdirs(LHCbG4PhysLists)
find_package(CLHEP REQUIRED)
include_directories(SYSTEM ${CMAKE_INSTALL_PREFIX}/include ${CLHEP_INCLUDE_DIRS})
link_directories(${CMAKE_INSTALL_PREFIX}/lib)
set(Geant4_LIBRARIES
-lG4analysis
-lG4physicslists
-lG4intercoms
-lG4global
-lG4run
-lG4tracking
-lG4track
-lG4event
-lG4processes
-lG4particles
-lG4geometry
-lG4materials
-lG4graphics_reps)
gaudi_add_executable(G4GammaToDiLeptonConversionTest
G4GammaToDiLeptonConversionTest.cc src/*.cc
INCLUDE_DIRS include CLHEP
LINK_LIBRARIES ${Geant4_LIBRARIES} CLHEP)
add_dependencies(G4GammaToDiLeptonConversionTest Geant4)
gaudi_install_scripts()
// BASED ON TESTEM6 BY THE GEANT4 COLLABORATION
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
/// \file electromagnetic/TestEm6/TestEm6.cc
/// \brief Main program of the electromagnetic/TestEm6 example
//
// $Id: TestEm6.cc 83428 2014-08-21 15:46:01Z gcosmo $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#include "Geant4/G4RunManager.hh"
#include "Geant4/G4UImanager.hh"
#include "Geant4/Randomize.hh"
#include "Geant4/G4GammaConversionToMuons.hh"
#include "Geant4/G4ProcessTable.hh"
#include "DetectorConstruction.hh"
#include "PrimaryGeneratorAction.hh"
#include "SteppingVerbose.hh"
#include "PhysicsList.hh"
#include "RunAction.hh"
#include "SteppingAction.hh"
#include "StackingAction.hh"
#ifdef G4VIS_USE
#include "G4VisExecutive.hh"
#endif
#ifdef G4UI_USE
#include "G4UIExecutive.hh"
#endif
G4double energy = 1000; //in GeV
G4int nEvts = 100;
G4double thickness = 0.3; //in mm
G4String dimu_xsec_fac = "1000";
G4String output_dir = ".";
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
int main(int argc,char** argv) {
for(int i{0}; i<argc; ++i)
{
if(G4String(argv[i]) == "--nevts")
{
++i;
nEvts = G4int(atoi(argv[i]));
++i;
}
if(G4String(argv[i]) == "--energy")
{
++i;
energy = G4double(atof(argv[i]));
++i;
}
if(G4String(argv[i]) == "--thickness")
{
++i;
thickness = G4double(atof(argv[i]));
++i;
}
if(G4String(argv[i]) == "--scale")
{
++i;
dimu_xsec_fac = G4String(argv[i]);
++i;
}
if(G4String(argv[i]) == "--outputdir")
{
++i;
output_dir = G4String(argv[i]);
++i;
}
}
//choose the Random engine
CLHEP::HepRandom::setTheEngine(new CLHEP::RanecuEngine);
//my Verbose output class
G4VSteppingVerbose::SetInstance(new SteppingVerbose);
//Construct the default run manager
G4RunManager * runManager = new G4RunManager;
//Set Physics List
runManager->SetUserInitialization(new PhysicsList);
//set mandatory initialization classes
DetectorConstruction* det;
runManager->SetUserInitialization(det = new DetectorConstruction(thickness));
runManager->SetUserAction(new PrimaryGeneratorAction(det, energy, nEvts));
//set user action classes
RunAction* RunAct;
runManager->SetUserAction(RunAct = new RunAction(det, energy, thickness, nEvts, output_dir));
runManager->SetUserAction(new SteppingAction(RunAct));
runManager->SetUserAction(new StackingAction);
//get the pointer to the User Interface manager
G4UImanager* UI = G4UImanager::GetUIpointer();
// Initialize Run Manager
UI->ApplyCommand("/run/initialize");
// Increase Gamma2MuMu XSec to 1000x
UI->ApplyCommand("/testem/phys/SetGammaToMuPairFac "+dimu_xsec_fac);
//Start Simulation
UI->ApplyCommand("/run/beamOn");
//job termination
delete runManager;
return 0;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
# $Id: GNUmakefile 66241 2012-12-13 18:34:42Z gunter $
# --------------------------------------------------------------
# GNUmakefile for examples module. Gabriele Cosmo, 06/04/98.
# --------------------------------------------------------------
name := TestEm6
G4TARGET := $(name)
G4EXLIB := true
ifndef G4INSTALL
G4INSTALL = ../../../..
endif
.PHONY: all
all: lib bin
include $(G4INSTALL)/config/architecture.gmk
include $(G4INSTALL)/config/binmake.gmk
histclean:
rm -f $(G4WORKDIR)/tmp/$(G4SYSTEM)/$(G4TARGET)/RunAction.o
rm -f $(G4WORKDIR)/tmp/$(G4SYSTEM)/$(G4TARGET)/SteppingAction.o
visclean:
rm -f g4*.prim g4*.eps g4*.wrl
rm -f .DAWN_*
$Id: History 100285 2016-10-17 08:42:54Z gcosmo $
-------------------------------------------------------------------
=========================================================
Geant4 - an Object-Oriented Toolkit for Simulation in HEP
=========================================================
TestEm6 History file
--------------------
This file should be used by the G4 example coordinator to briefly
summarize all major modifications introduced in the code and keep
track of all tags.
----------------------------------------------------------
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
14-10-16 G.Folger (testem6-V10-02-02)
- remove direct use of theParticleIterator, use GetParticleTableIterator().
fix required by clang39 on Linux and MAC
04-07-16 I. Hrivnacova (testem6-V10-02-01)
- Fixes for Doxygen documentation
10-12-15 V.Ivant (testem6-V10-02-00)
- H.Burkhardt fixed root macro allowing to work both with root5 and 6
28-10-15 D.Sawkey (testem6-V10-01-00)
- update physics description in READMEs
- add more standard EM physics builders
30-07-14 V.Ivant (testem6-V10-00-02)
- Naruhiro Chikuma have updated PhysicsList, DetectorConstruction,
and RunAction; bug fix
03-07-14 mma (testem6-V10-00-01)
- replace /testem/event/printModulo by /run/printProgress
08-06-14 mma (testem6-V10-00-00)
- suppress EventAction and its messenger
18-09-13 V.Ivant (testem6-V09-06-04)
- fixed tag format
17-09-13 V.Ivant (testem6-V09-05-04)
- TestEm6.in - added cross section factor to gamma->mu+mu- process
05-09-13 mma (testem6-V09-06-03)
- PhysicsList: restore G4GammaConversionToMuons
19-06-13 mma (testem6-V09-06-02)
- SteppingVerbose: use G4Step::GetSecondaryInCurrentStep()
07-06-13 mma (testem6-V09-06-01)
- Cosmetic in SteppingAction.
13-02-13 I.Hrivnacova (testem6-V09-06-00)
- Applied coding guidelines (virtual keyword, data members initialization)
12-10-12 V.Ivant (testem6-V09-05-03)
- Migration to the updated analysis tool and inplicit units
11-10-12 mma (testem6-V09-05-02)
- coding conventions: virtual
06-04-12 mma (testem6-V09-05-01)
- all classes : apply G4 coding conventions
11-03-12 mma (testem6-V09-05-00)
- RunAction.hh and .cc : migrate to new g4tools histogramming system
Do not need aida anymore, nor G4ANALYSIS_USE
08-11-11 mma (testem6-V09-04-00)
- modify SteppingVerbose for OutOfWorld
09-11-10 I.Hrivnacova (testem6-V09-03-05)
- Fixed compilation error on gcc-4.5.1.
09-11-10 M.Asai (testem6-V09-03-04)
- Fix AIDA file option.
06-06-10 J.Perl (testem6-V09-03-03)
- Remove unused variable in EventAction
03-06-10 J.Perl (testem6-V09-03-02)
- Updated vis usage
21-05-10 mma (testem6-V09-03-01)
- TestEm6.cc : introduction of G4UIExecutive
31-03-10 V.Ivant (testem6-V09-03-00)
- Remove obsolete MSC from comments line
27-11-09 V.Ivant (testem6-V09-02-01)
- H.Burkhardt add StackingAction allowing remove secondary particles;
cleanup PhysicsList for 9.3.
13-05-09 V.Ivant (testem6-V09-02-00)
- Increased upper limit of energy in the tables to 1000 TeV
18-09-08 mma (testem6-V09-01-02)
- RunAction : change default histogram format (root)
12-06-08 mma (testem6-V09-01-01)
- Remove AIDA from GNUmakefile
06-05-08 mma (testem6-V09-01-00)
- README : update Aida informations
20-10-06 mma (testem6-V08-01-00)
- GNUmakefile : LOADLIBS
24-05-06 mma (testem6-V08-00-01)
- register G4StepLimiter in PhysicsList
16-02-06 mma (testem6-V08-00-00)
- add command /testem/phys/SetAnnihiToHadronFac
06-12-05 Gabriele Cosmo
- Trivial changes for support of CLHEP-2.0.X series.
29-11-05 V.Ivant (testem6-V07-01-02)
- Add GenericIon to the PhysicsList
23-11-05 V.Ivant (testem6-V07-01-01)
- extend test to mu+mu- and pi+pi- pair creation processes and G4hhIonisation
in order to test all processes of the subdirectory
22-11-05 mma (testem6-V07-01-00)
- update README for OpenScientist
01-06-05 mma (testem6-V07-00-01)
- RunAction : option "noErrors" for hbook files;
3rd May 2005 John Allison (examples-V07-00-03)
- Replaced vis manager with G4VisExecutive.
02-03-05 mma (testem6-V07-00-00)
- RunAction : put a protection for the creation of analysis factory;
02 Dec 04: V.Ivant (testem6-V06-02-01)
- Migration to cmath
27-09-04 mma (testem6-V06-02-00)
- define correctly all UI subdirectories.
- modifs in RunAction for hbook,root,XML (Jaida)
31-03-04 mma (testem6-V06-01-00)
- remove direct interface with root
15-03-04 mma (testem6-V06-00-00)
- example of histograms with ROOT: USE_ROOT
25-11-03 V.Ivanchenko (testem6-V05-02-02)
- Fix geometry (G.Cosmo)
13-11-03 John Allison
- Removed OPACS from Vis Manager.
24-10-03 mma (testem6-V05-02-01)
- PhysListEmStandard: AddProcess(Bremsstrahlung,-1,3,3) ..etc..
10-10-03 mma (testem6-V05-02-00)
- NOHIST replaced by ANALYSIS_USE
- cosmetic in material definitions
- SetMaterial() in constructor. all macros updated for /run/initialize
10-06-03 mma (testem6-V05-01-00)
- proper deletion of old geometry in case of update
- fixe compilation warning
01-04-03 mma (testem6-V05-00-02)
- PVPlacement in logical mother even for the world
20-02-03 V.Ivant (testem6-V05-00-01)
- Migration to cut per region
12-02-03 mma (testem6-V05-00-00)
- DetectorConstruction: change volume name
30-01-03 hbu
- PhysicsList: implementation of (e+,e-) annihilation to (mu+,mu-)
- macros run11.mac and run12.mac
12-12-02 mma (testem6-V04-01-00)
- migration to aida 3.0
- UI directory /testem/
05-06-02 mma (testem6-V04-00-01)
- old histograming package clhep/hist replaced by AIDA 2.2/anaphe
23-05-02 mma (testem6-V04-00-00)
- creation
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
/// \file electromagnetic/TestEm6/include/DetectorConstruction.hh
/// \brief Definition of the DetectorConstruction class
//
// $Id: DetectorConstruction.hh 83428 2014-08-21 15:46:01Z gcosmo $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef DetectorConstruction_h
#define DetectorConstruction_h 1
#include "Geant4/G4VUserDetectorConstruction.hh"
#include "Geant4/globals.hh"
class G4LogicalVolume;
class G4Material;
class G4UniformMagField;
class G4UserLimits;
class DetectorMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class DetectorConstruction : public G4VUserDetectorConstruction
{
public:
DetectorConstruction(G4float);
~DetectorConstruction();
public:
G4VPhysicalVolume* Construct() override;
void SetBoxDepth (G4double);
void SetSizeXY (G4double);
void SetMaterial (const G4String&);
void SetMagField (G4double);
void SetMaxStepSize (G4double);
void UpdateGeometry();
public:
const
G4VPhysicalVolume* GetWorld() {return fP_Box;};
G4double GetXYSize() {return fBoxXY;};
G4double GetBoxDepth() {return fBoxDepth;};
G4Material* GetMaterial() {return fMaterial;};
void PrintParameters();
private:
G4VPhysicalVolume* fP_Box;
G4LogicalVolume* fL_Box;
G4double fBoxXY;
G4double fBoxDepth;
G4Material* fMaterial;
G4UniformMagField* fMagField;
G4UserLimits* fUserLimits;
DetectorMessenger* fDetectorMessenger;
private:
void DefineMaterials();
G4VPhysicalVolume* ConstructVolumes();
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
/// \file electromagnetic/TestEm6/include/DetectorMessenger.hh
/// \brief Definition of the DetectorMessenger class
//
// $Id: DetectorMessenger.hh 66241 2012-12-13 18:34:42Z gunter $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef DetectorMessenger_h
#define DetectorMessenger_h 1
#include "Geant4/globals.hh"
#include "Geant4/G4UImessenger.hh"
class DetectorConstruction;
class G4UIdirectory;
class G4UIcmdWithAString;
class G4UIcmdWithADoubleAndUnit;
class G4UIcmdWithoutParameter;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class DetectorMessenger: public G4UImessenger
{
public:
DetectorMessenger(DetectorConstruction* );
~DetectorMessenger();
void SetNewValue(G4UIcommand*, G4String) override;
private:
DetectorConstruction* fDetector;
G4UIdirectory* fTestemDir;
G4UIdirectory* fDetDir;
G4UIcmdWithAString* fMaterCmd;
G4UIcmdWithADoubleAndUnit* fSizeCmd;
G4UIcmdWithADoubleAndUnit* fMagFieldCmd;
G4UIcmdWithADoubleAndUnit* fMaxStepCmd;
G4UIcmdWithoutParameter* fUpdateCmd;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
/// \file electromagnetic/TestEm6/include/PhysicsList.hh
/// \brief Definition of the PhysicsList class
//
// $Id: PhysicsList.hh 83428 2014-08-21 15:46:01Z gcosmo $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef PhysicsList_h
#define PhysicsList_h 1
#include "Geant4/G4VModularPhysicsList.hh"
#include "Geant4/globals.hh"
#include "Geant4/G4EmConfigurator.hh"
class G4VPhysicsConstructor;
class StepMax;
class PhysicsListMessenger;
class G4GammaConversionToMuons;
class G4GammaConversion;
class G4AnnihiToMuPair;
class G4eeToHadrons;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class PhysicsList: public G4VModularPhysicsList
{
public:
PhysicsList();
virtual ~PhysicsList();
// Construct particles
void ConstructParticle() override;
void ConstructProcess() override;
void AddPhysicsList(const G4String& name);
void ConstructHighEnergy();
void AddStepMax();
// Construct processes and register them
void SetGammaToMuPairFac(G4double);
void SetAnnihiToMuPairFac(G4double);
void SetAnnihiToHadronFac(G4double);
private:
G4VPhysicsConstructor* fEmPhysicsList;
G4VPhysicsConstructor* fDecayPhysicsList;
G4String fEmName;
StepMax* fStepMaxProcess;
PhysicsListMessenger* fMes;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
/// \file electromagnetic/TestEm6/include/PhysicsListMessenger.hh
/// \brief Definition of the PhysicsListMessenger class
//
// $Id: PhysicsListMessenger.hh 83428 2014-08-21 15:46:01Z gcosmo $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef PhysicsListMessenger_h
#define PhysicsListMessenger_h 1
#include "Geant4/globals.hh"
#include "Geant4/G4UImessenger.hh"
class PhysicsList;
class G4UIdirectory;
class G4UIcmdWithADouble;
class G4UIcmdWithAString;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class PhysicsListMessenger: public G4UImessenger
{
public:
PhysicsListMessenger(PhysicsList*);
~PhysicsListMessenger();
void SetNewValue(G4UIcommand*, G4String) override;
private:
PhysicsList* fPhysList;
G4UIdirectory* fPhysDir;
G4UIcmdWithADouble* fGammaToMuPairFacCmd;
G4UIcmdWithADouble* fGammaToEPairFacCmd;
G4UIcmdWithADouble* fAnnihiToMuPairFacCmd;
G4UIcmdWithADouble* fAnnihiToHadronFacCmd;
G4UIcmdWithAString* fListCmd;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
/// \file electromagnetic/TestEm6/include/PrimaryGeneratorAction.hh
/// \brief Definition of the PrimaryGeneratorAction class
//
// $Id: PrimaryGeneratorAction.hh 66241 2012-12-13 18:34:42Z gunter $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef PrimaryGeneratorAction_h
#define PrimaryGeneratorAction_h 1
#include "Geant4/G4VUserPrimaryGeneratorAction.hh"
#include "Geant4/globals.hh"
class G4ParticleGun;
class G4Event;
class DetectorConstruction;
class PrimaryGeneratorMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction
{
public:
PrimaryGeneratorAction(DetectorConstruction*, G4double, G4int);
~PrimaryGeneratorAction();
public:
void GeneratePrimaries(G4Event*) override;
private:
G4ParticleGun* fParticleGun;
DetectorConstruction* fDetector;
PrimaryGeneratorMessenger* fGunMessenger;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
/// \file electromagnetic/TestEm6/include/PrimaryGeneratorMessenger.hh
/// \brief Definition of the PrimaryGeneratorMessenger class
//
// $Id: PrimaryGeneratorMessenger.hh 66241 2012-12-13 18:34:42Z gunter $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef PrimaryGeneratorMessenger_h
#define PrimaryGeneratorMessenger_h 1
#include "Geant4/G4UImessenger.hh"
#include "Geant4/globals.hh"
class PrimaryGeneratorAction;
class G4UIdirectory;
class G4UIcmdWithADouble;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class PrimaryGeneratorMessenger: public G4UImessenger
{
public:
PrimaryGeneratorMessenger(PrimaryGeneratorAction*);
~PrimaryGeneratorMessenger();
private:
PrimaryGeneratorAction* fAction;
G4UIdirectory* fGunDir;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
/// \file electromagnetic/TestEm6/include/ProcessesCount.hh
/// \brief Definition of the ProcessesCount class
//
// $Id: ProcessesCount.hh 66241 2012-12-13 18:34:42Z gunter $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef ProcessesCount_HH
#define ProcessesCount_HH
#include "Geant4/globals.hh"
#include <vector>
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class OneProcessCount
{
public:
OneProcessCount(G4String name) {fName=name; fCounter=0;};
~OneProcessCount() {};
public:
G4String GetName() {return fName;};
G4int GetCounter() {return fCounter;};
void Count() {fCounter++;};
private:
G4String fName; // process name
G4int fCounter; // process counter
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
typedef std::vector<OneProcessCount*> ProcessesCount;
#endif
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
/// \file electromagnetic/TestEm6/include/RunAction.hh
/// \brief Definition of the RunAction class
//
// $Id: RunAction.hh 83428 2014-08-21 15:46:01Z gcosmo $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef RunAction_h
#define RunAction_h 1
#include "Geant4/G4UserRunAction.hh"
#include "ProcessesCount.hh"
#include "Geant4/globals.hh"
#include "Geant4/G4ParticleDefinition.hh"
#include "DetectorConstruction.hh"
#include "Geant4/g4root.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class G4Run;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class RunAction : public G4UserRunAction
{
public:
RunAction(DetectorConstruction*, G4double, G4double, G4int, G4String);
~RunAction();
public:
void BeginOfRunAction(const G4Run*) override;
void EndOfRunAction(const G4Run*) override;
void CountProcesses(G4String);
private:
DetectorConstruction* fDetector;
ProcessesCount* fProcCounter;
G4AnalysisManager* fAnalysis;
G4Material* fMat;
G4double fMinE;
G4double fMaxE;
G4int fnBin;
G4String fileName;
G4int fNtColId[3];
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
/// \file electromagnetic/TestEm6/include/StackingAction.hh
/// \brief Definition of the StackingAction class
//
// $Id: StackingAction.hh 66241 2012-12-13 18:34:42Z gunter $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef StackingAction_h
#define StackingAction_h 1
#include "Geant4/G4UserStackingAction.hh"
#include "Geant4/globals.hh"
class G4Track;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class StackingAction : public G4UserStackingAction
{
public:
StackingAction();
~StackingAction();
G4ClassificationOfNewTrack ClassifyNewTrack(const G4Track* ) override;
};
#endif
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
/// \file electromagnetic/TestEm6/include/StepMax.hh
/// \brief Definition of the StepMax class
//
// $Id: StepMax.hh 66241 2012-12-13 18:34:42Z gunter $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef StepMax_h
#define StepMax_h 1
#include "Geant4/globals.hh"
#include "Geant4/G4VDiscreteProcess.hh"
#include "Geant4/G4ParticleDefinition.hh"
#include "Geant4/G4Step.hh"
class StepMaxMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class StepMax : public G4VDiscreteProcess
{
public:
StepMax(const G4String& processName = "UserMaxStep");
~StepMax();
void SetMaxStep(G4double);
inline G4double GetMaxStep() { return fMaxChargedStep; };
G4bool IsApplicable(const G4ParticleDefinition&) override;
G4double PostStepGetPhysicalInteractionLength(const G4Track& track,
G4double previousStepSize,
G4ForceCondition* condition) override;
G4VParticleChange* PostStepDoIt(const G4Track&, const G4Step&) override;
G4double GetMeanFreePath(const G4Track&, G4double, G4ForceCondition*) override;
private:
G4double fMaxChargedStep;
G4double fProposedStep;
StepMaxMessenger* fMessenger;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
/// \file electromagnetic/TestEm6/include/StepMaxMessenger.hh
/// \brief Definition of the StepMaxMessenger class
//
// $Id: StepMaxMessenger.hh 67268 2013-02-13 11:38:40Z ihrivnac $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef StepMaxMessenger_h
#define StepMaxMessenger_h 1
#include "Geant4/globals.hh"
#include "Geant4/G4UImessenger.hh"
class StepMax;
class G4UIcmdWithADoubleAndUnit;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class StepMaxMessenger: public G4UImessenger
{
public:
StepMaxMessenger(StepMax*);
~StepMaxMessenger();
void SetNewValue(G4UIcommand*, G4String) override;
private:
StepMax* fStepMax;
G4UIcmdWithADoubleAndUnit* fStepMaxCmd;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
//
// ********************************************************************
// * License and Disclaimer *
// * *
// * The Geant4 software is copyright of the Copyright Holders of *
// * the Geant4 Collaboration. It is provided under the terms and *
// * conditions of the Geant4 Software License, included in the file *
// * LICENSE and available at http://cern.ch/geant4/license . These *
// * include a list of copyright holders. *
// * *
// * Neither the authors of this software system, nor their employing *
// * institutes,nor the agencies providing financial support for this *
// * work make any representation or warranty, express or implied, *
// * regarding this software system or assume any liability for its *
// * use. Please see the license in the file LICENSE and URL above *
// * for the full disclaimer and the limitation of liability. *
// * *
// * This code implementation is the result of the scientific and *
// * technical work of the GEANT4 collaboration. *
// * By using, copying, modifying or distributing the software (or *
// * any work based on the software) you agree to acknowledge its *
// * use in resulting scientific publications, and indicate your *
// * acceptance of all terms of the Geant4 Software license. *
// ********************************************************************
//
/// \file electromagnetic/TestEm6/include/SteppingAction.hh
/// \brief Definition of the SteppingAction class
//
// $Id: SteppingAction.hh 66241 2012-12-13 18:34:42Z gunter $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#ifndef SteppingAction_h
#define SteppingAction_h 1
#include "Geant4/G4UserSteppingAction.hh"
#include "Geant4/globals.hh"
#include "Geant4/G4ParticleDefinition.hh"
#include "Geant4/G4ParticleTypes.hh"
class RunAction;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
class SteppingAction : public G4UserSteppingAction
{
public:
SteppingAction(RunAction*);
~SteppingAction();
void UserSteppingAction(const G4Step*) override;
private:
RunAction* fRunAction;
G4double fMuonMass;
G4double fEMass;
G4MuonPlus* muplus_def = G4MuonPlus::MuonPlusDefinition();
G4Positron* eplus_def = G4Positron::PositronDefinition();
int tuple_index = -1;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
#endif
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment