General interface for gauge constraints of tensor networks
mtfishman opened this issue · 0 comments
mtfishman commented
A design could be:
abstract type AbstractGaugeConstraint end
struct ITensorNetwork{V,C<:AbstractGaugeConstraint} <: AbstractITensorNetwork{V}
data_graph::DataGraph{V,ITensor,ITensor,NamedGraph{V},NamedEdge{V}}
gauge_constraint::C
end
# No gauge constraint, this could be the default
# fallback.
struct NoGaugeConstraint <: AbstractGaugeConstraint
end
# Symmetric gauge, stores the message tensors
# Λₑ which are the same as the Vidal gauge bond
# matrices
struct SymmetricGauge{V} <: AbstractGaugeConstraint
message_tensors::DataGraph{V,ITensor,ITensor,NamedGraph{V},NamedEdge{V}}
end
# Vidal gauge, stores the edges where the bond matrices
# Λₑ are present. The bond matrices themselves are
# stored in the `data_graph` of the ITensorNetwork.
struct VidalGauge{E} <: AbstractGaugeConstraint
edges::Vector{E}
end
# isoTNS gauge, stores the vertices that
# defines the gauge center region.
struct IsometricGauge{v} <: AbstractGaugeConstraint
center::Vector{V}
end