eigh_rho

tenpy.linalg.truncation.eigh_rho(rho, trunc_par, UPLO='L', sort=None)[source]

Performs EIG of a hermitian matrix rho (= density matrix) and truncates it.

Perform a hermitian eigenvalue decomposition with eigh() and truncates with truncate(). The result is an approximation rho ~= tensordot(V.scale_axis(W*renormalization, 1), V.conj().T, axes=1)

Parameters:
  • rho (Array, shape (M, M)) – The matrix, on which the eigenvalue decomposition (EIG) is performed. Usually, rho represents a density matrix and is assumed to be hermitian AND positive so that the eigenvalues are non-negative.

  • trunc_par (dict) – truncation parameters as described in truncate().

  • UPLO ({'L', 'U'}) – Whether to take the lower (‘L’, default) or upper (‘U’) triangular part of a. Only used for hermitian eigenvalue decomposition.

  • sort ({‘m>’, ‘m<’, ‘>’, ‘<’, None}) – How the eigenvalues should are sorted within each charge block. Defaults to None, which is same as ‘<’. See argsort() for details.

Returns:

  • W (1D ndarray) – The eigenvalues, sorted within the same charge blocks according to sort.

  • V (Array) – Unitary matrix; V[:, i] is normalized eigenvector with eigenvalue W[i]. The first label is inherited from A, the second label is 'eig'.

  • err (TruncationError) – The truncation error introduced.