Skip to content

Commit

Permalink
Merge pull request #53 from QuantumKitHub/pb-ctmrg-allsides
Browse files Browse the repository at this point in the history
Implement simultaneous CTMRG scheme and CTMRG gradients without gauge-fix differentiation
  • Loading branch information
pbrehmer authored Jul 16, 2024
2 parents 9a6b409 + 677bbeb commit ec5902b
Show file tree
Hide file tree
Showing 22 changed files with 1,030 additions and 432 deletions.
3 changes: 1 addition & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,8 @@ ctm_alg = CTMRG(; tol=1e-10, miniter=4, maxiter=100, verbosity=1, trscheme=trunc
opt_alg = PEPSOptimize(;
boundary_alg=ctm_alg,
optimizer=LBFGS(4; maxiter=100, gradtol=1e-4, verbosity=2),
gradient_alg=GMRES(; tol=1e-6, maxiter=100),
gradient_alg=LinSolver(),
reuse_env=true,
verbosity=2,
)

# ground state search
Expand Down
3 changes: 1 addition & 2 deletions docs/src/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,8 @@ ctm_alg = CTMRG(; tol=1e-10, miniter=4, maxiter=100, verbosity=1, trscheme=trunc
opt_alg = PEPSOptimize(;
boundary_alg=ctm_alg,
optimizer=LBFGS(4; maxiter=100, gradtol=1e-4, verbosity=2),
gradient_alg=GMRES(; tol=1e-6, maxiter=100),
gradient_alg=LinSolver(),
reuse_env=true,
verbosity=2,
)

# ground state search
Expand Down
5 changes: 2 additions & 3 deletions examples/heisenberg.jl
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,12 @@ H = square_lattice_heisenberg(; Jx=-1, Jy=1, Jz=-1)
# Parameters
χbond = 2
χenv = 20
ctm_alg = CTMRG(; tol=1e-10, miniter=4, maxiter=100, verbosity=1, trscheme=truncdim(χenv))
ctm_alg = CTMRG(; tol=1e-10, miniter=4, maxiter=100, verbosity=2)
opt_alg = PEPSOptimize(;
boundary_alg=ctm_alg,
optimizer=LBFGS(4; maxiter=100, gradtol=1e-4, verbosity=2),
gradient_alg=GMRES(; tol=1e-6, maxiter=100),
gradient_alg=LinSolver(; solver=GMRES(; tol=1e-6, maxiter=100)),
reuse_env=true,
verbosity=2,
)

# Ground state search
Expand Down
15 changes: 12 additions & 3 deletions src/PEPSKit.jl
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ using MPSKit: loginit!, logiter!, logfinish!, logcancel!
include("utility/util.jl")
include("utility/svd.jl")
include("utility/rotations.jl")
include("utility/diffset.jl")
include("utility/hook_pullback.jl")
include("utility/autoopt.jl")

Expand All @@ -31,7 +32,9 @@ include("environments/ctmrgenv.jl")
include("operators/localoperator.jl")
include("operators/models.jl")

include("algorithms/ctmrg_gauge_fix.jl")
include("algorithms/ctmrg.jl")
include("algorithms/ctmrg_all_sides.jl")
include("algorithms/peps_opt.jl")

include("utility/symmetrization.jl")
Expand All @@ -54,19 +57,25 @@ Module containing default values that represent typical algorithm parameters.
- `fpgrad_tol = 1e-6`: Convergence tolerance for the fixed-point gradient iteration
"""
module Defaults
using TensorKit, KrylovKit, OptimKit
const ctmrg_maxiter = 100
const ctmrg_miniter = 4
const ctmrg_tol = 1e-12
const fpgrad_maxiter = 100
const ctmrg_tol = 1e-10
const fpgrad_maxiter = 20
const fpgrad_tol = 1e-6
const ctmrgscheme = :simultaneous
const iterscheme = :fixed
const fwd_alg = TensorKit.SVD()
const rrule_alg = GMRES(; tol=ctmrg_tol)
const optimizer = LBFGS(10; maxiter=100, gradtol=1e-4, verbosity=2)
end

export SVDAdjoint, IterSVD, NonTruncSVDAdjoint
export FixedSpaceTruncation, ProjectorAlg, CTMRG, CTMRGEnv
export LocalOperator
export expectation_value, costfun
export leading_boundary
export PEPSOptimize, GeomSum, ManualIter, LinSolve
export PEPSOptimize, GeomSum, ManualIter, LinSolver
export fixedpoint

export InfinitePEPS, InfiniteTransferPEPS
Expand Down
Loading

0 comments on commit ec5902b

Please sign in to comment.