Import Geant4 4.0.0 source tree

This commit is contained in:
Gabriele Cosmo
2016-06-08 16:18:25 +02:00
parent 36c080dca6
commit 921d3b1cda
3990 changed files with 185376 additions and 82884 deletions
@@ -0,0 +1,97 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02CalorHit.hh,v 1.2 2001/07/11 09:58:01 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef F02CalorHit_h
#define F02CalorHit_h 1
#include "G4VHit.hh"
#include "G4THitsCollection.hh"
#include "G4Allocator.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02CalorHit : public G4VHit
{
public:
F02CalorHit();
~F02CalorHit();
F02CalorHit(const F02CalorHit&);
const F02CalorHit& operator=(const F02CalorHit&);
int operator==(const F02CalorHit&) const;
inline void* operator new(size_t);
inline void operator delete(void*);
void Print();
public:
void AddAbs(G4double de, G4double dl) {EdepAbs += de; TrackLengthAbs += dl;};
void AddGap(G4double de, G4double dl) {EdepGap += de; TrackLengthGap += dl;};
G4double GetEdepAbs() { return EdepAbs; };
G4double GetTrakAbs() { return TrackLengthAbs; };
G4double GetEdepGap() { return EdepGap; };
G4double GetTrakGap() { return TrackLengthGap; };
private:
G4double EdepAbs, TrackLengthAbs;
G4double EdepGap, TrackLengthGap;
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
typedef G4THitsCollection<F02CalorHit> F02CalorHitsCollection;
extern G4Allocator<F02CalorHit> F02CalorHitAllocator;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
inline void* F02CalorHit::operator new(size_t)
{
void* aHit;
aHit = (void*) F02CalorHitAllocator.MallocSingle();
return aHit;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
inline void F02CalorHit::operator delete(void* aHit)
{
F02CalorHitAllocator.FreeSingle((F02CalorHit*) aHit);
}
#endif
@@ -0,0 +1,66 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02CalorimeterSD.hh,v 1.3 2001/10/15 17:20:40 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef F02CalorimeterSD_h
#define F02CalorimeterSD_h 1
#include "globals.hh"
#include "G4VSensitiveDetector.hh"
#include "F02CalorHit.hh"
class F02DetectorConstruction;
class G4HCofThisEvent;
class G4Step;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02CalorimeterSD : public G4VSensitiveDetector
{
public:
F02CalorimeterSD(G4String, F02DetectorConstruction* );
~F02CalorimeterSD();
void Initialize(G4HCofThisEvent*);
G4bool ProcessHits(G4Step*,G4TouchableHistory*);
void EndOfEvent(G4HCofThisEvent*);
void clear();
void PrintAll();
private:
F02CalorHitsCollection* CalCollection;
F02DetectorConstruction* Detector;
G4int* HitID;
};
#endif
@@ -0,0 +1,135 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02DetectorConstruction.hh,v 1.4 2001/10/25 09:30:13 grichine Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
#ifndef F02DetectorConstruction_h
#define F02DetectorConstruction_h 1
#include "G4VUserDetectorConstruction.hh"
#include "globals.hh"
#include "G4ios.hh"
class G4Box;
class G4Tubs;
class G4LogicalVolume;
class G4VPhysicalVolume;
class G4Material;
class G4UniformMagField;
class F02DetectorMessenger;
class F02CalorimeterSD;
class F02ElectroMagneticField;
class F02DetectorConstruction : public G4VUserDetectorConstruction
{
public:
F02DetectorConstruction();
~F02DetectorConstruction();
public:
void SetAbsorberMaterial (G4String);
void SetAbsorberThickness(G4double);
void SetAbsorberRadius(G4double);
void SetAbsorberZpos(G4double);
void SetWorldMaterial(G4String);
void SetWorldSizeZ(G4double);
void SetWorldSizeR(G4double);
G4VPhysicalVolume* Construct();
void UpdateGeometry();
public:
void PrintCalorParameters();
G4Material* GetWorldMaterial() {return WorldMaterial;};
G4double GetWorldSizeZ() {return WorldSizeZ;};
G4double GetWorldSizeR() {return WorldSizeR;};
G4double GetAbsorberZpos() {return zAbsorber;};
G4double GetzstartAbs() {return zstartAbs;};
G4double GetzendAbs() {return zendAbs;};
G4Material* GetAbsorberMaterial() {return AbsorberMaterial;};
G4double GetAbsorberThickness() {return AbsorberThickness;};
G4double GetAbsorberRadius() {return AbsorberRadius;};
const G4VPhysicalVolume* GetphysiWorld() {return physiWorld;};
const G4VPhysicalVolume* GetAbsorber() {return physiAbsorber;};
G4LogicalVolume* GetLogicalAbsorber() {return logicAbsorber;};
private:
G4Tubs* solidWorld; // pointer to the solid World
G4LogicalVolume* logicWorld; // pointer to the logical World
G4VPhysicalVolume* physiWorld; // pointer to the physical World
G4Tubs* solidAbsorber; // pointer to the solid Absorber
G4LogicalVolume* logicAbsorber; // pointer to the logical Absorber
G4VPhysicalVolume* physiAbsorber; // pointer to the physical Absorber
G4UniformMagField* magField; // pointer to the magnetic field
F02ElectroMagneticField* fEmField;
F02DetectorMessenger* detectorMessenger; // pointer to the Messenger
F02CalorimeterSD* calorimeterSD; // pointer to the sensitive detector
G4Material* AbsorberMaterial;
G4double AbsorberThickness;
G4double AbsorberRadius;
G4bool worldchanged;
G4double zAbsorber ;
G4double zstartAbs , zendAbs ;
G4Material* WorldMaterial;
G4double WorldSizeR;
G4double WorldSizeZ;
private:
void DefineMaterials();
void ComputeCalorParameters();
G4VPhysicalVolume* ConstructCalorimeter();
};
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
inline void F02DetectorConstruction::ComputeCalorParameters()
{
// Compute derived parameters of the calorimeter
zstartAbs = zAbsorber-0.5*AbsorberThickness;
zendAbs = zAbsorber+0.5*AbsorberThickness;
}
#endif
@@ -0,0 +1,75 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02DetectorMessenger.hh,v 1.3 2001/10/25 09:30:13 grichine Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef F02DetectorMessenger_h
#define F02DetectorMessenger_h 1
#include "globals.hh"
#include "G4UImessenger.hh"
class F02DetectorConstruction;
class G4UIdirectory;
class G4UIcmdWithAString;
class G4UIcmdWithAnInteger;
class G4UIcmdWithADoubleAndUnit;
class G4UIcmdWithoutParameter;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02DetectorMessenger: public G4UImessenger
{
public:
F02DetectorMessenger(F02DetectorConstruction* );
~F02DetectorMessenger();
void SetNewValue(G4UIcommand*, G4String);
private:
F02DetectorConstruction* F02Detector;
G4UIdirectory* F02detDir;
G4UIcmdWithAString* AbsMaterCmd;
G4UIcmdWithADoubleAndUnit* AbsThickCmd;
G4UIcmdWithADoubleAndUnit* AbsRadCmd;
G4UIcmdWithADoubleAndUnit* AbsZposCmd;
G4UIcmdWithAString* WorldMaterCmd;
G4UIcmdWithADoubleAndUnit* WorldZCmd;
G4UIcmdWithADoubleAndUnit* WorldRCmd;
G4UIcmdWithoutParameter* UpdateCmd;
};
#endif
@@ -0,0 +1,103 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02ElectroMagneticField.hh,v 1.6 2001/12/04 17:53:53 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
// A class for control of the Magnetic Field of the detector.
// The field is assumed to be uniform.
//
// $ Id: $
// Should this be a:
// i) messenger
// ii) user class that creates the field ?
// iii) simply a derived class of Uniform field ? <== I have chosen this now.
// iv) a field manager that creates/updates field (Prefered?)
//
#ifndef F02ElectroMagneticField_H
#define F02ElectroMagneticField_H
#include "G4MagneticField.hh"
// #include "G4ElectroMagneticField.hh"
#include "G4UniformElectricField.hh"
class G4FieldManager;
class G4ChordFinder;
class G4EquationOfMotion;
class G4Mag_EqRhs;
class G4EqMagElectricField;
class G4MagIntegratorStepper;
class F02FieldMessenger;
class F02ElectroMagneticField : public G4UniformElectricField
{
public:
F02ElectroMagneticField(G4ThreeVector) ; // The value of the field
F02ElectroMagneticField() ; // A zero field
~F02ElectroMagneticField() ;
void GetFieldValue( const G4double [4], G4double * ) const {;}
void SetStepperType( G4int i) { fStepperType = i ; }
void SetStepper();
void SetMinStep(G4double s) { fMinStep = s ; }
void UpdateField();
void SetFieldValue(G4ThreeVector fieldVector);
void SetFieldValue(G4double fieldValue);
G4ThreeVector GetConstantFieldValue();
protected:
// Find the global Field Manager
G4FieldManager* GetGlobalFieldManager() ;
G4FieldManager* fFieldManager ;
G4ChordFinder* fChordFinder ;
G4EqMagElectricField* fEquation ;
G4UniformElectricField* fEMfield ;
G4MagIntegratorStepper* fStepper ;
G4int fStepperType ;
G4double fMinStep ;
F02FieldMessenger* fFieldMessenger;
};
#endif
@@ -0,0 +1,68 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02EventAction.hh,v 1.3 2001/11/07 16:36:32 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef F02EventAction_h
#define F02EventAction_h 1
#include "G4UserEventAction.hh"
#include "globals.hh"
class F02RunAction;
class F02EventActionMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02EventAction : public G4UserEventAction
{
public:
F02EventAction(F02RunAction* F02RA);
~F02EventAction();
public:
void BeginOfEventAction(const G4Event*);
void EndOfEventAction(const G4Event*);
G4int GetEventno();
void setEventVerbose(G4int level);
void SetDrawFlag(G4String val) {drawFlag = val;};
void SetPrintModulo(G4int val) {printModulo = val;};
private:
G4int calorimeterCollID;
F02EventActionMessenger* eventMessenger;
F02RunAction* runaction;
G4int verboselevel;
G4String drawFlag;
G4int printModulo;
};
#endif
@@ -0,0 +1,60 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02EventActionMessenger.hh,v 1.2 2001/07/11 09:58:01 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef F02EventActionMessenger_h
#define F02EventActionMessenger_h 1
#include "globals.hh"
#include "G4UImessenger.hh"
class F02EventAction;
class G4UIcmdWithAString;
class G4UIcmdWithAnInteger;
class G4UIcmdWithADoubleAndUnit;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02EventActionMessenger: public G4UImessenger
{
public:
F02EventActionMessenger(F02EventAction*);
~F02EventActionMessenger();
void SetNewValue(G4UIcommand*, G4String);
private:
F02EventAction* eventAction;
G4UIcmdWithAnInteger* setVerboseCmd;
G4UIcmdWithAString* DrawCmd;
G4UIcmdWithAnInteger* PrintCmd;
};
#endif
@@ -0,0 +1,72 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02FieldMessenger.hh,v 1.2 2001/07/11 09:58:02 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef F02FieldMessenger_h
#define F02FieldMessenger_h 1
#include "globals.hh"
#include "G4UImessenger.hh"
class F02ElectroMagneticField;
class G4UIdirectory;
class G4UIcmdWithAString;
class G4UIcmdWithAnInteger;
class G4UIcmdWithADoubleAndUnit;
class G4UIcmdWithoutParameter;
class F02FieldMessenger: public G4UImessenger
{
public:
F02FieldMessenger(F02ElectroMagneticField* );
~F02FieldMessenger();
void SetNewValue(G4UIcommand*, G4String);
void SetNewValue(G4UIcommand*, G4int);
private:
F02ElectroMagneticField* fEMfield;
G4UIdirectory* F02detDir;
G4UIcmdWithAnInteger* StepperCmd;
G4UIcmdWithADoubleAndUnit* MagFieldCmd;
G4UIcmdWithADoubleAndUnit* MinStepCmd;
G4UIcmdWithoutParameter* UpdateCmd;
G4UIcmdWithAString* AbsMaterCmd;
};
#endif
@@ -0,0 +1,133 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02PhysicsList.hh,v 1.2 2001/07/11 09:58:02 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
#ifndef F02PhysicsList_h
#define F02PhysicsList_h 1
#include "G4VUserPhysicsList.hh"
#include "globals.hh"
class G4PhotoElectricEffect;
class G4ComptonScattering;
class G4GammaConversion;
class G4MultipleScattering;
class G4PAIonisation ;
class G4ForwardXrayTR ;
class G4eIonisation;
class G4eBremsstrahlung;
class G4eplusAnnihilation;
class G4MuIonisation;
class G4MuBremsstrahlung;
class G4MuPairProduction;
class G4hIonisation;
class G4hIonisationPlus;
class F02StepCut;
class F02DetectorConstruction;
class F02PhysicsListMessenger;
class F02PhysicsList: public G4VUserPhysicsList
{
public:
F02PhysicsList( F02DetectorConstruction*);
~F02PhysicsList();
protected:
// Construct particle and physics
void ConstructParticle();
void ConstructProcess();
void SetCuts();
protected:
// these methods Construct particles
void ConstructBosons();
void ConstructLeptons();
void ConstructMesons();
void ConstructBarions();
protected:
// these methods Construct physics processes and register them
void AddParameterisation();
void ConstructGeneral();
void ConstructEM();
public:
void SetGammaCut(G4double);
void SetElectronCut(G4double);
void SetProtonCut(G4double);
void SetCutsByEnergy(G4double);
void GetRange(G4double);
void SetMaxStep(G4double);
public:
G4double MaxChargedStep;
private:
G4PhotoElectricEffect* thePhotoElectricEffect;
G4ComptonScattering* theComptonScattering;
G4GammaConversion* theGammaConversion;
G4MultipleScattering* theeminusMultipleScattering;
G4eIonisation* theeminusIonisation;
G4eBremsstrahlung* theeminusBremsstrahlung;
G4PAIonisation* fPAIonisation ;
G4ForwardXrayTR* fForwardXrayTR ;
G4MultipleScattering* theeplusMultipleScattering;
G4eIonisation* theeplusIonisation;
G4eBremsstrahlung* theeplusBremsstrahlung;
G4eplusAnnihilation* theeplusAnnihilation;
F02StepCut* theeminusStepCut ;
F02StepCut* theeplusStepCut ;
G4double cutForGamma;
G4double cutForElectron;
G4double cutForProton;
F02DetectorConstruction* pDet;
F02PhysicsListMessenger* physicsListMessenger;
};
#endif
@@ -0,0 +1,66 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02PhysicsListMessenger.hh,v 1.3 2001/10/15 17:20:41 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef F02PhysicsListMessenger_h
#define F02PhysicsListMessenger_h 1
#include "globals.hh"
#include "G4UImessenger.hh"
class F02PhysicsList;
class G4UIcmdWithoutParameter;
class G4UIcmdWithADouble;
class G4UIcmdWithADoubleAndUnit;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02PhysicsListMessenger: public G4UImessenger
{
public:
F02PhysicsListMessenger(F02PhysicsList*);
~F02PhysicsListMessenger();
void SetNewValue(G4UIcommand*, G4String);
private:
F02PhysicsList* F02List;
G4UIcmdWithADoubleAndUnit* setMaxStepCmd;
G4UIcmdWithADoubleAndUnit* cutGCmd;
G4UIcmdWithADoubleAndUnit* cutECmd;
G4UIcmdWithADoubleAndUnit* cutPCmd;
G4UIcmdWithADoubleAndUnit* rCmd;
G4UIcmdWithADoubleAndUnit* eCmd;
};
#endif
@@ -0,0 +1,73 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02PrimaryGeneratorAction.hh,v 1.3 2001/10/15 17:20:41 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef F02PrimaryGeneratorAction_h
#define F02PrimaryGeneratorAction_h 1
#include "G4VUserPrimaryGeneratorAction.hh"
#include "globals.hh"
class G4ParticleGun;
class G4Event;
class F02DetectorConstruction;
class F02PrimaryGeneratorMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction
{
public:
F02PrimaryGeneratorAction(F02DetectorConstruction*);
~F02PrimaryGeneratorAction();
public:
void GeneratePrimaries(G4Event*);
void SetRndmFlag(G4String val) { rndmFlag = val;}
void Setxvertex(G4double x) ;
void Setyvertex(G4double y) ;
void Setzvertex(G4double z) ;
static G4String GetPrimaryName() ;
private:
G4ParticleGun* particleGun; // pointer a to G4 service class
F02DetectorConstruction* F02Detector; // pointer to the geometry
F02PrimaryGeneratorMessenger* gunMessenger; // messenger of this class
G4String rndmFlag; // flag for a random impact point
static G4String thePrimaryParticleName ;
G4double xvertex,yvertex,zvertex;
G4bool vertexdefined ;
};
#endif
@@ -0,0 +1,61 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02PrimaryGeneratorMessenger.hh,v 1.2 2001/07/11 09:58:02 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef F02PrimaryGeneratorMessenger_h
#define F02PrimaryGeneratorMessenger_h 1
#include "G4UImessenger.hh"
#include "globals.hh"
class F02PrimaryGeneratorAction;
class G4UIcmdWithAString;
class G4UIcmdWithADoubleAndUnit;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02PrimaryGeneratorMessenger: public G4UImessenger
{
public:
F02PrimaryGeneratorMessenger(F02PrimaryGeneratorAction*);
~F02PrimaryGeneratorMessenger();
void SetNewValue(G4UIcommand*, G4String);
private:
F02PrimaryGeneratorAction* F02Action;
G4UIcmdWithAString* RndmCmd;
G4UIcmdWithADoubleAndUnit* setxvertexCmd;
G4UIcmdWithADoubleAndUnit* setyvertexCmd;
G4UIcmdWithADoubleAndUnit* setzvertexCmd;
};
#endif
@@ -0,0 +1,65 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02RunAction.hh,v 1.4 2001/11/07 16:36:32 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef F02RunAction_h
#define F02RunAction_h 1
#include "G4UserRunAction.hh"
#include "globals.hh"
#include "g4std/iostream"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02RunMessenger;
class G4Run;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02RunAction : public G4UserRunAction
{
public:
F02RunAction();
~F02RunAction();
public:
void BeginOfRunAction(const G4Run*);
void EndOfRunAction(const G4Run*);
void SetRndmFreq(G4int val) {saveRndm = val;}
G4int GetRndmFreq() {return saveRndm;}
private:
F02RunMessenger* runMessenger;
G4int saveRndm;
};
#endif
@@ -0,0 +1,68 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02RunMessenger.hh,v 1.3 2001/10/15 17:20:41 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef F02RunMessenger_h
#define F02RunMessenger_h 1
#include "globals.hh"
#include "G4UImessenger.hh"
#include "G4ios.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02RunAction;
class G4UIdirectory;
class G4UIcmdWithAnInteger;
class G4UIcmdWithAString;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02RunMessenger: public G4UImessenger
{
public:
F02RunMessenger(F02RunAction* );
~F02RunMessenger();
void SetNewValue(G4UIcommand* ,G4String );
private:
F02RunAction* runAction;
G4UIdirectory* RndmDir;
G4UIcmdWithAnInteger* RndmSaveCmd;
G4UIcmdWithAString* RndmReadCmd;
};
#endif
@@ -0,0 +1,125 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02StepCut.hh,v 1.3 2001/10/15 17:20:42 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
#ifndef F02StepCut_h
#define F02StepCut_h 1
#include "G4ios.hh"
#include "globals.hh"
#include "G4VDiscreteProcess.hh"
#include "G4Step.hh"
class F02StepCut : public G4VDiscreteProcess
{
public:
F02StepCut(const G4String& processName ="UserStepCut" );
F02StepCut(F02StepCut &);
~F02StepCut();
G4double PostStepGetPhysicalInteractionLength(
const G4Track& track,
G4double previousStepSize,
G4ForceCondition* condition
);
G4VParticleChange* PostStepDoIt(
const G4Track& ,
const G4Step&
);
void SetMaxStep(G4double);
protected:
// it is not needed here !
G4double GetMeanFreePath(const G4Track& aTrack,
G4double previousStepSize,
G4ForceCondition* condition
);
private:
// hide assignment operator as private
F02StepCut & operator=(const F02StepCut &right);
private:
G4double MaxChargedStep ;
};
// inlined function members implementation
#include "G4Step.hh"
#include "G4Track.hh"
#include "G4UserLimits.hh"
#include "G4VParticleChange.hh"
#include "G4EnergyLossTables.hh"
inline G4double F02StepCut::PostStepGetPhysicalInteractionLength(
const G4Track& aTrack,
G4double previousStepSize,
G4ForceCondition* condition
)
{
// condition is set to "Not Forced"
*condition = NotForced;
G4double ProposedStep = DBL_MAX;
if((MaxChargedStep > 0.) &&
(aTrack.GetVolume() != 0) &&
(aTrack.GetVolume()->GetName() == "Absorber") &&
(aTrack.GetDynamicParticle()->GetDefinition()->GetPDGCharge() != 0.))
ProposedStep = MaxChargedStep ;
return ProposedStep;
}
inline G4VParticleChange* F02StepCut::PostStepDoIt(
const G4Track& aTrack,
const G4Step&
)
{
// do nothing
aParticleChange.Initialize(aTrack);
return &aParticleChange;
}
inline G4double F02StepCut::GetMeanFreePath(const G4Track& aTrack,
G4double previousStepSize,
G4ForceCondition* condition
)
{
return 0.;
}
#endif
@@ -0,0 +1,57 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02SteppingAction.hh,v 1.4 2001/11/07 16:36:32 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef F02SteppingAction_h
#define F02SteppingAction_h 1
#include "G4UserSteppingAction.hh"
#include "G4Event.hh"
#include "G4EventManager.hh"
#include "G4ios.hh"
#include "globals.hh"
class F02SteppingMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02SteppingAction : public G4UserSteppingAction
{
public:
F02SteppingAction();
~F02SteppingAction();
void UserSteppingAction(const G4Step*);
private:
F02SteppingMessenger* steppingMessenger;
};
#endif
@@ -0,0 +1,63 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02SteppingMessenger.hh,v 1.2 2001/07/11 09:58:03 gunter Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef F02SteppingMessenger_h
#define F02SteppingMessenger_h 1
#include "globals.hh"
#include "G4UImessenger.hh"
#include "G4ios.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02SteppingAction;
class G4UIdirectory;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02SteppingMessenger: public G4UImessenger
{
public:
F02SteppingMessenger(F02SteppingAction* );
~F02SteppingMessenger();
void SetNewValue(G4UIcommand* ,G4String );
private:
F02SteppingAction* steppingAction;
G4UIdirectory* steppingDir;
};
#endif
@@ -0,0 +1,61 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02SteppingVerbose.hh,v 1.3 2001/10/15 17:20:42 gcosmo Exp $
// GEANT4 tag $Name: geant4-04-00 $
//
//
//---------------------------------------------------------------
//
// F02SteppingVerbose.hh
//
// Description:
// This class manages the vervose outputs in G4SteppingManager.
//
//
// Contact:
// Questions and comments to this code should be sent to
// Katsuya Amako (e-mail: Katsuya.Amako@kek.jp)
// Takashi Sasaki (e-mail: Takashi.Sasaki@kek.jp)
//
//---------------------------------------------------------------
#ifndef F02SteppingVerbose_h
#define F02SteppingVerbose_h 1
#include "G4SteppingVerbose.hh"
class F02SteppingVerbose : public G4SteppingVerbose
{
public:
F02SteppingVerbose();
~F02SteppingVerbose();
// Constructor/Destructor
void StepInfo();
void TrackingStarted();
};
#endif
@@ -0,0 +1,66 @@
//
// ********************************************************************
// * DISCLAIMER *
// * *
// * The following disclaimer summarizes all the specific disclaimers *
// * of contributors to this software. The specific disclaimers,which *
// * govern, are listed with their locations in: *
// * http://cern.ch/geant4/license *
// * *
// * 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. *
// * *
// * 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: F02VisManager.hh,v 1.2 2001/07/11 09:58:03 gunter Exp $
// GEANT4 tag $Name: geant4-04-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 F02VisManager_h
#define F02VisManager_h 1
#include "G4VisManager.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class F02VisManager: public G4VisManager
{
public:
F02VisManager ();
private:
void RegisterGraphicsSystems ();
};
#endif