-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy patheffMasses.cxx
73 lines (59 loc) · 1.93 KB
/
effMasses.cxx
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
/*****************************************************************************
* Project: RooFit *
* *
* This code was autogenerated by RooClassFactory *
*****************************************************************************/
// Your description goes here...
#include "Riostream.h"
#include "effMasses.h"
#include "RooAbsReal.h"
#include "RooAbsCategory.h"
#include <math.h>
#include "TMath.h"
ClassImp(effMasses)
effMasses::effMasses(const char *name, const char *title,
RooAbsReal& _x,
RooAbsReal& _y,
RooRealVar* _x2,
RooRealVar* _y2,
RooAbsPdf* _effDalitz) :
RooAbsPdf(name,title),
x("x","x",this,_x),
y("y","y",this,_y),
//x2("x2","x2",this,_x2),
//y2("y2","y2",this,_y2),
x2(_x2),
y2(_y2),
effDalitz(_effDalitz)
{
}
effMasses::effMasses(const effMasses& other, const char* name) :
RooAbsPdf(other,name),
x("x",this,other.x),
y("y",this,other.y),
//x2("x2",this,other.x2),
//y2("y2",this,other.y2),
x2(other.x2),
y2(other.y2),
effDalitz(other.effDalitz)
{
}
Double_t effMasses::evaluate() const
{
// ENTER EXPRESSION IN TERMS OF VARIABLE ARGUMENTS HERE
x2->setVal( x*x ) ;
y2->setVal( y*y );
RooArgSet nSet(*x2,*y2);
Double_t detJ = 1; detJ = 4*x*y;
if (effDalitz) {
//cout <<"effDalitz->getValV() = " <<effDalitz->getValV() <<endl;
//cout <<"effDalitz->getVal() = " <<effDalitz->getVal() <<endl;
//return detJ * effDalitz->getVal() ;
return effDalitz->getVal()/detJ ;
//return effDalitz->getValV() ;
//return effDalitz->getValV( &nSet ) ;
} else {
cout <<"\"effDalitz\" pdf pointer = 0! Aborting" <<endl;
abort();
}
}