Incoherent fit results using simultaneous PDFs

Hi!

I’m trying to fit a set of similar histograms with a simultaneous fit.
The idea is that some of the PDF are connected by some of their parameters (e.g. shape parameters, normalization,…).

When I tried this, I noticed that the result of the simultaneous fits, done leaving all PDF parameters independent, were different from the ones obtained by independent fits.
This is not what I expected, so I reduced this test to a minimal level.

Approach 1:

  • get a TH1D and create a RooDataHist from that
  • define a signal+background PDF
  • fit the data with the PDF

Approach 2:

  • define a RooCategory with just one entry
  • create a RooDataHist from the category and one TH1D
  • define a signal+background PDF and import it into a RooSimultaneous
  • fit the multiple RooDataHist (with just one entry) with the simultaneous PDF

I would expect these two approaches to give me the same results, but this is not the case.
Below you can find fit results for the two approaches and in attachment all that’s needed to reproduce my test.
Any suggestion?
Thanks a lot in advance,

Carlo

FIT RESULTS - APPROACH 1

FCN=-259803 FROM MINOS STATUS=SUCCESSFUL 648 CALLS 1206 TOTAL
EDM=1.53586e-05 STRATEGY= 1 ERROR MATRIX ACCURATE
EXT PARAMETER PARABOLIC MINOS ERRORS
NO. NAME VALUE ERROR NEGATIVE POSITIVE
1 alpha_7 5.19399e-01 2.03493e-02 -2.02681e-02 2.04961e-02
2 beta_7 1.42810e-02 2.18404e-03 -2.18181e-03 2.19413e-03
3 mean_7 1.45462e+02 1.36663e-02 -1.36441e-02 1.38302e-02
4 nbkg_7 3.55175e+04 2.12777e+02 -2.12006e+02 2.13572e+02
5 nsig_7 4.72814e+03 1.20367e+02 -1.19763e+02 1.20982e+02
6 sigma_7 4.83299e-01 1.57096e-02 -1.55017e-02 1.59386e-02

FIT RESULTS - APPROACH 2

FCN=-260010 FROM MINOS STATUS=SUCCESSFUL 746 CALLS 1374 TOTAL
EDM=0.000255443 STRATEGY= 1 ERROR MATRIX ACCURATE
EXT PARAMETER PARABOLIC MINOS ERRORS
NO. NAME VALUE ERROR NEGATIVE POSITIVE
1 alpha_7 5.53903e-01 2.10536e-02 -2.07505e-02 2.14097e-02
2 beta_7 1.39648e-02 2.22802e-03 -2.19697e-03 2.26473e-03
3 mean_7 1.45586e+02 1.39986e-02 -1.39731e-02 1.40518e-02
4 nbkg_7 3.53941e+04 2.13380e+02 -2.12937e+02 2.13902e+02
5 nsig_7 4.85203e+03 1.22447e+02 -1.22082e+02 1.22851e+02
6 sigma_7 4.97277e-01 1.61047e-02 -1.58633e-02 1.63751e-02
testFit.root (14.3 KB)
test_minimal.C (3.07 KB)