Issue with Majorana Wavefunction Calculation in a Topological Superconducting System

Without looking too closely, I suspect it’s the lack of Jordan-Wigner strings. For an in depth discussion see

You should try inserting F operators, see more here