diff --git a/Project.toml b/Project.toml index 33776a3..014fedf 100644 --- a/Project.toml +++ b/Project.toml @@ -8,7 +8,7 @@ LinearAlgebra = "37e2e46d-f89d-539d-b4ee-838fcccc9c8e" TensorKit = "07d1fe3e-3e46-537d-9eac-e9e13d0d4cec" [compat] -TensorKit = "0.13, 0.14" +TensorKit = "0.14" julia = "1.10" [extras] diff --git a/src/grassmann.jl b/src/grassmann.jl index e4fc1fc..ac8d5df 100644 --- a/src/grassmann.jl +++ b/src/grassmann.jl @@ -26,10 +26,11 @@ mutable struct GrassmannTangent{T<:AbstractTensorMap, Z::AbstractTensorMap{TT₂,S,N₁,N₂}) where {TT₁,TT₂,S,N₁,N₂} T = typeof(W) TT = promote_type(float(scalartype(W)), scalartype(Z)) + Tr = real(TT) M = similarstoragetype(W, TT) - Mr = similarstoragetype(W, real(TT)) + Mr = similarstoragetype(W, Tr) TU = tensormaptype(S, N₁, 1, M) - TS = isreal(sectortype(S)) ? tensormaptype(S, 1, 1, Mr) : tensormaptype(S, 1, 1, M) + TS = DiagonalTensorMap{Tr,S,Mr} TV = tensormaptype(S, 1, N₂, M) return new{T,TU,TS,TV}(W, Z, nothing, nothing, nothing) end