CMS 3D CMS Logo

Residual.h
Go to the documentation of this file.
1 #ifndef L1Trigger_TrackFindingTracklet_interface_Residual_h
2 #define L1Trigger_TrackFindingTracklet_interface_Residual_h
3 
5 
6 #include <cassert>
7 
8 namespace trklet {
9 
10  class Settings;
11  class Stub;
12 
13  class Residual {
14  public:
15  Residual() { valid_ = false; }
16 
17  ~Residual() = default;
18 
19  void init(Settings const& settings,
20  unsigned int layerdisk,
21  int iphiresid,
22  int irzresid,
23  int istubid,
24  double phiresid,
25  double rzresid,
26  double phiresidapprox,
27  double rzresidapprox,
28  const Stub* stubptr);
29 
30  bool valid() const { return valid_; }
31 
32  const FPGAWord& fpgaphiresid() const {
33  assert(valid_);
34  return fpgaphiresid_;
35  };
36 
37  const FPGAWord& fpgarzresid() const {
38  assert(valid_);
39  return fpgarzresid_;
40  };
41 
42  const FPGAWord& fpgastubid() const {
43  assert(valid_);
44  return fpgastubid_;
45  };
46 
47  double phiresid() const {
48  assert(valid_);
49  return phiresid_;
50  };
51 
52  double rzresid() const {
53  assert(valid_);
54  return rzresid_;
55  };
56 
57  double phiresidapprox() const {
58  assert(valid_);
59  return phiresidapprox_;
60  };
61 
62  double rzresidapprox() const {
63  assert(valid_);
64  return rzresidapprox_;
65  };
66 
67  const Stub* stubptr() const {
68  assert(valid_);
69  return stubptr_;
70  }
71 
72  protected:
73  bool valid_;
74 
75  unsigned int layerdisk_;
76 
80 
81  double phiresid_;
82  double rzresid_;
83 
86 
87  const Stub* stubptr_;
88  };
89 
90 }; // namespace trklet
91 #endif
double phiresid() const
Definition: Residual.h:47
double phiresid_
Definition: Residual.h:81
const FPGAWord & fpgastubid() const
Definition: Residual.h:42
double rzresid() const
Definition: Residual.h:52
FPGAWord fpgastubid_
Definition: Residual.h:79
const FPGAWord & fpgaphiresid() const
Definition: Residual.h:32
const Stub * stubptr_
Definition: Residual.h:87
void init(Settings const &settings, unsigned int layerdisk, int iphiresid, int irzresid, int istubid, double phiresid, double rzresid, double phiresidapprox, double rzresidapprox, const Stub *stubptr)
Definition: Residual.cc:7
double phiresidapprox_
Definition: Residual.h:84
assert(be >=bs)
FPGAWord fpgaphiresid_
Definition: Residual.h:77
const FPGAWord & fpgarzresid() const
Definition: Residual.h:37
~Residual()=default
FPGAWord fpgarzresid_
Definition: Residual.h:78
double phiresidapprox() const
Definition: Residual.h:57
double rzresidapprox() const
Definition: Residual.h:62
double rzresidapprox_
Definition: Residual.h:85
double rzresid_
Definition: Residual.h:82
const Stub * stubptr() const
Definition: Residual.h:67
bool valid() const
Definition: Residual.h:30
unsigned int layerdisk_
Definition: Residual.h:75