Import Geant4 10.0.0 source tree
This commit is contained in:
@@ -0,0 +1,52 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 biasing/B03/include/B03ActionInitialization.hh
|
||||
/// \brief Definition of the B03ActionInitialization class
|
||||
//
|
||||
//
|
||||
// $Id: B03ActionInitialization.hh 66780 2013-01-12 14:56:35Z gcosmo $
|
||||
//
|
||||
|
||||
#ifndef B03ActionInitialization_h
|
||||
#define B03ActionInitialization_h 1
|
||||
|
||||
#include "G4VUserActionInitialization.hh"
|
||||
|
||||
class B03ActionInitialization : public G4VUserActionInitialization
|
||||
{
|
||||
public:
|
||||
B03ActionInitialization();
|
||||
virtual ~B03ActionInitialization();
|
||||
|
||||
public:
|
||||
virtual void BuildForMaster() const;
|
||||
virtual void Build() const;
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
@@ -0,0 +1,66 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 biasing/B03/include/B03DetectorConstruction.hh
|
||||
/// \brief Definition of the B03DetectorConstruction class
|
||||
//
|
||||
//
|
||||
// $Id: B03DetectorConstruction.hh 70238 2013-05-27 11:59:40Z gcosmo $
|
||||
//
|
||||
|
||||
#ifndef B03DetectorConstruction_hh
|
||||
#define B03DetectorConstruction_hh B03DetectorConstruction_hh
|
||||
|
||||
#include "globals.hh"
|
||||
#include "G4VUserDetectorConstruction.hh"
|
||||
|
||||
class G4VPhysicalVolume;
|
||||
class G4IStore;
|
||||
|
||||
class B03DetectorConstruction : public G4VUserDetectorConstruction
|
||||
{
|
||||
public:
|
||||
B03DetectorConstruction();
|
||||
~B03DetectorConstruction();
|
||||
|
||||
virtual G4VPhysicalVolume* Construct();
|
||||
|
||||
G4VPhysicalVolume* GetWorldVolume();
|
||||
G4VPhysicalVolume& GetWorldVolumeAddress() const;
|
||||
|
||||
// G4String GetCellName(G4int i);
|
||||
|
||||
void SetSensitive();
|
||||
|
||||
// virtual void ConstructSDandField();
|
||||
|
||||
private:
|
||||
|
||||
G4VPhysicalVolume* fWorldVolume;
|
||||
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,80 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 biasing/B03/include/B03ImportanceDetectorConstruction.hh
|
||||
/// \brief Definition of the B03ImportanceDetectorConstruction class
|
||||
//
|
||||
//
|
||||
// $Id: B03ImportanceDetectorConstruction.hh 70238 2013-05-27 11:59:40Z gcosmo $
|
||||
//
|
||||
|
||||
#ifndef B03ImportanceDetectorConstruction_hh
|
||||
#define B03ImportanceDetectorConstruction_hh B03ImportanceDetectorConstruction_hh
|
||||
|
||||
#include "globals.hh"
|
||||
#include <map>
|
||||
#include <vector>
|
||||
#include "G4GeometryCell.hh"
|
||||
#include "B03PVolumeStore.hh"
|
||||
|
||||
#include "G4VUserParallelWorld.hh"
|
||||
|
||||
class G4VPhysicalVolume;
|
||||
class G4LogicalVolume;
|
||||
|
||||
|
||||
|
||||
class B03ImportanceDetectorConstruction : public G4VUserParallelWorld
|
||||
{
|
||||
public:
|
||||
B03ImportanceDetectorConstruction(G4String worldName);
|
||||
~B03ImportanceDetectorConstruction();
|
||||
|
||||
const G4VPhysicalVolume &GetPhysicalVolumeByName(const G4String& name) const;
|
||||
G4VPhysicalVolume &GetWorldVolumeAddress() const;
|
||||
G4String ListPhysNamesAsG4String();
|
||||
G4String GetCellName(G4int i);
|
||||
G4GeometryCell GetGeometryCell(G4int i);
|
||||
|
||||
G4VPhysicalVolume* GetWorldVolume();
|
||||
|
||||
void SetSensitive();
|
||||
|
||||
virtual void ConstructSD();
|
||||
|
||||
private:
|
||||
virtual void Construct();
|
||||
B03PVolumeStore fPVolumeStore;
|
||||
|
||||
// std::vector< G4VPhysicalVolume * > fPhysicalVolumeVector;
|
||||
std::vector< G4LogicalVolume * > fLogicalVolumeVector;
|
||||
|
||||
// G4VPhysicalVolume *fWorldVolume;
|
||||
|
||||
G4VPhysicalVolume* fGhostWorld;
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,68 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 biasing/B03/include/B03PVolumeStore.hh
|
||||
/// \brief Definition of the B03PVolumeStore class
|
||||
//
|
||||
//
|
||||
// $Id: B03PVolumeStore.hh 66359 2012-12-18 09:08:26Z gcosmo $
|
||||
// GEANT4 tag
|
||||
//
|
||||
// ----------------------------------------------------------------------
|
||||
// Class B03PVolumeStore
|
||||
//
|
||||
// Class description:
|
||||
//
|
||||
// ...
|
||||
|
||||
// Author: Michael Dressel (Michael.Dressel@cern.ch)
|
||||
// ----------------------------------------------------------------------
|
||||
|
||||
#ifndef B03PVolumeStore_hh
|
||||
#define B03PVolumeStore_hh B03PVolumeStore_hh
|
||||
|
||||
#include "globals.hh"
|
||||
#include <set>
|
||||
#include "G4GeometryCell.hh"
|
||||
#include "G4GeometryCellComp.hh"
|
||||
|
||||
typedef std::set< G4GeometryCell, G4GeometryCellComp > B03SetGeometryCell;
|
||||
|
||||
class B03PVolumeStore {
|
||||
public:
|
||||
B03PVolumeStore();
|
||||
~B03PVolumeStore();
|
||||
|
||||
void AddPVolume(const G4GeometryCell &cell);
|
||||
const G4VPhysicalVolume *GetPVolume(const G4String &name) const;
|
||||
G4String GetPNames() const;
|
||||
|
||||
private:
|
||||
B03SetGeometryCell fSetGeometryCell;
|
||||
};
|
||||
|
||||
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,90 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 biasing/B03/include/B03PhysicsList.hh
|
||||
/// \brief Definition of the B03PhysicsList class
|
||||
//
|
||||
//
|
||||
#ifndef B03PhysicsList_h
|
||||
#define B03PhysicsList_h 1
|
||||
|
||||
#include "G4VUserPhysicsList.hh"
|
||||
#include "globals.hh"
|
||||
#include "G4GeometrySampler.hh"
|
||||
|
||||
#include <vector>
|
||||
|
||||
// taken from Tst12PhysicsList
|
||||
|
||||
class B03PhysicsList: public G4VUserPhysicsList
|
||||
{
|
||||
public:
|
||||
B03PhysicsList();
|
||||
virtual ~B03PhysicsList();
|
||||
|
||||
public:
|
||||
void AddParallelWorldName(G4String& pname)
|
||||
{fParaWorldName.push_back(pname);}
|
||||
|
||||
void AddBiasing(G4GeometrySampler *mgs, G4String& pname)
|
||||
{fGeomSampler = mgs; fBiasWorldName = pname;}
|
||||
|
||||
protected:
|
||||
// Construct particle and physics
|
||||
virtual void ConstructParticle();
|
||||
virtual void ConstructProcess();
|
||||
|
||||
//
|
||||
virtual void SetCuts();
|
||||
|
||||
protected:
|
||||
// these methods Construct physics processes and register them
|
||||
virtual void ConstructGeneral();
|
||||
virtual void ConstructEM();
|
||||
virtual void ConstructHad();
|
||||
virtual void ConstructLeptHad();
|
||||
|
||||
void AddScoringProcess();
|
||||
void AddBiasingProcess();
|
||||
|
||||
//
|
||||
void ConstructAllBosons();
|
||||
void ConstructAllLeptons();
|
||||
void ConstructAllMesons();
|
||||
void ConstructAllBaryons();
|
||||
void ConstructAllIons();
|
||||
void ConstructAllShortLiveds();
|
||||
|
||||
private:
|
||||
std::vector<G4String> fParaWorldName;
|
||||
G4String fBiasWorldName;
|
||||
G4GeometrySampler* fGeomSampler;
|
||||
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,54 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 biasing/B03/include/B03PrimaryGeneratorAction.hh
|
||||
/// \brief Definition of the B03PrimaryGeneratorAction class
|
||||
//
|
||||
//
|
||||
|
||||
#ifndef B03PrimaryGeneratorAction_hh
|
||||
#define B03PrimaryGeneratorAction_hh B03PrimaryGeneratorAction_hh
|
||||
|
||||
#include "G4VUserPrimaryGeneratorAction.hh"
|
||||
|
||||
class G4ParticleGun;
|
||||
class G4Event;
|
||||
|
||||
class B03PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction
|
||||
{
|
||||
public:
|
||||
B03PrimaryGeneratorAction();
|
||||
~B03PrimaryGeneratorAction();
|
||||
|
||||
public:
|
||||
virtual void GeneratePrimaries(G4Event* anEvent);
|
||||
|
||||
private:
|
||||
G4ParticleGun* fParticleGun;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
|
||||
@@ -0,0 +1,88 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 biasing/B03/include/B03Run.hh
|
||||
/// \brief Definition of the B03Run class
|
||||
//
|
||||
//
|
||||
// $Id: B03Run.hh 70093 2013-05-23 09:03:57Z gcosmo $
|
||||
//
|
||||
//---------------------------------------------------------------------
|
||||
// (Purpose)
|
||||
// Example implementation for multi-functional-detector and
|
||||
// primitive scorer.
|
||||
// This B03Run class has collections which accumulate
|
||||
// a event information into a run information.
|
||||
//
|
||||
//---------------------------------------------------------------------
|
||||
|
||||
#ifndef B03Run_h
|
||||
#define B03Run_h 1
|
||||
|
||||
#include "G4Run.hh"
|
||||
#include "G4Event.hh"
|
||||
|
||||
#include "G4THitsMap.hh"
|
||||
#include <vector>
|
||||
//
|
||||
class B03Run : public G4Run {
|
||||
|
||||
public:
|
||||
// constructor and destructor.
|
||||
// vector of multifunctionaldetector name has to given to constructor.
|
||||
B03Run(const std::vector<G4String> mfdName);
|
||||
virtual ~B03Run();
|
||||
|
||||
public:
|
||||
// virtual method from G4Run.
|
||||
// The method is overriden in this class for scoring.
|
||||
virtual void RecordEvent(const G4Event*);
|
||||
|
||||
// Access methods for scoring information.
|
||||
// - Number of HitsMap for this RUN.
|
||||
// This is equal to number of collections.
|
||||
G4int GetNumberOfHitsMap() const {return fRunMap.size();}
|
||||
// - Get HitsMap of this RUN.
|
||||
// by sequential number, by multifucntional name and collection name,
|
||||
// and by collection name with full path.
|
||||
G4THitsMap<G4double>* GetHitsMap(G4int i){return fRunMap[i];}
|
||||
G4THitsMap<G4double>* GetHitsMap(const G4String& detName,
|
||||
const G4String& colName);
|
||||
G4THitsMap<G4double>* GetHitsMap(const G4String& fullName);
|
||||
// - Dump All HitsMap of this RUN.
|
||||
// This method calls G4THisMap::PrintAll() for individual HitsMap.
|
||||
void DumpAllScorer();
|
||||
|
||||
virtual void Merge(const G4Run*);
|
||||
|
||||
private:
|
||||
std::vector<G4String> fCollName;
|
||||
std::vector<G4int> fCollID;
|
||||
std::vector<G4THitsMap<G4double>*> fRunMap;
|
||||
};
|
||||
|
||||
//
|
||||
|
||||
#endif
|
||||
@@ -0,0 +1,79 @@
|
||||
//
|
||||
// ********************************************************************
|
||||
// * 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 biasing/B03/include/B03RunAction.hh
|
||||
/// \brief Definition of the B03RunAction class
|
||||
//
|
||||
//
|
||||
// $Id: B03RunAction.hh 72862 2013-08-05 08:26:38Z ahoward $
|
||||
//
|
||||
|
||||
#ifndef B03RunAction_h
|
||||
#define B03RunAction_h 1
|
||||
|
||||
#include "G4UserRunAction.hh"
|
||||
#include "globals.hh"
|
||||
#include <vector>
|
||||
|
||||
class G4Run;
|
||||
|
||||
//=======================================================================
|
||||
// B03RunAction
|
||||
//
|
||||
//
|
||||
//
|
||||
//=======================================================================
|
||||
//
|
||||
class B03RunAction : public G4UserRunAction
|
||||
{
|
||||
public:
|
||||
// constructor and destructor
|
||||
B03RunAction();
|
||||
virtual ~B03RunAction();
|
||||
|
||||
public:
|
||||
// virtual method from G4UserRunAction.
|
||||
virtual G4Run* GenerateRun();
|
||||
virtual void BeginOfRunAction(const G4Run*);
|
||||
virtual void EndOfRunAction(const G4Run*);
|
||||
|
||||
public:
|
||||
void PrintHeader(std::ostream *out);
|
||||
std::string FillString(const std::string &name, char c, G4int n,
|
||||
G4bool back=true);
|
||||
|
||||
private:
|
||||
// Data member
|
||||
// - vector of MultiFunctionalDetecor names.
|
||||
std::vector<G4String> fSDName;
|
||||
// G4int fFieldName;
|
||||
G4int fFieldValue;
|
||||
|
||||
|
||||
};
|
||||
|
||||
//
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user