Closed apozas closed 2 years ago
Upon inspection, the _apply_inflation_symmetries was setting certain nonzero-index moments to the zero index under the permutation. This should never happen. Turns out that apply_inflation_symmetries was just fine, but the real bug was in calculate_momentmatrix, where where we were evaluating mon_is_zero BEFORE setting the monomial to canonical form. I fixed it, and also adjusted to_canonical to map all zero-equivalent operators to a canonical zero monomial.
Running the code
Produces the following error
I don't find this error if I change the number of outcomes to
[2,2]
, the inflation level to[1]
, or the NPA level tonpa1
. But I do find it when the number of outcomes is[3,3]
.