Likelihood fit changes signals order

Dear Rooters,

Fitting two Breit-Wigner signals using likelihood method “L”, defined as signal1 + signal2 + background with initial parameters signal1:(norm p0, gamma p1, mean p2) and signal2:(norm p3, gamma p4, mean p5), background:(p6, p7, p8, p9), I get signal1 around p5 and signal2 around p2, that is, the signals get swapped? Why? Using the Chi2 method the signal fits get the right order.

I appreciate,
Luiz


Please read tips for efficient and successful posting and posting code

ROOT Version: 6.24/06
Platform: Fedora 35
Compiler: c++ (GCC) 11.2.1 20210728 (Red Hat 11.2.1-1)


I think @moneta can help.