Skip to content

Commit 1c8db08

Browse files
authored
Normalize result in contract function
Refactor contract function to normalize result by dim_sec.
1 parent a71a1f0 commit 1c8db08

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/fusiontensor/array_cast.jl

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,14 +151,16 @@ function contract_fusion_trees(
151151
# \___________| \___________|
152152
# \ |
153153
# \----------------dim_sec---------------- /
154-
return contract(
154+
res = contract(
155155
ntuple(i -> 2 * i - 1, N),
156156
split_array_block,
157157
ntuple(identity, 2 * N),
158158
p,
159159
ntuple(i -> 2 * i, N),
160-
1 / dim_sec, # normalization factor
161160
)
161+
# normalization factor
162+
res ./= dim_sec
163+
return res
162164
end
163165

164166
function contract_singlet_projector(f1::SectorFusionTree, f2::SectorFusionTree)

0 commit comments

Comments
 (0)