Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found
Select Git revision
  • addWoodcockProcess
  • atlas-wdck
  • atlaspatch_G4GammaGeneralProcess
  • branch_10.6.3.10_dev01
  • fix-ATLASSIM-6363-6396
  • fix-for-ATLASSIM-6923
  • fix-mc23-wdck
  • fix-woodcock-build
  • geant4-0.0-release
  • geant4-0.1-release
  • geant4-1.0-release
  • geant4-1.1-release
  • geant4-10.0-release
  • geant4-10.1-release
  • geant4-10.1.3-atlaspatch
  • geant4-10.1.3-atlastests
  • geant4-10.2-atlaspatch
  • geant4-10.2-release
  • geant4-10.2.3-atlaspatch
  • geant4-10.3-release
  • geant4-10.3.1-atlaspatch
  • geant4-10.3.3-atlaspatch
  • geant4-10.4-atlaspatch
  • geant4-10.4.2-atlaspatch
  • geant4-10.4.3-atlaspatch
  • geant4-10.5.0.beta-atlaspatch
  • geant4-10.5.1-atlaspatch
  • geant4-10.5.1-singlelibrarytest
  • geant4-10.6.0-atlaspatch
  • geant4-10.6.0.beta-atlaspatch
  • geant4-10.6.2-atlaspatch
  • geant4-10.6.2-singlelibrarytest
  • geant4-10.6.3-atlaspatch
  • geant4-10.6.3-atlaspatch-QSSStepper
  • geant4-10.6.3.8-hadronicPatch
  • geant4-10.7.0.beta-atlaspatch
  • geant4-10.7.0.beta-atlaspatch-G4MagIntDrv.patch
  • geant4-10.7.1-atlaspatch
  • geant4-10.7.2-atlaspatch
  • geant4-11.1.1-atlaspatch
  • geant4-11.1.2-atlaspatch
  • geant4-11.1.3-atlaspatch
  • geant4-11.2.2-atlaspatch
  • geant4-11.3.0-atlaspatch
  • geant4-11.3.2-atlaspatch
  • geant4-2.0-release
  • geant4-3.0-release
  • geant4-3.1-release
  • geant4-3.2-release
  • geant4-4.0-release
  • geant4-4.1-release
  • geant4-5.0-release
  • geant4-5.1-release
  • geant4-5.2-release
  • geant4-6.0-release
  • geant4-6.1-release
  • geant4-6.2-release
  • geant4-7.0-release
  • geant4-7.1-release
  • geant4-8.0-release
  • geant4-8.1-release
  • geant4-8.2-release
  • geant4-8.3-release
  • geant4-9.0-release
  • geant4-9.1-release
  • geant4-9.2-release
  • geant4-9.3-release
  • geant4-9.4-release
  • geant4-9.5-release
  • geant4-9.6-release
  • geant4-9.6.3-atlaspatch
  • geant4-v10.6.0.1-G4MagIntDrv.patch
  • geant4.10.6.3.5
  • geometryTesting
  • master
  • mc23-fix-loopers
  • quasistableTesting
  • temporaryFixG4GenericTrap
  • v10.1.3.2_newElastic
  • v10.6.3.3-atlassim-5739
  • v10.6.3.3_ATLASSIM_5598_BERT
  • v10.6.3.3_ATLASSIM_5598_BERT_FTFP
  • 10.6.3.10_dev01
  • 10.6.3.10_dev02
  • v0.0.1
  • v0.0.2
  • v0.0.3
  • v0.0.4
  • v0.1.0
  • v0.1.1
  • v1.0.0
  • v1.1.0
  • v10.0.0
  • v10.0.1
  • v10.0.2
  • v10.0.3
  • v10.0.4
  • v10.1.0
  • v10.1.1
  • v10.1.2
  • v10.1.3
  • v10.1.3.1
  • v10.1.3.2
  • v10.1.3.2_newElastic
  • v10.1.3.2qs
  • v10.1.3.3
  • v10.1.3.4
  • v10.1.3.5
  • v10.1.3.6
  • v10.1.3.7
  • v10.1.3.7_ConfigureForTrackPatch
  • v10.1.3.8
  • v10.1.3.8.1
  • v10.1.3.t1
  • v10.1.3.t2
  • v10.2.0
  • v10.2.1
  • v10.2.2
  • v10.2.3
  • v10.2.3.1
  • v10.3.0
  • v10.3.0.beta
  • v10.3.1
  • v10.3.1.1
  • v10.3.2
  • v10.3.3
  • v10.4.0
  • v10.4.0.beta
  • v10.4.1
  • v10.4.2
  • v10.4.2.1
  • v10.4.3
  • v10.4.3.1
  • v10.5.0
  • v10.5.0.1
  • v10.5.0.1_ReportLoopingParticle
  • v10.5.0.1_verboseG4Exception
  • v10.5.0.beta
  • v10.5.1
  • v10.6.0
  • v10.6.0.1
  • v10.6.0.1_G4MagInt_Drv
  • v10.6.0.beta
  • v10.6.1
  • v10.6.2
  • v10.6.3
  • v10.6.3.10
  • v10.6.3.11
  • v10.6.3.12
  • v10.6.3.13
  • v10.6.3.14
  • v10.6.3.15
  • v10.6.3.2
  • v10.6.3.3
  • v10.6.3.4
  • v10.6.3.5
  • v10.6.3.6
  • v10.6.3.7
  • v10.6.3.8
  • v10.6.3.8_hadronicPatch
  • v10.6.3.9
  • v10.7.0
  • v10.7.0.beta
  • v10.7.0.beta.1
  • v10.7.0.beta.1_G4MagInt_Drv
  • v10.7.1
  • v10.7.2
  • v10.7.3
  • v10.7.4
  • v11.0.0
  • v11.0.0.beta
  • v11.0.1
  • v11.0.2
  • v11.0.3
  • v11.0.4
  • v11.1.0
  • v11.1.0.beta
  • v11.1.1
  • v11.1.2
  • v11.1.3
  • v11.1.3.1
  • v11.1.3.2
182 results

Target

Select target project
  • mnovak/geant4
  • ghugo/geant4
  • cbira/geant4
  • jebrown/geant4
  • averbyts/geant4
  • cirrone/geant4
  • jrodrig2/geant4
  • ekourlit/geant4
  • zuysal/geant4
  • whopkins/geant4
  • mbandier/geant4
  • ldesorgh/geant4
  • mpuccio/geant4
  • ivorobye/geant4
  • kurasige/geant4
  • pcanal/geant4
  • ychiu/geant4
  • mrenda/geant4
  • ssnyder/geant4
  • graemes/geant4
  • atlas-simulation-team/geant4
21 results
Select Git revision
  • geant4-0.0-release
  • geant4-0.1-release
  • geant4-1.0-release
  • geant4-1.1-release
  • geant4-10.0-release
  • geant4-10.1-release
  • geant4-10.2-release
  • geant4-10.3-release
  • geant4-10.4-release
  • geant4-10.5-release
  • geant4-10.6-release
  • geant4-10.7-release
  • geant4-11.0-release
  • geant4-11.1-release
  • geant4-11.2-release
  • geant4-11.3-release
  • geant4-2.0-release
  • geant4-3.0-release
  • geant4-3.1-release
  • geant4-3.2-release
  • geant4-4.0-release
  • geant4-4.1-release
  • geant4-5.0-release
  • geant4-5.1-release
  • geant4-5.2-release
  • geant4-6.0-release
  • geant4-6.1-release
  • geant4-6.2-release
  • geant4-7.0-release
  • geant4-7.1-release
  • geant4-8.0-release
  • geant4-8.1-release
  • geant4-8.2-release
  • geant4-8.3-release
  • geant4-9.0-release
  • geant4-9.1-release
  • geant4-9.2-release
  • geant4-9.3-release
  • geant4-9.4-release
  • geant4-9.5-release
  • geant4-9.6-release
  • master
  • geant4-10-00-patch-04-ref
  • geant4-10-01-patch-03-ref
  • v0.0.1
  • v0.0.2
  • v0.0.3
  • v0.0.4
  • v0.1.0
  • v0.1.1
  • v1.0.0
  • v1.1.0
  • v10.0.0
  • v10.0.1
  • v10.0.2
  • v10.0.3
  • v10.0.4
  • v10.1.0
  • v10.1.1
  • v10.1.2
  • v10.1.3
  • v10.2.0
  • v10.2.1
  • v10.2.2
  • v10.2.3
  • v10.3.0
  • v10.3.0.beta
  • v10.3.1
  • v10.3.2
  • v10.3.3
  • v10.4.0
  • v10.4.0.beta
  • v10.4.1
  • v10.4.2
  • v10.4.3
  • v10.5.0
  • v10.5.0.beta
  • v10.5.1
  • v10.6.0
  • v10.6.0.beta
  • v10.6.1
  • v10.6.2
  • v10.6.3
  • v10.7.0
  • v10.7.0.beta
  • v10.7.1
  • v10.7.2
  • v10.7.3
  • v10.7.4
  • v11.0.0
  • v11.0.0.beta
  • v11.0.1
  • v11.0.2
  • v11.0.3
  • v11.0.4
  • v11.1.0
  • v11.1.0.beta
  • v11.1.1
  • v11.1.2
  • v11.1.3
  • v11.2.0
  • v11.2.0.beta
  • v11.2.1
  • v11.2.2
  • v11.3.0
  • v11.3.0.beta
  • v11.3.1
  • v11.3.2
  • v11.4.0.beta
  • v2.0.0
  • v2.0.1
  • v3.0.0
  • v3.1.0
  • v3.2.0
  • v4.0.0
  • v4.0.1
  • v4.0.2
  • v4.1.0
  • v4.1.1
  • v5.0.0
  • v5.0.1
  • v5.1.0
  • v5.1.1
  • v5.2.0
  • v5.2.1
  • v5.2.2
  • v6.0.0
  • v6.0.1
  • v6.1.0
  • v6.2.0
  • v6.2.1
  • v6.2.2
  • v7.0.0
  • v7.0.1
  • v7.1.0
  • v7.1.1
  • v8.0.0
  • v8.0.1
  • v8.1.0
  • v8.1.1
  • v8.1.2
  • v8.2.0
