Skip to content

Commit

Permalink
changed the value of the spectrum returned in the von neumann entropy…
Browse files Browse the repository at this point in the history
… for pure states from 1 to 0
  • Loading branch information
Abdulla Alhajri authored and Abdulla Alhajri committed Jun 13, 2024
1 parent 5676a8a commit 30c5bbd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/qibo/quantum_info/entropies.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
"""Submodule with entropy measures."""
""Submodule with entropy measures."""
from typing import Union
Expand Down Expand Up @@ -461,7 +461,7 @@ def von_neumann_entropy(
if purity(state) == 1.0:
if return_spectrum:
return 0.0, backend.cast([1.0], dtype=float)
return 0.0, backend.cast([0.0], dtype=float)
return 0.0
Expand Down

0 comments on commit 30c5bbd

Please sign in to comment.