Skip to content

Commit

Permalink
Update src/qibo/backends/numpy.py
Browse files Browse the repository at this point in the history
  • Loading branch information
renatomello authored Mar 12, 2024
1 parent 671a791 commit 64ffb7b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/qibo/backends/numpy.py
Original file line number Diff line number Diff line change
Expand Up @@ -764,7 +764,7 @@ def calculate_expectation_density_matrix(self, hamiltonian, state, normalize):
ev = self.np.real(self.np.trace(self.cast(hamiltonian @ state)))
if normalize:
norm = self.np.real(self.np.trace(state))
ev = ev / norm
ev /= norm
return ev

# TODO: remove this method
Expand Down

0 comments on commit 64ffb7b

Please sign in to comment.