/
githubmirror
/
cmssw
Обзор
Документация
Войти
/
githubmirror
/
cmssw
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
master
GeneratorInterface/CosmicMuonGenerator/interface/CosMuoGenProducer.h
95 строк
4 KB
Tamas
Add new functionality for upward going case in the Cosmics generator
22 июл 2025, 01:00
22 июл 2025, 01:00
1b04eca
Код
Авторство
О чём код?
#ifndef CosMuoGenProducer_h #define CosMuoGenProducer_h // // CosmicMuonProducer by droll (01/FEB/2006) // #include "HepMC/GenEvent.h" #include "FWCore/Framework/interface/one/EDProducer.h" #include "FWCore/Framework/interface/EventSetup.h" #include "FWCore/Framework/interface/Event.h" #include "FWCore/Framework/interface/LuminosityBlock.h" #include "FWCore/Framework/interface/Run.h" #include "FWCore/ParameterSet/interface/ParameterSet.h" #include "FWCore/Utilities/interface/Exception.h" #include "GeneratorInterface/CosmicMuonGenerator/interface/CosmicMuonGenerator.h" #include <memory> namespace edm { class CosMuoGenProducer : public one::EDProducer<EndRunProducer, one::WatchLuminosityBlocks> { public: CosMuoGenProducer(const ParameterSet&); ~CosMuoGenProducer() override; private: void beginLuminosityBlock(LuminosityBlock const&, EventSetup const&) override; void endLuminosityBlock(LuminosityBlock const&, EventSetup const&) override {} void produce(Event& e, const EventSetup& es) override; void endRunProduce(Run& r, const EventSetup& es) override; void clear(); // define the configurable generator parameters int32_t RanS; // seed of random number generator (from Framework) double MinP; // min. P [GeV] double MinP_CMS; // min. P at CMS surface [GeV]; default is MinP_CMS=MinP, thus no bias from access-shaft double MaxP; // max. P [GeV] double MinT; // min. theta [deg] double MaxT; // max. theta [deg] double MinPh; // min. phi [deg] double MaxPh; // max. phi [deg] double MinS; // min. t0 [ns] double MaxS; // max. t0 [ns] double ELSF; // scale factor for energy loss double RTarget; // Radius of target-cylinder which cosmics HAVE to hit [mm], default is CMS-dimensions double ZTarget; // z-length of target-cylinder which cosmics HAVE to hit [mm], default is CMS-dimensions double ZCTarget; // z-position of centre of target-cylinder which cosmics HAVE to hit [mm], default is Nominal Interaction Point bool TrackerOnly; //if set to "true" detector with tracker-only setup is used, so no material or B-field outside is considerd bool MultiMuon; //read in multi-muon events from file instead of generating single muon events std::string MultiMuonFileName; //file containing multi muon events, to be read in int32_t MultiMuonFileFirstEvent; int32_t MultiMuonNmin; bool TIFOnly_constant; //if set to "true" cosmics can also be generated below 2GeV with unphysical constant energy dependence bool TIFOnly_linear; //if set to "true" cosmics can also be generated below 2GeV with unphysical linear energy dependence bool MTCCHalf; //if set to "true" muons are sure to hit half of CMS important for MTCC, //still material and B-field of whole CMS is considered //Plug position (default = on shaft) double PlugVtx; double PlugVtz; //material densities in g/cm^3 double VarRhoAir; double VarRhoWall; double VarRhoRock; double VarRhoClay; double VarRhoPlug; double ClayLayerWidth; //[mm] //For upgoing muon generation: Neutrino energy limits double MinEn; double MaxEn; double NuPrdAlt; bool AllMu; //Accepting All Muons regardeless of direction /// depth of the surface where upgoing muon is generated relative to bottom of CMS double SurfaceDepthToCMS; // external cross section and filter efficiency double extCrossSect; double extFilterEff; std::unique_ptr<CosmicMuonGenerator> CosMuoGen; // the event format itself bool cmVerbosity_; bool isInitialized_; }; } // namespace edm #endif