Skip to content

Commit

Permalink
implement the optimal contraction ordering for BTRG
Browse files Browse the repository at this point in the history
  • Loading branch information
VictorVanthilt committed Feb 14, 2025
1 parent d3ae4a1 commit fbffcd3
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions src/schemes/btrg.jl
Original file line number Diff line number Diff line change
Expand Up @@ -54,11 +54,13 @@ function step!(scheme::BTRG, trunc::TensorKit.TruncationScheme)
S1 = scheme.S1
S2 = scheme.S2

@tensor opt = true scheme.T[-1 -2; -3 -4] := D[-1 1; 8] * S1[2; 1] * B[-2; 3 2] *
S2[3; 4] *
C[4; 5 -3] *
S1[5; 6] * A[7 6; -4] * S2[8; 7]

@tensor scheme.T[-1 -2; -3 -4] := D[-1 7; 4] *
S1[1; 7] *
B[-2; 3 1] *
S2[3; 2] *
C[2; 8 -3] *
S1[8; 5] *
A[6 5; -4] * S2[4; 6]
scheme.S1 = S1′
scheme.S2 = S2′
return scheme
Expand Down

0 comments on commit fbffcd3

Please sign in to comment.