Make qsymm work with non-Hermitian Hamiltonians

Making qsymm work with non-Hermitian Hamiltonians can be achieved by a few relatively simple steps:

  • Model already works with non-Hermitian Hamiltonians. All symbols are assumed real (this we should clarify in the docstring), but it is still possible to express an arbitrary Hamiltonian family by separating the Hermitian and anti-Hermitian parts.

  • The symmetry finder doesn't rely on any assumption about the input being Hermitian as far as I know, and should work as is. We should still review the code with this in mind and write some tests. To be clear, we do not allow non-Hermitian conserved quantities or non-(anti)unitary discrete (anti)symmetries, because this would require dealing with non-compact Lie-algebras, which is hard.

  • We should add a transpose attribute to PointGroupElements to signal that the transformed operator is also transposed, which requires amending the apply method. This will allow declaring hermiticity-like constraints as symmetries by setting conjugate=True and transpose=True. Should provide a constructor hermiticity for convenience. The symmetry finder should work to find such symmetries if they are provided in candidates (this is not completely obvious, should think more and test it).

  • The Hamiltonian generator now only produces Hermitian Hamiltonians. We could add a hermitian flag that controls whether the result is made Hermitian. This requires changing the basis the Hamiltonian terms are generated from to a full matrix basis from the current Hermitian matrix basis in continuum generator, the same in the onsites in bloch_generator and skipping the Hermitian symmetrization for the hoppings. With hermitian=False and some hermiticity-like symmetries provided in symmetries everything should work the same.