# TGenPhaseSpace decay: why outcome depends on the order of Lorentzvectors defined

I am using the class TGenPhaseSpace for a 3 body decay of 7Li. Here the energy spectra obtained for decay particles should not depend on the order at which I am defining the corresponding Lorentzvectors. However, I am seeing a difference in the energy spectra when I’m changing the order. For example, the following are the lines from my code where the order is first N1, then D1 and then A2.

``````TLorentzVector Li7(0.0,0.0,0.0,m7li+Ex2);
Double_t m1[3] = {mn, md, ma};
TGenPhaseSpace A2D1N1;

A2D1N1.SetDecay(Li7,3,m1);
A2D1N1.Generate();  //--------------------- n+d+alpha decay of 7Li  ************
TLorentzVector *N1 = A2D1N1.GetDecay(0);
TLorentzVector *D1 = A2D1N1.GetDecay(1);
TLorentzVector *A2 = A2D1N1.GetDecay(2);
Using this I'm getting an energy output for N1.
Now if I change it to say D1, then N1 and then A2 then the code will be:
TLorentzVector Li7(0.0,0.0,0.0,m7li+Ex2);
Double_t m1[3] = {md, mn, ma};
TGenPhaseSpace A2D1N1;

A2D1N1.SetDecay(Li7,3,m1);
A2D1N1.Generate();  //--------------------- n+d+alpha decay of 7Li  ************
TLorentzVector *D1 = A2D1N1.GetDecay(0);
TLorentzVector *N1 = A2D1N1.GetDecay(1);
TLorentzVector *A2 = A2D1N1.GetDecay(2);
``````

The output for this should be same as the earlier as the decay happens simultaneously. But I’m getting different results. Can anyone help what’s happening here?

ROOT Version: 6.2
Platform: Ubuntu

Welcome to the ROOT Forum!
Maybe @moneta can help