Jour2: "corrected" myfunc.C ne compile pas!!!

Bug #1398818 reported by John Frankland on 2014-12-03
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Formation ROOT
Daniel Cussol
Daniel Cussol

Bug Description

La version compilable de myfunc.C (p.27) devrait être:

#include "TF1.h"
#include "TH1.h"
#include "TROOT.h" // <============= missing!

Double_t myfunction(Double_t *x, Double_t *par)
 Float_t xx = x[0];
 Double_t f = TMath::Abs(par[0]*sin(par[1]*xx)/xx);
 return f;
void makefunc()
   TF1* f1 = new TF1("func",myfunction,0,10,2);
   f1->SetParNames("constant", "coefficient");
void myfit()
   TH1F* h1 = new TH1F("h1","test",100,0,10);
   TF1* f1 = (TF1*)gROOT->GetFunction("func"); //<=====renvoie TObject* !!

description: updated
Daniel Cussol (cussol) wrote :

Le transparent a été corrigé.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers