Import Geant4 1.0.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-08 15:28:20 +02:00
parent aaa409b6ee
commit ca1c8cb059
2995 changed files with 106830 additions and 299600 deletions
@@ -0,0 +1,77 @@
// This code implementation is the intellectual property of
// the GEANT4 collaboration.
//
// By copying, distributing or modifying the Program (or any work
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: Em1DetectorConstruction.hh,v 1.1.4.1 1999/12/07 20:46:53 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef Em1DetectorConstruction_h
#define Em1DetectorConstruction_h 1
#include "G4VUserDetectorConstruction.hh"
#include "globals.hh"
class G4LogicalVolume;
class G4Material;
class G4UniformMagField;
class Em1DetectorMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class Em1DetectorConstruction : public G4VUserDetectorConstruction
{
public:
Em1DetectorConstruction();
~Em1DetectorConstruction();
public:
G4VPhysicalVolume* Construct();
void SetSize (G4double);
void SetMaterial (G4String);
void SetMagField (G4double);
void UpdateGeometry();
public:
const
G4VPhysicalVolume* GetWorld() {return pBox;};
G4double GeSize() {return BoxSize;};
G4Material* GetMaterial() {return aMaterial;};
void PrintParameters();
private:
G4VPhysicalVolume* pBox;
G4LogicalVolume* lBox;
G4double BoxSize;
G4Material* aMaterial;
G4UniformMagField* magField;
Em1DetectorMessenger* detectorMessenger;
private:
void DefineMaterials();
G4VPhysicalVolume* ConstructVolumes();
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#endif
@@ -0,0 +1,51 @@
// This code implementation is the intellectual property of
// the GEANT4 collaboration.
//
// By copying, distributing or modifying the Program (or any work
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: Em1DetectorMessenger.hh,v 1.1.4.1 1999/12/07 20:46:53 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef Em1DetectorMessenger_h
#define Em1DetectorMessenger_h 1
#include "globals.hh"
#include "G4UImessenger.hh"
class Em1DetectorConstruction;
class G4UIdirectory;
class G4UIcmdWithAString;
class G4UIcmdWithADoubleAndUnit;
class G4UIcmdWithoutParameter;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class Em1DetectorMessenger: public G4UImessenger
{
public:
Em1DetectorMessenger(Em1DetectorConstruction* );
~Em1DetectorMessenger();
void SetNewValue(G4UIcommand*, G4String);
private:
Em1DetectorConstruction* Em1Detector;
G4UIdirectory* Em1detDir;
G4UIcmdWithAString* MaterCmd;
G4UIcmdWithADoubleAndUnit* SizeCmd;
G4UIcmdWithADoubleAndUnit* MagFieldCmd;
G4UIcmdWithoutParameter* UpdateCmd;
};
#endif
@@ -0,0 +1,53 @@
// This code implementation is the intellectual property of
// the GEANT4 collaboration.
//
// By copying, distributing or modifying the Program (or any work
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: Em1EventAction.hh,v 1.1.4.1 1999/12/07 20:46:53 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef Em1EventAction_h
#define Em1EventAction_h 1
#include "G4UserEventAction.hh"
#include "globals.hh"
class Em1RunAction;
class Em1EventActionMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class Em1EventAction : public G4UserEventAction
{
public:
Em1EventAction(Em1RunAction*);
~Em1EventAction();
public:
void BeginOfEventAction(const G4Event*);
void EndOfEventAction(const G4Event*);
void addEdep(G4double Edep) {TotalEnergyDeposit += Edep;};
G4double GetEnergyDeposit() {return TotalEnergyDeposit;};
void SetDrawFlag(G4String val) {drawFlag = val;};
void SetPrintModulo(G4int val) {printModulo = val;};
private:
Em1RunAction* Em1Run;
G4double TotalEnergyDeposit;
G4String drawFlag;
G4int printModulo;
Em1EventActionMessenger* eventMessenger;
};
#endif
@@ -0,0 +1,42 @@
// This code implementation is the intellectual property of
// the GEANT4 collaboration.
//
// By copying, distributing or modifying the Program (or any work
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: Em1EventActionMessenger.hh,v 1.1.4.1 1999/12/07 20:46:53 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef Em1EventActionMessenger_h
#define Em1EventActionMessenger_h 1
#include "globals.hh"
#include "G4UImessenger.hh"
class Em1EventAction;
class G4UIcmdWithAString;
class G4UIcmdWithAnInteger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class Em1EventActionMessenger: public G4UImessenger
{
public:
Em1EventActionMessenger(Em1EventAction*);
~Em1EventActionMessenger();
void SetNewValue(G4UIcommand*, G4String);
private:
Em1EventAction* eventAction;
G4UIcmdWithAString* DrawCmd;
G4UIcmdWithAnInteger* PrintCmd;
};
#endif
@@ -0,0 +1,66 @@
// This code implementation is the intellectual property of
// the GEANT4 collaboration.
//
// By copying, distributing or modifying the Program (or any work
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: Em1PhysicsList.hh,v 1.1.4.1 1999/12/07 20:46:53 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef Em1PhysicsList_h
#define Em1PhysicsList_h 1
#include "G4VUserPhysicsList.hh"
#include "globals.hh"
class Em1DetectorConstruction;
class Em1PhysicsListMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class Em1PhysicsList: public G4VUserPhysicsList
{
public:
Em1PhysicsList(Em1DetectorConstruction*);
~Em1PhysicsList();
protected:
// Construct particles
void ConstructParticle();
void ConstructBosons();
void ConstructLeptons();
void ConstructMesons();
void ConstructBarions();
public:
void SetCuts();
void SetGammaCut(G4double);
void SetElectronCut(G4double);
void SetProtonCut(G4double);
void SetCutsByEnergy(G4double);
void GetRange(G4double);
protected:
// Construct processes and register them
void ConstructProcess();
void ConstructGeneral();
void ConstructEM();
private:
Em1DetectorConstruction* pDet;
Em1PhysicsListMessenger* pMes;
G4double cutForGamma;
G4double cutForElectron;
G4double cutForProton;
};
#endif
@@ -0,0 +1,44 @@
// This code implementation is the intellectual property of
// the GEANT4 collaboration.
//
// By copying, distributing or modifying the Program (or any work
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: Em1PhysicsListMessenger.hh,v 1.1.4.1 1999/12/07 20:46:54 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef Em1PhysicsListMessenger_h
#define Em1PhysicsListMessenger_h 1
#include "globals.hh"
#include "G4UImessenger.hh"
class Em1PhysicsList;
class G4UIcmdWithADoubleAndUnit;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class Em1PhysicsListMessenger: public G4UImessenger
{
public:
Em1PhysicsListMessenger(Em1PhysicsList*);
~Em1PhysicsListMessenger();
void SetNewValue(G4UIcommand*, G4String);
private:
Em1PhysicsList* physList;
G4UIcmdWithADoubleAndUnit* cutGCmd;
G4UIcmdWithADoubleAndUnit* cutECmd;
G4UIcmdWithADoubleAndUnit* cutPCmd;
G4UIcmdWithADoubleAndUnit* rCmd;
G4UIcmdWithADoubleAndUnit* eCmd;
};
#endif
@@ -0,0 +1,43 @@
// This code implementation is the intellectual property of
// the GEANT4 collaboration.
//
// By copying, distributing or modifying the Program (or any work
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: Em1PrimaryGeneratorAction.hh,v 1.1.4.1 1999/12/07 20:46:54 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef Em1PrimaryGeneratorAction_h
#define Em1PrimaryGeneratorAction_h 1
#include "G4VUserPrimaryGeneratorAction.hh"
#include "globals.hh"
class G4ParticleGun;
class G4Event;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class Em1PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction
{
public:
Em1PrimaryGeneratorAction();
~Em1PrimaryGeneratorAction();
public:
void GeneratePrimaries(G4Event*);
private:
G4ParticleGun* particleGun; //pointer a to G4 service class
};
#endif
@@ -0,0 +1,69 @@
// This code implementation is the intellectual property of
// the GEANT4 collaboration.
//
// By copying, distributing or modifying the Program (or any work
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: Em1RunAction.hh,v 1.1.4.1 1999/12/07 20:46:54 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef Em1RunAction_h
#define Em1RunAction_h 1
#include "G4UserRunAction.hh"
#include "ProcessesCount.hh"
#include "globals.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class G4Run;
class Em1RunActionMessenger;
class HepTupleManager;
class HepHistogram;
class Em1RunAction : public G4UserRunAction
{
public:
Em1RunAction();
~Em1RunAction();
public:
void BeginOfRunAction(const G4Run*);
void EndOfRunAction(const G4Run*);
void CountTraks0(G4int nt) { NbOfTraks0 += nt;}
void CountTraks1(G4int nt) { NbOfTraks1 += nt;}
void CountSteps0(G4int ns) { NbOfSteps0 += ns;}
void CountSteps1(G4int ns) { NbOfSteps1 += ns;}
void CountProcesses(G4String);
public:
HepHistogram* GetHisto(G4int id) {return histo[id];}
void SetRndmFreq(G4int val) {saveRndm = val;}
G4int GetRndmFreq() {return saveRndm;}
private:
void bookHisto();
void cleanHisto();
private:
G4int NbOfTraks0, NbOfTraks1;
G4int NbOfSteps0, NbOfSteps1;
ProcessesCount* ProcCounter;
HepTupleManager* hbookManager;
HepHistogram* histo[3];
Em1RunActionMessenger* runMessenger;
G4int saveRndm;
};
#endif
@@ -0,0 +1,45 @@
// This code implementation is the intellectual property of
// the GEANT4 collaboration.
//
// By copying, distributing or modifying the Program (or any work
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: Em1RunActionMessenger.hh,v 1.1.4.1 1999/12/07 20:46:54 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef Em1RunActionMessenger_h
#define Em1RunActionMessenger_h 1
#include "globals.hh"
#include "G4UImessenger.hh"
class Em1RunAction;
class G4UIdirectory;
class G4UIcmdWithAString;
class G4UIcmdWithAnInteger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class Em1RunActionMessenger: public G4UImessenger
{
public:
Em1RunActionMessenger(Em1RunAction*);
~Em1RunActionMessenger();
void SetNewValue(G4UIcommand*, G4String);
private:
Em1RunAction* Em1Run;
G4UIdirectory* RndmDir;
G4UIcmdWithAnInteger* RndmSaveCmd;
G4UIcmdWithAString* RndmReadCmd;
};
#endif
@@ -0,0 +1,39 @@
// This code implementation is the intellectual property of
// the GEANT4 collaboration.
//
// By copying, distributing or modifying the Program (or any work
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: Em1SteppingAction.hh,v 1.1.4.1 1999/12/07 20:46:54 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef Em1SteppingAction_h
#define Em1SteppingAction_h 1
#include "G4UserSteppingAction.hh"
class Em1RunAction;
class Em1EventAction;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class Em1SteppingAction : public G4UserSteppingAction
{
public:
Em1SteppingAction(Em1RunAction*,Em1EventAction*);
~Em1SteppingAction();
void UserSteppingAction(const G4Step*);
private:
Em1RunAction* runAction;
Em1EventAction* eventAction;
};
#endif
@@ -0,0 +1,34 @@
// This code implementation is the intellectual property of
// the GEANT4 collaboration.
//
// By copying, distributing or modifying the Program (or any work
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: Em1TrackingAction.hh,v 1.1.4.1 1999/12/07 20:46:54 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
//
//
#ifndef Em1TrackingAction_h
#define Em1TrackingAction_h 1
#include "G4UserTrackingAction.hh"
class Em1RunAction;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class Em1TrackingAction : public G4UserTrackingAction {
public:
Em1TrackingAction(Em1RunAction*);
~Em1TrackingAction() {};
void PostUserTrackingAction(const G4Track*);
private:
Em1RunAction* runAction;
};
#endif
@@ -0,0 +1,50 @@
// This code implementation is the intellectual property of
// the GEANT4 collaboration.
//
// By copying, distributing or modifying the Program (or any work
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: Em1VisManager.hh,v 1.1.4.1 1999/12/07 20:46:54 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
// Example Visualization Manager implementing virtual function
// RegisterGraphicsSystems. Exploits C-pre-processor variables
// G4VIS_USE_DAWN, etc., which are set by the GNUmakefiles if
// environment variables of the same name are set.
// So all you have to do is set environment variables and compile and
// instantiate this in your main().
// Alternatively, you can implement an empty function here and just
// register the systems you want in your main(), e.g.:
// G4VisManager* myVisManager = new MyVisManager;
// myVisManager -> RegisterGraphicsSystem (new MyGraphicsSystem);
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef Em1VisManager_h
#define Em1VisManager_h 1
#include "G4VisManager.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class Em1VisManager: public G4VisManager {
public:
Em1VisManager ();
private:
void RegisterGraphicsSystems ();
};
#endif
@@ -0,0 +1,61 @@
// This code implementation is the intellectual property of
// the GEANT4 collaboration.
//
// By copying, distributing or modifying the Program (or any work
// based on the Program) you indicate your acceptance of this statement,
// and all its terms.
//
// $Id: ProcessesCount.hh,v 1.1.2.1.2.1 1999/12/07 20:46:55 gunter Exp $
// GEANT4 tag $Name: geant4-01-00 $
//
//
// -----------------------------------------------------------------
// GEANT 4 class header file
//
// For information related to this code contact:
// CERN, CN Division, ASD group
//
// ------------------- class ProcessesCount -----------------
//
// 26-10-98: first version, M.Maire
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef ProcessesCount_HH
#define ProcessesCount_HH
#include "globals.hh"
#include "g4rw/tpordvec.h"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class OneProcessCount
{
public:
OneProcessCount(G4String name) {Name=name; Counter=0;};
~OneProcessCount() {};
G4int operator==(const OneProcessCount& right) const {return (this==&right);};
G4int operator!=(const OneProcessCount& right) const {return (this!=&right);};
private:
OneProcessCount(OneProcessCount& right) {*this= right;};
const OneProcessCount& operator=(const OneProcessCount& right) {return right;};
public:
G4String GetName() {return Name;};
G4int GetCounter() {return Counter;};
void Count() {Counter++;};
private:
G4String Name; // process name
G4int Counter; // process counter
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
typedef G4RWTPtrOrderedVector<OneProcessCount> ProcessesCount;
#endif