Hello,
I’m trying to use RooAddPdf to do a template fit, where some “processes” I’d like to fit are quantum interferences (i.e. can yield negative “event numbers”)… Note that the total event number will always be positive.
For simplicity’s sake, let’s consider the case where I only have one background (“TT”, with the constant coefficient “TT_var” set to 1) and one interference contribution (“OC8ut”, with the coefficient “OC8ut_var” which can be negative). I defined the RooRealVar corresponding to “OC8ut_var” with a range from -5 to 5. With PDFs defined from histograms corresponding to each “process”, the model is then: OC8ut_var * OC8ut_histPdf + TT_var * TT_histPdf.
These are the errors I get:
[#0] WARNING:Minization -- RooFitGlue: Minimized function has error status.
Returning maximum FCN so far (178074) to force MIGRAD to back out of this region. Error log follows
Parameter values: OC8ut_var=-0.293208
RooNLLVar::nll_Template_model_data_hist[ paramSet=(OC8ut_var,TT_var) ]
function value is NAN @ paramSet=(OC8ut_var = -0.293208,TT_var = 1)
RooAddPdf::Template_model[ OC8ut_var * OC8ut_histPdf + TT_var * TT_histPdf ]
p.d.f value is less than zero (-0.000068), forcing value to zero @ !refCoefNorm=(), !pdfs=(OC8ut_histPdf = 0.0704018/78.2799,TT_histPdf = 6.82026/31612.8), !coefficients=(OC8ut_var = -0.293208,TT_var = 1)
getLogVal() top-level p.d.f evaluates to zero @ !refCoefNorm=(), !pdfs=(OC8ut_histPdf = 0.0704018/78.2799,TT_histPdf = 6.82026/31612.8), !coefficients=(OC8ut_var = -0.293208,TT_var = 1)
Is there a way to use RooAddPdf with negative coefficients? If not, what do you think would be the best way to do this fit?
I can provide additional information if needed.
Cheers,
Sébastien