CMS 3D CMS Logo

TrackletCalculatorBase.h
Go to the documentation of this file.
1 #ifndef L1Trigger_TrackFindingTracklet_interface_TrackletCalculatorBase_h
2 #define L1Trigger_TrackFindingTracklet_interface_TrackletCalculatorBase_h
3 
7 
8 #include <vector>
9 
10 namespace trklet {
11 
12  class Settings;
13  class Globals;
14  class Stub;
15  class L1TStub;
16  class Tracklet;
17 
19  public:
20  TrackletCalculatorBase(std::string name, Settings const& settings, Globals* global);
21 
22  ~TrackletCalculatorBase() override = default;
23 
24  void exacttracklet(double r1,
25  double z1,
26  double phi1,
27  double r2,
28  double z2,
29  double phi2,
30  double,
31  double& rinv,
32  double& phi0,
33  double& t,
34  double& z0,
35  double phiproj[N_LAYER - 2], //=4
36  double zproj[N_LAYER - 2],
37  double phider[N_LAYER - 2],
38  double zder[N_LAYER - 2],
39  double phiprojdisk[N_DISK], //=5
40  double rprojdisk[N_DISK],
41  double phiderdisk[N_DISK],
42  double rderdisk[N_DISK]);
43 
44  void exacttrackletdisk(double r1,
45  double z1,
46  double phi1,
47  double r2,
48  double z2,
49  double phi2,
50  double,
51  double& rinv,
52  double& phi0,
53  double& t,
54  double& z0,
55  double phiprojLayer[N_PSLAYER], //=3
56  double zprojLayer[N_PSLAYER],
57  double phiderLayer[N_PSLAYER],
58  double zderLayer[N_PSLAYER],
59  double phiproj[N_DISK - 2], //=3
60  double rproj[N_DISK - 2],
61  double phider[N_DISK - 2],
62  double rder[N_DISK - 2]);
63 
64  void exacttrackletOverlap(double r1,
65  double z1,
66  double phi1,
67  double r2,
68  double z2,
69  double phi2,
70  double,
71  double& rinv,
72  double& phi0,
73  double& t,
74  double& z0,
75  double phiprojLayer[N_PSLAYER], //=3
76  double zprojLayer[N_PSLAYER],
77  double phiderLayer[N_PSLAYER],
78  double zderLayer[N_PSLAYER],
79  double phiproj[N_DISK - 2], //=3
80  double rproj[N_DISK - 2],
81  double phider[N_DISK - 2],
82  double rder[N_DISK - 2]);
83 
84  void exactproj(double rproj,
85  double rinv,
86  double phi0,
87  double t,
88  double z0,
89  double& phiproj,
90  double& zproj,
91  double& phider,
92  double& zder);
93 
94  void exactprojdisk(double zproj,
95  double rinv,
96  double phi0,
97  double t,
98  double z0,
99  double& phiproj,
100  double& rproj,
101  double& phider,
102  double& rder);
103 
104  void addDiskProj(Tracklet* tracklet, int disk);
105  bool addLayerProj(Tracklet* tracklet, int layer);
106 
107  void addProjection(int layer, int iphi, TrackletProjectionsMemory* trackletprojs, Tracklet* tracklet);
108  void addProjectionDisk(int disk, int iphi, TrackletProjectionsMemory* trackletprojs, Tracklet* tracklet);
109 
110  bool goodTrackPars(bool goodrinv, bool goodz0);
111 
112  bool inSector(int iphi0, int irinv, double phi0approx, double rinvapprox);
113 
114  bool barrelSeeding(const Stub* innerFPGAStub,
115  const L1TStub* innerStub,
116  const Stub* outerFPGAStub,
117  const L1TStub* outerStub);
118  bool diskSeeding(const Stub* innerFPGAStub,
119  const L1TStub* innerStub,
120  const Stub* outerFPGAStub,
121  const L1TStub* outerStub);
122  bool overlapSeeding(const Stub* innerFPGAStub,
123  const L1TStub* innerStub,
124  const Stub* outerFPGAStub,
125  const L1TStub* outerStub);
126 
127  protected:
128  unsigned int iSeed_;
129  unsigned int layerdisk1_;
130  unsigned int layerdisk2_;
131 
132  int TCIndex_;
133 
134  unsigned int iSector_;
135  double phimin_, phimax_;
136 
138 
139  //First index is layer/disk second is phi region
140  std::vector<std::vector<TrackletProjectionsMemory*> > trackletprojlayers_;
141  std::vector<std::vector<TrackletProjectionsMemory*> > trackletprojdisks_;
142  };
143 
144 }; // namespace trklet
145 #endif
constexpr int N_DISK
Definition: Settings.h:22
bool diskSeeding(const Stub *innerFPGAStub, const L1TStub *innerStub, const Stub *outerFPGAStub, const L1TStub *outerStub)
bool goodTrackPars(bool goodrinv, bool goodz0)
bool addLayerProj(Tracklet *tracklet, int layer)
void exacttrackletOverlap(double r1, double z1, double phi1, double r2, double z2, double phi2, double, double &rinv, double &phi0, double &t, double &z0, double phiprojLayer[N_PSLAYER], double zprojLayer[N_PSLAYER], double phiderLayer[N_PSLAYER], double zderLayer[N_PSLAYER], double phiproj[N_DISK - 2], double rproj[N_DISK - 2], double phider[N_DISK - 2], double rder[N_DISK - 2])
void exacttracklet(double r1, double z1, double phi1, double r2, double z2, double phi2, double, double &rinv, double &phi0, double &t, double &z0, double phiproj[N_LAYER - 2], double zproj[N_LAYER - 2], double phider[N_LAYER - 2], double zder[N_LAYER - 2], double phiprojdisk[N_DISK], double rprojdisk[N_DISK], double phiderdisk[N_DISK], double rderdisk[N_DISK])
void exactprojdisk(double zproj, double rinv, double phi0, double t, double z0, double &phiproj, double &rproj, double &phider, double &rder)
bool overlapSeeding(const Stub *innerFPGAStub, const L1TStub *innerStub, const Stub *outerFPGAStub, const L1TStub *outerStub)
void addProjection(int layer, int iphi, TrackletProjectionsMemory *trackletprojs, Tracklet *tracklet)
void exacttrackletdisk(double r1, double z1, double phi1, double r2, double z2, double phi2, double, double &rinv, double &phi0, double &t, double &z0, double phiprojLayer[N_PSLAYER], double zprojLayer[N_PSLAYER], double phiderLayer[N_PSLAYER], double zderLayer[N_PSLAYER], double phiproj[N_DISK - 2], double rproj[N_DISK - 2], double phider[N_DISK - 2], double rder[N_DISK - 2])
TrackletParametersMemory * trackletpars_
std::vector< std::vector< TrackletProjectionsMemory * > > trackletprojdisks_
constexpr unsigned int N_PSLAYER
Definition: Settings.h:23
void exactproj(double rproj, double rinv, double phi0, double t, double z0, double &phiproj, double &zproj, double &phider, double &zder)
std::vector< std::vector< TrackletProjectionsMemory * > > trackletprojlayers_
double rinv(double phi1, double phi2, double r1, double r2)
Definition: Util.h:49
TrackletCalculatorBase(std::string name, Settings const &settings, Globals *global)
void addDiskProj(Tracklet *tracklet, int disk)
void addProjectionDisk(int disk, int iphi, TrackletProjectionsMemory *trackletprojs, Tracklet *tracklet)
~TrackletCalculatorBase() override=default
bool inSector(int iphi0, int irinv, double phi0approx, double rinvapprox)
constexpr int N_LAYER
Definition: Settings.h:21
bool barrelSeeding(const Stub *innerFPGAStub, const L1TStub *innerStub, const Stub *outerFPGAStub, const L1TStub *outerStub)