void test_GraphConv() { double x[10]={0,1,2,3,4,5,6,7,8,9}; double y[10]; for (int i = 0; i < 10; i++) y[i] = std::exp( -x[i]/10 ); auto g = new TGraph(10,x,y); auto f1 = new TF1("f1",[&](double *xx, double *){ return g->Eval(xx[0]); },0,10,0); auto f2 = new TF1("f2","gaus"); auto conv = new TF1Convolution(f1,f2,-5,15,true); auto funcConv = new TF1("funcConv",*conv, 0., 10, conv->GetNpar()); funcConv->SetParameters(1,0,3); // amplitude, mean and sigma of gaussian funcConv->Print("V"); // need to use drawclone because hraph object will be deleted funcConv->DrawClone(); }