Import Geant4 10.7.0 source tree

This commit is contained in:
Gabriele Cosmo
2020-12-04 12:30:43 +01:00
parent 67ba86d073
commit dab42d2018
3770 changed files with 226369 additions and 286486 deletions
@@ -1,6 +1,9 @@
#----------------------------------------------------------------------------
# Setup the project
cmake_minimum_required(VERSION 2.6 FATAL_ERROR)
cmake_minimum_required(VERSION 3.8...3.18)
if(${CMAKE_VERSION} VERSION_LESS 3.12)
cmake_policy(VERSION ${CMAKE_MAJOR_VERSION}.${CMAKE_MINOR_VERSION})
endif()
project(gflasha)
#----------------------------------------------------------------------------
@@ -29,19 +29,15 @@
//
// Created by Joanna Weng 26.11.2004
// G4 includes
// G4 includes
#include "G4Types.hh"
#include "G4ios.hh"
#include "G4Timer.hh"
#include "G4UImanager.hh"
#ifdef G4MULTITHREADED
#include "G4MTRunManager.hh"
#else
#include "G4RunManager.hh"
#endif
#include "G4RunManagerFactory.hh"
// my project
// my project
#include "ExGflashDetectorConstruction.hh"
#include "ExGflashActionInitialization.hh"
@@ -54,7 +50,7 @@
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
int main(int argc,char** argv)
{
{
// Instantiate G4UIExecutive if interactive mode
G4UIExecutive* ui = nullptr;
if ( argc == 1 ) {
@@ -64,21 +60,15 @@ int main(int argc,char** argv)
// timer to see GFlash performance
G4Timer timer;
timer.Start();
G4cout<<"+-------------------------------------------------------+"<<G4endl;
G4cout<<"| |"<<G4endl;
G4cout<<"| This is an example of Shower |"<<G4endl;
G4cout<<"| Parameterization with GFLASH |"<<G4endl;
G4cout<<"+-------------------------------------------------------+"<<G4endl;
auto* runManager = G4RunManagerFactory::CreateRunManager();
#ifdef G4MULTITHREADED
G4MTRunManager * runManager = new G4MTRunManager;
#else
G4RunManager * runManager = new G4RunManager;
#endif
// UserInitialization classes (mandatory)
ExGflashDetectorConstruction* detector = new ExGflashDetectorConstruction;
runManager->SetUserInitialization(detector);
@@ -88,7 +78,7 @@ int main(int argc,char** argv)
// -- Create a fast simulation physics constructor, used to augment
// -- the above physics list to allow for fast simulation:
G4FastSimulationPhysics* fastSimulationPhysics = new G4FastSimulationPhysics();
// -- We now configure the fastSimulationPhysics object.
// -- The gflash model (GFlashShowerModel, see ExGflashDetectorConstruction.cc)
// -- is applicable to e+ and e- : we augment the physics list for these
@@ -114,22 +104,22 @@ int main(int argc,char** argv)
UImanager->ApplyCommand("/run/verbose 0");
runManager->Initialize();
UImanager->ApplyCommand("/Step/Verbose 0");
if (ui) // Define UI terminal for interactive mode
{
{
UImanager->ApplyCommand("/control/execute vis.mac");
ui->SessionStart();
delete ui;
}
else // Batch mode
{
{
G4String s=*(argv+1);
UImanager->ApplyCommand("/control/execute "+s);
}
delete visManager;
delete runManager;
timer.Stop();
G4cout << G4endl;
G4cout << "******************************************";
@@ -142,7 +132,7 @@ int main(int argc,char** argv)
G4cout << G4endl;
G4cout << "******************************************";
G4cout << G4endl;
return 0;
}
@@ -16,6 +16,9 @@ committal in the CVS repository !
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
10-Nov-2020 B. Morgan (exgflasha-V10-06-00)
- Migration to G4RunManagerFactory.
28-Oct-2019 I. Hrivnacova (exgflasha-V10-05-01)
- Fixed formatting in .README.txt and Doxygen warnings