quantumlib / OpenFermion-Cirq

Quantum circuits for simulations of quantum chemistry and materials.
Apache License 2.0
276 stars 87 forks source link

Translator QubitOperator to Pauli objects #396

Closed xabomon closed 4 years ago

xabomon commented 4 years ago

I started to write some function to translate from QubitOperator to Pauli strings or Pauli sums, related to #372

I decided to make a new folder "utils".

I'm not quite sure about the aims of the PauliString/PauliSum classes, so I haven't been able to come up with any useful test. Feedback on this front is very much appreciated.

xabomon commented 4 years ago

Hi @kevinsung

Thanks for the comments. I updated the functions as requested.

tanujkhattar commented 4 years ago

Also, since OpenFermion-Cirq is getting deprecated, we would need this PR in OpenFermion instead.

xabomon commented 4 years ago

Hi @tanujkhattar

Thanks for the feedback. What about finishing up the PR here, and when all looks good create a new PR in OpenFermion?

I will try to do so today.

tanujkhattar commented 4 years ago

LGTM! @kevinsung @vtomole PTAL and approve so this can be merged (I don't have write access to this repo).

xabomon commented 4 years ago

Hi @tanujkhattar

Will it be better to make a new PR to OpenFermion with the current code and close this one?

tanujkhattar commented 4 years ago

@xabomon Since the PR in OpenFermion is definitely required, it would probably be enough to have this code there. So +1 to your idea. Can you please make the new PR in OpenFermion?

xabomon commented 4 years ago

Yes I will make a new PR.

xabomon commented 4 years ago

Opened a PR in OpenFermion:

https://github.com/quantumlib/OpenFermion/pull/625

xabomon commented 4 years ago

As this PR has been merge to OF I will go ahead and close it here.