2#ifndef RIVET_ExptSmearingFunctions_HH
3#define RIVET_ExptSmearingFunctions_HH
5#include "Rivet/Tools/JetSmearingFunctions.hh"
6#include "Rivet/Tools/MomentumSmearingFunctions.hh"
7#include "Rivet/Tools/ParticleSmearingFunctions.hh"
40 if (e.
abspid() != PID::ELECTRON)
return 0;
41 if (e.
abseta() > 2.5)
return 0;
42 if (e.
pT() < 10 * GeV)
return 0;
43 return (e.
abseta() < 1.5) ? 0.95 : 0.85;
50 if (e.
abspid() != PID::ELECTRON)
return 0;
51 const double et = e.
Et();
52 if (e.
abseta() > 2.5 || e.
Et() < 2 * GeV)
return 0;
53 if (et > 25 * GeV)
return 0.97;
54 if (et > 10 * GeV)
return 0.92 + (et / GeV - 10) / 15. * 0.05;
55 if (et > 6 * GeV)
return 0.85 + (et / GeV - 6) / 4. * 0.07;
56 if (et > 5 * GeV)
return 0.70 + (et / GeV - 5) / 1. * 0.15;
57 if (et > 2 * GeV)
return 0.00 + (et / GeV - 2) / 3. * 0.70;
68 if (e.
abspid() != PID::ELECTRON)
return 0;
71 const static vector<double> edges_eta = {0.0, 0.1, 0.8, 1.37, 1.52, 2.01, 2.37, 2.47};
72 const static vector<double> effs_eta = {0.950, 0.965, 0.955, 0.885, 0.950, 0.935, 0.90};
74 const static vector<double> edges_et = {0, 10, 20, 25, 30, 35, 40, 45, 50, 60, 80};
75 const static vector<double> effs_et = {
76 0.0, 0.90, 0.91, 0.92, 0.94, 0.95,
77 0.955, 0.965, 0.97, 0.98, 0.98};
79 if (e.
abseta() > 2.47)
return 0.0;
82 const int i_et =
binIndex(e.
Et() / GeV, edges_et,
true);
83 const double eff = effs_et[i_et] * effs_eta[i_eta]
96 if (e.
abspid() != PID::ELECTRON)
return 0;
98 const static vector<double> eta_edges_10 = {0.000, 0.049, 0.454, 1.107, 1.46, 1.790, 2.277, 2.500};
99 const static vector<double> eta_vals_10 = {0.730, 0.757, 0.780, 0.771, 0.77, 0.777, 0.778};
101 const static vector<double> eta_edges_15 = {0.000, 0.053, 0.456, 1.102, 1.463, 1.783, 2.263, 2.500};
102 const static vector<double> eta_vals_15 = {0.780, 0.800, 0.819, 0.759, 0.749, 0.813, 0.829};
104 const static vector<double> eta_edges_20 = {0.000, 0.065, 0.362, 0.719, 0.980, 1.289,
105 1.455, 1.681, 1.942, 2.239, 2.452, 2.500};
106 const static vector<double> eta_vals_20 = {0.794, 0.806, 0.816, 0.806, 0.797, 0.774,
107 0.764, 0.788, 0.793, 0.806, 0.825};
109 const static vector<double> eta_edges_25 = {0.000, 0.077, 0.338, 0.742, 1.004, 1.265,
110 1.467, 1.692, 1.940, 2.227, 2.452, 2.500};
111 const static vector<double> eta_vals_25 = {0.833, 0.843, 0.853, 0.845, 0.839, 0.804,
112 0.790, 0.825, 0.830, 0.833, 0.839};
114 const static vector<double> eta_edges_30 = {0.000, 0.077, 0.350, 0.707, 0.980, 1.289,
115 1.479, 1.681, 1.942, 2.239, 2.441, 2.500};
116 const static vector<double> eta_vals_30 = {0.863, 0.872, 0.881, 0.874, 0.870, 0.824,
117 0.808, 0.847, 0.845, 0.840, 0.842};
119 const static vector<double> eta_edges_35 = {0.000, 0.058, 0.344, 0.700, 1.009, 1.270,
120 1.458, 1.685, 1.935, 2.231, 2.468, 2.500};
121 const static vector<double> eta_vals_35 = {0.878, 0.889, 0.901, 0.895, 0.893, 0.849,
122 0.835, 0.868, 0.863, 0.845, 0.832};
124 const static vector<double> eta_edges_40 = {0.000, 0.047, 0.355, 0.699, 0.983, 1.280,
125 1.446, 1.694, 1.943, 2.227, 2.441, 2.500};
126 const static vector<double> eta_vals_40 = {0.894, 0.901, 0.909, 0.905, 0.904, 0.875,
127 0.868, 0.889, 0.876, 0.848, 0.827};
129 const static vector<double> eta_edges_45 = {0.000, 0.058, 0.356, 0.712, 0.997, 1.282,
130 1.459, 1.686, 1.935, 2.220, 2.444, 2.500};
131 const static vector<double> eta_vals_45 = {0.900, 0.911, 0.923, 0.918, 0.917, 0.897,
132 0.891, 0.904, 0.894, 0.843, 0.796};
134 const static vector<double> eta_edges_50 = {0.000, 0.059, 0.355, 0.711, 0.983, 1.280,
135 1.469, 1.682, 1.919, 2.227, 2.441, 2.500};
136 const static vector<double> eta_vals_50 = {0.903, 0.913, 0.923, 0.922, 0.923, 0.903,
137 0.898, 0.908, 0.895, 0.831, 0.774};
139 const static vector<double> eta_edges_60 = {0.000, 0.053, 0.351, 0.720, 1.006, 1.291,
140 1.469, 1.696, 1.946, 2.243, 2.455, 2.500};
141 const static vector<double> eta_vals_60 = {0.903, 0.917, 0.928, 0.924, 0.927, 0.915,
142 0.911, 0.915, 0.899, 0.827, 0.760};
144 const static vector<double> eta_edges_80 = {0.000, 0.053, 0.351, 0.720, 0.994, 1.292,
145 1.482, 1.708, 1.934, 2.220, 2.458, 2.500};
146 const static vector<double> eta_vals_80 = {0.936, 0.942, 0.952, 0.956, 0.956, 0.934,
147 0.931, 0.944, 0.933, 0.940, 0.948};
149 const static vector<double> et_edges = {10, 15, 20, 25, 30, 35, 40, 45, 50, 60, 80};
150 const static vector<vector<double>> et_eta_edges = {eta_edges_10, eta_edges_15, eta_edges_20,
151 eta_edges_25, eta_edges_30, eta_edges_35,
152 eta_edges_40, eta_edges_45, eta_edges_50,
153 eta_edges_60, eta_edges_80};
154 const static vector<vector<double>> et_eta_vals = {eta_vals_10, eta_vals_15, eta_vals_20, eta_vals_25,
155 eta_vals_30, eta_vals_35, eta_vals_40, eta_vals_45,
156 eta_vals_50, eta_vals_60, eta_vals_80};
158 if (e.
abseta() > 2.5 || e.
Et() < 10 * GeV)
return 0.0;
159 const int i_et =
binIndex(e.
Et() / GeV, et_edges,
true);
168 if (e.
abspid() != PID::ELECTRON)
return 0;
175 if (e.
abspid() != PID::ELECTRON)
return 0;
177 const static vector<double> eta_edges_10 = {0.000, 0.049, 0.459, 1.100, 1.461, 1.789, 2.270, 2.500};
178 const static vector<double> eta_vals_10 = {0.581, 0.632, 0.668, 0.558, 0.548, 0.662, 0.690};
180 const static vector<double> eta_edges_15 = {0.000, 0.053, 0.450, 1.096, 1.463, 1.783, 2.269, 2.500};
181 const static vector<double> eta_vals_15 = {0.630, 0.678, 0.714, 0.633, 0.616, 0.700, 0.733};
183 const static vector<double> eta_edges_20 = {0.000, 0.065, 0.362, 0.719, 0.992, 1.277,
184 1.479, 1.692, 1.930, 2.227, 2.464, 2.500};
185 const static vector<double> eta_vals_20 = {0.653, 0.695, 0.735, 0.714, 0.688, 0.635,
186 0.625, 0.655, 0.680, 0.691, 0.674};
188 const static vector<double> eta_edges_25 = {0.000, 0.077, 0.362, 0.719, 0.992, 1.300,
189 1.479, 1.692, 1.942, 2.227, 2.464, 2.500};
190 const static vector<double> eta_vals_25 = {0.692, 0.732, 0.768, 0.750, 0.726, 0.677,
191 0.667, 0.692, 0.710, 0.706, 0.679};
193 const static vector<double> eta_edges_30 = {0.000, 0.053, 0.362, 0.719, 1.004, 1.277,
194 1.467, 1.681, 1.954, 2.239, 2.452, 2.500};
195 const static vector<double> eta_vals_30 = {0.724, 0.763, 0.804, 0.789, 0.762, 0.702,
196 0.690, 0.720, 0.731, 0.714, 0.681};
198 const static vector<double> eta_edges_35 = {0.000, 0.044, 0.342, 0.711, 0.971, 1.280,
199 1.456, 1.683, 1.944, 2.218, 2.442, 2.500};
200 const static vector<double> eta_vals_35 = {0.736, 0.778, 0.824, 0.811, 0.784, 0.730,
201 0.718, 0.739, 0.743, 0.718, 0.678};
203 const static vector<double> eta_edges_40 = {0.000, 0.047, 0.355, 0.699, 0.983, 1.268,
204 1.457, 1.671, 1.931, 2.204, 2.453, 2.500};
205 const static vector<double> eta_vals_40 = {0.741, 0.774, 0.823, 0.823, 0.802, 0.764,
206 0.756, 0.771, 0.771, 0.734, 0.684};
208 const static vector<double> eta_edges_45 = {0.000, 0.056, 0.354, 0.711, 0.984, 1.280,
209 1.458, 1.684, 1.945, 2.207, 2.442, 2.500};
210 const static vector<double> eta_vals_45 = {0.758, 0.792, 0.841, 0.841, 0.823, 0.792,
211 0.786, 0.796, 0.794, 0.734, 0.663};
213 const static vector<double> eta_edges_50 = {0.000, 0.059, 0.355, 0.699, 0.983, 1.268,
214 1.446, 1.682, 1.943, 2.216, 2.453, 2.500};
215 const static vector<double> eta_vals_50 = {0.771, 0.806, 0.855, 0.858, 0.843, 0.810,
216 0.800, 0.808, 0.802, 0.730, 0.653};
218 const static vector<double> eta_edges_60 = {0.000, 0.050, 0.350, 0.707, 0.981, 1.278,
219 1.468, 1.694, 1.944, 2.242, 2.453, 2.500};
220 const static vector<double> eta_vals_60 = {0.773, 0.816, 0.866, 0.865, 0.853, 0.820,
221 0.812, 0.817, 0.804, 0.726, 0.645};
223 const static vector<double> eta_edges_80 = {0.000, 0.051, 0.374, 0.720, 0.981, 1.279,
224 1.468, 1.707, 1.945, 2.207, 2.457, 2.500};
225 const static vector<double> eta_vals_80 = {0.819, 0.855, 0.899, 0.906, 0.900, 0.869,
226 0.865, 0.873, 0.869, 0.868, 0.859};
228 const static vector<double> et_edges = {10, 15, 20, 25, 30, 35, 40, 45, 50, 60, 80};
229 const static vector<vector<double>> et_eta_edges = {eta_edges_10, eta_edges_15, eta_edges_20,
230 eta_edges_25, eta_edges_30, eta_edges_35,
231 eta_edges_40, eta_edges_45, eta_edges_50,
232 eta_edges_60, eta_edges_80};
233 const static vector<vector<double>> et_eta_vals = {eta_vals_10, eta_vals_15, eta_vals_20, eta_vals_25,
234 eta_vals_30, eta_vals_35, eta_vals_40, eta_vals_45,
235 eta_vals_50, eta_vals_60, eta_vals_80};
237 if (e.
abseta() > 2.5 || e.
Et() < 10 * GeV)
return 0.0;
238 const int i_et =
binIndex(e.
Et() / GeV, et_edges,
true);
247 if (e.
abspid() != PID::ELECTRON)
return 0;
248 const static vector<double> et_edges = { 20, 25, 30, 35, 40, 45, 50, 60, 80};
249 const static vector<double> et_effs = {
250 0.785, 0.805, 0.820, 0.830, 0.840,
251 0.850, 0.875, 0.910, 0.910};
252 const static vector<double> eta_edges = {0.000, 0.051, 0.374, 0.720, 0.981, 1.279,
253 1.468, 1.707, 1.945, 2.207, 2.457, 2.500};
254 const static vector<double> eta_refs = {0.819, 0.855, 0.899, 0.906, 0.900, 0.869,
255 0.865, 0.873, 0.869, 0.868, 0.859};
256 if (e.
abseta() > 2.5 || e.
Et() < 20 * GeV)
return 0.0;
257 const int i_et =
binIndex(e.
Et() / GeV, et_edges,
true);
259 const double eff_et = et_effs[i_et];
269 static const vector<double> edges_eta = {0., 2.5, 3.};
270 static const vector<double> edges_pt = {0., 0.1, 25.};
271 static const vector<double> e2s = {0.000, 0.015, 0.005, 0.005, 0.005, 0.005, 0.107, 0.107, 0.107};
272 static const vector<double> es = {0.00, 0.00, 0.05, 0.05, 0.05, 0.05, 2.08, 2.08, 2.08};
273 static const vector<double> cs = {0.00, 0.00, 0.25, 0.25, 0.25, 0.25, 0.00, 0.00, 0.00};
276 const int i_pt =
binIndex(e.
pT() / GeV, edges_pt,
true);
277 const int i = i_eta * edges_pt.size() + i_pt;
280 const double c1 =
sqr(e2s[i]), c2 =
sqr(es[i]), c3 =
sqr(cs[i]);
281 const double resolution = sqrt(c1 * e.
E2() + c2 * e.
E() + c3) * GeV;
304 if (e.
abspid() != PID::ELECTRON)
return 0;
305 if (e.
abseta() > 2.5)
return 0;
306 if (e.
pT() < 10 * GeV)
return 0;
307 return (e.
abseta() < 1.5) ? 0.95 : 0.85;
330 if (e.
abspid() != PID::ELECTRON)
return 0;
358 double resolution = 0;
360 if (e.
pT() > 0.1 * GeV &&
abseta < 2.5) {
362 resolution =
add_quad(0.06, 1.3e-3 * e.
pT() / GeV) * GeV;
365 resolution =
add_quad(0.10, 1.7e-3 * e.
pT() / GeV) * GeV;
368 resolution =
add_quad(0.25, 3.1e-3 * e.
pT() / GeV) * GeV;
396 if (y.
abspid() != PID::PHOTON)
return 0;
398 if (y.
pT() < 10 * GeV)
return 0;
401 static const vector<double> edges_eta = {0., 0.6, 1.37, 1.52, 1.81, 2.37};
402 static const vector<double> edges_pt = {10., 15., 20., 25., 30., 35., 40., 45.,
403 50., 60., 80., 100., 125., 150., 175., 250.};
404 static const vector<double> effs = {
405 0.53, 0.65, 0.73, 0.83, 0.86, 0.93, 0.94, 0.96, 0.97, 0.98, 0.98, 0.98, 0.98, 0.98, 0.98, 0.98,
406 0.45, 0.57, 0.67, 0.74, 0.84, 0.87, 0.93, 0.94, 0.95, 0.96, 0.97, 0.98, 0.98, 0.99, 0.99, 0.99,
407 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00,
408 0.48, 0.56, 0.68, 0.76, 0.86, 0.90, 0.93, 0.95, 0.96, 0.97, 0.98, 0.99, 0.99, 1.00, 1.00, 1.00,
409 0.50, 0.61, 0.74, 0.82, 0.88, 0.92, 0.94, 0.95, 0.96, 0.97, 0.98, 0.98, 0.98, 0.98, 0.99, 0.99};
412 const int i_pt =
binIndex(y.
pT() / GeV, edges_pt,
true);
413 const int i = i_eta * edges_pt.size() + i_pt;
414 const double eff = effs[i];
438 if (y.
abspid() != PID::PHOTON)
return 0;
440 if (y.
pT() < 10 * GeV)
return 0;
443 static const vector<double> edges_eta = {0., 0.6, 1.37, 1.52, 1.81, 2.37};
444 static const vector<double> edges_pt = {10., 15., 20., 25., 30., 35., 40., 45.,
445 50., 60., 80., 100., 125., 150., 175., 250.};
446 static const vector<double> effs = {
447 0.55, 0.70, 0.85, 0.89, 0.93, 0.95, 0.96, 0.96, 0.97, 0.97, 0.98, 0.97, 0.97, 0.97, 0.97, 0.97,
448 0.47, 0.66, 0.79, 0.86, 0.89, 0.94, 0.96, 0.97, 0.97, 0.98, 0.97, 0.98, 0.98, 0.98, 0.98, 0.98,
449 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00,
450 0.54, 0.71, 0.84, 0.88, 0.92, 0.93, 0.94, 0.95, 0.96, 0.96, 0.96, 0.96, 0.96, 0.96, 0.96, 0.96,
451 0.61, 0.74, 0.83, 0.88, 0.91, 0.94, 0.95, 0.96, 0.97, 0.98, 0.98, 0.98, 0.98, 0.98, 0.98, 0.98};
454 const int i_pt =
binIndex(y.
pT() / GeV, edges_pt,
true);
455 const int i = i_eta * edges_pt.size() + i_pt;
456 const double eff = effs[i];
480 if (y.
abspid() != PID::PHOTON)
return 0;
481 if (y.
pT() < 10 * GeV || y.
abseta() > 2.5)
return 0;
482 return (y.
abseta() < 1.5) ? 0.95 : 0.85;
505 if (y.
abspid() != PID::PHOTON)
return 0;
529 inline Particle PHOTON_SMEAR_ATLAS_RUN2(
const Particle& y) {
547 if (m.
abspid() != PID::MUON)
return 0;
548 if (m.
abseta() > 2.7)
return 0;
549 if (m.
pT() < 10 * GeV)
return 0;
550 return (m.
abseta() < 1.5) ? 0.95 : 0.85;
573 if (m.
abspid() != PID::MUON)
return 0;
574 if (m.
abseta() > 2.5)
return 0;
575 if (m.
abseta() < 0.1)
return 0.61;
577 return (m.
abseta() < 1) ? 0.98 : 0.99;
585 if (m.
abspid() != PID::MUON)
return 0;
586 static const vector<double> edges_pt = {0., 3., 4., 5., 6., 7., 8., 9., 10., 15., 20., 30., 40.};
587 static const vector<double> effs_pt = {0., 0.58, 0.70, 0.75, 0.80, 0.82, 0.85,
588 0.87, 0.90, 0.95, 0.98, 1.00, 1.00};
589 const int i_pt =
binIndex(m.
pT() / GeV, edges_pt,
true);
590 const double eff_pt = effs_pt[i_pt];
599 if (m.
abspid() != PID::MUON)
return 0;
600 if (m.
abseta() > 2.5)
return 0;
601 static const vector<double> edges_pt = {0., 3.5, 4., 5., 6., 7., 8., 10.};
602 static const vector<double> effs = {0.00, 0.88, 0.92, 0.97, 0.98, 0.98, 0.98, 0.99};
603 const int i_pt =
binIndex(m.
pT() / GeV, edges_pt,
true);
604 const double eff = effs[i_pt];
614 if (m.
abspid() != PID::MUON)
return 0;
615 if (m.
abseta() > 2.5)
return 0;
616 static const vector<double> edges_pt = {0., 3.5, 4., 5., 6., 7., 8., 9., 10., 12.,
617 14., 16., 18., 20., 25., 30., 35., 40., 45., 50.};
618 static const vector<double> effs_pt = {0.00, 0.48, 0.62, 0.82, 0.94, 0.95, 0.96, 0.96, 0.97, 0.97,
619 0.97, 0.97, 0.97, 0.98, 0.98, 0.98, 0.98, 0.98, 0.98, 0.98};
620 const int i_pt =
binIndex(m.
pT() / GeV, edges_pt,
true);
621 const double eff_pt = effs_pt[i_pt];
622 static const vector<double> edges_eta = {0., 0.25, 0.50, 0.75, 1.00, 1.25, 1.50, 1.75, 2.00, 2.25, 2.50};
623 static const vector<double> effs_eta = {0.85, 0.99, 0.99, 0.99, 0.99, 0.99, 0.99, 0.99, 0.99, 0.99, 0.99};
625 const double eff_eta = effs_eta[i_eta] / 0.99;
634 if (m.
abspid() != PID::MUON)
return 0;
635 if (m.
abseta() > 2.5)
return 0;
636 static const vector<double> edges_pt = {0., 3.5, 4., 5., 6., 7., 8., 9., 10., 12., 14., 16., 18., 20.};
637 static const vector<double> effs_pt = {0.00, 0.00, 0.68, 0.81, 0.85, 0.88, 0.89,
638 0.90, 0.91, 0.92, 0.92, 0.92, 0.93, 0.93};
639 const int i_pt =
binIndex(m.
pT() / GeV, edges_pt,
true);
640 const double eff_pt = effs_pt[i_pt];
641 static const vector<double> edges_eta = {0., 0.25, 0.50, 0.75, 1.00, 1.25, 1.50, 1.75, 2.00, 2.25, 2.50};
642 static const vector<double> effs_eta = {0.78, 0.94, 0.96, 0.96, 0.96, 0.96, 0.96, 0.96, 0.96, 0.96, 0.96};
644 const double eff_eta = effs_eta[i_eta] / 0.96;
654 static const vector<double> edges_eta = {0, 1.5, 2.5};
655 static const vector<double> edges_pt = {0, 0.1, 1.0, 10., 200.};
656 static const vector<double> res = {0., 0.03, 0.02, 0.03, 0.05, 0., 0.04, 0.03, 0.04, 0.05};
659 const int i_pt =
binIndex(m.
pT() / GeV, edges_pt,
true);
660 const int i = i_eta * edges_pt.size() + i_pt;
661 const double resolution_fixed = res[i];
666 const double resolution = resolution_fixed
667 * (1.0 +
max(0.0, (((0.45 - 0.05) / 0.05 - 1.0) / 2300) * (m.
pT() - 200 * GeV) / GeV));
685 double mres_pt = 0.015;
687 if (m.
pT() > 50 * GeV) mres_pt = 0.015 + 0.01 * (m.
pT() - 50 * GeV) / (50 * GeV);
689 if (m.
pT() > 100 * GeV) mres_pt = 0.025 + 0.0084 * (m.
pT() - 100 * GeV) / (100 * GeV);
690 const double ptres_pt =
SQRT2 * mres_pt;
691 const double resolution = (m.
abseta() < 1.5 ? 1.0 : 1.25) * ptres_pt;
697 if (m.
abspid() != PID::MUON)
return 0;
698 if (m.
abseta() > 2.4)
return 0;
699 if (m.
pT() < 10 * GeV)
return 0;
700 return 0.95 * (m.
abseta() < 1.5 ? 1 : exp(0.5 - 5e-4 * m.
pT() / GeV));
754 double resolution = 0;
756 if (m.
pT() > 0.1 * GeV &&
abseta < 2.5) {
758 resolution =
add_quad(0.01, 2.0e-4 * m.
pT() / GeV);
761 resolution =
add_quad(0.02, 3.0e-4 * m.
pT() / GeV);
764 resolution =
add_quad(0.05, 2.6e-4 * m.
pT() / GeV);
797 if (t.
abseta() > 2.5)
return 0;
804 if (
p.charge3() != 0 &&
p.abseta() < 2.5 &&
p.pT() > 1 * GeV) chargedhadrons +=
p;
807 if (chargedhadrons.empty())
return 0;
808 if (pThadvis < 20 * GeV)
return 0;
809 if (pThadvis < 40 * GeV) {
810 if (chargedhadrons.size() == 1)
return (t.
abspid() == PID::TAU) ? 0.56 : 0;
811 if (chargedhadrons.size() == 3)
return (t.
abspid() == PID::TAU) ? 0.38 : 0;
814 if (chargedhadrons.size() == 1)
return (t.
abspid() == PID::TAU) ? 0.56 : 0;
815 if (chargedhadrons.size() == 3)
return (t.
abspid() == PID::TAU) ? 0.38 : 0;
844 if (j.
abseta() > 2.5)
return 0;
851 if (
p.charge3() != 0 &&
p.abseta() < 2.5 &&
p.pT() > 1 * GeV) chargedhadrons +=
p;
855 if (chargedhadrons.empty())
return 0;
856 if (pThadvis < 20 * GeV)
return 0;
861 if (pThadvis < 40 * GeV)
862 return chargedhadrons.size() == 1 ? 1 / 20.
863 : chargedhadrons.size() == 3 ? 1 / 100.
866 return chargedhadrons.size() == 1 ? 1 / 25.
867 : chargedhadrons.size() == 3 ? 1 / 400.
871 const Particles prongs = ttags[0].stableDescendants(Cuts::charge3 > 0 && Cuts::pT > 1 * GeV
872 && Cuts::abseta < 2.5);
873 return prongs.size() == 1 ? 0.56 : 0.38;
883 if (t.
abspid() != PID::TAU)
return 0;
884 if (t.
abseta() > 2.5)
return 0;
891 if (
p.charge3() != 0 &&
p.abseta() < 2.5 &&
p.pT() > 1 * GeV) chargedhadrons +=
p;
894 if (chargedhadrons.empty())
return 0;
895 if (pThadvis < 20 * GeV)
return 0;
896 if (chargedhadrons.size() == 1)
return (t.
abspid() == PID::TAU) ? 0.55 : 0;
897 if (chargedhadrons.size() == 3)
return (t.
abspid() == PID::TAU) ? 0.40 : 0;
923 if (j.
abseta() > 2.5)
return 0;
930 if (
p.charge3() != 0 &&
p.abseta() < 2.5 &&
p.pT() > 1 * GeV) chargedhadrons +=
p;
933 if (chargedhadrons.empty())
return 0;
934 if (pThadvis < 20 * GeV)
return 0;
943 return chargedhadrons.size() == 1 ? 1 / 50. : chargedhadrons.size() == 3 ? 1 / 110. : 0;
944 const Particles prongs = ttags[0].stableDescendants(Cuts::charge3 > 0 && Cuts::pT > 1 * GeV
945 && Cuts::abseta < 2.5);
946 return prongs.size() == 1 ? 0.55 : 0.40;
968 static const vector<double> binedges_pt = {0., 50., 70., 100., 150., 200., 1000., 10000.};
969 static const vector<double> jer = {0.145, 0.115, 0.095, 0.075,
970 0.07, 0.05, 0.04, 0.04};
971 const int ipt =
binIndex(t.
pT() / GeV, binedges_pt,
true);
972 if (ipt < 0)
return t;
973 const double resolution = jer.at(ipt);
977 const double fsmear =
max(
randnorm(1., resolution), 0.);
997 if (t.
abspid() != PID::TAU)
return 0;
998 return (t.
abspid() == PID::TAU) ? 0.6 : 0;
1020 if (t.
abspid() != PID::TAU)
return 0;
1021 return (t.
abspid() == PID::TAU) ? 0.6 : 0;
1064 if (j.
abseta() > 2.5)
return 0;
1065 const auto ftagsel = [&](
const Particle&
p) {
1066 return p.pT() > 5 * GeV &&
deltaR(
p, j) < 0.3;
1068 if (j.
bTagged(ftagsel))
return 0.80 * tanh(0.003 * j.
pT() / GeV) * (30 / (1 + 0.0860 * j.
pT() / GeV));
1069 if (j.
cTagged(ftagsel))
return 0.20 * tanh(0.020 * j.
pT() / GeV) * (1 / (1 + 0.0034 * j.
pT() / GeV));
1070 return 0.002 + 7.3e-6 * j.
pT() / GeV;
1079 if (j.
abseta() > 2.5)
return 0;
1080 if (j.
bTagged(Cuts::pT > 5 * GeV))
return 0.77;
1081 if (j.
cTagged(Cuts::pT > 5 * GeV))
return 1 / 4.5;
1087 if (j.
abseta() > 2.5)
return 0;
1088 if (j.
bTagged(Cuts::pT > 5 * GeV))
return 0.77;
1089 if (j.
cTagged(Cuts::pT > 5 * GeV))
return 1 / 6.0;
1096 inline double JET_BTAG_ATLAS_RUN2_2016_MV2C10_77(
const Jet& j) {
1104 const static vector<double> binedges_pt = {0.00, 30.0, 40.00, 50.00, 60.0, 75.00,
1105 90.0, 105., 150., 200., 500};
1106 const static vector<double> eff_pt = {0.63, 0.705, 0.74, 0.76, 0.775, 0.785,
1107 0.795, 0.80, 0.79, 0.75, 0.68};
1109 return eff_pt[
binIndex(j.pt(), binedges_pt,
true)];
1111 else if (j.cTagged()) {
1115 else if (j.tauTagged()) {
1124 inline double JET_BTAG_ATLAS_RUN2_DL1d_77(
const Jet& j) {
1126 if (j.abseta() > 2.5)
return 0.;
1139 const static vector<double> binedges_pt = {0.00, 20., 30., 40., 60., 85., 110.,
1140 140., 175., 250., 400., 800., 1200., 2000.};
1141 const static vector<double> eff_pt = {0.0, 0.68, 0.74, 0.77, 0.79, 0.8, 0.81,
1142 0.81, 0.805, 0.78, 0.75, 0.7, 0.65, 0.5};
1144 return eff_pt[
binIndex(j.pt(), binedges_pt,
true)];
1146 else if (j.cTagged()) {
1151 else if (j.tauTagged()) {
1163 inline double JET_BTAG_ATLAS_RUN2_DL1r_77(
const Jet& j) {
1164 if (j.pt() <= 20 * GeV || j.abseta() > 2.5)
return 0.;
1166 const static vector<double> binedges_pt = {20., 30., 40., 60., 85., 110., 140.,
1167 175., 210., 250., 400., 600., 800., 1000.,
1168 1200., 1400., 1500., 2000.0, 3000.0};
1172 const static vector<double> eff_pt = {0.667, 0.731, 0.771, 0.791, 0.801, 0.805, 0.806,
1173 0.798, 0.795, 0.825, 0.802, 0.771, 0.741, 0.706,
1174 0.679, 0.674, 0.634, 0.5, 0.5};
1177 return eff_pt[
binIndex(j.pt(), binedges_pt,
true)];
1179 else if (j.cTagged()) {
1180 const static vector<double> c_rej_pt = {5.30, 5.23, 5.55, 5.91, 6.13, 6.30, 6.32, 6.50, 6.10, 3.04,
1181 3.05, 3.21, 3.37, 3.616, 3.83, 3.96, 4.01, 2.90, 2.90};
1183 return 1. / c_rej_pt[
binIndex(j.pt(), binedges_pt,
true)];
1186 const static vector<double> light_rej_pt = {143, 191, 239, 261, 235, 257, 248, 189, 158, 32.8,
1187 19.1, 14.2, 12.4, 11.2, 11.0, 11.2, 12.4, 8.27, 8.27};
1189 return 1. / light_rej_pt[
binIndex(j.pt(), binedges_pt,
true)];
1202 static const vector<double> binedges_pt = {0., 50., 70., 100., 150., 200., 1000., 10000.};
1203 static const vector<double> jer = {0.145, 0.115, 0.095, 0.075,
1204 0.07, 0.05, 0.04, 0.04};
1205 const int ipt =
binIndex(j.
pT() / GeV, binedges_pt,
true);
1206 if (ipt < 0)
return j;
1207 const double resolution = jer.at(ipt);
1211 const double fsmear =
max(
randnorm(1., resolution), 0.);
1251 if (met.
mod() < 25 * GeV)
1252 smeared_met *= 1.05;
1253 else if (met.
mod() < 40 * GeV)
1254 smeared_met *= (1.05 - (0.04 / 15) * (met.
mod() / GeV - 25));
1256 smeared_met *= 1.01;
1258 return {smeared_met, 0.45 * sqrt(set / GeV) * GeV, 0.0};
1278 const Vector3 smeared_met = met * (1 + 0.45 *
min(1.0, exp(-(met.
mod() - 25 * GeV) / (10 * GeV))) - 0.02);
1282 const double resolution1 = (set < 180 * GeV ? set / 180. : 1) * 0.45 * sqrt(
max(set / GeV, 180)) * GeV;
1286 const double resolution2 = 15 * GeV + 0.5 * sqrt(met.
mod() / GeV) * GeV;
1291 const double sigma =
min(resolution1, resolution2);
1293 return {smeared_met, sigma, 0.0};
1310 const Vector3 smeared_met = met * (1 + 1.15 * exp(-met.
mod() / (20 * GeV)) - 0.01);
1315 const double resolution = 20 * GeV;
1317 return {smeared_met, resolution, 0.0};
1331 const double resolution_x = (1.1 + 0.6 * sqrt(set / GeV)) * GeV;
1332 const double resolution_y = (1.4 + 0.6 * sqrt(set / GeV)) * GeV;
1333 const double resolution = sqrt(
sqr(resolution_x) +
sqr(resolution_y));
1334 return {met, resolution, 0.0};
1348 const double resolution_para = (2.0 + 0.64 * sqrt(set / GeV)) * GeV;
1349 const double resolution_perp = (-1.5 + 0.68 * sqrt(set / GeV)) * GeV;
1350 const double resolution = sqrt(
sqr(resolution_para) +
sqr(resolution_perp));
1351 return {met, resolution, 0.0};
1367 if (
p.charge3() == 0)
return 0;
1368 if (
p.abseta() > 2.5)
return 0;
1369 if (
p.pT() < 0.1 * GeV)
return 0;
1371 if (
p.abspid() == PID::ELECTRON) {
1372 if (
p.abseta() < 1.5) {
1373 if (
p.pT() < 1 * GeV)
return 0.73;
1374 if (
p.pT() < 100 * GeV)
return 0.95;
1378 if (
p.pT() < 1 * GeV)
return 0.50;
1379 if (
p.pT() < 100 * GeV)
1385 else if (
p.abspid() == PID::MUON) {
1386 if (
p.abseta() < 1.5) {
1387 return (
p.pT() < 1 * GeV) ? 0.75 : 0.99;
1390 return (
p.pT() < 1 * GeV) ? 0.70 : 0.98;
1394 if (
p.abseta() < 1.5) {
1395 return (
p.pT() < 1 * GeV) ? 0.70 : 0.95;
1398 return (
p.pT() < 1 * GeV) ? 0.60 : 0.85;
1427 if (
p.charge3() == 0)
return 0;
1428 if (
p.abseta() > 2.5)
return 0;
1429 if (
p.pT() < 0.1 * GeV)
return 0;
1431 if (
p.abspid() == PID::ELECTRON) {
1432 if (
p.abseta() < 1.5) {
1433 if (
p.pT() < 1 * GeV)
return 0.73;
1434 if (
p.pT() < 100 * GeV)
return 0.95;
1438 if (
p.pT() < 1 * GeV)
return 0.50;
1439 if (
p.pT() < 100 * GeV)
1445 else if (
p.abspid() == PID::MUON) {
1446 if (
p.abseta() < 1.5) {
1447 return (
p.pT() < 1 * GeV) ? 0.75 : 0.99;
1450 return (
p.pT() < 1 * GeV) ? 0.70 : 0.98;
1454 if (
p.abseta() < 1.5) {
1455 return (
p.pT() < 1 * GeV) ? 0.70 : 0.95;
1458 return (
p.pT() < 1 * GeV) ? 0.60 : 0.85;
1492 if (j.
abseta() > 2.4)
return 1.0;
1494 if (j.
pt() <= 20 * GeV || j.
pt() >= 60 * GeV)
return 1.0;
1496 const static vector<double> binedges_pt = {20 * GeV, 25 * GeV, 30 * GeV, 35 * GeV, 40 * GeV,
1497 45 * GeV, 50 * GeV, 55 * GeV, 60 * GeV};
1498 const static vector<double> binvals = {0.9, 0.93, 0.94, 0.95, 0.96, 0.96, 0.97, 0.97};
1500 const size_t bini =
binIndex(j.
pt(), binedges_pt);
1501 return binvals[bini];
1512 if (j.
abseta() > 2.4)
return 1.0;
1514 if (j.
pt() <= 20 * GeV || j.
pt() >= 60 * GeV)
return 1.0;
1516 const static vector<double> binedges_pt = {20 * GeV, 25 * GeV, 30 * GeV, 35 * GeV, 40 * GeV,
1517 45 * GeV, 50 * GeV, 55 * GeV, 60 * GeV};
1518 const static vector<double> binvals = {0.86, 0.9, 0.92, 0.93, 0.94, 0.95, 0.95, 0.96};
1520 const size_t bini =
binIndex(j.
pt(), binedges_pt);
1521 return binvals[bini];
1532 if (j.
abseta() > 2.4)
return 1.0;
1534 if (j.
pt() <= 20 * GeV || j.
pt() >= 60 * GeV)
return 1.0;
1536 const static vector<double> binedges_pt = {20 * GeV, 25 * GeV, 30 * GeV, 35 * GeV, 40 * GeV,
1537 45 * GeV, 50 * GeV, 55 * GeV, 60 * GeV};
1538 const static vector<double> binvals = {0.81, 0.84, 0.87, 0.90, 0.91, 0.92, 0.93, 0.94};
1540 const size_t bini =
binIndex(j.
pt(), binedges_pt);
1541 return binvals[bini];
1549 inline double ELECTRON_EFF_IDENTITY_LOOSE(
const Particle& e) {
1552 inline double ELECTRON_EFF_IDENTITY_MEDIUM(
const Particle& e) {
1555 inline double ELECTRON_EFF_IDENTITY_TIGHT(
const Particle& e) {
1558 inline double MUON_EFF_IDENTITY_LOOSE(
const Particle& m) {
1561 inline double MUON_EFF_IDENTITY_MEDIUM(
const Particle& m) {
1564 inline double MUON_EFF_IDENTITY_TIGHT(
const Particle& m) {
1567 inline double PHOTON_EFF_IDENTITY_LOOSE(
const Particle& y) {
1570 inline double PHOTON_EFF_IDENTITY_MEDIUM(
const Particle& y) {
1573 inline double PHOTON_EFF_IDENTITY_TIGHT(
const Particle& y) {
1576 inline double TAU_EFF_IDENTITY_LOOSE(
const Particle& t) {
1579 inline double TAU_EFF_IDENTITY_MEDIUM(
const Particle& t) {
1582 inline double TAU_EFF_IDENTITY_TIGHT(
const Particle& t) {
1599 inline double TRK_EFF_IDENTITY_TIGHT(
const Particle& trk) {
1606 inline double JET_BTAG_IDENTITY_IDENTITY(
const Jet& j) {
static FourMomentum mkXYZM(double px, double py, double pz, double mass)
Make a vector from (px,py,pz) coordinates and the mass.
Definition Vector4.hh:809
Representation of a clustered jet of particles.
Definition Jet.hh:47
bool cTagged(const Cut &c=Cuts::open(), double dRmax=-1) const
Does this jet have at least one c-tag? (with optional Cut and dR restriction).
Definition Jet.hh:217
Particles & particles()
Get the particles in this jet.
Definition Jet.hh:84
bool bTagged(const Cut &c=Cuts::open(), double dRmax=-1) const
Does this jet have at least one b-tag? (with optional Cut and dR restriction).
Definition Jet.hh:188
Particles tauTags(const Cut &c=Cuts::open(), double dRmax=-1) const
Get the tau particles tag-matched to this jet.
double py() const
y component of momentum.
Definition ParticleBase.hh:190
double pT() const
Get the directly (alias).
Definition ParticleBase.hh:81
double mass2() const
Get the mass**2 directly.
Definition ParticleBase.hh:116
double abseta() const
Get the directly (alias).
Definition ParticleBase.hh:133
double mass() const
Get the mass directly.
Definition ParticleBase.hh:112
double pz() const
z component of momentum.
Definition ParticleBase.hh:194
double pt() const
Get the directly.
Definition ParticleBase.hh:77
double px() const
x component of momentum.
Definition ParticleBase.hh:186
double Et() const
Get the directly.
Definition ParticleBase.hh:103
double E() const
Get the energy directly.
Definition ParticleBase.hh:59
double E2() const
Get the energy-squared.
Definition ParticleBase.hh:68
Particle representation, either from a HepMC::GenEvent or reconstructed.
Definition Particle.hh:50
PdgId pid() const
This Particle's PDG ID code.
Definition Particle.hh:221
PdgId abspid() const
Absolute value of the PDG ID code.
Definition Particle.hh:225
Particles children(const Cut &c=Cuts::OPEN) const
Get a list of the direct descendants from the current particle (with optional selection Cut).
Specialised vector of Particle objects.
Definition Particle.hh:21
Three-dimensional specialisation of Vector.
Definition Vector3.hh:39
double mod() const
Calculate the modulus of a vector. .
Definition VectorN.hh:99
double mass(const FourMomentum &a, const FourMomentum &b)
Calculate mass of two 4-vectors.
Definition Vector4.hh:1474
double p(const ParticleBase &p)
Unbound function access to p.
Definition ParticleBaseUtils.hh:819
double abseta(const ParticleBase &p)
Unbound function access to abseta.
Definition ParticleBaseUtils.hh:844
double ELECTRON_EFF_ATLAS_RUN1_MEDIUM(const Particle &e)
ATLAS Run 1 'medium' electron reco+identification efficiency.
Definition ExptSmearingFunctions.hh:95
double ELECTRON_EFF_ATLAS_RUN1_TIGHT(const Particle &e)
ATLAS Run 1 'tight' electron reco+identification efficiency.
Definition ExptSmearingFunctions.hh:174
double ELECTRON_EFF_ATLAS_RUN2_LOOSE(const Particle &e)
ATLAS Run 2 'loose' electron reco+identification efficiency.
Definition ExptSmearingFunctions.hh:67
double ELECTRON_EFF_CMS_RUN1(const Particle &e)
CMS Run 1 electron reconstruction efficiency.
Definition ExptSmearingFunctions.hh:303
Particle ELECTRON_SMEAR_ATLAS_RUN1(const Particle &e)
ATLAS Run 1 electron reco smearing.
Definition ExptSmearingFunctions.hh:268
double ELECTRON_EFF_CMS_RUN2_TIGHT(const Particle &e)
Definition ExptSmearingFunctions.hh:345
double ELECTRON_EFF_ATLAS_RUN2_TIGHT(const Particle &e)
ATLAS Run 2 'tight' electron reco+identification efficiency.
Definition ExptSmearingFunctions.hh:246
double ELECTRON_EFF_CMS_RUN1_MEDIUM(const Particle &e)
Definition ExptSmearingFunctions.hh:316
double ELECTRON_RECOEFF_ATLAS_RUN2(const Particle &e)
Definition ExptSmearingFunctions.hh:49
Particle ELECTRON_SMEAR_CMS_RUN1(const Particle &e)
CMS electron energy smearing, preserving direction.
Definition ExptSmearingFunctions.hh:356
double ELECTRON_EFF_CMS_RUN2(const Particle &e)
Definition ExptSmearingFunctions.hh:329
double ELECTRON_EFF_ATLAS_RUN2_MEDIUM(const Particle &e)
ATLAS Run 2 'medium' electron reco+identification efficiency.
Definition ExptSmearingFunctions.hh:167
double ELECTRON_EFF_CMS_RUN2_MEDIUM(const Particle &e)
Definition ExptSmearingFunctions.hh:340
Particle ELECTRON_SMEAR_ATLAS_RUN2(const Particle &e)
Definition ExptSmearingFunctions.hh:294
double ELECTRON_EFF_ATLAS_RUN1_LOOSE(const Particle &e)
Pretend that ATLAS Run 1 loose was the same as in Run 2.
Definition ExptSmearingFunctions.hh:89
double ELECTRON_EFF_CMS_RUN1_LOOSE(const Particle &e)
Definition ExptSmearingFunctions.hh:311
double ELECTRON_RECOEFF_ATLAS_RUN1(const Particle &e)
Definition ExptSmearingFunctions.hh:39
Particle ELECTRON_SMEAR_CMS_RUN2(const Particle &e)
Definition ExptSmearingFunctions.hh:382
double ELECTRON_EFF_CMS_RUN2_LOOSE(const Particle &e)
Definition ExptSmearingFunctions.hh:335
double ELECTRON_EFF_CMS_RUN1_TIGHT(const Particle &e)
Definition ExptSmearingFunctions.hh:321
Jet JET_SMEAR_ATLAS_RUN2(const Jet &j)
Definition ExptSmearingFunctions.hh:1221
double JET_BTAG_ATLAS_RUN2_MV2C20(const Jet &j)
Return the ATLAS Run 2 MC2c20 77% WP jet flavour tagging efficiency for the given Jet.
Definition ExptSmearingFunctions.hh:1078
Jet JET_SMEAR_ATLAS_RUN1(const Jet &j)
ATLAS Run 1 jet smearing.
Definition ExptSmearingFunctions.hh:1198
Jet JET_SMEAR_CMS_RUN1(const Jet &j)
Definition ExptSmearingFunctions.hh:1228
Jet JET_SMEAR_CMS_RUN2(const Jet &j)
Definition ExptSmearingFunctions.hh:1235
double JET_BTAG_ATLAS_RUN2_MV2C10(const Jet &j)
Return the ATLAS Run 2 MC2c10 77% WP jet flavour tagging efficiency for the given Jet.
Definition ExptSmearingFunctions.hh:1086
double JET_BTAG_ATLAS_RUN1_XXX(const Jet &j)
Alias for naming scheme.
Definition ExptSmearingFunctions.hh:1073
double JET_BTAG_ATLAS_RUN1(const Jet &j)
Return the ATLAS Run 1 jet flavour tagging efficiency for the given Jet, from Delphes.
Definition ExptSmearingFunctions.hh:1062
METSmearParams MET_SMEARPARAMS_ATLAS_RUN2(const Vector3 &met, double set)
Definition ExptSmearingFunctions.hh:1270
Vector3 MET_SMEAR_ATLAS_RUN2(const Vector3 &met, double set)
ATLAS Run 2 ETmiss smearing.
Definition ExptSmearingFunctions.hh:1297
Vector3 MET_SMEAR_ATLAS_RUN2_PFLOW(const Vector3 &met, double set)
ATLAS Run 2 pflow ETmiss smearing.
Definition ExptSmearingFunctions.hh:1321
METSmearParams MET_SMEARPARAMS_ATLAS_RUN2_PFLOW(const Vector3 &met, double)
Definition ExptSmearingFunctions.hh:1307
METSmearParams MET_SMEARPARAMS_ATLAS_RUN1(const Vector3 &met, double set)
ATLAS Run 1 ETmiss resolution.
Definition ExptSmearingFunctions.hh:1248
Vector3 MET_SMEAR_CMS_RUN1(const Vector3 &met, double set)
CMS Run 1 ETmiss smearing.
Definition ExptSmearingFunctions.hh:1338
Vector3 MET_SMEAR_NORM(const METSmearParams &msps)
Smear a nominal vector magnitude by Gaussian with the given absolute resolutions.
Definition MomentumSmearingFunctions.hh:185
Vector3 MET_SMEAR_ATLAS_RUN1(const Vector3 &met, double set)
ATLAS Run 1 ETmiss smearing.
Definition ExptSmearingFunctions.hh:1262
Vector3 MET_SMEAR_CMS_RUN2(const Vector3 &met, double set)
CMS Run 2 ETmiss smearing.
Definition ExptSmearingFunctions.hh:1355
METSmearParams MET_SMEARPARAMS_CMS_RUN1(const Vector3 &met, double set)
Definition ExptSmearingFunctions.hh:1329
METSmearParams MET_SMEARPARAMS_CMS_RUN2(const Vector3 &met, double set)
CMS Run 2 ETmiss smearing.
Definition ExptSmearingFunctions.hh:1346
FourMomentum P4_SMEAR_E_GAUSS(const FourMomentum &p, double resolution)
Definition MomentumSmearingFunctions.hh:76
FourMomentum P4_SMEAR_PT_GAUSS(const FourMomentum &p, double resolution)
Smear a FourMomentum's transverse momentum using a Gaussian of absolute width resolution.
Definition MomentumSmearingFunctions.hh:84
double MUON_EFF_ATLAS_RUN1_LOOSE(const Particle &m)
Definition ExptSmearingFunctions.hh:554
double MUON_EFF_ATLAS_RUN2_TIGHT(const Particle &m)
ATLAS Run 2 muon reco+ID efficiency.
Definition ExptSmearingFunctions.hh:633
Particle MUON_SMEAR_ATLAS_RUN1(const Particle &m)
Definition ExptSmearingFunctions.hh:653
Particle MUON_SMEAR_CMS_RUN1(const Particle &m)
CMS Run 1 muon reco smearing.
Definition ExptSmearingFunctions.hh:749
double MUON_EFF_ATLAS_RUN2_LOOSE(const Particle &m)
ATLAS Run 2 muon reco+ID efficiency.
Definition ExptSmearingFunctions.hh:598
double MUON_EFF_CMS_RUN2(const Particle &m)
Definition ExptSmearingFunctions.hh:725
double MUON_EFF_ATLAS_RUN1(const Particle &m)
ATLAS Run 1 muon reco efficiency.
Definition ExptSmearingFunctions.hh:546
double MUON_EFF_CMS_RUN2_TIGHT(const Particle &m)
Definition ExptSmearingFunctions.hh:743
double MUON_ISOEFF_ATLAS_RUN2_LOOSE(const Particle &m)
ATLAS Run 2 muon isolation efficiency.
Definition ExptSmearingFunctions.hh:584
double MUON_EFF_CMS_RUN2_LOOSE(const Particle &m)
Definition ExptSmearingFunctions.hh:731
Particle MUON_SMEAR_ATLAS_RUN2(const Particle &m)
Definition ExptSmearingFunctions.hh:683
double MUON_RECOEFF_ATLAS_RUN2(const Particle &m)
Definition ExptSmearingFunctions.hh:572
double MUON_EFF_CMS_RUN1(const Particle &m)
CMS Run 1 muon reco efficiency.
Definition ExptSmearingFunctions.hh:696
double MUON_EFF_CMS_RUN1_TIGHT(const Particle &m)
Definition ExptSmearingFunctions.hh:717
double MUON_EFF_ATLAS_RUN1_TIGHT(const Particle &m)
Definition ExptSmearingFunctions.hh:564
double MUON_EFF_CMS_RUN2_MEDIUM(const Particle &m)
Definition ExptSmearingFunctions.hh:737
double MUON_EFF_CMS_RUN1_LOOSE(const Particle &m)
Definition ExptSmearingFunctions.hh:705
double MUON_EFF_CMS_RUN1_MEDIUM(const Particle &m)
Definition ExptSmearingFunctions.hh:711
double MUON_EFF_ATLAS_RUN1_MEDIUM(const Particle &m)
Definition ExptSmearingFunctions.hh:559
Particle MUON_SMEAR_CMS_RUN2(const Particle &m)
Definition ExptSmearingFunctions.hh:779
double MUON_EFF_ATLAS_RUN2_MEDIUM(const Particle &m)
ATLAS Run 2 muon reco+ID efficiency.
Definition ExptSmearingFunctions.hh:613
double PARTICLE_EFF_ONE(const Particle &)
Take a Particle and return 1.
Definition ParticleSmearingFunctions.hh:39
Particle PARTICLE_SMEAR_IDENTITY(const Particle &p)
Take a Particle and return it unmodified.
Definition ParticleSmearingFunctions.hh:67
double JET_BTAG_IDENTITY(const Jet &j)
Alias for JET_BTAG_PERFECT.
Definition JetSmearingFunctions.hh:78
double PHOTON_EFF_CMS_RUN1_TIGHT(const Particle &y)
Definition ExptSmearingFunctions.hh:496
double PHOTON_EFF_CMS_RUN2_TIGHT(const Particle &y)
Definition ExptSmearingFunctions.hh:520
double PHOTON_EFF_CMS_RUN2_LOOSE(const Particle &y)
Definition ExptSmearingFunctions.hh:510
double PHOTON_EFF_ATLAS_RUN2_TIGHT(const Particle &y)
Definition ExptSmearingFunctions.hh:471
double PHOTON_EFF_ATLAS_RUN1_MEDIUM(const Particle &y)
Definition ExptSmearingFunctions.hh:424
Particle PHOTON_SMEAR_ATLAS_RUN1(const Particle &y)
Definition ExptSmearingFunctions.hh:526
double PHOTON_EFF_ATLAS_RUN1_TIGHT(const Particle &y)
Definition ExptSmearingFunctions.hh:429
double PHOTON_EFF_ATLAS_RUN2_LOOSE(const Particle &y)
Definition ExptSmearingFunctions.hh:461
double PHOTON_EFF_ATLAS_RUN2_MEDIUM(const Particle &y)
Definition ExptSmearingFunctions.hh:466
double PHOTON_EFF_ATLAS_RUN1(const Particle &y)
ATLAS Run 2 photon reco efficiency.
Definition ExptSmearingFunctions.hh:395
double PHOTON_EFF_CMS_RUN2_MEDIUM(const Particle &y)
Definition ExptSmearingFunctions.hh:515
double PHOTON_EFF_CMS_RUN1_LOOSE(const Particle &y)
Definition ExptSmearingFunctions.hh:486
double PHOTON_EFF_CMS_RUN2(const Particle &y)
Definition ExptSmearingFunctions.hh:504
double PHOTON_EFF_CMS_RUN1(const Particle &y)
Definition ExptSmearingFunctions.hh:479
double PHOTON_EFF_ATLAS_RUN2(const Particle &y)
ATLAS Run 2 photon reco efficiency.
Definition ExptSmearingFunctions.hh:437
double PHOTON_EFF_ATLAS_RUN1_LOOSE(const Particle &y)
Definition ExptSmearingFunctions.hh:419
double PHOTON_EFF_CMS_RUN1_MEDIUM(const Particle &y)
Definition ExptSmearingFunctions.hh:491
double TAU_EFF_ATLAS_RUN2_LOOSE(const Particle &t)
Definition ExptSmearingFunctions.hh:907
double TAU_EFF_ATLAS_RUN2_MEDIUM(const Particle &t)
ATLAS Run 2 13 TeV tau efficiencies (medium working point).
Definition ExptSmearingFunctions.hh:882
double TAUJET_EFF_ATLAS_RUN1(const Jet &j)
ATLAS Run 1 8 TeV tau misID rates (medium working point).
Definition ExptSmearingFunctions.hh:843
double TAU_EFF_ATLAS_RUN2_TIGHT(const Particle &t)
Definition ExptSmearingFunctions.hh:912
double TAU_EFF_ATLAS_RUN1(const Particle &t)
Definition ExptSmearingFunctions.hh:821
Particle TAU_SMEAR_CMS_RUN1(const Particle &t)
Definition ExptSmearingFunctions.hh:1043
double TAU_EFF_ATLAS_RUN1_MEDIUM(const Particle &t)
ATLAS Run 1 8 TeV tau efficiencies (medium working point).
Definition ExptSmearingFunctions.hh:796
double TAU_EFF_ATLAS_RUN1_TIGHT(const Particle &t)
Definition ExptSmearingFunctions.hh:831
Particle TAU_SMEAR_CMS_RUN2(const Particle &t)
Definition ExptSmearingFunctions.hh:1051
double TAU_EFF_CMS_RUN2_TIGHT(const Particle &t)
Definition ExptSmearingFunctions.hh:1035
double TAU_EFF_CMS_RUN1_TIGHT(const Particle &t)
Definition ExptSmearingFunctions.hh:1012
double TAU_EFF_ATLAS_RUN2(const Particle &t)
Definition ExptSmearingFunctions.hh:902
Particle TAU_SMEAR_ATLAS_RUN1(const Particle &t)
Definition ExptSmearingFunctions.hh:953
double TAUJET_EFF_ATLAS_RUN2(const Jet &j)
ATLAS Run 2 13 TeV tau misID rate (medium working point).
Definition ExptSmearingFunctions.hh:922
double TAU_EFF_ATLAS_RUN1_LOOSE(const Particle &t)
Definition ExptSmearingFunctions.hh:826
double TAU_EFF_CMS_RUN1_LOOSE(const Particle &t)
Definition ExptSmearingFunctions.hh:1002
double TAU_EFF_CMS_RUN2(const Particle &t)
Definition ExptSmearingFunctions.hh:1019
double TAU_EFF_CMS_RUN2_MEDIUM(const Particle &t)
Definition ExptSmearingFunctions.hh:1030
double TAU_EFF_CMS_RUN1_MEDIUM(const Particle &t)
Definition ExptSmearingFunctions.hh:1007
double TAU_EFF_CMS_RUN2_LOOSE(const Particle &t)
Definition ExptSmearingFunctions.hh:1025
double TAU_EFF_CMS_RUN1(const Particle &t)
Definition ExptSmearingFunctions.hh:996
Particle TAU_SMEAR_ATLAS_RUN2(const Particle &t)
Definition ExptSmearingFunctions.hh:988
double ATLAS_JVT_EFF_MEDIUM(const Jet &j)
Return the efficiency of the ATLAS JVT tagger at > 0.4 W.P.
Definition ExptSmearingFunctions.hh:1511
Particle TRK_SMEAR_CMS_RUN2(const Particle &t)
Definition ExptSmearingFunctions.hh:1480
double TRK_EFF_CMS_RUN2(const Particle &p)
Definition ExptSmearingFunctions.hh:1466
Particle TRK_SMEAR_ATLAS_RUN1(const Particle &t)
Definition ExptSmearingFunctions.hh:1414
double ATLAS_JVT_EFF_TIGHT(const Jet &j)
Return the efficiency of the ATLAS JVT tagger at > 0.7 W.P.
Definition ExptSmearingFunctions.hh:1531
double TRK_EFF_CMS_RUN1(const Particle &p)
CMS Run 1 tracking efficiency.
Definition ExptSmearingFunctions.hh:1426
double ATLAS_JVT_EFF_LOOSE(const Jet &j)
Return the efficiency of the ATLAS JVT tagger at > 0.2 W.P.
Definition ExptSmearingFunctions.hh:1491
Particle TRK_SMEAR_CMS_RUN1(const Particle &t)
Definition ExptSmearingFunctions.hh:1474
Particle TRK_SMEAR_ATLAS_RUN2(const Particle &t)
Definition ExptSmearingFunctions.hh:1420
double TRK_EFF_ATLAS_RUN1(const Particle &p)
ATLAS Run 1 tracking efficiency.
Definition ExptSmearingFunctions.hh:1366
double TRK_EFF_ATLAS_RUN2(const Particle &p)
Definition ExptSmearingFunctions.hh:1406
Definition LHCbCommon.hh:9
double deltaR(double rap1, double phi1, double rap2, double phi2)
Definition MathUtils.hh:754
std::enable_if_t< std::is_arithmetic_v< N1 > &&std::is_arithmetic_v< N2 >, signed_if_mixed_t< N1, N2 > > max(N1 a, N2 b)
Get the maximum of two numbers.
Definition MathUtils.hh:124
std::enable_if_t< std::is_arithmetic_v< NUM >, NUM > add_quad(NUM a, NUM b)
Named number-type addition in quadrature operation.
Definition MathUtils.hh:260
std::enable_if_t< std::is_arithmetic_v< NUM >, NUM > sqr(NUM a)
Named number-type squaring operation.
Definition MathUtils.hh:237
double randnorm(double loc, double scale)
Return a random number sampled from a Gaussian/normal distribution.
std::enable_if_t< std::is_arithmetic_v< N1 > &&std::is_arithmetic_v< N2 >, signed_if_mixed_t< N1, N2 > > min(N1 a, N2 b)
Get the minimum of two numbers.
Definition MathUtils.hh:113
std::enable_if_t< std::is_arithmetic_v< N1 > &&std::is_arithmetic_v< N2 > &&std::is_arithmetic_v< N3 >, bool > inRange(N1 value, N2 low, N3 high, RangeBoundary lowbound=CLOSED, RangeBoundary highbound=OPEN)
Determine if value is in the range low to high, for floating point numbers.
Definition MathUtils.hh:147
constexpr double SQRT2
A pre-defined value of .
Definition MathConstants.hh:22
std::enable_if_t< std::is_arithmetic_v< NUM1 > &&std::is_arithmetic_v< NUM2 >, int > binIndex(NUM1 val, std::initializer_list< NUM2 > binedges, bool allow_overflow=false)
Return the bin index of the given value, val, given a vector of bin edges.
Definition MathUtils.hh:503
Struct for holding MET-smearing parameters.
Definition MomentumSmearingFunctions.hh:150