24 using namespace RooFit;
26 void rf208_convolution()
32 RooRealVar t(
"t",
"t", -10, 30);
35 RooRealVar ml(
"ml",
"mean landau", 5., -20, 20);
36 RooRealVar sl(
"sl",
"sigma landau", 1, 0.1, 10);
37 RooLandau landau(
"lx",
"lx", t, ml, sl);
40 RooRealVar mg(
"mg",
"mg", 0);
41 RooRealVar sg(
"sg",
"sg", 2, 0.1, 10);
42 RooGaussian gauss(
"gauss",
"gauss", t, mg, sg);
48 t.setBins(10000,
"cache");
51 RooFFTConvPdf lxg(
"lxg",
"landau (X) gauss", t, landau, gauss);
57 RooDataSet *data = lxg.generate(t, 10000);
63 RooPlot *frame = t.frame(Title(
"landau (x) gauss convolution"));
66 landau.plotOn(frame, LineStyle(kDashed));
69 new TCanvas(
"rf208_convolution",
"rf208_convolution", 600, 600);
70 gPad->SetLeftMargin(0.15);
71 frame->GetYaxis()->SetTitleOffset(1.4);