Difficulty in fitting convoluted function

ROOT Version: 6.24/00
Platform: 5.17.12-100.fc34.x86_64
Compiler: gcc version 11.3.1 20220421 (Red Hat 11.3.1-2) (GCC)

Hi RooFit experts,

I am trying to fit data ( test.txt) with a gaussian convoluted with exponential function using the macro attached below.

gexp_conv.C (2.2 KB)

However, neither I am able to see the correct distribution as expected from the data nor the fit.
Can you please help? This is my first time with RooFit!

Any help is highly appreciated.

Thanking you.

With best regards,

Ajay

I think @moneta can help you.

@couet @moneta

I think I have made some progress in fitting gaussian convoluted exponential to the data
[test.txt (10.0 KB)] using the modified
the version of the earlier code which is [gexp_conv.C (2.8 KB)].

However, the fit is still very poor. It would be of great help you could guide me on how to improve the fit.

Thanking you.

Hello @ajaydeo,

thanks for following up and sorry for the late reply!

The problem with your fit is that the model is not appropriate for your data, at least with how the exponential is defined in RooFit. A RooExponential has no boundaries, so it is increasing to the left forever. This can’t fit your data.

Another RooFit user worked around this by multiplying the exponential with a step function before the convolution:

I have adapted your script to do this too, and also improved the parameter boundaries a bit. The fit now looks like this:
gexp_conv.C (3.0 KB)

Looks already a bit better! But still doesn’t fit perfectly. Maybe you need to include a second Gaussian.

Hope this helps!
Jonas

@jonas
Thank you very much for your reply and the improved macro.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.