1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
|
#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
// 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
|