Understanding NBD Fit parameters

ROOT Version: 6.32.04
Platform: WSL2 Ubuntu

Hello! I am performing an NBD fit to a charged hadron multiplicity curve. I define a fit function:

// Fitting function
TF1 *fist = new TF1("fist", "[0]*ROOT::Math::negative_binomial_pdf([1],[2],x)", 0, 60);

And then perform the fit with initial guesses for the variables.

// Input fit params
fist->SetParameter(0,1);		// normalisation parameter
fist->SetParameter(1,15);		// k - shape parameter
fist->SetParameter(2,0.5);		// p - probability parameter
// Perform fitting
hist->Fit("fist", "R0");

My doubts:

1 - As I understand the documentation, the negative_binomial_pdf accepts (k,p,n) respectively. Initially, I kept n as a parameter (by setting it to [3]). However, this did not work. After tweaking, I observed that setting n as x solves the issue. But I do not understand why?

2 - Is there a way to improve the fit further? Provided the plot below for reference.

Looking forward to any inputs since I am still new to ROOT. Thanks in advance!

Hello,

Thanks for the post and welcome to ROOT’s Community!
Interesting LEP fit.

  1. The fit procedure leads to estimates of the parameters values and uncertainties: how you set it up (what are variables or parameters is up to you)
  2. Hard to say… Depends on many factors: try to inspect the output of the minimizer to see if the fit converged correctly, for example.

Cheers,
D

Hi @Danilo,

Thanks for the response! I have a few follow-ups:

1 - To rephrase, do you perhaps know why using [0]*ROOT::Math::negative_binomial_pdf([1],[2],[3]) leads to the bad fit result shown below,

… while using [0]*ROOT::Math::negative_binomial_pdf([1],[2],x) solves the issue?

As per the literature, using k,n as parameters for nCh curves is best. However, the only definition that works for me in ROOT requires n as an independent variable and k,p to be set.


(from a Los Alamos paper, can’t add a link as a new user)

2 - I will check this out, thank you.

Hope the question is clearer now. I want to build a qualitative understanding of how to use variables and parameters.

Cheers, Philip