Problem in running selector code

Dear Experts,

I am running selector code for fitting gen angular variables. I have used the function

RooGenericPdf f(“f”, “1/(2PI) + (1/(2PI))s3cos(2genAngPhi) + (1/(2PI))a9sin(2*genAngPhi)”, RooArgSet(genAngPhi,s3,a9));

It is compiling but when I am running it is giving error as shown below. I have defined PI as “#define PI 3.14159265358979”. Could you please tell me how to solve this issue?

Error in RooFormula::Compile: Bad numerical expression : “PI”
[#0] ERROR:InputArguments – RooFormula::RooFormula(f): compile error
[#0] ERROR:Eval – RooFormula::eval(f): Formula doesn’t compile: 1/(2PI) + (1/(2PI))s3cos(2genAngPhi) + (1/(2PI))a9sin(2*genAngPhi)

Try to use TMath::Pi() instead.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.