You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
CalMacCQ
changed the title
QubitPauliString.state_expectation does not work for named registersQubitPauliString.state_expectation does not work for named qubits
Nov 17, 2023
@willsimmons1465 I'm interested in your opinion on this. It feels like it should work with non-default qubits, but should it? If one digs into the code path there are explicit requirements that the qubit register be the default: e.g. here.
I'd expect to be able to calculate$\langle X\rangle$ on a qubit named
"p"
as follows with QubitPauliString.state_expectation.However this gives
If I simply substitute
"p"
for the default qubit name"q"
everything works fine.The text was updated successfully, but these errors were encountered: