CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
MuMatchWindow.h
Go to the documentation of this file.
1 #ifndef L1Trigger_L1TTrackMatch_MUMATCHWINDOW_H
2 #define L1Trigger_L1TTrackMatch_MUMATCHWINDOW_H
3 
4 #include "TF1.h"
5 #include <string>
6 #include <memory>
7 #include <iostream>
8 
9 /*
10 ** class : MuMatchWindow
11 ** author : L.Cadamuro (UF)
12 ** date : 25/12/2018
13 ** brief : encodes the lower, central, and upper bounds to match a track to a muon
14 ** to be flexible, limits are given as strings to create a TF1 function
15 */
16 
18 public:
19  MuMatchWindow();
22  void SetName(std::string name) { name_ = name; }
23 
27 
28  void SetLower(TF1* formula);
29  void SetCentral(TF1* formula);
30  void SetUpper(TF1* formula);
31 
32  // bool matches (double pt);
33  const double bound_low(double pt) { return fLow_->Eval(pt); }
34  const double bound_cent(double pt) { return fCent_->Eval(pt); }
35  const double bound_high(double pt) { return fHigh_->Eval(pt); }
36 
37 private:
39  std::shared_ptr<TF1> fLow_;
40  std::shared_ptr<TF1> fCent_;
41  std::shared_ptr<TF1> fHigh_;
42 };
43 
44 #endif
std::shared_ptr< TF1 > fCent_
Definition: MuMatchWindow.h:40
const double bound_cent(double pt)
Definition: MuMatchWindow.h:34
const double bound_low(double pt)
Definition: MuMatchWindow.h:33
void SetLower(std::string formula)
Definition: MuMatchWindow.cc:9
std::shared_ptr< TF1 > fHigh_
Definition: MuMatchWindow.h:41
void SetUpper(std::string formula)
std::shared_ptr< TF1 > fLow_
Definition: MuMatchWindow.h:39
const double bound_high(double pt)
Definition: MuMatchWindow.h:35
void SetName(std::string name)
Definition: MuMatchWindow.h:22
void SetCentral(std::string formula)
std::string name_
Definition: MuMatchWindow.h:38