Reference
GradedArrays.AbelianBlocks — Type
AbelianBlocks{T,N,A<:AbelianGradedArray{T,N}} <: AbstractArray{AbelianSectorArray,N}Lazy view of an AbelianGradedArray's block storage, following the BlockArrays convention: getindex delegates to view(parent, Block.(I)...) (shares data), setindex! copies into the existing view.
GradedArrays.AbelianGradedArray — Type
AbelianGradedArray{T,N,D<:AbstractArray{T,N},S<:SectorRange} <: AbstractGradedArray{T,N}A graded array that stores non-zero blocks in a dictionary keyed by block indices. Each axis is a GradedOneTo carrying sectors, sector lengths, and a dual flag.
Blocks are stored as plain dense arrays of type D (default Array{T,N}). Accessing a block via a[Block(i,j)] returns a AbelianSectorArray wrapping the data with the appropriate sectors.
GradedArrays.AbelianSectorArray — Type
AbelianSectorArray{T,N,A,S} <: AbstractSectorArray{T, N}Unfused N-D data tensor for abelian symmetries. Stores one SectorRange per axis, plus a dense data array. Implements the Wigner-Eckart decomposition: the full tensor is the Kronecker product of an AbelianSectorDelta (structural) with the data array (reduced matrix elements).
GradedArrays.AbelianSectorDelta — Type
AbelianSectorDelta{T,N,S<:SectorRange} <: AbstractSectorDelta{T, N}Unfused N-D structural tensor for abelian symmetries. Stores one SectorRange per axis. For abelian symmetries, every element equals one(T) (the Kronecker delta selection rule).
GradedArrays.AbstractGradedArray — Type
AbstractGradedArray{T,N} <: AbstractArray{T,N}Abstract supertype for graded (symmetry-structured) arrays whose axes carry sector labels. Concrete subtypes include AbelianGradedArray and FusedGradedMatrix.
GradedArrays.AbstractSectorArray — Type
AbstractSectorArray{T,N} <: AbstractArray{T,N}Abstract supertype for data tensors labeled by sector information. Concrete subtypes:
AbelianSectorArray: unfused N-D abelian data tensor (one sector per axis)SectorMatrix: fused 2D data matrix (one coupled sector label)
GradedArrays.AbstractSectorDelta — Type
AbstractSectorDelta{T,N} <: AbstractArray{T,N}Abstract supertype for structural (Kronecker/identity) tensors associated to sector labels. Concrete subtypes:
AbelianSectorDelta: unfused N-D abelian structural tensor (product of Kronecker deltas)SectorIdentity: fused 2D structural factor (identity matrix per coupled sector)
GradedArrays.Data — Type
Data{N}Block-data indexing type analogous to BlockArrays.Block{N}. Indexing a graded array with Data(i, j, ...) accesses the raw data array for that block, without sector metadata wrappers.
GradedArrays.FusedGradedMatrix — Type
FusedGradedMatrix{T,D<:AbstractMatrix{T},S<:SectorRange}Block-diagonal matrix produced by matricizing an AbstractGradedArray. Each diagonal block corresponds to a coupled sector from fusing codomain/domain legs.
Fields:
sectors::Vector{S}— coupled sectors, sorted and unique (always non-dual, codomain convention)blocks::Vector{D}— diagonal blocks, one per sector
The codomain (row) axis is non-dual with sectors sectors[i] and sector lengths derived from size(blocks[i], 1). The domain (column) axis is dual with sectors dual(sectors[i]) and sector lengths from size(blocks[i], 2).
GradedArrays.FusedGradedMatrix — Method
FusedGradedMatrix(a::AbelianGradedMatrix{T})Convert a 2D block-diagonal AbelianGradedArray (as produced by matricize) into a FusedGradedMatrix. Extracts diagonal blocks from the stored entries.
GradedArrays.GradedOneTo — Type
GradedOneTo{S<:SectorRange}Represents a graded axis — a collection of sectors with sector lengths and a dual flag. This is the axis type for AbelianGradedArray.
Stores non-dual SectorRange values in nondual_sectors, sector lengths, and a single isdual flag. The sectors accessor applies the isdual flag on the fly.
GradedArrays.SectorIdentity — Type
SectorIdentity{T,S<:SectorRange} <: AbstractSectorDelta{T, 2}Fused 2D structural factor for a single coupled sector. By Schur's lemma, the structural part of each block in the fused (matricized) basis is the identity matrix for the irrep. Carries no free data — completely determined by the sector. The codomain axis is non-dual, the domain axis is dual.
GradedArrays.SectorMatrix — Type
SectorMatrix{T,D<:AbstractMatrix{T},S<:SectorRange} <: AbstractSectorArray{T, 2}Fused 2D data matrix for a single coupled sector. One block of a FusedGradedMatrix. In the representation-theoretic sense, this is an element of HomG(Vc, W_c) for coupled sector c — the reduced matrix element (degeneracy/multiplicity tensor) after Schur's lemma has factored out the structural part (SectorIdentity).
The codomain (row) axis is non-dual; the domain (column) axis is dual. The stored SectorRange is always non-dual (codomain convention).
GradedArrays.SectorOneTo — Type
SectorOneTo{S<:SectorRange}Represents one sector's index space — a SectorRange (sector label + dual flag) paired with a data length (multiplicity). This is the building block for GradedOneTo.
Stores a SectorRange and a data length. The isdual accessor is derived from the stored SectorRange.
GradedArrays.SectorRange — Type
SectorRange(sector::TKS.Sector, isdual::Bool)Unit range with elements of type Int that additionally stores a sector to denote the grading. Equivalent to Base.OneTo(length(sector)). Additionally holds a flag to denote the duality.
Base.zeros — Method
zeros(T, axs::GradedOneTo...)Create an AbelianGradedArray{T} with all allowed (zero-flux) blocks filled with zeros.
GradedArrays.data — Method
data(sa::AbstractSectorArray)Return the raw data array underlying the sector array.
GradedArrays.gradedrange — Method
gradedrange(xs::AbstractVector{<:Pair})Generic fallback that converts sector keys via to_sector before constructing GradedOneTo. This supports NamedTuple keys (for sector products) and other non-standard key types.
GradedArrays.gradedrange — Method
gradedrange(xs::AbstractVector{<:Pair{<:SectorRange, <:Integer}})Construct a GradedOneTo from pairs of SectorRange to multiplicities. All SectorRange values must have the same isdual flag. Non-dual inputs produce a non-dual axis; dual inputs produce a dual axis.
Examples
gradedrange([U1(0) => 2, U1(1) => 3]) # non-dual
gradedrange([U1(0)' => 2, U1(1)' => 3]) # dualGradedArrays.masked_inversion_parity — Method
Compute the parity of the number of inversions of a masked permutation