Hi,
I want to calculate the maxima of a function. But when I apply the below code it gives the highest value of x in the range ( 4 here in the macro). Can you please tell me how to do it.
TF1 *f3 = new TF1(“f3”,“f0/f1”,0,4.); // Division of two functions
Double_t c = f3->GetMaximumX(); //GetXmax();
std::cout << "c = "<< c << std::endl;
The answer I get is c = 4. The analytical answer of 1.02.
Thank you
Please read tips for efficient and successful posting and posting code
ROOT Version: Not Provided
Platform: Not Provided
Compiler: Not Provided