コード例 #1
0
ファイル: GeantFastSimConfig.cpp プロジェクト: ocolegro/FCCSW
G4VModularPhysicsList* GeantFastSimConfig::getPhysicsList() {
   // we pass the ownership to Geant4Simulation which will register it in G4RunManager and will be deleted in ~G4RunManager()
   G4VModularPhysicsList* physicsList = new FTFP_BERT;
   // Coupled transportation enables calculation of particle trajectory in envelopes with fast sim models attached
   G4PhysicsListHelper::GetPhysicsListHelper()->UseCoupledTransportation();
   // Attach Fast Simulation Process (will take over normal transportation if FastSimModel triggered
   physicsList->RegisterPhysics(new FastSimPhysics);
   return physicsList;
}
コード例 #2
0
G4VModularPhysicsList* G4FastSimPhysicsList::getPhysicsList() {
  // ownership passed to G4SimSvc which will register it in G4RunManager. To be deleted in ~G4RunManager()
  G4VModularPhysicsList* physicsList = m_physicsListTool->getPhysicsList();
  // Coupled transportation enables calculation of particle trajectory in envelopes with fast sim models attached
  G4PhysicsListHelper::GetPhysicsListHelper()->UseCoupledTransportation();
  // Attach Fast Simulation Process (will take over normal transportation if FastSimModel triggered
  physicsList->RegisterPhysics(new sim::FastSimPhysics);
  return physicsList;
}
コード例 #3
0
ファイル: Geant4PhysicsList.cpp プロジェクト: AIDASoft/DD4hep
/// Extend physics list from factory:
G4VUserPhysicsList* Geant4PhysicsListActionSequence::extensionList()    {
  G4VModularPhysicsList* physics = ( m_extends.empty() )
    ? new EmptyPhysics()
    : G4PhysListFactory().GetReferencePhysList(m_extends);
  // Register all physics constructors with the physics list
  constructPhysics(physics);
  // Ensure the particles and processes declared are also invoked.
  // Hence: Create a special physics constructor doing so.
  // Ownership is transferred to the physics list.
  // Do not delete this pointer afterwards....
  physics->RegisterPhysics(new ParticlePhysics(this,physics));
  return physics;
}