CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
ZMuMuFunction.h
Go to the documentation of this file.
1 #ifndef ElectroWeakAnalysis_ZMuMu_ZMuMuFunction_h
2 #define ElectroWeakAnalysis_ZMuMu_ZMuMuFunction_h
7 #include <boost/shared_ptr.hpp>
8 
9 namespace function {
10  class ZMuMuFunction {
11  public:
12  static const unsigned int arguments = 1;
13  ZMuMuFunction(const Parameter & m, const Parameter & g,
14  const Parameter & Ng, const Parameter & Ni,
15  const Parameter & me, const Parameter & s,
16  const Parameter & N, const Parameter & eff_tr, const Parameter & eff_sa):
17  mass(m.ptr()), width(g.ptr()),
18  Ngamma(Ng.ptr()), Nint(Ni.ptr()),
19  mean(me.ptr()), sigma(s.ptr()),
20  numberOfEvents(N.ptr()),
21  efficiencyTrack(eff_tr.ptr()), efficiencyStandalone(eff_sa.ptr()),
22  zls_(m, g, Ng, Ni), gau_(me, s),
23  cgz_(zls_, gau_, -3*s.value(), 3*s.value(), 200) {}
24  ZMuMuFunction(boost::shared_ptr<double> m, boost::shared_ptr<double> g,
25  boost::shared_ptr<double> Ng, boost::shared_ptr<double> Ni,
26  boost::shared_ptr<double> me, boost::shared_ptr<double> s,
27  boost::shared_ptr<double> N,
28  boost::shared_ptr<double> eff_tr, boost::shared_ptr<double> eff_sa):
29  mass(m), width(g),
30  Ngamma(Ng), Nint(Ni),
31  mean(me), sigma(s),
32  numberOfEvents(N),
33  efficiencyTrack(eff_tr), efficiencyStandalone(eff_sa),
34  zls_(m, g, Ng, Ni), gau_(me, s),
35  cgz_(zls_, gau_, -3*(*s), 3*(*s), 200) {}
36  double operator()(double x) const {
37  double eff_tr_2 = *efficiencyTrack * (*efficiencyTrack);
38  double eff_sa_2 = *efficiencyStandalone * (*efficiencyStandalone);
39  return cgz_(x) * (*numberOfEvents) * eff_tr_2 * eff_sa_2;
40  }
41  boost::shared_ptr<double> mass, width, Ngamma, Nint, mean, sigma;
43  private:
44  ZLineShape zls_;
46  Convolution<ZLineShape, Gaussian> cgz_;
47  };
48 }
49 
50 #endif
double operator()(double x) const
Definition: ZMuMuFunction.h:36
boost::shared_ptr< double > Ngamma
Definition: ZMuMuFunction.h:41
Definition: vlib.h:257
Double_t Gaussian(Double_t *x, Double_t *par)
boost::shared_ptr< double > sigma
Definition: ZMuMuFunction.h:41
boost::shared_ptr< double > Nint
Definition: ZMuMuFunction.h:41
boost::shared_ptr< double > mass
Definition: ZMuMuFunction.h:41
ZMuMuFunction(boost::shared_ptr< double > m, boost::shared_ptr< double > g, boost::shared_ptr< double > Ng, boost::shared_ptr< double > Ni, boost::shared_ptr< double > me, boost::shared_ptr< double > s, boost::shared_ptr< double > N, boost::shared_ptr< double > eff_tr, boost::shared_ptr< double > eff_sa)
Definition: ZMuMuFunction.h:24
The Signals That Services Can Subscribe To This is based on ActivityRegistry and is current per Services can connect to the signals distributed by the ActivityRegistry in order to monitor the activity of the application Each possible callback has some defined which we here list in angle e g
Definition: Activities.doc:4
boost::shared_ptr< double > width
Definition: ZMuMuFunction.h:41
Convolution< ZLineShape, Gaussian > cgz_
Definition: ZMuMuFunction.h:46
boost::shared_ptr< double > mean
Definition: ZMuMuFunction.h:41
boost::shared_ptr< double > efficiencyStandalone
Definition: ZMuMuFunction.h:42
static const unsigned int arguments
Definition: ZMuMuFunction.h:12
#define N
Definition: blowfish.cc:9
boost::shared_ptr< double > numberOfEvents
Definition: ZMuMuFunction.h:42
ZMuMuFunction(const Parameter &m, const Parameter &g, const Parameter &Ng, const Parameter &Ni, const Parameter &me, const Parameter &s, const Parameter &N, const Parameter &eff_tr, const Parameter &eff_sa)
Definition: ZMuMuFunction.h:13
boost::shared_ptr< double > efficiencyTrack
Definition: ZMuMuFunction.h:42
x
Definition: VDTMath.h:216