-
Notifications
You must be signed in to change notification settings - Fork 4.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4054 from civanch/neutron_backgound
Neutron backgound: backport from 7_1_X
- Loading branch information
Showing
14 changed files
with
628 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import FWCore.ParameterSet.Config as cms | ||
|
||
def customise(process): | ||
|
||
# fragment allowing to simulate neutron background in muon system | ||
|
||
if hasattr(process,'g4SimHits'): | ||
# time window 10 millisecond | ||
process.common_maximum_time.MaxTrackTime = cms.double(100000000.0) | ||
process.common_maximum_time.MaxTimeNames = cms.vstring('ZDCRegion') | ||
process.common_maximum_time.MaxTrackTimes = cms.vdouble(2000) | ||
# Physics List XS | ||
process.g4SimHits.Physics.type = cms.string('SimG4Core/Physics/FTFP_BERT_HP_EML') | ||
process.g4SimHits.Physics.CutsOnProton = cms.untracked.bool(False) | ||
process.g4SimHits.Physics.FlagFluo = cms.bool(True) | ||
process.g4SimHits.Physics.RusRoGammaEnergyLimit = cms.double(0.0) | ||
# Eta cut | ||
process.g4SimHits.Generator.MinEtaCut = cms.double(-7.0) | ||
process.g4SimHits.Generator.MaxEtaCut = cms.double(7.0) | ||
# stacking action | ||
process.g4SimHits.StackingAction.MaxTrackTime = cms.double(100000000.0) | ||
process.g4SimHits.StackingAction.MaxTimeNames = cms.vstring('ZDCRegion') | ||
process.g4SimHits.StackingAction.MaxTrackTimes = cms.vdouble(2000) | ||
# stepping action | ||
process.g4SimHits.SteppingAction.MaxTrackTime = cms.double(100000000.0) | ||
process.g4SimHits.SteppingAction.MaxTimeNames = cms.vstring('ZDCRegion') | ||
process.g4SimHits.SteppingAction.MaxTrackTimes = cms.vdouble(2000) | ||
# Russian roulette disabled | ||
process.g4SimHits.StackingAction.RusRoGammaEnergyLimit = cms.double(0.0) | ||
process.g4SimHits.StackingAction.RusRoNeutronEnergyLimit = cms.double(0.0) | ||
# full simulation of HF | ||
process.g4SimHits.HFShower.UseHFGflash = cms.bool(False) | ||
|
||
return(process) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import FWCore.ParameterSet.Config as cms | ||
|
||
def customise(process): | ||
|
||
# fragment allowing to simulate neutron background in muon system | ||
|
||
if hasattr(process,'g4SimHits'): | ||
# time window 10 millisecond | ||
process.common_maximum_time.MaxTrackTime = cms.double(100000000.0) | ||
process.common_maximum_time.MaxTimeNames = cms.vstring('ZDCRegion') | ||
process.common_maximum_time.MaxTrackTimes = cms.vdouble(2000) | ||
# Physics List XS | ||
process.g4SimHits.Physics.type = cms.string('SimG4Core/Physics/FTFP_BERT_XS_EML') | ||
process.g4SimHits.Physics.CutsOnProton = cms.untracked.bool(False) | ||
process.g4SimHits.Physics.FlagFluo = cms.bool(True) | ||
process.g4SimHits.Physics.RusRoGammaEnergyLimit = cms.double(0.0) | ||
# Eta cut | ||
process.g4SimHits.Generator.MinEtaCut = cms.double(-7.0) | ||
process.g4SimHits.Generator.MaxEtaCut = cms.double(7.0) | ||
# stacking action | ||
process.g4SimHits.StackingAction.MaxTrackTime = cms.double(100000000.0) | ||
process.g4SimHits.StackingAction.MaxTimeNames = cms.vstring('ZDCRegion') | ||
process.g4SimHits.StackingAction.MaxTrackTimes = cms.vdouble(2000) | ||
# stepping action | ||
process.g4SimHits.SteppingAction.MaxTrackTime = cms.double(100000000.0) | ||
process.g4SimHits.SteppingAction.MaxTimeNames = cms.vstring('ZDCRegion') | ||
process.g4SimHits.SteppingAction.MaxTrackTimes = cms.vdouble(2000) | ||
# Russian roulette disabled | ||
process.g4SimHits.StackingAction.RusRoGammaEnergyLimit = cms.double(0.0) | ||
process.g4SimHits.StackingAction.RusRoNeutronEnergyLimit = cms.double(0.0) | ||
# full simulation of HF | ||
process.g4SimHits.HFShower.UseHFGflash = cms.bool(False) | ||
|
||
return(process) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
#ifndef SimG4Core_PhysicsLists_CMSEmStandardPhysicsXS_h | ||
#define SimG4Core_PhysicsLists_CMSEmStandardPhysicsXS_h | ||
|
||
#include "G4VPhysicsConstructor.hh" | ||
#include "globals.hh" | ||
|
||
class CMSEmStandardPhysicsXS : public G4VPhysicsConstructor { | ||
|
||
public: | ||
CMSEmStandardPhysicsXS(G4int ver); | ||
virtual ~CMSEmStandardPhysicsXS(); | ||
|
||
virtual void ConstructParticle(); | ||
virtual void ConstructProcess(); | ||
|
||
private: | ||
G4int verbose; | ||
}; | ||
|
||
#endif | ||
|
||
|
||
|
||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
#include "FTFPCMS_BERT_HP_EML.hh" | ||
#include "SimG4Core/PhysicsLists/interface/CMSEmStandardPhysicsXS.h" | ||
#include "SimG4Core/PhysicsLists/interface/CMSMonopolePhysics.h" | ||
#include "FWCore/MessageLogger/interface/MessageLogger.h" | ||
|
||
#include "G4DecayPhysics.hh" | ||
#include "G4EmExtraPhysics.hh" | ||
#include "G4IonPhysics.hh" | ||
#include "G4StoppingPhysics.hh" | ||
#include "G4HadronElasticPhysics.hh" | ||
#include "G4NeutronTrackingCut.hh" | ||
#include "G4HadronicProcessStore.hh" | ||
|
||
#include "G4DataQuestionaire.hh" | ||
#include "HadronPhysicsFTFP_BERT_HP.hh" | ||
|
||
FTFPCMS_BERT_HP_EML::FTFPCMS_BERT_HP_EML(G4LogicalVolumeToDDLogicalPartMap& map, | ||
const HepPDT::ParticleDataTable * table_, | ||
sim::FieldBuilder *fieldBuilder_, | ||
const edm::ParameterSet & p) : PhysicsList(map, table_, fieldBuilder_, p) { | ||
|
||
G4DataQuestionaire it(photon); | ||
|
||
int ver = p.getUntrackedParameter<int>("Verbosity",0); | ||
bool emPhys = p.getUntrackedParameter<bool>("EMPhysics",true); | ||
bool hadPhys = p.getUntrackedParameter<bool>("HadPhysics",true); | ||
bool tracking= p.getParameter<bool>("TrackingCut"); | ||
//bool munucl = p.getParameter<bool>("FlagMuNucl"); | ||
edm::LogInfo("PhysicsList") << "You are using the simulation engine: " | ||
<< "FTFP_BERT_EML with Flags for EM Physics " | ||
<< emPhys << ", for Hadronic Physics " | ||
<< hadPhys << " and tracking cut " << tracking; | ||
|
||
if (emPhys) { | ||
// EM Physics | ||
RegisterPhysics( new CMSEmStandardPhysicsXS(ver)); | ||
|
||
// Synchroton Radiation & GN Physics | ||
G4EmExtraPhysics* gn = new G4EmExtraPhysics(ver); | ||
//if(munucl) { G4String yes = "on"; gn->MuonNuclear(yes); } | ||
RegisterPhysics(gn); | ||
} | ||
|
||
// Decays | ||
this->RegisterPhysics( new G4DecayPhysics(ver) ); | ||
|
||
if (hadPhys) { | ||
G4HadronicProcessStore::Instance()->SetVerbose(ver); | ||
|
||
// Hadron Elastic scattering | ||
RegisterPhysics( new G4HadronElasticPhysics(ver)); | ||
|
||
// Hadron Physics | ||
RegisterPhysics( new HadronPhysicsFTFP_BERT_HP(ver)); | ||
|
||
// Stopping Physics | ||
RegisterPhysics( new G4StoppingPhysics(ver)); | ||
|
||
// Ion Physics | ||
RegisterPhysics( new G4IonPhysics(ver)); | ||
|
||
// Neutron tracking cut | ||
if (tracking) { | ||
RegisterPhysics( new G4NeutronTrackingCut(ver)); | ||
} | ||
} | ||
|
||
// Monopoles | ||
RegisterPhysics( new CMSMonopolePhysics(table_,fieldBuilder_,p)); | ||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
#ifndef SimG4Core_PhysicsLists_FTFPCMS_BERT_HP_EML_H | ||
#define SimG4Core_PhysicsLists_FTFPCMS_BERT_HP_EML_H | ||
|
||
#include "SimG4Core/Physics/interface/PhysicsList.h" | ||
#include "FWCore/ParameterSet/interface/ParameterSet.h" | ||
|
||
class FTFPCMS_BERT_HP_EML: public PhysicsList { | ||
|
||
public: | ||
FTFPCMS_BERT_HP_EML(G4LogicalVolumeToDDLogicalPartMap& map, const HepPDT::ParticleDataTable * table_, sim::FieldBuilder *fieldBuilder_, const edm::ParameterSet & p); | ||
}; | ||
|
||
#endif | ||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,74 @@ | ||
#include "FTFPCMS_BERT_XS_EML.hh" | ||
#include "SimG4Core/PhysicsLists/interface/CMSEmStandardPhysicsXS.h" | ||
#include "SimG4Core/PhysicsLists/interface/CMSMonopolePhysics.h" | ||
#include "FWCore/MessageLogger/interface/MessageLogger.h" | ||
|
||
#include "G4DecayPhysics.hh" | ||
#include "G4EmExtraPhysics.hh" | ||
#include "G4IonPhysics.hh" | ||
#include "G4StoppingPhysics.hh" | ||
#include "G4HadronElasticPhysicsXS.hh" | ||
#include "G4NeutronCrossSectionXS.hh" | ||
#include "G4NeutronTrackingCut.hh" | ||
#include "G4HadronicProcessStore.hh" | ||
|
||
#include "G4DataQuestionaire.hh" | ||
#include "HadronPhysicsFTFP_BERT.hh" | ||
|
||
FTFPCMS_BERT_XS_EML::FTFPCMS_BERT_XS_EML(G4LogicalVolumeToDDLogicalPartMap& map, | ||
const HepPDT::ParticleDataTable * table_, | ||
sim::FieldBuilder *fieldBuilder_, | ||
const edm::ParameterSet & p) : PhysicsList(map, table_, fieldBuilder_, p) { | ||
|
||
G4DataQuestionaire it(photon); | ||
|
||
int ver = p.getUntrackedParameter<int>("Verbosity",0); | ||
bool emPhys = p.getUntrackedParameter<bool>("EMPhysics",true); | ||
bool hadPhys = p.getUntrackedParameter<bool>("HadPhysics",true); | ||
bool tracking= p.getParameter<bool>("TrackingCut"); | ||
//bool munucl = p.getParameter<bool>("FlagMuNucl"); | ||
edm::LogInfo("PhysicsList") << "You are using the simulation engine: " | ||
<< "FTFP_BERT_EML with Flags for EM Physics " | ||
<< emPhys << ", for Hadronic Physics " | ||
<< hadPhys << " and tracking cut " << tracking; | ||
|
||
if (emPhys) { | ||
// EM Physics | ||
RegisterPhysics( new CMSEmStandardPhysicsXS(ver)); | ||
|
||
// Synchroton Radiation & GN Physics | ||
G4EmExtraPhysics* gn = new G4EmExtraPhysics(ver); | ||
//if(munucl) { G4String yes = "on"; gn->MuonNuclear(yes); } | ||
RegisterPhysics(gn); | ||
} | ||
|
||
// Decays | ||
this->RegisterPhysics( new G4DecayPhysics(ver) ); | ||
|
||
if (hadPhys) { | ||
G4HadronicProcessStore::Instance()->SetVerbose(ver); | ||
|
||
// Hadron Elastic scattering | ||
RegisterPhysics( new G4HadronElasticPhysicsXS(ver)); | ||
|
||
// Hadron Physics | ||
RegisterPhysics( new HadronPhysicsFTFP_BERT(ver)); | ||
|
||
// Stopping Physics | ||
RegisterPhysics( new G4StoppingPhysics(ver)); | ||
|
||
// Ion Physics | ||
RegisterPhysics( new G4IonPhysics(ver)); | ||
|
||
RegisterPhysics( new G4NeutronCrossSectionXS(ver)); | ||
|
||
// Neutron tracking cut | ||
if (tracking) { | ||
RegisterPhysics( new G4NeutronTrackingCut(ver)); | ||
} | ||
} | ||
|
||
// Monopoles | ||
RegisterPhysics( new CMSMonopolePhysics(table_,fieldBuilder_,p)); | ||
} | ||
|
Oops, something went wrong.