I have a question regarding the behaviour of RooFFTConvPdf which probably stems from an inherent misunderstanding of how the convolution process works, but here goes.
I want to convolve a “physics” pdf with another “resolution” pdf which depends on the value of the physics pdf observable. More concretely, if the observable is x, I want to convolve with a gaussian with a width which varies as a function of x. i.e.
f(x) (x) g(x’;mean = 0, sigma(x))
Here x and x’ refer to the same observable i.e. the same RooRealVar, but I don’t think they should be interpreted as identical for sampling of the resolution pdf. Accordingly, my question relates to how RooFFTConvPdf samples the input pdfs. Will it resample the resolution pdf for every value of x and correctly substitute that value of x into sigma (i.e. effectively convolving with different symmetric gaussian at each x) or will it instead sample the resolution pdf once and calculate sigma(x’) (i.e. convolving with the same skewed gaussian at all x)? Here’s come code which may do what I want (it compiles and runs fine at least!).
[code]// Set Up Common Variables
RooRealVar energy(“energy”, “Photon Energy”, 1e-3, 200e-3, “TeV”);
// Set up Power law physics model
RooRealVar plIndex(“plIndex”, “Power Law Spectral Index”, -2, -100000, -0.01);
RooGenericPdf spec(“spec”, “pow(@0,@1)”, RooArgList(energy, plIndex));
// Set up gaussian resolution model
RooProduct resSigNC(“resSigNC”, “Resolution Model Sigma Without Offset”, RooArgSet(energy, RooConst(0.1)));
RooAddition resSigma(“resSigma”, “Resolution Model Sigma”, RooArgSet(resSigNC, RooConst(1e-4)));
RooGaussian resMod(“resMod”, “Resolution Model”, energy, RooConst(0.0), resSigma);
// Set energy binning to adequate resolution
// Set up smeared power law model
RooFFTConvPdf smearedSpec(“smearedSpec”, “Smeared Spectrum”, energy, spec, resMod);
RooPlot * eFrame = energy.frame();
It’s not completely clear to me whether RooFFTConvPdf is doing what I want or not. Perhaps what I want to do is in fact a 2D convolution?
Any help would be much appreciated,