Skip to content

Commit

Permalink
Add a minus sign for plotting thg swap gate
Browse files Browse the repository at this point in the history
  • Loading branch information
BoxiLi committed Sep 11, 2022
1 parent 733b405 commit bf8ca2e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/qutip_qip/circuit/circuit.py
Original file line number Diff line number Diff line change
Expand Up @@ -967,7 +967,7 @@ def latex_code(self):
distance = abs(
gate.targets[1] - gate.targets[0]
)
col.append(r" \qswap \qwx[%d] \qw" % distance)
col.append(r" \qswap \qwx[-%d] \qw" % distance)
_swap_processing = True

elif (
Expand Down

0 comments on commit bf8ca2e

Please sign in to comment.