# LanczosEvolution¶

Inheritance Diagram

Methods

 LanczosEvolution.__init__(H, psi0, options) Initialize self. Calculate expm(delta H).dot(psi0) using Lanczos.
class tenpy.linalg.lanczos.LanczosEvolution(H, psi0, options)[source]

Calculate $$exp(delta H) |psi0>$$ using Lanczos.

It turns out that the Lanczos algorithm is also good for calculating the matrix exponential applied to the starting vector. Instead of diagonalizing the tri-diagonal T and taking the ground state, we now calculate exp(delta T) e_0 in the Krylov ONB, where e_0 = (1, 0, 0, ...) corresponds to psi0 in the original basis.

Parameters

psi0, options (H,) – Hamiltonian, starting vector and parameters as defined in LanczosGroundState. The option :cfg:optionLanczosEvolution.P_tol defines when convergence is reached, see _converged() for details.

Options

config LanczosEvolution
option summary

cutoff (from Lanczos) in LanczosGroundState

Cutoff to abort if beta (= norm of next vector in Krylov basis before nor [...]

E_shift (from Lanczos) in LanczosGroundState

Shift the energy (=eigenvalues) by that amount *during* the Lanczos run by [...]

E_tol

Ignored.

min_gap

Ignored.

N_cache (from Lanczos) in LanczosGroundState

The maximum number of psi to keep in memory during the first iteration. [...]

N_max (from Lanczos) in LanczosGroundState

Maximum number of steps to perform.

N_min (from Lanczos) in LanczosGroundState

Minimum number of steps to perform.

P_tol (from Lanczos) in LanczosGroundState

Tolerance for the error estimate from the Ritz Residual, [...]

reortho (from Lanczos) in LanczosGroundState

For poorly conditioned matrices, one can quickly loose orthogonality of the [...]

verbose (from Config) in Config

How much to print what's being done; higher means print more. [...]

option E_tol

Ignored.

option min_gap

Ignored.

delta

Prefactor of H in the exponential.

Type

float/complex

_result_norm

Norm of the resulting vector.

Type

float

run(delta)[source]

Calculate expm(delta H).dot(psi0) using Lanczos.

Parameters

delta (float/complex) – Time step by which we should evolve psi0: prefactor of H in the exponential. Note that the complex i is not included!

Returns

• psi_f (Array) – Best approximation for expm(delta H).dot(psi0). If Lanczos.E_shift is used, it’s an approximation for expm(delta (H + E_shift)).dot(psi).

• N (int) – Krylov space dimension used.