-
Notifications
You must be signed in to change notification settings - Fork 2.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Enable PauliSumOp comparison with single PauliOp * Also fix the commutative case where equals is called on PauliOp * Add reno release note for PauliSumOp equals Co-authored-by: Ikko Hamamura <ikkoham@users.noreply.github.com>
- Loading branch information
Showing
4 changed files
with
23 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
7 changes: 7 additions & 0 deletions
7
releasenotes/notes/paulisumop-may-equal-pauliop-af86de94020fba22.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
fixes: | ||
- | | ||
:class:`~qiskit.opflow.PauliSumOp` equality tests now handle the case when | ||
one of the compared items is a single :class:`~qiskit.opflow.PauliOp`. | ||
For example, ``0 * X + I == I`` now evaluates to True, whereas it was | ||
False prior to this release. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters