Dear experts,
I am trying to do convolution of a multidimensional p.d.f. as described in the RooFit manual:
M(x,y) = T(x,y) (X) R(x)
I am successful in convolving a 2D p.d.f. with a 1D p.d.f. However, my case calls for convolution of a 3D p.d.f. with 1D p.d.f., like:
M(x,y,z) = T(x,y,z) (X) R(x)
When I do this convolution I don’t have any problems until I try to generate some events. Please see the code snippet at the bottom of the message. My error occurs at the last line and at this point I get an error which says:
[#0] ERROR:InputArguments -- RooDataHist::weight(myPdfConv_myPDF_CONV_gauss_CACHEHIST_Obs[Y,hs,m]_BufFrac0.1_BufStrat0) interpolation in 3 dimensions not yet implemented
My question is if this is the expected behavior. Is that something that has not been implemented yet? Meaning, I can do 2D (X) 1D, but not 3D (X) 1D. Or have I simply misconfigured something to receive this error.
Thanks!
...
...
// S e t u p c o m p o n e n t p d f s
// ---------------------------------------
// Construct observable
RooRealVar Y("Y","Y",-2.5,2.5) ;
RooRealVar m("m","m",71.,111.) ;
RooRealVar hs("hs","hs",-1.,1.) ;
// Construct custom PDF
RooRealVar par1("par1","par1",0.25,0.,1.) ;
RooRealVar par2("par2","par2",2.4357,0.1,10) ;
RooRealVar par3("par3","par3",2.1,0.1,10.) ;
RooZxsec myPdf("myPDF","myPDF", Y, m, hs, par1, par2, par3);
par2.setConstant( kTRUE );
par3.setConstant( kTRUE );
// Construct gauss(t,mg,sg)
RooRealVar mg("mg","mg",0) ;
RooRealVar sg("sg","sg",2,0.1,10) ;
RooGaussian gauss("gauss","gauss",m,mg,sg) ;
mg.setConstant( kTRUE );
sg.setConstant( kTRUE );
// C o n s t r u c t c o n v o l u t i o n p d f
// ---------------------------------------
// Set #bins to be used for FFT sampling to 10000
m.setBins(1000,"cache") ;
// Construct landau (x) gauss
RooFFTConvPdf myPdfConv("myPdfConv","Zxsec (X) gauss", m, myPdf, gauss) ;
myPdfConv.setCacheObservables( RooArgSet(Y,hs) );
// S a m p l e , f i t a n d p l o t c o n v o l u t e d p d f
// ----------------------------------------------------------------------
// Sample 1000 events in x from gxlx
RooDataSet* data = myPdfConv.generate(RooArgSet(Y,m,hs),1000) ;
...
...