Import Geant4 9.2.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-09 15:58:43 +02:00
parent 96c8bcd0af
commit b79225fb37
7544 changed files with 245407 additions and 91099 deletions
+21 -1
View File
@@ -1,4 +1,4 @@
$Id: History,v 1.117 2007/11/19 20:18:05 perl Exp $
$Id: History,v 1.123 2008/12/01 09:45:42 gcosmo Exp $
--------------------------------------------------
=========================================================
@@ -14,6 +14,26 @@ track of all tags.
----------------------------------------------------------
* Reverse chronological order (last date on top), please *
----------------------------------------------------------
24-11-08 Laurent Garnier (exampleN03-V09-01-05)
- Removed unnecessary inclusion of qapplication.h in main().
- Added Qt setup to vis macros.
31-10-08 mma (exampleN03-V09-01-04)
- Use G4hMultipleScattering for muons and protons
26-10-08 mma (exampleN03-V09-01-03)
- Update PhysicsList for proton and ions
07-05-08 J.Allison (exampleN03-V09-01-02)
- Protected "/control/execute vis.mac" with G4VIS_USE flag.
10-04-08 mma (exampleN03-V09-01-01)
- PhysicsList : replace G4MultipleScattering by G4eMultipleScattering
- update README
17-01-08 mma (exampleN03-V09-01-00)
- exampleN03.cc : make viManager available in batch mode
16-11-07 Laurent Garnier (exampleN03-V09-00-01)
- exampleN03 : Adding Qt render possibility
+10 -2
View File
@@ -1,4 +1,4 @@
$Id: README,v 1.16 2005/11/22 16:11:04 maire Exp $
$Id: README,v 1.17 2008/04/10 16:26:53 maire Exp $
-------------------------------------------------------------------
=========================================================
@@ -9,6 +9,7 @@ $Id: README,v 1.16 2005/11/22 16:11:04 maire Exp $
----------
This example simulates a simple Sampling Calorimeter setup.
(See also examples/extended/electromagnetic/TestEm3)
1- GEOMETRY DEFINITION
@@ -53,6 +54,9 @@ $Id: README,v 1.16 2005/11/22 16:11:04 maire Exp $
have a unique homogeneous block of matter, which looks like
a bubble chamber rather than a calorimeter ...
(see the macro of commands: newgeom.mac)
A more general version of this geometry can be found in :
examples/extended/electromagnetic/TestEm3
2- AN EVENT : THE PRIMARY GENERATOR
@@ -186,6 +190,10 @@ $Id: README,v 1.16 2005/11/22 16:11:04 maire Exp $
Idle> /control/execute newgeom.mac
....
Idle> exit
8- HISTOGRAMS
There is no histograms in novice examples. See a more complete version
of example N03 in : examples/extended/electromagnetic/TestEm3
+23 -23
View File
@@ -24,8 +24,8 @@
// ********************************************************************
//
//
// $Id: exampleN03.cc,v 1.33 2007/11/16 10:50:41 lgarnier Exp $
// GEANT4 tag $Name: geant4-09-01 $
// $Id: exampleN03.cc,v 1.36 2008/11/24 13:54:38 lgarnier Exp $
// GEANT4 tag $Name: geant4-09-02 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -33,8 +33,6 @@
#include "G4RunManager.hh"
#include "G4UImanager.hh"
#include "G4UIterminal.hh"
#include "G4UItcsh.hh"
#include "Randomize.hh"
@@ -50,18 +48,18 @@
#include "G4VisExecutive.hh"
#endif
#ifdef G4UI_USE_XM
#if defined(G4UI_USE_TCSH)
#include "G4UIterminal.hh"
#include "G4UItcsh.hh"
#elif defined(G4UI_USE_XM)
#include "G4UIXm.hh"
#endif
#ifdef G4UI_USE_WIN32
#elif defined(G4UI_USE_WIN32)
#include "G4UIWin32.hh"
#endif
#ifdef G4UI_USE_QT
#elif defined(G4UI_USE_QT)
#include "G4UIQt.hh"
#include "G4Qt.hh"
#include <qapplication.h>
#else
#include "G4UIterminal.hh"
#endif
@@ -109,6 +107,13 @@ int main(int argc,char** argv)
//
runManager->Initialize();
#ifdef G4VIS_USE
// Initialize visualization
//
G4VisManager* visManager = new G4VisExecutive;
visManager->Initialize();
#endif
// Get the pointer to the User Interface manager
//
G4UImanager* UI = G4UImanager::GetUIpointer();
@@ -121,11 +126,6 @@ int main(int argc,char** argv)
}
else // interactive mode : define visualization UI terminal
{
#ifdef G4VIS_USE
G4VisManager* visManager = new G4VisExecutive;
visManager->Initialize();
#endif
G4UIsession* session = 0;
#if defined(G4UI_USE_TCSH)
session = new G4UIterminal(new G4UItcsh);
@@ -141,20 +141,20 @@ int main(int argc,char** argv)
#else
session = new G4UIterminal();
#endif
UI->ApplyCommand("/control/execute vis.mac");
#ifdef G4VIS_USE
UI->ApplyCommand("/control/execute vis.mac");
#endif
session->SessionStart();
delete session;
#ifdef G4VIS_USE
delete visManager;
#endif
}
// Job termination
// Free the store: user actions, physics_list and detector_description are
// owned and deleted by the run manager, so they should not
// be deleted in the main() program !
#ifdef G4VIS_USE
delete visManager;
#endif
delete runManager;
return 0;
File diff suppressed because it is too large Load Diff
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03DetectorConstruction.hh,v 1.7 2006/06/29 17:48:32 gunter Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03DetectorMessenger.hh,v 1.7 2006/06/29 17:48:34 gunter Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03EventAction.hh,v 1.12 2007/07/02 13:22:08 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03EventActionMessenger.hh,v 1.10 2007/07/02 13:22:08 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03PhysicsList.hh,v 1.13 2007/07/02 13:22:08 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03PrimaryGeneratorAction.hh,v 1.8 2007/07/02 13:22:08 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03PrimaryGeneratorMessenger.hh,v 1.8 2007/07/02 13:22:08 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03RunAction.hh,v 1.11 2007/07/02 13:22:08 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03SteppingAction.hh,v 1.10 2007/07/02 13:22:08 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03SteppingVerbose.hh,v 1.9 2006/06/29 17:48:52 gunter Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -24,8 +24,8 @@
// ********************************************************************
//
//
// $Id: ExN03DetectorConstruction.cc,v 1.23 2006/06/29 17:48:54 gunter Exp $
// GEANT4 tag $Name: geant4-09-01 $
// $Id: ExN03DetectorConstruction.cc,v 1.24 2008/08/12 20:00:03 gum Exp $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -183,7 +183,7 @@ Aerog->AddElement (C , fractionmass= 0.1*perCent);
//
G4Material* CO2 =
new G4Material("CarbonicGas", density= 27.*mg/cm3, ncomponents=2,
new G4Material("CarbonicGas", density= 1.842*mg/cm3, ncomponents=2,
kStateGas, 325.*kelvin, 50.*atmosphere);
CO2->AddElement(C, natoms=1);
CO2->AddElement(O, natoms=2);
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03DetectorMessenger.cc,v 1.10 2006/06/29 17:48:58 gunter Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
+8 -8
View File
@@ -24,8 +24,8 @@
// ********************************************************************
//
//
// $Id: ExN03EventAction.cc,v 1.28 2006/10/26 14:30:05 allison Exp $
// GEANT4 tag $Name: geant4-09-01 $
// $Id: ExN03EventAction.cc,v 1.29 2008/01/17 17:31:32 maire Exp $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -65,11 +65,11 @@ ExN03EventAction::~ExN03EventAction()
void ExN03EventAction::BeginOfEventAction(const G4Event* evt)
{
G4int evtNb = evt->GetEventID();
if (evtNb%printModulo == 0) {
G4cout << "\n---> Begin of event: " << evtNb << G4endl;
CLHEP::HepRandom::showEngineStatus();
}
G4int evtNb = evt->GetEventID();
if (evtNb%printModulo == 0) {
G4cout << "\n---> Begin of event: " << evtNb << G4endl;
CLHEP::HepRandom::showEngineStatus();
}
// initialisation per event
EnergyAbs = EnergyGap = 0.;
@@ -102,7 +102,7 @@ void ExN03EventAction::EndOfEventAction(const G4Event* evt)
<< G4BestUnit(TrackLGap,"Length")
<< G4endl;
}
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03EventActionMessenger.cc,v 1.12 2006/10/26 14:28:00 allison Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
+40 -19
View File
@@ -24,8 +24,8 @@
// ********************************************************************
//
//
// $Id: ExN03PhysicsList.cc,v 1.21 2007/07/02 13:22:08 vnivanch Exp $
// GEANT4 tag $Name: geant4-09-01 $
// $Id: ExN03PhysicsList.cc,v 1.24 2008/10/31 08:40:41 maire Exp $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -141,7 +141,8 @@ void ExN03PhysicsList::ConstructProcess()
#include "G4GammaConversion.hh"
#include "G4PhotoElectricEffect.hh"
#include "G4MultipleScattering.hh"
#include "G4eMultipleScattering.hh"
#include "G4hMultipleScattering.hh"
#include "G4eIonisation.hh"
#include "G4eBremsstrahlung.hh"
@@ -152,6 +153,10 @@ void ExN03PhysicsList::ConstructProcess()
#include "G4MuPairProduction.hh"
#include "G4hIonisation.hh"
#include "G4hBremsstrahlung.hh"
#include "G4hPairProduction.hh"
#include "G4ionIonisation.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -171,32 +176,48 @@ void ExN03PhysicsList::ConstructEM()
} else if (particleName == "e-") {
//electron
pmanager->AddProcess(new G4MultipleScattering,-1, 1,1);
pmanager->AddProcess(new G4eIonisation, -1, 2,2);
pmanager->AddProcess(new G4eBremsstrahlung, -1, 3,3);
pmanager->AddProcess(new G4eMultipleScattering,-1, 1, 1);
pmanager->AddProcess(new G4eIonisation, -1, 2, 2);
pmanager->AddProcess(new G4eBremsstrahlung, -1, 3, 3);
} else if (particleName == "e+") {
//positron
pmanager->AddProcess(new G4MultipleScattering,-1, 1,1);
pmanager->AddProcess(new G4eIonisation, -1, 2,2);
pmanager->AddProcess(new G4eBremsstrahlung, -1, 3,3);
pmanager->AddProcess(new G4eplusAnnihilation, 0,-1,4);
pmanager->AddProcess(new G4eMultipleScattering,-1, 1, 1);
pmanager->AddProcess(new G4eIonisation, -1, 2, 2);
pmanager->AddProcess(new G4eBremsstrahlung, -1, 3, 3);
pmanager->AddProcess(new G4eplusAnnihilation, 0,-1, 4);
} else if( particleName == "mu+" ||
particleName == "mu-" ) {
//muon
pmanager->AddProcess(new G4MultipleScattering,-1, 1,1);
pmanager->AddProcess(new G4MuIonisation, -1, 2,2);
pmanager->AddProcess(new G4MuBremsstrahlung, -1, 3,3);
pmanager->AddProcess(new G4MuPairProduction, -1, 4,4);
pmanager->AddProcess(new G4hMultipleScattering,-1, 1, 1);
pmanager->AddProcess(new G4MuIonisation, -1, 2, 2);
pmanager->AddProcess(new G4MuBremsstrahlung, -1, 3, 3);
pmanager->AddProcess(new G4MuPairProduction, -1, 4, 4);
} else if( particleName == "proton" ||
particleName == "pi-" ||
particleName == "pi+" ) {
//proton
pmanager->AddProcess(new G4hMultipleScattering, -1, 1, 1);
pmanager->AddProcess(new G4hIonisation, -1, 2, 2);
pmanager->AddProcess(new G4hBremsstrahlung, -1, 3, 3);
pmanager->AddProcess(new G4hPairProduction, -1, 4, 4);
} else if ((!particle->IsShortLived()) &&
} else if( particleName == "alpha" ||
particleName == "He3" ||
particleName == "GenericIon" ) {
//Ions
pmanager->AddProcess(new G4hMultipleScattering, -1, 1, 1);
pmanager->AddProcess(new G4ionIonisation, -1, 2, 2);
} else if ((!particle->IsShortLived()) &&
(particle->GetPDGCharge() != 0.0) &&
(particle->GetParticleName() != "chargedgeantino")) {
//all others charged particles except geantino
pmanager->AddProcess(new G4MultipleScattering,-1, 1,1);
pmanager->AddProcess(new G4hIonisation, -1, 2,2);
}
pmanager->AddProcess(new G4hMultipleScattering,-1, 1, 1);
pmanager->AddProcess(new G4hIonisation, -1, 2, 2);
}
}
}
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03PrimaryGeneratorAction.cc,v 1.8 2006/06/29 17:49:07 gunter Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03PrimaryGeneratorMessenger.cc,v 1.9 2006/06/29 17:49:09 gunter Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
+4 -4
View File
@@ -24,8 +24,8 @@
// ********************************************************************
//
//
// $Id: ExN03RunAction.cc,v 1.18 2006/06/29 17:49:11 gunter Exp $
// GEANT4 tag $Name: geant4-09-01 $
// $Id: ExN03RunAction.cc,v 1.19 2008/01/17 17:31:32 maire Exp $
// GEANT4 tag $Name: geant4-09-02 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -54,7 +54,7 @@ void ExN03RunAction::BeginOfRunAction(const G4Run* aRun)
//inform the runManager to save random number seed
G4RunManager::GetRunManager()->SetRandomNumberStore(true);
//initialize cumulative quantities
//
sumEAbs = sum2EAbs =sumEGap = sum2EGap = 0.;
@@ -116,7 +116,7 @@ void ExN03RunAction::EndOfRunAction(const G4Run* aRun)
<< "\n mean trackLength in Gap : " << G4BestUnit(sumLGap,"Length")
<< " +- " << G4BestUnit(rmsLGap,"Length")
<< "\n------------------------------------------------------------\n"
<< G4endl;
<< G4endl;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03SteppingAction.cc,v 1.15 2006/06/29 17:49:13 gunter Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//
@@ -25,7 +25,7 @@
//
//
// $Id: ExN03SteppingVerbose.cc,v 1.13 2006/06/29 17:49:16 gunter Exp $
// GEANT4 tag $Name: geant4-09-01 $
// GEANT4 tag $Name: geant4-09-02 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo......
+3
View File
@@ -2,6 +2,9 @@
examples/novice/N03/visTutor/History
====================================
24th November 2008 Laurent Garnier
- exNo3Vis14.mac,exNo3Vis15.mac : Change OGLSQT by OGLSQt
3rd May 2005 John Allison (examples-V07-00-03)
- Replaced vis manager with G4VisExecutive.
+2 -2
View File
@@ -47,8 +47,8 @@
# with the OGLSQT (OpenGL Stored QT) driver
###########################################
# Invoke the OGLSQT driver
/vis/open OGLSQT
# Invoke the OGLSQt driver
/vis/open OGLSQt
# Bird's-eye view of the detector geometry
#
+1 -1
View File
@@ -31,7 +31,7 @@
/vis/scene/create
# Invoke the OpenInventor driver
/vis/sceneHandler/create OGLIQT
/vis/sceneHandler/create OGLIQt
/vis/viewer/create
# Add the world volume to the current scene
+2 -2
View File
@@ -32,8 +32,8 @@
/gui/addButton vis Vis2(OGLSX) "/control/execute visTutor/exN03Vis2.mac"
/gui/addButton vis Vis3(OGLSX) "/control/execute visTutor/exN03Vis3.mac"
/gui/addButton vis Vis4(OGLIX) "/control/execute visTutor/exN03Vis4.mac"
/gui/addButton vis Vis15(OGLIQT) "/control/execute visTutor/exN03Vis15.mac"
/gui/addButton vis Vis14(OGLSQT) "/control/execute visTutor/exN03Vis14.mac"
/gui/addButton vis Vis15(OGLIQt) "/control/execute visTutor/exN03Vis15.mac"
/gui/addButton vis Vis14(OGLSQt) "/control/execute visTutor/exN03Vis14.mac"
/gui/addButton vis Vis5(OIX) "/control/execute visTutor/exN03Vis5.mac"
/gui/addButton vis Vis6(VRML2FILE) "/control/execute visTutor/exN03Vis6.mac"
/gui/addButton vis Vis7(DAWNFILE) "/control/execute visTutor/exN03Vis7.mac"