Replace parity=±1 flag with bosonic=True/False flag
For instance, in number_operator. I think a True/False flag is much more intuitive and pythonic. @josh146 @babbush
That makes sense! I can't quite recall my original thinking, maybe I chose a numeric parity flag just in case (at some point in the future) OpenFermion decided to implement something more exotic, like anyons?
@kevinsung what is the status of this issue? I can make a quick pull request if it is not already waiting for a merge
Please, go ahead.
I believe this is changed. number_operator input line is number_operator(i, coefficient=1., particle_hole_symmetry=False) @kevinsung should this be closed?
@ncrubin The definition of number_operator is not what you said; it's actually https://github.com/quantumlib/OpenFermion/blob/1997ea6042285339cec58c12c33a903b9ec97a30/src/openfermion/hamiltonians/special_operators.py#L273
This issue has not been fixed.
@kevinsung LOL there are a bunch of number_operator functions. Apparently I pasted the one you and Bryan wrote a couple of years ago. https://github.com/quantumlib/OpenFermion/commit/4c0df2e1e9cf641683259eba4d2736eea34da1f7
Oh, it looks like that one should be marked private, since it was defined for use in the file that contains it (and not exported).