Skip to content

Commit

Permalink
Fix DMRG2 information printing
Browse files Browse the repository at this point in the history
  • Loading branch information
lkdvos committed Nov 23, 2023
1 parent f549d30 commit db36b5e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/algorithms/groundstate/dmrg.jl
Original file line number Diff line number Diff line change
Expand Up @@ -119,15 +119,15 @@ function find_groundstate!(Ψ::AbstractFiniteMPS, H, alg::DMRG2, envs=environmen
Ψ, envs = alg.finalize(iter, Ψ, H, envs)::Tuple{typeof(Ψ),typeof(envs)}
end

alg.verbose && @info "DMRG iteration:" iter ϵ λ = expectation_value(Ψ, H, envs) Δt
alg.verbose && @info "DMRG2 iteration:" iter ϵ λ = sum(expectation_value(Ψ, H, envs)) Δt

ϵ <= alg.tol && break
iter == alg.maxiter &&
@warn "DMRG maximum iterations" iter ϵ λ = expectation_value(Ψ, H, envs)
@warn "DMRG2 maximum iterations" iter ϵ λ = sum(expectation_value(Ψ, H, envs))
end

Δt = (Base.time_ns() - t₀) / 1.0e9
alg.verbose && @info "DMRG summary:" ϵ λ = sum(expectation_value(Ψ, H, envs)) Δt
alg.verbose && @info "DMRG2 summary:" ϵ λ = sum(expectation_value(Ψ, H, envs)) Δt
return Ψ, envs, ϵ
end

Expand Down

0 comments on commit db36b5e

Please sign in to comment.