Skip to content

Commit a632346

Browse files
committed
Properly update for MPSKit 0.11
1 parent 9111d38 commit a632346

File tree

5 files changed

+18
-18
lines changed

5 files changed

+18
-18
lines changed

.github/workflows/CI.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
fail-fast: false
2222
matrix:
2323
version:
24-
- '1.6' # LTS version
24+
- '1.8' # LTS version
2525
- '1' # automatically expands to the latest stable 1.x release of Julia
2626
os:
2727
- ubuntu-latest

Project.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,13 @@ TensorOperations = "6aa20fa7-93e2-5fca-9bc0-fbd0db3c71a2"
1313
TupleTools = "9d95972d-f1c8-5527-a6e0-b4b365fa01f6"
1414

1515
[compat]
16-
MPSKit = "0.9, 0.10, 0.11"
16+
MPSKit = "0.11"
1717
MacroTools = "0.5"
1818
PrecompileTools = "1"
1919
TensorKit = "0.11, 0.12"
2020
TensorOperations = "4"
2121
TupleTools = "1"
22-
julia = "1.6"
22+
julia = "1.8"
2323

2424
[extras]
2525
Test = "8dfed614-e22c-5e08-85e1-65c5234f0b40"

test/heisenberg.jl

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
11
using MPSKit
22
using TensorKit
33

4-
alg = VUMPS(; maxiter=25, verbose=false)
4+
alg = VUMPS(; maxiter=25, verbosity=0)
55
E₀ = -1.401484014561
66
E₁ = 0.41047925
77

88
@testset "xxx" begin
99
H = @inferred heisenberg_XXX()
1010
ψ = InfiniteMPS([ComplexSpace(3)], [ComplexSpace(48)])
11-
@test sum(abs.(imag.(expectation_value(ψ, H)))) 0 atol = 1e-10
11+
@test imag(expectation_value(ψ, H)) 0 atol = 1e-10
1212
ψ, envs, δ = find_groundstate(ψ, H, alg)
13-
@test E₀ sum(expectation_value(ψ, H, envs)) atol = 1e-2
13+
@test E₀ expectation_value(ψ, H, envs) atol = 1e-2
1414

1515
ΔEs, qps = excitations(H, QuasiparticleAnsatz(), Float64(pi), ψ, envs)
1616
@test E₁ first(ΔEs) atol = 1e-2
@@ -19,9 +19,9 @@ end
1919
@testset "xxx SU2" begin
2020
H = @inferred heisenberg_XXX(SU2Irrep)
2121
ψ = InfiniteMPS([Rep[SU₂](1 => 1)], [Rep[SU₂](1 // 2 => 5, 3 // 2 => 5, 5 // 2 => 1)])
22-
@test sum(abs.(imag.(expectation_value(ψ, H)))) 0 atol = 1e-10
22+
@test imag(expectation_value(ψ, H)) 0 atol = 1e-10
2323
ψ, envs, δ = find_groundstate(ψ, H, alg)
24-
@test E₀ sum(expectation_value(ψ, H, envs)) atol = 1e-2
24+
@test E₀ expectation_value(ψ, H, envs) atol = 1e-2
2525

2626
ΔEs, qps = excitations(H, QuasiparticleAnsatz(), Float64(pi), ψ, envs;
2727
sector=SU2Irrep(1))
@@ -33,9 +33,9 @@ end
3333
ψ = InfiniteMPS([Rep[U₁](0 => 1, 1 => 1, -1 => 1)],
3434
[Rep[U₁](1 // 2 => 10, -1 // 2 => 10, 3 // 2 => 5, -3 // 2 => 5,
3535
5 // 2 => 3, -5 // 2 => 3)])
36-
@test sum(abs.(imag.(expectation_value(ψ, H)))) 0 atol = 1e-10
36+
@test imag(expectation_value(ψ, H)) 0 atol = 1e-10
3737
ψ, envs, δ = find_groundstate(ψ, H, alg)
38-
@test E₀ sum(expectation_value(ψ, H, envs)) atol = 1e-2
38+
@test E₀ expectation_value(ψ, H, envs) atol = 1e-2
3939

4040
ΔEs, qps = excitations(H, QuasiparticleAnsatz(), Float64(pi), ψ, envs;
4141
sector=U1Irrep(1))

test/sixvertex.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ using TensorKit
33
using Test
44

55
F₀ = (4 / 3)^(3 / 2)
6-
alg = VUMPS(; maxiter=25, verbose=false)
6+
alg = VUMPS(; maxiter=25, verbosity=0)
77

88
@testset "ℤ₁" begin
99
mpo = @inferred sixvertex()

test/tfim.jl

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,30 +4,30 @@ using TensorKit
44
using Test
55

66
E₀ = -1.273239
7-
alg = VUMPS(; maxiter=25, verbose=false)
7+
alg = VUMPS(; maxiter=25, verbosity=0)
88

99
@testset "no symmetry" begin
1010
H = @inferred transverse_field_ising()
1111
ψ₀ = InfiniteMPS([ComplexSpace(2)], [ComplexSpace(16)])
12-
@test sum(abs.(imag.(expectation_value(ψ₀, H)))) 0 atol = 1e-10
12+
@test imag(expectation_value(ψ₀, H)) 0 atol = 1e-10
1313
ψ, envs, δ = find_groundstate(ψ₀, H, alg)
14-
@test E₀ sum(expectation_value(ψ, H, envs)) atol = 1e-5
14+
@test E₀ expectation_value(ψ, H, envs) atol = 1e-5
1515
end
1616

1717
@testset "Z2 symmetry" begin
1818
H = @inferred transverse_field_ising(Z2Irrep)
1919
ψ₀ = InfiniteMPS([Rep[ℤ₂](0 => 1, 1 => 1)], [Rep[ℤ₂](0 => 8, 1 => 8)])
20-
@test sum(abs.(imag.(expectation_value(ψ₀, H)))) 0 atol = 1e-10
20+
@test imag(expectation_value(ψ₀, H)) 0 atol = 1e-10
2121
ψ, envs, δ = find_groundstate(ψ₀, H, alg)
22-
@test E₀ sum(expectation_value(ψ, H, envs)) atol = 1e-5
22+
@test E₀ expectation_value(ψ, H, envs) atol = 1e-5
2323
end
2424

2525
@testset "fZ2 symmetry" begin
2626
H = @inferred transverse_field_ising(fℤ₂)
2727
ψ₀ = InfiniteMPS([Vect[fℤ₂](0 => 1, 1 => 1)], [Vect[fℤ₂](0 => 8, 1 => 8)])
28-
@test sum(abs.(imag.(expectation_value(ψ₀, H)))) 0 atol = 1e-10
28+
@test imag(expectation_value(ψ₀, H)) 0 atol = 1e-10
2929
ψ, envs, δ = find_groundstate(ψ₀, H, alg)
30-
@test E₀ sum(expectation_value(ψ, H, envs)) atol = 1e-3
30+
@test E₀ expectation_value(ψ, H, envs) atol = 1e-5
3131
end
3232

3333
@testset "illegal symmetry" begin

0 commit comments

Comments
 (0)