142 results
Show changes
Showing
with 1629 additions and 0 deletions
// 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: G3toG4EventAction.hh,v 1.1 2000/07/24 11:23:42 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef G3toG4EventAction_h
#define G3toG4EventAction_h 1
#include "G4UserEventAction.hh"
#include "globals.hh"
class G3toG4EventActionMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class G3toG4EventAction : public G4UserEventAction
{
public:
G3toG4EventAction();
~G3toG4EventAction();
public:
void BeginOfEventAction(const G4Event* anEvent);
void EndOfEventAction(const G4Event* anEvent);
void SetDrawFlag(G4String val) {drawFlag = val;};
private:
G4String drawFlag; // control the drawing of event
G3toG4EventActionMessenger* eventMessenger;
};
#endif
// 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: G3toG4EventActionMessenger.hh,v 1.1 2000/07/24 11:23:42 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef G3toG4EventActionMessenger_h
#define G3toG4EventActionMessenger_h 1
#include "globals.hh"
#include "G4UImessenger.hh"
class G3toG4EventAction;
class G4UIcmdWithAString;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class G3toG4EventActionMessenger: public G4UImessenger
{
public:
G3toG4EventActionMessenger(G3toG4EventAction*);
~G3toG4EventActionMessenger();
void SetNewValue(G4UIcommand*, G4String);
private:
G3toG4EventAction* eventAction;
G4UIcmdWithAString* DrawCmd;
};
#endif
// 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: G3toG4PhysicsList.hh,v 1.1 2000/07/24 11:23:42 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef G3toG4PhysicsList_h
#define G3toG4PhysicsList_h 1
#include "G4VUserPhysicsList.hh"
#include "globals.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class G3toG4PhysicsList: public G4VUserPhysicsList
{
public:
G3toG4PhysicsList();
~G3toG4PhysicsList();
protected:
// Construct particle and physics
virtual void ConstructParticle();
virtual void ConstructProcess();
virtual void SetCuts();
public:
// Set/Get cut values
void SetCutForGamma(G4double);
void SetCutForElectron(G4double);
void SetCutForProton(G4double);
G4double GetCutForGamma() const;
G4double GetCutForElectron() const;
G4double GetCutForProton() const;
protected:
// these methods Construct particles
void ConstructBosons();
void ConstructLeptons();
void ConstructMesons();
void ConstructBaryons();
protected:
// these methods Construct physics processes and register them
void ConstructGeneral();
void ConstructEM();
private:
G4double cutForGamma;
G4double cutForElectron;
G4double cutForProton;
G4double currentDefaultCut;
};
#endif
// 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: G3toG4PrimaryGeneratorAction.hh,v 1.1 2000/07/24 11:23:42 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
#ifndef G3toG4PrimaryGeneratorAction_h
#define G3toG4PrimaryGeneratorAction_h 1
#include "G4Event.hh"
#include "G4ParticleGun.hh"
#include "G4VUserPrimaryGeneratorAction.hh"
#include "G4ThreeVector.hh"
class G3toG4PrimaryGeneratorAction : public G4VUserPrimaryGeneratorAction
{
public:
G3toG4PrimaryGeneratorAction();
~G3toG4PrimaryGeneratorAction();
public:
void GeneratePrimaries(G4Event* anEvent);
private:
G4ParticleGun* particleGun;
G4ThreeVector GetRandomDirection();
};
#endif
// 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: G3toG4RunAction.hh,v 1.1 2000/07/24 11:23:42 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
#ifndef G3toG4RunAction_h
#define G3toG4RunAction_h 1
#include "G4UserRunAction.hh"
#include "globals.hh"
class G4Run;
class G3toG4RunAction : public G4UserRunAction
{
public:
G3toG4RunAction();
~G3toG4RunAction();
public:
void BeginOfRunAction(const G4Run* aRun);
void EndOfRunAction(const G4Run* aRun);
private:
G4int runIDcounter;
};
#endif
// 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: G3toG4VisManager.hh,v 1.1 2000/07/24 11:23:43 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
//
//....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 G3toG4VisManager_h
#define G3toG4VisManager_h 1
#include "G4VisManager.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class G3toG4VisManager: public G4VisManager {
public:
G3toG4VisManager ();
private:
void RegisterGraphicsSystems ();
};
#endif
// 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: G3toG4DetectorConstruction.cc,v 1.1 2000/07/24 11:23:43 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
//--------------------------------------------------------------------------
// G3toG4DetectorConstruction. Most the work is Done in
// G4BuildGeom, which returns a G4LogicalVolume*, a pointer to the
// top-level logiical volume in the detector defined by the call List file
// inFile
//--------------------------------------------------------------------------
#include "G4ios.hh"
#include "G3toG4DetectorConstruction.hh"
#include "G4VisAttributes.hh"
#include "G4Colour.hh"
#include "G4Material.hh"
#include "G4Box.hh"
G3toG4DetectorConstruction::G3toG4DetectorConstruction(G4String inFile){
_inFile = inFile;
G4cout << "Instantiated G3toG4DetectorConstruction using call list file \""
<< _inFile << "\"" << G4endl;
}
G3toG4DetectorConstruction::~G3toG4DetectorConstruction(){
// G4cout << "Deleted G3toG4DetectorConstruction..." << G4endl;
}
G4VPhysicalVolume*
G3toG4DetectorConstruction::Construct(){
_lv = G4BuildGeom(_inFile);
//_lv = SimpleConstruct();
if (_lv != 0) {
_pv = new G4PVPlacement(0, G4ThreeVector(), _lv, _lv->GetName(), 0,
false, 0);
G4cout << "Top-level G3toG4 logical volume " << _lv->GetName() << " "
<< *(_lv -> GetVisAttributes()) << G4endl;
} else
G4cerr << "creation of logical mother failed !!!" << G4endl;
return _pv;
}
G4LogicalVolume*
G3toG4DetectorConstruction::SimpleConstruct(){
G4String name, symbol; //a=mass of a mole;
G4double a, z, density, fractionmass; //z=mean number of protons;
G4int ncomponents, iz, n; //iz=number of protons in an isotope;
// n=number of nucleons in an isotope;
a = 14.01*g/mole;
G4Element* N = new G4Element(name="Nitrogen",symbol="N" , z= 7., a);
a = 16.00*g/mole;
G4Element* O = new G4Element(name="Oxygen" ,symbol="O" , z= 8., a);
//
// define a material from elements. case 2: mixture by fractional mass
//
density = 1.290*mg/cm3;
G4Material* Air = new G4Material(name="Air" , density, ncomponents=2);
Air->AddElement(N, fractionmass=0.7);
Air->AddElement(O, fractionmass=0.3);
G4VSolid* Mother = new G4Box("TestMother", //its name
100*cm, 100*cm, 100*cm); //its size
G4VSolid* Daughter = new G4Box("TestDaughter", 50*cm, 20*cm, 10*cm);
G4LogicalVolume* logicMother = new G4LogicalVolume(Mother, //its solid
Air, //its material
"LTestMother");//its name
G4LogicalVolume* logicDaughter = new G4LogicalVolume(Daughter, //its solid
Air, //its material
"LTestDaughter");
G4VPhysicalVolume* physiDaughter = new G4PVPlacement(0,
G4ThreeVector(),
logicDaughter,
"PTestDaughter",
logicMother,
false,0);
//
// Visualization attributes
//
logicMother->SetVisAttributes (G4VisAttributes::Invisible);
G4VisAttributes* DaughterVisAtt= new G4VisAttributes(G4Colour(1.0,1.0,1.0));
DaughterVisAtt->SetVisibility(true);
logicDaughter->SetVisAttributes(DaughterVisAtt);
return logicMother;
}
// 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: G3toG4EventAction.cc,v 1.1 2000/07/24 11:23:44 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#include "g4rw/tvordvec.h"
#include "G4ios.hh"
#include "G3toG4EventAction.hh"
#include "G3toG4EventActionMessenger.hh"
#include "G4Event.hh"
#include "G4EventManager.hh"
#include "G4HCofThisEvent.hh"
#include "G4TrajectoryContainer.hh"
#include "G4Trajectory.hh"
#include "G4VVisManager.hh"
#include "G4UImanager.hh"
#include "G4UnitsTable.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
G3toG4EventAction::G3toG4EventAction()
: drawFlag("all"),eventMessenger(NULL)
{
eventMessenger = new G3toG4EventActionMessenger(this);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
G3toG4EventAction::~G3toG4EventAction()
{
delete eventMessenger;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void G3toG4EventAction::BeginOfEventAction(const G4Event* Ev)
{;}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void G3toG4EventAction::EndOfEventAction(const G4Event* Ev)
{
const G4Event* evt = fpEventManager->GetConstCurrentEvent();
G4cout << ">>> Event " << evt->GetEventID() << G4endl;
G4TrajectoryContainer * trajectoryContainer = evt->GetTrajectoryContainer();
G4int n_trajectories = 0;
if(trajectoryContainer){
n_trajectories = trajectoryContainer->entries();
}
G4cout << " " << n_trajectories
<< " trajectories stored in this event." << G4endl;
if(G4VVisManager::GetConcreteInstance()){
for(G4int i=0; i<n_trajectories; i++) {
G4Trajectory* trj = (G4Trajectory*)(*(evt->GetTrajectoryContainer()))[i];
if (drawFlag == "all") trj->DrawTrajectory(50);
else if ((drawFlag == "charged")&&(trj->GetCharge() != 0.))
trj->DrawTrajectory(50);
}
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
// 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: G3toG4EventActionMessenger.cc,v 1.1 2000/07/24 11:23:44 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#include "G3toG4EventActionMessenger.hh"
#include "G3toG4EventAction.hh"
#include "G4UIcmdWithAString.hh"
#include "globals.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
G3toG4EventActionMessenger::G3toG4EventActionMessenger(G3toG4EventAction* EvAct)
:eventAction(EvAct)
{
DrawCmd = new G4UIcmdWithAString("/event/draw",this);
DrawCmd->SetGuidance("Draw the tracks in the event");
DrawCmd->SetGuidance(" Choice : none, charged, all (default)");
DrawCmd->SetParameterName("choice",true);
DrawCmd->SetDefaultValue("all");
DrawCmd->SetCandidates("none charged all");
DrawCmd->AvailableForStates(Idle);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
G3toG4EventActionMessenger::~G3toG4EventActionMessenger()
{
delete DrawCmd;
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void G3toG4EventActionMessenger::SetNewValue(G4UIcommand * command,G4String newValue)
{
if(command == DrawCmd)
{eventAction->SetDrawFlag(newValue);}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
// 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: G3toG4PhysicsList.cc,v 1.1 2000/07/24 11:23:44 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#include "G3toG4PhysicsList.hh"
#include "G4ParticleDefinition.hh"
#include "G4ParticleWithCuts.hh"
#include "G4ProcessManager.hh"
#include "G4ProcessVector.hh"
#include "G4ParticleTypes.hh"
#include "G4ParticleTable.hh"
#include "G4Material.hh"
#include "G4ios.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
G3toG4PhysicsList::G3toG4PhysicsList(): G4VUserPhysicsList()
{
currentDefaultCut = defaultCutValue = 2.0*mm;
cutForGamma = defaultCutValue;
cutForElectron = defaultCutValue;
cutForProton = defaultCutValue;
SetVerboseLevel(1);
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
G3toG4PhysicsList::~G3toG4PhysicsList()
{}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void G3toG4PhysicsList::ConstructParticle()
{
// In this method, static member functions should be called
// for all particles which you want to use.
// This ensures that objects of these particle types will be
// created in the program.
ConstructBosons();
ConstructLeptons();
ConstructMesons();
ConstructBaryons();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void G3toG4PhysicsList::ConstructBosons()
{
// pseudo-particles
G4Geantino::GeantinoDefinition();
G4ChargedGeantino::ChargedGeantinoDefinition();
// gamma
G4Gamma::GammaDefinition();
// optical photon
G4OpticalPhoton::OpticalPhotonDefinition();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void G3toG4PhysicsList::ConstructLeptons()
{
// leptons
G4Electron::ElectronDefinition();
G4Positron::PositronDefinition();
G4MuonPlus::MuonPlusDefinition();
G4MuonMinus::MuonMinusDefinition();
G4NeutrinoE::NeutrinoEDefinition();
G4AntiNeutrinoE::AntiNeutrinoEDefinition();
G4NeutrinoMu::NeutrinoMuDefinition();
G4AntiNeutrinoMu::AntiNeutrinoMuDefinition();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void G3toG4PhysicsList::ConstructMesons()
{
// mesons
G4PionPlus::PionPlusDefinition();
G4PionMinus::PionMinusDefinition();
G4PionZero::PionZeroDefinition();
G4Eta::EtaDefinition();
G4EtaPrime::EtaPrimeDefinition();
G4KaonPlus::KaonPlusDefinition();
G4KaonMinus::KaonMinusDefinition();
G4KaonZero::KaonZeroDefinition();
G4AntiKaonZero::AntiKaonZeroDefinition();
G4KaonZeroLong::KaonZeroLongDefinition();
G4KaonZeroShort::KaonZeroShortDefinition();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void G3toG4PhysicsList::ConstructBaryons()
{
// barions
G4Proton::ProtonDefinition();
G4AntiProton::AntiProtonDefinition();
G4Neutron::NeutronDefinition();
G4AntiNeutron::AntiNeutronDefinition();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void G3toG4PhysicsList::ConstructProcess()
{
AddTransportation();
ConstructEM();
ConstructGeneral();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#include "G4ComptonScattering.hh"
#include "G4GammaConversion.hh"
#include "G4PhotoElectricEffect.hh"
#include "G4MultipleScattering.hh"
#include "G4eIonisation.hh"
#include "G4eBremsstrahlung.hh"
#include "G4eplusAnnihilation.hh"
#include "G4MuIonisation.hh"
#include "G4MuBremsstrahlung.hh"
#include "G4MuPairProduction.hh"
#include "G4hIonisation.hh"
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void G3toG4PhysicsList::ConstructEM()
{
theParticleIterator->reset();
while( (*theParticleIterator)() ){
G4ParticleDefinition* particle = theParticleIterator->value();
G4ProcessManager* pmanager = particle->GetProcessManager();
G4String particleName = particle->GetParticleName();
if (particleName == "gamma") {
//gamma
pmanager->AddDiscreteProcess(new G4PhotoElectricEffect());
pmanager->AddDiscreteProcess(new G4ComptonScattering());
pmanager->AddDiscreteProcess(new G4GammaConversion());
} else if (particleName == "e-") {
//electron
pmanager->AddProcess(new G4MultipleScattering(),-1, 1,1);
pmanager->AddProcess(new G4eIonisation(), -1, 2,2);
pmanager->AddProcess(new G4eBremsstrahlung(), -1,-1,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,-1,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,-1,3);
pmanager->AddProcess(new G4MuPairProduction(), -1,-1,4);
} 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);
}
}
}
#include "G4Decay.hh"
void G3toG4PhysicsList::ConstructGeneral()
{
// Add Decay Process
G4Decay* theDecayProcess = new G4Decay();
theParticleIterator->reset();
while( (*theParticleIterator)() ){
G4ParticleDefinition* particle = theParticleIterator->value();
G4ProcessManager* pmanager = particle->GetProcessManager();
if (theDecayProcess->IsApplicable(*particle)) {
pmanager ->AddProcess(theDecayProcess);
// set ordering for PostStepDoIt and AtRestDoIt
pmanager ->SetProcessOrdering(theDecayProcess, idxPostStep);
pmanager ->SetProcessOrdering(theDecayProcess, idxAtRest);
}
}
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void G3toG4PhysicsList::SetCuts()
{
// reactualise cutValues
if (currentDefaultCut != defaultCutValue)
{
if(cutForGamma == currentDefaultCut) cutForGamma = defaultCutValue;
if(cutForElectron == currentDefaultCut) cutForElectron = defaultCutValue;
if(cutForProton == currentDefaultCut) cutForProton = defaultCutValue;
currentDefaultCut = defaultCutValue;
}
if (verboseLevel >0){
G4cout << "G3toG4PhysicsList::SetCuts:";
G4cout << "CutLength : " << G4BestUnit(defaultCutValue,"Length") << G4endl;
}
// set cut values for gamma at first and for e- second and next for e+,
// because some processes for e+/e- need cut values for gamma
SetCutValue(cutForGamma, "gamma");
SetCutValue(cutForElectron, "e-");
SetCutValue(cutForElectron, "e+");
// set cut values for proton and anti_proton before all other hadrons
// because some processes for hadrons need cut values for proton/anti_proton
SetCutValue(cutForProton, "proton");
SetCutValue(cutForProton, "anti_proton");
SetCutValueForOthers(defaultCutValue);
if (verboseLevel>0) DumpCutValuesTable();
}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void G3toG4PhysicsList::SetCutForGamma(G4double cut)
{
ResetCuts();
cutForGamma = cut;
}
void G3toG4PhysicsList::SetCutForElectron(G4double cut)
{
ResetCuts();
cutForElectron = cut;
}
void G3toG4PhysicsList::SetCutForProton(G4double cut)
{
ResetCuts();
cutForProton = cut;
}
G4double G3toG4PhysicsList::GetCutForGamma() const
{
return cutForGamma;
}
G4double G3toG4PhysicsList::GetCutForElectron() const
{
return cutForElectron;
}
G4double G3toG4PhysicsList::GetCutForProton() const
{
return cutForGamma;
}
// 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: G3toG4PrimaryGeneratorAction.cc,v 1.2 2000/08/01 09:44:01 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
#include "globals.hh"
#include "Randomize.hh"
#include "G3toG4PrimaryGeneratorAction.hh"
#include "G4Event.hh"
#include "G4ParticleGun.hh"
#include "G4ParticleTable.hh"
#include "G4ParticleDefinition.hh"
G3toG4PrimaryGeneratorAction::G3toG4PrimaryGeneratorAction(){
G4int n_particle = 1;
particleGun = new G4ParticleGun(n_particle);
G4ParticleTable* particleTable = G4ParticleTable::GetParticleTable();
G4String particleName;
G4ParticleDefinition* particle
= particleTable->FindParticle(particleName="chargedgeantino");
particleGun->SetParticleDefinition(particle);
G4ThreeVector direction(0, 0, 1);
particleGun->SetParticleMomentumDirection(direction.unit());
particleGun->SetParticleEnergy(1.*GeV);
particleGun->SetParticlePosition(G4ThreeVector(0.*cm, 0.*cm,0.*cm));
}
G3toG4PrimaryGeneratorAction::~G3toG4PrimaryGeneratorAction(){
delete particleGun;
}
void
G3toG4PrimaryGeneratorAction::GeneratePrimaries(G4Event* anEvent){
//G4ThreeVector direction = GetRandomDirection();
//particleGun->SetParticleMomentumDirection( direction.unit() ) ;
G4cout << ">>>>>>>> Primary direction: "
<< particleGun->GetParticleMomentumDirection() << G4endl;
particleGun->GeneratePrimaryVertex(anEvent);
}
G4ThreeVector
G3toG4PrimaryGeneratorAction::GetRandomDirection() {
G4ThreeVector retval;
G4double CosTheta;
G4double SinTheta;
G4double Phi;
G4double SinPhi;
G4double CosPhi;
G4double rand;
rand = G4UniformRand();
CosTheta = 2.0*rand -1.0;
SinTheta = sqrt (1.-CosTheta*CosTheta);
rand = G4UniformRand();
Phi = twopi*rand;
SinPhi = sin (Phi);
CosPhi = cos (Phi);
retval.setX(SinTheta*CosPhi);
retval.setY(SinTheta*SinPhi);
retval.setZ(CosTheta);
return retval;
}
// 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: G3toG4RunAction.cc,v 1.1 2000/07/24 11:23:44 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
#include "G4ios.hh"
#include "G3toG4RunAction.hh"
#include "G4Run.hh"
#include "G4VVisManager.hh"
#include "G4UImanager.hh"
#include "G4ios.hh"
G3toG4RunAction::G3toG4RunAction(){
runIDcounter = 0;
}
G3toG4RunAction::~G3toG4RunAction(){;}
void G3toG4RunAction::BeginOfRunAction(const G4Run* aRun){
((G4Run *)(aRun))->SetRunID(runIDcounter++);
G4cout << "### Run " << aRun->GetRunID() << " start." << G4endl;
G4UImanager* UI = G4UImanager::GetUIpointer();
if (G4VVisManager::GetConcreteInstance()) {
UI->ApplyCommand("/vis~/clear/view");
UI->ApplyCommand("/vis~/draw/current");
}
}
void G3toG4RunAction::EndOfRunAction(const G4Run* aRun){;}
// 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: G3toG4VisManager.cc,v 1.1 2000/07/24 11:23:45 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
//
// John Allison 24th January 1998.
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#include "G4ios.hh"
#ifdef G4VIS_USE
#include "G3toG4VisManager.hh"
// Supported drivers...
#ifdef G4VIS_USE_DAWN
#include "G4FukuiRenderer.hh"
#endif
#ifdef G4VIS_USE_DAWNFILE
#include "G4DAWNFILE.hh"
#endif
#ifdef G4VIS_USE_OPACS
#include "G4Wo.hh"
#include "G4Xo.hh"
#endif
#ifdef G4VIS_USE_OPENGLX
#include "G4OpenGLImmediateX.hh"
#include "G4OpenGLStoredX.hh"
#endif
#ifdef G4VIS_USE_OPENGLWIN32
#include "G4OpenGLImmediateWin32.hh"
#include "G4OpenGLStoredWin32.hh"
#endif
#ifdef G4VIS_USE_OPENGLXM
#include "G4OpenGLImmediateXm.hh"
#include "G4OpenGLStoredXm.hh"
#endif
#ifdef G4VIS_USE_OIX
#include "G4OpenInventorX.hh"
#endif
#ifdef G4VIS_USE_OIWIN32
#include "G4OpenInventorWin32.hh"
#endif
#ifdef G4VIS_USE_RAYX
#include "G4RayX.hh"
#endif
#ifdef G4VIS_USE_VRML
#include "G4VRML1.hh"
#include "G4VRML2.hh"
#endif
#ifdef G4VIS_USE_VRMLFILE
#include "G4VRML1File.hh"
#include "G4VRML2File.hh"
#endif
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
G3toG4VisManager::G3toG4VisManager () {}
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
void G3toG4VisManager::RegisterGraphicsSystems () {
#ifdef G4VIS_USE_DAWN
RegisterGraphicsSystem (new G4FukuiRenderer);
#endif
#ifdef G4VIS_USE_DAWNFILE
RegisterGraphicsSystem (new G4DAWNFILE);
#endif
#ifdef G4VIS_USE_OPACS
RegisterGraphicsSystem (new G4Wo);
RegisterGraphicsSystem (new G4Xo);
#endif
#ifdef G4VIS_USE_OPENGLX
RegisterGraphicsSystem (new G4OpenGLImmediateX);
RegisterGraphicsSystem (new G4OpenGLStoredX);
#endif
#ifdef G4VIS_USE_OPENGLWIN32
RegisterGraphicsSystem (new G4OpenGLImmediateWin32);
RegisterGraphicsSystem (new G4OpenGLStoredWin32);
#endif
#ifdef G4VIS_USE_OPENGLXM
RegisterGraphicsSystem (new G4OpenGLImmediateXm);
RegisterGraphicsSystem (new G4OpenGLStoredXm);
#endif
#ifdef G4VIS_USE_OIX
RegisterGraphicsSystem (new G4OpenInventorX);
#endif
#ifdef G4VIS_USE_OIWIN32
RegisterGraphicsSystem (new G4OpenInventorWin32);
#endif
#ifdef G4VIS_USE_RAYX
RegisterGraphicsSystem (new G4RayX);
#endif
#ifdef G4VIS_USE_VRML
RegisterGraphicsSystem (new G4VRML1);
RegisterGraphicsSystem (new G4VRML2);
#endif
#ifdef G4VIS_USE_VRMLFILE
RegisterGraphicsSystem (new G4VRML1File);
RegisterGraphicsSystem (new G4VRML2File);
#endif
if (fVerbose > 0) {
G4cout <<
"\nYou have successfully chosen to use the following graphics systems."
<< G4endl;
PrintAvailableGraphicsSystems ();
}
}
#endif
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
# $Id: GNUmakefile,v 1.1 2000/07/24 11:23:46 gcosmo Exp $
# ----------------------------------------------------------------
name := cltog4
G4TARGET := $(name)
G4EXLIB := true
ifndef G4INSTALL
G4INSTALL = ../../../..
endif
.PHONY: all
all: lib bin
include $(G4INSTALL)/config/binmake.gmk
// 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: cltog4.cc,v 1.1 2000/07/24 11:23:46 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
//
#include "G4ios.hh"
#include "g4std/fstream"
#include <math.h>
// example header file includes
#include "G3toG4DetectorConstruction.hh"
#include "G3toG4RunAction.hh"
#include "G3toG4PrimaryGeneratorAction.hh"
#include "G3toG4PhysicsList.hh"
#include "G4LogicalVolume.hh"
#include "G3VolTable.hh"
// geant4 includes
#include "G4RunManager.hh"
#include "G4UImanager.hh"
#include "G4UIterminal.hh"
G4int main(int argc, char** argv)
{
G4String inFile;
G4String macroFile = "";
if (argc < 2) {
G4cout << "Correct syntax:" << argv[0] << " <call_list_file> [ <macro_file> ]"
<< G4endl;
G4cout << "If only one argument is specified, macro file " << macroFile
<< "will be used." << G4endl
<< "The second argument is used to override the default macro file"
<< " name." << G4endl;
return 1;
}
if (argc >= 2) {
// Process the command line
inFile = argv[1];
G4std::ifstream in(inFile);
if (!in) {
G4cout << "Cannot open input file """ << inFile << """" << G4endl;
return 1;
}
}
if (argc >= 3) {
macroFile = argv[2];
G4std::ifstream mac(macroFile);
if (!mac) {
G4cout << "Cannot open macro file """ << macroFile << """" << G4endl;
return 2;
}
}
if (argc >= 4) {
G4cout << "Too many command line arguments (" << argc <<")" << G4endl;
return 1;
}
// run manager
G4RunManager * RunManager = new G4RunManager;
// user initialization classes
RunManager->SetUserInitialization(new G3toG4DetectorConstruction(inFile));
RunManager->SetUserInitialization(new G3toG4PhysicsList);
// user action classes
RunManager->SetUserAction(new G3toG4RunAction);
RunManager->SetUserAction(new G3toG4PrimaryGeneratorAction);
G4UImanager * UI = G4UImanager::GetUIpointer();
// set some additional defaults and initial actions
UI->ApplyCommand("/control/verbose 1");
UI->ApplyCommand("/run/verbose 1");
UI->ApplyCommand("/tracking/verbose 1");
UI->ApplyCommand("/tracking/storeTrajectory 1");
UI->ApplyCommand("/run/initialize");
G4bool batch_mode = macroFile != "";
if(!batch_mode) {
G4UIsession * session = new G4UIterminal;
if (session != 0) {
session->SessionStart();
delete session;
// G4cout << "deleted G4UITerminal..." << G4endl;
}
}
else {
// Batch mode
G4String command = "/control/execute ";
UI->ApplyCommand(command+macroFile);
}
delete RunManager;
return EXIT_SUCCESS;
}
/control/verbose 1
/tracking/verbose 1
#
# Initialize GEANT4
#
/run/initialize
#
/gun/position 0. -1.5 0.
/gun/direction 0. 1. 0.
/gun/energy 1 GeV
/gun/particle chargedgeantino
/run/beamOn 10
#
# Termination
#
**********************************************
Geant4 version $Name: examples-V02-00-01 $
(30-Jun-2000)
Copyright : Geant4 Collaboration
**********************************************
Instantiated G3toG4DetectorConstruction using call list file "/afs/cern.ch/sw/geant4/stt/dev2/src/geant4/examples/extended/g3tog4/data/testmodel.dat"
/run/verbose 1
/tracking/verbose 1
/tracking/storeTrajectory 1
/run/initialize
Instantiated unit rotation matrix irot=0
Reading the call List file /afs/cern.ch/sw/geant4/stt/dev2/src/geant4/examples/extended/g3tog4/data/testmodel.dat...
G4ggclos: setting top-level VolTableEntry
Dump of VTD - 26 entries:
Instantiated 26 volume table entries
15 positions.
G3VolTable element 0 name BOX1 has 1 daughters
G3VolTable element 1 name BOX1_1 has 1 daughters
G3VolTable element 2 name BOX1_2 has 1 daughters
G3VolTable element 3 name BOX1_3 has 1 daughters
G3VolTable element 4 name BOX1_4 has 1 daughters
G3VolTable element 5 name BOX2 has 1 daughters
G3VolTable element 6 name BOX2_1 has 1 daughters
G3VolTable element 7 name BOX2_2 has 1 daughters
G3VolTable element 8 name BOX2_3 has 1 daughters
G3VolTable element 9 name BOX2_4 has 1 daughters
G3VolTable element 10 name BOX2_5 has 1 daughters
G3VolTable element 11 name BXD1 has 0 daughters
G3VolTable element 12 name BXD1_1 has 0 daughters
G3VolTable element 13 name BXD1_2 has 0 daughters
G3VolTable element 14 name BXD1_2_ENV has 1 daughters
G3VolTable element 15 name BXD1_3 has 0 daughters
G3VolTable element 16 name BXD1_3_ENV has 1 daughters
G3VolTable element 17 name BXD1_4 has 0 daughters
G3VolTable element 18 name BXD1_4_ENV has 1 daughters
G3VolTable element 19 name BXD1_5 has 0 daughters
G3VolTable element 20 name BXD1_5_ENV has 1 daughters
G3VolTable element 21 name HALL has 6 daughters
G3VolTable element 22 name TBD1 has 0 daughters
G3VolTable element 23 name TBD2 has 0 daughters
G3VolTable element 24 name TUB1 has 1 daughters
G3VolTable element 25 name TUB2 has 1 daughters
Call List file read completed. Build geometry
G3toG4 top level volume is HALL
Top-level G3toG4 logical volume HALL G4VisAttributes: invisible, daughters visible, colour: (1,1,1,1)
linestyle: solid, line width: 1
drawing style unforced
Top-level G3toG4 logical volume HALL G4VisAttributes: invisible, daughters visible, colour: (1,1,1,1)
linestyle: solid, line width: 1
drawing style unforced
G3toG4PhysicsList::SetCuts:CutLength : 2 mm
phot: Total cross sections from a parametrisation. Good description from 10 KeV to 50 MeV for all Z
Sandia crossSection below 50 KeV
PhysicsTables from 50 keV to 50 MeV in 100 bins.
compt: Total cross sections from a parametrisation. Good description from 10 KeV to (100/Z) GeV.
Scattered gamma energy according Klein-Nishina.
PhysicsTables from 10 keV to 100 GeV in 100 bins.
conv: Total cross sections from a parametrisation. Good description from 1.5 MeV to 100 GeV for all Z.
e+e- energies according Bethe-Heitler
PhysicsTables from 1.022 MeV to 100 GeV in 100 bins.
msc: Tables of transport mean free paths.
New model of MSC , computes the lateral
displacement of the particle , too.
PhysicsTables from 100 eV to 100 TeV in 100 bins.
eIoni: delta cross sections from Moller+Bhabha. Good description from 1 KeV to 100 GeV.
delta ray energy sampled from differential Xsection.
PhysicsTables from 1 keV to 100 TeV in 100 bins.
eIoni Minimum Delta cut in range=0.2 mm.
material min.delta energy(keV)
HYDROGEN 42.188
DEUTERIUM 67.152
HELIUM 37.603
LITHIUM 76.534
BERILLIUM 158.48
CARBON 187.37
NITROGEN 99.234
NEON 121.67
ALUMINIUM 191.93
IRON 356.55
COPPER 380.9
TUNGSTEN 559.7
LEAD 370.42
URANIUM 527.66
AIR 0.99
VACUUM 0.99
eBrem: Total cross sections from a parametrisation. Good description from 10 KeV to 100 GeV.
log scale extrapolation above 100 GeV
Gamma energy sampled from a parametrised formula.
PhysicsTables from 1 keV to 100 TeV in 100 bins.
annihil: Total cross section from Heilter formula (annihilation into 2 photons).
gamma energies sampled according Heitler
PhysicsTables from 10 keV to 10 TeV in 100 bins.
msc: Tables of transport mean free paths.
New model of MSC , computes the lateral
displacement of the particle , too.
PhysicsTables from 100 eV to 100 TeV in 100 bins.
hIoni Minimum Delta cut in range=0.2 mm.
material min.delta energy(keV)
HYDROGEN 42.188
DEUTERIUM 67.152
HELIUM 37.603
LITHIUM 76.534
BERILLIUM 158.48
CARBON 187.37
NITROGEN 99.234
NEON 121.67
ALUMINIUM 191.93
IRON 356.55
COPPER 380.9
TUNGSTEN 559.7
LEAD 370.42
URANIUM 527.66
AIR 0.99
VACUUM 0.99
hIoni: Knock-on electron cross sections .
Good description above the mean excitation energy.
delta ray energy sampled from differential Xsection.
PhysicsTables from 1 keV to 100 TeV in 100 bins.
msc: Tables of transport mean free paths.
New model of MSC , computes the lateral
displacement of the particle , too.
PhysicsTables from 100 eV to 100 TeV in 100 bins.
MuIoni: knock-on electron cross sections .
Good description above the mean excitation energy.
delta ray energy sampled from differential Xsection.
PhysicsTables from 1 keV to 1000 PeV in 150 bins.
MuBrems: theoretical cross section
Good description up to 1000 PeV.
PhysicsTables from 1 keV to 1000 PeV in 150 bins.
MuPairProd: theoretical cross sections
Good description up to 1000 PeV.
PhysicsTables from 1 keV to 1000 PeV in 150 bins.
============= The cut Energy ==============================
gamma e- mu- proton neutron
Cut in range 2 mm 2 mm 2 mm 2 mm 2 mm
Cut in energy
HYDROGEN 990 eV 162 keV 1.81 MeV 4.78 MeV 990 eV
DEUTERIUM 990 eV 271 keV 2.81 MeV 7.63 MeV 990 eV
HELIUM 990 eV 145 keV 1.6 MeV 4.22 MeV 990 eV
LITHIUM 1.33 keV 322 keV 3.18 MeV 8.52 MeV 990 eV
BERILLIUM 2.4 keV 782 keV 6.26 MeV 16.8 MeV 990 eV
CARBON 4.3 keV 976 keV 7.26 MeV 19.4 MeV 990 eV
NITROGEN 3.34 keV 444 keV 4.07 MeV 10.8 MeV 990 eV
NEON 5.38 keV 568 keV 4.9 MeV 13 MeV 990 eV
ALUMINIUM 9.56 keV 1.03 MeV 7.44 MeV 19.4 MeV 990 eV
IRON 29.5 keV 2.43 MeV 12.6 MeV 32.6 MeV 990 eV
COPPER 35.7 keV 2.68 MeV 13.3 MeV 34.3 MeV 990 eV
TUNGSTEN 133 keV 4.66 MeV 17.6 MeV 44.4 MeV 990 eV
LEAD 121 keV 2.61 MeV 12.6 MeV 31.8 MeV 990 eV
URANIUM 169 keV 4.28 MeV 16.8 MeV 41.7 MeV 990 eV
AIR 990 eV 990 eV 82.2 keV 174 keV 990 eV
VACUUM 990 eV 990 eV 990 eV 990 eV 990 eV
===================================================
Idle> /control/verbose 1
Idle> /tracking/verbose 1
Idle> #
Idle> # Initialize GEANT4
Idle> #
Idle> /run/initialize
Idle> #
Idle> /gun/position 0. -1.5 0.
Idle> /gun/direction 0. 1. 0.
Idle> /gun/energy 1 GeV
Idle> /gun/particle chargedgeantino
Idle> /run/beamOn 10
### Run 0 start.
Start Run processing.
>>>>>>>> Primary direction: (0,1,0)
*********************************************************************************************************
* G4Track Information: Particle = chargedgeantino, Track ID = 1, Parent ID = 0
*********************************************************************************************************
Step# X(mm) Y(mm) Z(mm) KinE(MeV) dE(MeV) StepLeng TrackLeng NextVolume ProcName
0 0 -15 0 1e+03 0 0 0 TBD1 initStep
1 0 200 0 1e+03 0 215 215 TBD2 Transportation
2 0 360 0 1e+03 0 160 375 HALL Transportation
3 0 4e+03 0 1e+03 0 3.64e+03 4.02e+03 OutOfWorld Transportation
>>>>>>>> Primary direction: (0,1,0)
*********************************************************************************************************
* G4Track Information: Particle = chargedgeantino, Track ID = 1, Parent ID = 0
*********************************************************************************************************
Step# X(mm) Y(mm) Z(mm) KinE(MeV) dE(MeV) StepLeng TrackLeng NextVolume ProcName
0 0 -15 0 1e+03 0 0 0 TBD1 initStep
1 0 200 0 1e+03 0 215 215 TBD2 Transportation
2 0 360 0 1e+03 0 160 375 HALL Transportation
3 0 4e+03 0 1e+03 0 3.64e+03 4.02e+03 OutOfWorld Transportation
>>>>>>>> Primary direction: (0,1,0)
*********************************************************************************************************
* G4Track Information: Particle = chargedgeantino, Track ID = 1, Parent ID = 0
*********************************************************************************************************
Step# X(mm) Y(mm) Z(mm) KinE(MeV) dE(MeV) StepLeng TrackLeng NextVolume ProcName
0 0 -15 0 1e+03 0 0 0 TBD1 initStep
1 0 200 0 1e+03 0 215 215 TBD2 Transportation
2 0 360 0 1e+03 0 160 375 HALL Transportation
3 0 4e+03 0 1e+03 0 3.64e+03 4.02e+03 OutOfWorld Transportation
>>>>>>>> Primary direction: (0,1,0)
*********************************************************************************************************
* G4Track Information: Particle = chargedgeantino, Track ID = 1, Parent ID = 0
*********************************************************************************************************
Step# X(mm) Y(mm) Z(mm) KinE(MeV) dE(MeV) StepLeng TrackLeng NextVolume ProcName
0 0 -15 0 1e+03 0 0 0 TBD1 initStep
1 0 200 0 1e+03 0 215 215 TBD2 Transportation
2 0 360 0 1e+03 0 160 375 HALL Transportation
3 0 4e+03 0 1e+03 0 3.64e+03 4.02e+03 OutOfWorld Transportation
>>>>>>>> Primary direction: (0,1,0)
*********************************************************************************************************
* G4Track Information: Particle = chargedgeantino, Track ID = 1, Parent ID = 0
*********************************************************************************************************
Step# X(mm) Y(mm) Z(mm) KinE(MeV) dE(MeV) StepLeng TrackLeng NextVolume ProcName
0 0 -15 0 1e+03 0 0 0 TBD1 initStep
1 0 200 0 1e+03 0 215 215 TBD2 Transportation
2 0 360 0 1e+03 0 160 375 HALL Transportation
3 0 4e+03 0 1e+03 0 3.64e+03 4.02e+03 OutOfWorld Transportation
>>>>>>>> Primary direction: (0,1,0)
*********************************************************************************************************
* G4Track Information: Particle = chargedgeantino, Track ID = 1, Parent ID = 0
*********************************************************************************************************
Step# X(mm) Y(mm) Z(mm) KinE(MeV) dE(MeV) StepLeng TrackLeng NextVolume ProcName
0 0 -15 0 1e+03 0 0 0 TBD1 initStep
1 0 200 0 1e+03 0 215 215 TBD2 Transportation
2 0 360 0 1e+03 0 160 375 HALL Transportation
3 0 4e+03 0 1e+03 0 3.64e+03 4.02e+03 OutOfWorld Transportation
>>>>>>>> Primary direction: (0,1,0)
*********************************************************************************************************
* G4Track Information: Particle = chargedgeantino, Track ID = 1, Parent ID = 0
*********************************************************************************************************
Step# X(mm) Y(mm) Z(mm) KinE(MeV) dE(MeV) StepLeng TrackLeng NextVolume ProcName
0 0 -15 0 1e+03 0 0 0 TBD1 initStep
1 0 200 0 1e+03 0 215 215 TBD2 Transportation
2 0 360 0 1e+03 0 160 375 HALL Transportation
3 0 4e+03 0 1e+03 0 3.64e+03 4.02e+03 OutOfWorld Transportation
>>>>>>>> Primary direction: (0,1,0)
*********************************************************************************************************
* G4Track Information: Particle = chargedgeantino, Track ID = 1, Parent ID = 0
*********************************************************************************************************
Step# X(mm) Y(mm) Z(mm) KinE(MeV) dE(MeV) StepLeng TrackLeng NextVolume ProcName
0 0 -15 0 1e+03 0 0 0 TBD1 initStep
1 0 200 0 1e+03 0 215 215 TBD2 Transportation
2 0 360 0 1e+03 0 160 375 HALL Transportation
3 0 4e+03 0 1e+03 0 3.64e+03 4.02e+03 OutOfWorld Transportation
>>>>>>>> Primary direction: (0,1,0)
*********************************************************************************************************
* G4Track Information: Particle = chargedgeantino, Track ID = 1, Parent ID = 0
*********************************************************************************************************
Step# X(mm) Y(mm) Z(mm) KinE(MeV) dE(MeV) StepLeng TrackLeng NextVolume ProcName
0 0 -15 0 1e+03 0 0 0 TBD1 initStep
1 0 200 0 1e+03 0 215 215 TBD2 Transportation
2 0 360 0 1e+03 0 160 375 HALL Transportation
3 0 4e+03 0 1e+03 0 3.64e+03 4.02e+03 OutOfWorld Transportation
>>>>>>>> Primary direction: (0,1,0)
*********************************************************************************************************
* G4Track Information: Particle = chargedgeantino, Track ID = 1, Parent ID = 0
*********************************************************************************************************
Step# X(mm) Y(mm) Z(mm) KinE(MeV) dE(MeV) StepLeng TrackLeng NextVolume ProcName
0 0 -15 0 1e+03 0 0 0 TBD1 initStep
1 0 200 0 1e+03 0 215 215 TBD2 Transportation
2 0 360 0 1e+03 0 160 375 HALL Transportation
3 0 4e+03 0 1e+03 0 3.64e+03 4.02e+03 OutOfWorld Transportation
Run terminated.
Run Summary
Number of events processed : 10
User=0.04s Real=0.06s Sys=0s
Idle> #
Idle> # Termination
Idle> #
Idle> G4 kernel has come to Quit state.
// 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: G3toG4DetectorConstruction.hh,v 1.1 2000/07/24 11:23:47 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
#ifndef G3toG4DetectorConstruction_h
#define G3toG4DetectorConstruction_h 1
//--------------------------------------------------------------------------
// G3toG4DetectorConstruction. Most the work is Done in
// G4BuildGeom, which returns a G4LogicalVolume*, a pointer to the
// top-level logiical volume in the detector defined by the call List file
// inFile
//--------------------------------------------------------------------------
#include "G4VUserDetectorConstruction.hh"
#include "G4PVPlacement.hh"
#include "G4LogicalVolume.hh"
#include "G3G4Interface.hh"
#include "globals.hh"
class G3toG4DetectorConstruction : public G4VUserDetectorConstruction
{
public:
G3toG4DetectorConstruction(G4String inFile="svt.dat");
~G3toG4DetectorConstruction();
G4VPhysicalVolume* Construct();
G4LogicalVolume* SimpleConstruct();
private:
G4String _inFile;
G4VPhysicalVolume* _pv;
G4LogicalVolume* _lv;
};
#endif
// 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: G3toG4EventAction.hh,v 1.1 2000/07/24 11:23:47 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef G3toG4EventAction_h
#define G3toG4EventAction_h 1
#include "G4UserEventAction.hh"
#include "globals.hh"
class G3toG4EventActionMessenger;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class G3toG4EventAction : public G4UserEventAction
{
public:
G3toG4EventAction();
~G3toG4EventAction();
public:
void BeginOfEventAction(const G4Event* anEvent);
void EndOfEventAction(const G4Event* anEvent);
void SetDrawFlag(G4String val) {drawFlag = val;};
private:
G4String drawFlag; // control the drawing of event
G3toG4EventActionMessenger* eventMessenger;
};
#endif
// 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: G3toG4EventActionMessenger.hh,v 1.1 2000/07/24 11:23:48 gcosmo Exp $
// GEANT4 tag $Name: examples-V02-00-01 $
//
//
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
#ifndef G3toG4EventActionMessenger_h
#define G3toG4EventActionMessenger_h 1
#include "globals.hh"
#include "G4UImessenger.hh"
class G3toG4EventAction;
class G4UIcmdWithAString;
//....oooOO0OOooo........oooOO0OOooo........oooOO0OOooo........oooOO0OOooo....
class G3toG4EventActionMessenger: public G4UImessenger
{
public:
G3toG4EventActionMessenger(G3toG4EventAction*);
~G3toG4EventActionMessenger();
void SetNewValue(G4UIcommand*, G4String);
private:
G3toG4EventAction* eventAction;
G4UIcmdWithAString* DrawCmd;
};
#endif