LanczosEvolution
full name: tenpy.linalg.krylov_based.LanczosEvolution
parent module:
tenpy.linalg.krylov_based
type: class
Inheritance Diagram
Methods
|
|
|
|
|
|
|
Calculate |
- class tenpy.linalg.krylov_based.LanczosEvolution(H, psi0, options)[source]
Bases:
LanczosGroundState
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 h and taking the ground state, we now calculate
exp(delta h) e_0
in the Krylov ONB, wheree_0 = (1, 0, 0, ...)
corresponds topsi0
in the original basis.- Parameters:
H – Hamiltonian, starting vector and parameters as defined in
LanczosGroundState
. The option :cfg:option`LanczosEvolution.P_tol` defines when convergence is reached, see_converged()
for details.psi0 – Hamiltonian, starting vector and parameters as defined in
LanczosGroundState
. The option :cfg:option`LanczosEvolution.P_tol` defines when convergence is reached, see_converged()
for details.options – Hamiltonian, starting vector and parameters as defined in
LanczosGroundState
. The option :cfg:option`LanczosEvolution.P_tol` defines when convergence is reached, see_converged()
for details.
Options
- config LanczosEvolution
option summary cutoff (from KrylovBased) in KrylovBased
Cutoff to abort if the norm of the new krylov vector is too small. [...]
E_shift (from KrylovBased) in KrylovBased
Shift the energy (=eigenvalues) by that amount *during* the Lanczos run by [...]
Ignored.
Ignored.
N_cache (from LanczosGroundState) in LanczosGroundState
The maximum number of `psi` to keep in memory during the first iteration. [...]
N_max (from KrylovBased) in KrylovBased
Maximum number of steps to perform.
N_min (from KrylovBased) in KrylovBased
Minimum number of steps to perform.
P_tol (from KrylovBased) in KrylovBased
Tolerance for the error estimate from the Ritz Residual, [...]
reortho (from KrylovBased) in KrylovBased
For poorly conditioned matrices, one can quickly loose orthogonality of the [...]
- option E_tol
Ignored.
- option min_gap
Ignored.
- delta
Prefactor of H in the exponential.
- Type:
float/complex
- run(delta, normalize=None)[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!
normalize (bool) – Whether to normalize the resulting state. Defaults to
np.real(delta) == 0
.
- Returns:
psi_f (
Array
) – Best approximation forexpm(delta H).dot(psi0)
. IfLanczos.E_shift
is used, it’s an approximation forexpm(delta (H + E_shift)).dot(psi)
.N (int) – Krylov space dimension used.