Skip to content
This repository was archived by the owner on Mar 20, 2025. It is now read-only.

Output eigenvalue from ITensorTDVP.dmrg and dmrg_x #71

Merged
merged 2 commits into from
May 6, 2024
Merged

Conversation

mtfishman
Copy link
Member

Output the eigenvalue along with the eigenvector from ITensorTDVP.dmrg and dmrg_x in a tuple.

The eigenvalue is returned as the first argument, following the convention of many eigensolvers in Julia, like LinearAlgebra.eigen, KrylovKit.eigsolve, Arpack.eigs, IterativeSolvers.lobpcg, and ITensors.ITensorMPS.dmrg.

User code like:

psi = dmrg_x(H, psi0; nsweeps=10, maxdim=100, cutoff=1e-6)
psi = ITensorTDVP.dmrg(H, psi0; nsweeps=10, maxdim=100, cutoff=1e-6)

will need to be changed to:

energy, psi = dmrg_x(H, psi0; nsweeps=10, maxdim=100, cutoff=1e-6)
energy, psi = ITensorTDVP.dmrg(H, psi0; nsweeps=10, maxdim=100, cutoff=1e-6)

@emstoudenmire @amilsted

@mtfishman mtfishman merged commit 4669573 into main May 6, 2024
8 of 9 checks passed
@mtfishman mtfishman deleted the dmrg_energy branch May 6, 2024 02:30
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant