Skip to content

unitary/isomorphism produce a non-unitary map when the domain is a SumSpace #63

Description

@VinceNeede

Summary

Following up on this discussion: unitary/isomorphism produce a non-unitary map when the domain is a SumSpace, even though the total and per-sector dimensions match exactly between domain and codomain.

MWE

using TensorKit, BlockTensorKit, LinearAlgebra

V1 = Rep[U₁](0 => 2, 1 => 1)
V2 = Rep[U₁](0 => 2, 1 => 1)  
Vsum = V1  V2
Vflat = oplus(Vsum)

@show dim(Vsum), dim(Vflat)                 # equal
for c in blocksectors(Vsum)
    @show c, dim(Vsum, c), dim(Vflat, c)    # equal, sector by sector
end

u = unitary(ComplexF64, Vflat, Vsum)
@show norm(u' * u - id(Vsum))               # expected ~0, got 1.7320508075688772

Expected behavior

norm(u' * u - id(Vsum)) should be ~0.

Actual behavior

Large nonzero residual — u has linearly dependent columns despite matching dimensions everywhere.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions