Library documentation

TensorKitSectors.GroupElement — Constant
const GroupElement

A constant of a singleton type used as GroupElement[G] or GroupElement[G, ω] with G <: Group a type of group, to construct or obtain a concrete subtype of AbstractElement{G} that implements the data structure used to represent elements of the group G, possibly with a second argument ω that specifies the associated 3-cocycle.

source
TensorKitSectors.Irrep — Constant
const Irrep

A constant of a singleton type used as Irrep[G] with G <: Group a type of group, to construct or obtain a concrete subtype of AbstractIrrep{G} that implements the data structure used to represent irreducible representations of the group G.

source
TensorKitSectors.A4Irrep — Type
struct A4Irrep <: AbstractIrrep{A₄}
A4Irrep(n::Integer)
Irrep[A₄](n::Integer)

Represents irreps of the alternating group $A₄$.

Fields

  • n::Int8: the label of the irrep, corresponding to $1$, $1′$, $1″$ and $3$.
source
TensorKitSectors.AbelianGroup — Type
abstract type AbelianGroup <: Group

Abstract supertype for representing different types of Abelian groups. Abelian groups have both irreps and group elements that have several simplified properties, that can be defined in general.

source
TensorKitSectors.AbstractGroupElement — Type
abstract type AbstractGroupElement{G <: Group} <: Sector

Abstract supertype for sectors which corresponds to group elements of a group G.

Actual concrete implementations of those irreps can be obtained as Element[G], or via their actual name, which generically takes the form (asciiG)Element, i.e. the ASCII spelling of the group name followed by Element.

All group elements have FusionStyle equal to UniqueFusion(). Furthermore, the BraidingStyle is set to NoBraiding(), although this can be overridden by a concrete implementation of AbstractGroupElement.

For the fusion structure, a specific SomeGroupElement <: AbstractGroupElement{SomeGroup} should only implement the following methods

Base.:*(c1::SomeGroupElement, c2::SomeGroupElement) -> SomeGroupElement
Base.one(::Type{SomeGroupElement}) -> SomeGroupElement
Base.inv(c::SomeGroupElement) -> SomeGroupElement
# and optionally
TensorKitSectors.cocycle(c1::SomeGroupElement, c2::SomeGroupElement, c3::SomeGroupElement) -> Number

The methods conj, dual, ⊗, Nsymbol, Fsymbol, dim, Asymbol, Bsymbol and frobenius_schur_phase will then be automatically defined. If no cocycle method is defined, the cocycle will be assumed to be trivial, i.e. equal to 1.

source
TensorKitSectors.AbstractIrrep — Type
abstract type AbstractIrrep{G <: Group} <: Sector

Abstract supertype for sectors which corresponds to irreps (irreducible representations) of a group G. As we assume unitary representations, these would be finite groups or compact Lie groups. Note that this could also include projective rather than linear representations.

Actual concrete implementations of those irreps can be obtained as Irrep[G], or via their actual name, which generically takes the form (asciiG)Irrep, i.e. the ASCII spelling of the group name followed by Irrep.

All irreps have BraidingStyle equal to Bosonic() and thus trivial twists.

source
TensorKitSectors.Alternating — Type
abstract type Alternating{N} <: Group

Type to represent the alternating group of order N!/2, which is the group of even permutations on N elements.

source
TensorKitSectors.Anyonic — Type
struct Anyonic <: HasBraiding

Braiding style with general (non-symmetric) braiding and arbitrary twists. Characterized by nontrivial braid group representations where $R^{ab}_c R^{ba}_c ≠ 1$ in general.

See also BraidingStyle.

source
TensorKitSectors.Bosonic — Type
struct Bosonic <: SymmetricBraiding

Braiding style with symmetric braiding and trivial twist. This is characterized by $R^{ab}_c R^{ba}_c = 1$ and $\theta_a = 1$ for all sectors.

See also BraidingStyle.

source
TensorKitSectors.BraidingStyle — Type
abstract type BraidingStyle
BraidingStyle(::Sector) -> ::BraidingStyle
BraidingStyle(I::Type{<:Sector}) -> ::BraidingStyle

Trait to describe the braiding behavior of sectors of type I, which can be either

  • NoBraiding: no braiding structure defined.
  • Bosonic: symmetric braiding structure with a trivial twist.
  • Fermionic: symmetric braiding structure with a non-trivial twist that squares to identity.
  • Anyonic: general braiding structure and arbitrary twists.

There is an abstract supertype HasBraiding that includes all styles that define Rsymbol (everything but NoBraiding). Furthermore, the abstract supertype SymmetricBraiding denotes the cases where braidings are equivalent to crossings, i.e. braiding twice is an identity operation. This includes the Bosonic and Fermionic styles, for which we can uniquely define permutations.

source
TensorKitSectors.CU1Irrep — Type
struct CU1Irrep <: AbstractIrrep{CU₁}
CU1Irrep(j, s = ifelse(j>zero(j), 2, 0))
Irrep[CU₁](j, s = ifelse(j>zero(j), 2, 0))

Represents irreps of the group $U₁ ⋊ C$ ($U₁$ and charge conjugation or reflection), which is also known as just O₂.

Fields

  • j::HalfInt: the value of the $U₁$ charge.
  • s::Int: the representation of charge conjugation.

They can take values:

  • if j == 0, s = 0 (trivial charge conjugation) or s = 1 (non-trivial charge conjugation)
  • if j > 0, s = 2 (two-dimensional representation)
source
TensorKitSectors.CU₁ — Type
abstract type CU₁ <: Group

Type to represent the group of U₁ in combination with charge conjugation, i.e. the group generated by U₁ and an additional element that acts as complex conjugation on U₁. This group is isomorphic to the orthogonal group O₂ of real orthogonal 2×2 matrices, and can be seen as the semidirect product U₁ ⋊ ℤ₂. This is a compact non-Abelian group.

source
TensorKitSectors.Cyclic — Type
abstract type Cyclic{N} <: AbelianGroup

Type to represent the cyclic group of order N, i.e. the multiplicative group of roots of unity of order N, which is a discrete abelian group. The cyclic group of order N is isomorphic to the additive group ℤ{N}, and we define the latter as a type alias const ℤ{N} = Cyclic{N}.

source
TensorKitSectors.DNIrrep — Type
struct DNIrrep{N} <: AbstractIrrep{Dihedral{N}}
DNIrrep{N}(n::Integer, isodd::Bool=false)
Irrep[Dihedral{N}](n::Integer, isodd::Bool=false)

Represents irreps of the dihedral group $D_N = Z_N ⋊ C$ ($Z_N$ and charge conjugation or reflection).

Properties

  • j::Int: the value of the $Z_N$ charge.
  • isodd::Bool: the representation of charge conjugation.

Combined these take the values $+0, -0, 1, ..., (N - 1) / 2$ for odd $N$, and $+0, -0, 1, ..., N / 2 - 1, +(N/2), -(N/2)$ for even $N$, where the $+$ ($-$) refer to the even (odd) one-dimensional irreps, while the others are two-dimensional.

source
TensorKitSectors.Dihedral — Type
abstract type Dihedral{N} <: Group

Type to represent the dihedral group of order 2N, which is the symmetry group of a regular polygon with N sides, and is a discrete non-Abelian group.

source
TensorKitSectors.FermionNumber — Type
const FermionNumber = U1Irrep ⊠ FermionParity
FermionNumber(a::Int)

Represents the fermion number as the direct product of a $U₁$ irrep a and a fermion parity, with the restriction that the fermion parity is odd if and only if a is odd.

See also: U1Irrep, FermionParity

source
TensorKitSectors.FermionParity — Type
struct FermionParity <: Sector
FermionParity(isodd::Bool)

Represents sectors with fermion parity. The fermion parity is a $ℤ₂$ quantum number that yields an additional sign when two odd fermions are exchanged, corresponding to a BraidingStyle that is Fermionic().

Fields

  • isodd::Bool: indicates whether the fermion parity is odd (true) or even (false).

See also: FermionNumber, FermionSpin

source
TensorKitSectors.FermionSpin — Type
const FermionSpin = SU2Irrep ⊠ FermionParity
FermionSpin(j::Real)

Represents the fermion spin as the direct product of a $SU₂$ irrep j and a fermion parity, with the restriction that the fermion parity is odd if 2 * j is odd.

See also: SU2Irrep, FermionParity

source
TensorKitSectors.Fermionic — Type
struct Fermionic <: SymmetricBraiding

Braiding style with symmetric braiding and nontrivial (symmetric) twist. This is characterized by $R^{ab}_c R^{ba}_c = 1$ and $\theta_a = \pm 1$ for all sectors.

See also BraidingStyle.

source
TensorKitSectors.FibonacciAnyon — Type
struct FibonacciAnyon <: Sector
FibonacciAnyon(s::Symbol)

Represents the anyons of the Fibonacci modular fusion category. It can take two values, corresponding to the trivial sector FibonacciAnyon(:I) and the non-trivial sector FibonacciAnyon(:τ) with fusion rules $τ ⊗ τ = 1 ⊕ τ$.

Fields

  • isunit::Bool: indicates whether the sector corresponds to the trivial anyon :I (true), or the non-trivial anyon :τ (false).
source
TensorKitSectors.FusionStyle — Type
abstract type FusionStyle
FusionStyle(::Sector)
FusionStyle(I::Type{<:Sector})

Trait to describe the fusion behavior of sectors of type I, which can be either

  • UniqueFusion: each fusion a ⊗ b has exactly one output c.
  • SimpleFusion: fusing a ⊗ b can lead to multiple values c, but each appears at most once.
  • GenericFusion: fusing a ⊗ b can lead to multiple values c that could appear multiple times.

There is an abstract supertype MultipleFusion of which both SimpleFusion and GenericFusion are subtypes. Furthermore, there is a type alias MultiplicityFreeFusion for those fusion types which do not require muliplicity labels.

source
TensorKitSectors.GenericFusion — Type
struct GenericFusion <: MultipleFusion

Fusion style with potentially multiple outputs c and nontrivial multiplicities. Here $N_c^{ab}$ can exceed 1, and multiplicity labels are required.

See also FusionStyle.

source
TensorKitSectors.GenericUnit — Type
struct GenericUnit <: UnitStyle

Unit style for multifusion categories with multiple unit objects (semisimple unit). Requires implementation of allunits(::Type{I}), leftunit(a), and rightunit(a).

See also UnitStyle.

source
TensorKitSectors.Group — Type
abstract type Group

Abstract supertype for representing different types of groups. Groups can be used to define Sector subtypes, either via their irreducible representations, or via their group elements, and typically appear as type parameter. As such, they are not meant to be instantiated and are defined as abstract types.

source
TensorKitSectors.HasBraiding — Type
abstract type HasBraiding <: BraidingStyle

Supertype for all braiding styles where an Rsymbol is defined. This includes all current BraidingStyles except NoBraiding.

source
TensorKitSectors.Heisenberg — Type
abstract type Heisenberg{N} <: Group

Type to represent the Heisenberg group of dimension N, which is the non-Abelian group of 3x3 upper triangular matrices with ones on the diagonal. This group is the semi-direct product ℤ{N} ⋊ ℤ{N}^2, and is only defined for N prime.

source
TensorKitSectors.HeisenbergIrrep — Type
struct HeisenbergIrrep{N} <: AbstractIrrep{Heisenberg{N}}
HeisenbergIrrep{N}(n::Int8)
Irrep[Heisenberg{N}](n::Int8)

Represents irreps of the finite Heisenberg group $H_N$ for N prime. Irreps are labeled by a single integer n: if N < n < 0, the irrep is the Schrödinger representation $πₖ$ with k = -n. Otherwise, the irrep is the character $χₐ,ᵦ$ with a, b = divrem(n, N), of which there are N².

Fields

  • n::Int8: the label of the irrep.
source
TensorKitSectors.IsingAnyon — Type
struct IsingAnyon <: Sector
IsingAnyon(s::Symbol)

Represents the anyons of the Ising modular fusion category. It can take three values, corresponding to the trivial sector IsingAnyon(:I) and the non-trivial sectors IsingAnyon(:σ) and IsingAnyon(:ψ), with fusion rules $ψ ⊗ ψ = 1$, $σ ⊗ ψ = σ$, and $σ ⊗ σ = 1 ⊕ ψ$.

Fields

  • s::Symbol: the label of the represented anyon, which can be :I, :σ, or :ψ.
source
TensorKitSectors.IsingBimodule — Type
struct IsingBimodule <: Sector

Type to represent the simple objects in the Ising category reinterpreted as a bimodule category composed of two copies of the category 𝒞 = 𝒟 = Irrep[ℤ₂], the two simple objects of which can be identified with the Ising anyons {I, ψ}, and the bimodule categories ℳ = ℳᵒᵖ = Vec, with a single simple object that can be identified with the Ising anyon σ. This constitutes the easiest example of a multifusion category and is implemented here for testing purposes and to illustrate how to implement such categories in TensorKitSectors.jl.

source
TensorKitSectors.LargeZNIrrep — Type
struct LargeZNIrrep{N} <: AbstractIrrep{ℤ{N}}
LargeZNIrrep{N}(n::Integer)
Irrep[ℤ{N}](n::Integer)

Represents irreps of the group $ℤ_N$ for some value of N, which is typically larger than 128. For smaller values of N, the ZNIrrep sector type should be used instead. An arbitrary Integer n can be provided to the constructor, but only the value mod(n, N) is relevant.

The constructor Irrep[ℤ{N}] should be preferred, as it will automatically select the most efficient storage type for a given value of N.

See also charge and modulus to extract the relevant data.

Fields

  • n::UInt: the integer label of the irrep, modulo N.
source
TensorKitSectors.NamedSector — Type
struct NamedSector{NT <: NamedSectorTuple}
NamedSector((; name₁=s₁, name₂=s₂, ...))

Represents the Deligne tensor product of sectors stored with named components. Similar to ProductSector, but components are accessible by name via s.name.

Examples

julia> s = NamedSector(; charge=U1Irrep(1), spin=SU2Irrep(1//2))
NamedSector(; charge=Irrep[U₁](1), spin=Irrep[SU₂](1/2))

julia> s.charge
Irrep[U₁](1)

julia> s.spin
Irrep[SU₂](1/2)
Warning

The sectors are stored internally in the s.sectors field, so the named components should not contain sectors as a name.

source
TensorKitSectors.PlanarTrivial — Type
struct PlanarTrivial <: Sector
PlanarTrivial()

Represents a trivial anyon sector, i.e. a trivial sector without braiding. This is mostly useful for testing.

source
TensorKitSectors.ProductGroup — Type
abstract type ProductGroup{T <: Tuple{Vararg{Group}}} <: Group

Type to represent the direct product of a tuple of groups. This is typically constructed via the × operator.

source
TensorKitSectors.ProductSector — Type
struct ProductSector{T <: SectorTuple}
ProductSector((s₁, s₂, ...))

Represents the Deligne tensor product of sectors. The type parameter T is a tuple of the component sectors. The recommended way to construct a ProductSector is using the deligneproduct (⊠) operator on the components.

source
TensorKitSectors.SU — Type
abstract type SU{N} <: Group

Type to represent the special unitary group $SU(N)$, which is a compact non-Abelian Lie group.

source
TensorKitSectors.SU2Irrep — Type
struct SU2Irrep <: AbstractIrrep{SU₂}
SU2Irrep(j::Real)
Irrep[SU₂](j::Real)

Represents irreps of the group $SU₂$. The irrep is labeled by a half integer j which can be entered as an arbitrary Real, but is stored as a HalfInt from the HalfIntegers.jl package.

Fields

  • j::HalfInt: the label of the irrep, which can be any non-negative half integer.
source
TensorKitSectors.Sector — Type
abstract type Sector

Abstract type for representing the (isomorphism classes of) simple objects in (unitary and pivotal) (pre-)fusion categories, e.g. the irreducible representations of a finite or compact group. Subtypes I <: Sector as the set of labels of a GradedSpace.

Every new I <: Sector should implement the following methods:

  • unit(::Type{I}): unit element of I. If there are multiple, implement allunits(::Type{I}) instead.
  • dual(a::I): $a̅$, conjugate or dual label of $a$
  • ⊗(a::I, b::I): iterable with unique fusion outputs of $a ⊗ b$ (i.e. don't repeat in case of multiplicities)
  • Nsymbol(a::I, b::I, c::I): number of times c appears in a ⊗ b, i.e. the multiplicity
  • FusionStyle(::Type{I}): UniqueFusion(), SimpleFusion() or GenericFusion()
  • BraidingStyle(::Type{I}): Bosonic(), Fermionic(), Anyonic(), ...
  • Fsymbol(a::I, b::I, c::I, d::I, e::I, f::I): F-symbol: scalar (in case of UniqueFusion/SimpleFusion) or rank-4 array (in case of GenericFusion)
  • Rsymbol(a::I, b::I, c::I): R-symbol: scalar (in case of UniqueFusion/SimpleFusion) or matrix (in case of GenericFusion)
  • isless(a::I, b::I): defines a canonical ordering of sectors
  • hash(a::I): hash function for sectors

and optionally

  • dim(a::I): quantum dimension of sector a
  • frobenius_schur_indicator(a::I): Frobenius-Schur indicator of a (1, 0, -1)
  • frobenius_schur_phase(a::I): Frobenius-Schur phase of a (±1)
  • sectorscalartype(::Type{I}): scalar type of F- and R-symbols
  • Bsymbol(a::I, b::I, c::I): B-symbol: scalar (in case of UniqueFusion/SimpleFusion) or matrix (in case of GenericFusion)
  • twist(a::I) -> twist of sector a

Furthermore, iterate and Base.IteratorSize should be made to work for the singleton type SectorValues{I}.

To help with the implementation of ⊗(a::I, b::I) as an iterator, the provided struct type SectorProductIterator{I} can be used, which stores a and b and requires the implementation of Base.iterate(::SectorProductIterator{I}, state...).

source
TensorKitSectors.SectorProductIterator — Type
struct SectorProductIterator{I <: Sector}
SectorProductIterator(a::I, b::I) where {I <: Sector}

Custom iterator to represent the (unique) fusion outputs of $a ⊗ b$.

Custom sectors that aim to use this have to provide the following functionality:

  • Base.iterate(::SectorProductIterator{I}, state...) where {I <: Sector}: iterate over the fusion outputs of a ⊗ b

If desired and it is possible to easily compute the number of unique fusion outputs, it is also possible to define Base.IteratorSize(::Type{SectorProductIterator{I}}) = Base.HasLength(), in which case Base.length(::SectorProductIterator{I}) has to be implemented.

See also ⊗.

source
TensorKitSectors.SectorValues — Type
struct SectorValues{I <: Sector}

Singleton type to represent an iterator over the possible values of type I, whose instance is obtained as values(I). For a new I::Sector, the following should be defined

  • Base.iterate(::SectorValues{I}[, state]): iterate over the values
  • Base.IteratorSize(::Type{SectorValues{I}}): HasLength(), SizeUnknown() or IsInfinite() depending on whether the number of values of type I is finite (and sufficiently small) or infinite; for a large number of values, SizeUnknown() is recommended because this will trigger the use of GenericGradedSpace.

If IteratorSize(I) == HasLength(), also the following must be implemented:

  • Base.length(::SectorValues{I}): the number of different values
  • Base.getindex(::SectorValues{I}, i::Int): a mapping between an index i and an instance of I. A fallback implementation exists that returns the ith value of the SectorValues iterator.
  • findindex(::SectorValues{I}, c::I): reverse mapping between a value c::I and an index i::Integer ∈ 1:length(values(I)). A fallback implementation exists that linearly searches through the SectorValues iterator.
source
TensorKitSectors.SimpleFusion — Type
struct SimpleFusion <: MultipleFusion

Fusion style where multiple outputs c can appear in a ⊗ b, but each appears at most once. As a result, $N_c^{ab} ≤ 1$ and no multiplicity labels are needed.

See also FusionStyle.

source
TensorKitSectors.SimpleUnit — Type
struct SimpleUnit <: UnitStyle

Unit style for fusion categories with a unique unit (identity) object. The unit satisfies $\mathbb{1} ⊗ a ≅ a ≅ a ⊗ \mathbb{1}$ for all sectors.

See also UnitStyle.

source
TensorKitSectors.TambaraYamagami — Type
struct TambaraYamagami{N, K} <: Sector
TambaraYamagami{N, K}(n::Integer)

Represents the Tambara-Yamagami fusion category built from the cyclic group $ℤ_N$. The simple objects are the group elements 0, 1, …, N - 1 of $ℤ_N$, together with a single non-invertible object m.

The non-trivial fusion rules are given by

\[g ⊗ h = g + h \mod N, \qquad g ⊗ m = m ⊗ g = m, \qquad m ⊗ m = \bigoplus_{g ∈ ℤ_N} g.\]

The F-symbols are constructed from a non-degenerate symmetric bicharacter $χ(g, h) = \exp(2π i g h / N)$, together with a Frobenius-Schur sign for the non-invertible object; the latter is fixed as κ = (-1)^K through the type parameter K::Bool. For fixed N, the two choices K = false (κ = 1) and K = true (κ = -1) generally give distinct fusion categories.

Only the case N == 2 and K == false admits a braiding, as this case coincides with Ising, but this is not currently implemented.

Fields

  • n::UInt8: a group element for 0 <= n < N, or the non-invertible object m for n == N.

References

[1] D. Tambara and S. Yamagami, Tensor categories with fusion rules of self-duality for finite abelian groups, J. Algebra 209, 692-707 (1998). [2] M. Barkeshli, P. Bonderson, M. Cheng and Z. Wang, Symmetry Fractionalization, Defects, and Gauging of Topological Phases, Phys. Rev. B 100, 115147 (2019), arXiv:1410.4540.

source
TensorKitSectors.TimeReversed — Type
struct TimeReversed{I <: Sector}
TimeReversed(a::Sector)
timereversed(a::Sector)

Represents the time-reversed version of the sector a, i.e. the sector with the same fusion rules and F-symbols, but with the inverse braiding. Time reversal acts trivially on sectors with symmetric braiding. In such cases, timereversed(a) simply returns a.

source
TensorKitSectors.Trivial — Type
struct Trivial <: Sector
Trivial()

Singleton type to represent the trivial sector, i.e. the trivial representation of the trivial group. This is equivalent to Rep[ℤ₁], or the unit object of the category Vect of ordinary vector spaces.

source
TensorKitSectors.U1Irrep — Type
struct U1Irrep <: AbstractIrrep{U₁}
U1Irrep(charge::Real)
Irrep[U₁](charge::Real)

Represents irreps of the group $U₁$. The irrep is labelled by a charge, which should be an integer for a linear representation. However, it is often useful to allow half integers to represent irreps of $U₁$ subgroups of $SU₂$, such as the $S^z$ of spin-1/2 system. Hence, the charge is stored as a HalfInt from the package HalfIntegers.jl, but can be entered as arbitrary Real. The sequence of the charges is: 0, 1/2, -1/2, 1, -1, ...

Fields

  • charge::HalfInt: the label of the irrep, which can be any half integer.
source
TensorKitSectors.UniqueFusion — Type
struct UniqueFusion <: FusionStyle

Fusion style where every product a ⊗ b has exactly one output c. As a result, $N_c^{ab} ≤ 1$ and no multiplicity labels are needed.

See also FusionStyle.

source
TensorKitSectors.UnitStyle — Type
abstract type UnitStyle
UnitStyle(::Sector)
UnitStyle(I::Type{<:Sector})

Trait to describe the semisimplicity of the unit sector of type I. This can be either

  • SimpleUnit: the unit is simple (e.g. fusion categories).
  • GenericUnit: the unit is semisimple (e.g. multifusion categories).
source
TensorKitSectors.U₁ — Type
abstract type U₁ <: AbelianGroup

Type to represent the group $U(1)$ of complex numbers of unit modulus, which is a compact Abelian Lie group.

source
TensorKitSectors.ZNElement — Type
struct ZNElement{N, p} <: AbstractGroupElement{ℤ{N}}
ZNElement{N, p}(n::Integer)
GroupElement[ℤ{N}, p](n::Integer)

Represents an element of the group $ℤ_N$ for some value of N < 64. (We need 2 * (N - 1) <= 127 in order for a ⊗ b to work correctly.) For N equals 2, 3 or 4, ℤ{N} can be replaced by ℤ₂, ℤ₃, ℤ₄. An arbitrary Integer n can be provided to the constructor, but only the value mod(n, N) is relevant. The second type parameter p should also be specified as an integer 0 <= p < N and specifies the 3-cocycle, which is then being given by

cocycle(a, b, c) = cispi(2 * p * a.n * (b.n + c.n - mod(b.n + c.n, N)) / N^2))

If p is not specified, it defaults to 0, i.e. the trivial cocycle.

Fields

  • n::Int8: the integer label of the element, modulo N.
source
TensorKitSectors.ZNIrrep — Type
struct ZNIrrep{N} <: AbstractIrrep{ℤ{N}}
ZNIrrep{N}(n::Integer)
Irrep[ℤ{N}](n::Integer)

Represents irreps of the group $ℤ_N$ for some value of N. For N equals 2, 3 or 4, ℤ{N} can be replaced by ℤ₂, ℤ₃, and ℤ₄. An arbitrary Integer n can be provided to the constructor, but only the value mod(n, N) is relevant.

The type of the stored integer (UInt8) requires N ≤ 128. Larger values of N should use the LargeZNIrrep instead. The constructor Irrep[ℤ{N}] should be preferred, as it will automatically select the most efficient storage type for a given value of N.

See also charge and modulus to extract the relevant data.

Fields

  • n::UInt8: the integer label of the irrep, modulo N.
source
Base.isreal — Method
isreal(::Type{<:Sector}) -> Bool

Return whether the topological data (Fsymbol, Rsymbol) of the sector is real or not (in which case it is complex).

source
TensorKitSectors.:× — Method
×(G::Vararg{Type{<:Group}}) -> ProductGroup{Tuple{G...}}
times(G::Vararg{Type{<:Group}}) -> ProductGroup{Tuple{G...}}

Construct the direct product of a (list of) groups.

source
TensorKitSectors.:⊗ — Function
⊗(a::I, b::I...) where {I <: Sector}
otimes(a::I, b::I...) where {I <: Sector}

Return an iterable of elements of c::I that appear in the fusion product a ⊗ b. Each sector c should appear at most once in this iteration, even if the multiplicity $N_c^{ab} > 1$. The actual multiplicities are accessed separately through Nsymbol.

The return type is typically SectorProductIterator{I} which provides a type-stable iterable that supports pretty-printing, but could also be any custom iterable.

See also FusionStyle for the trait associated to the fusion behavior of a given sector type.

source
TensorKitSectors.:⊠ — Method
⊠(s₁::Sector, s₂::Sector, ...)
⊠(; name₁::Sector=s₁, name₂::Sector=s₂, ...)
deligneproduct(s₁::Sector, s₂::Sector, ...)
deligneproduct(; name₁::Sector=s₁, name₂::Sector=s₂, ...)

Given two sectors s₁ and s₂, which label an isomorphism class of simple objects in a fusion category $C₁$ and $C₂$, s1 ⊠ s2 (obtained as \boxtimes+TAB) labels the isomorphism class of simple objects in the Deligne tensor product category $C₁ ⊠ C₂$.

The Deligne tensor product also works in the type domain and for spaces and tensors. For group representations, we have Irrep[G₁] ⊠ Irrep[G₂] == Irrep[G₁ × G₂].

source
TensorKitSectors.Asymbol — Method
Asymbol(a::I, b::I, c::I) where {I <: Sector}

Return the value of $A^{ab}_c$ which appears in transforming a splitting vertex into a fusion vertex using the transformation

a -<-μ-<- c                                                    b -<-ν-<- dual(a)
     ∨       -> √(dim(c) / dim(b)) * Asymbol(a, b, c)[μ, ν]         ∧
     b                                                              c

If FusionStyle(I) is UniqueFusion() or SimpleFusion(), the A-symbol is a number. Otherwise it is a square matrix with row and column size Nsymbol(a, b, c) == Nsymbol(dual(a), c, b).

source
TensorKitSectors.Bsymbol — Method
Bsymbol(a::I, b::I, c::I) where {I <: Sector}

Return the value of $B^{ab}_c$ which appears in transforming a splitting vertex into a fusion vertex using the transformation

a -<-μ-<- c                                                    a -<-ν-<- c
     ∨       -> √(dim(c) / dim(a)) * Bsymbol(a, b, c)[μ, ν]         ∧
     b                                                            dual(b)

If FusionStyle(I) is UniqueFusion() or SimpleFusion(), the B-symbol is a number. Otherwise it is a square matrix with row and column size Nsymbol(a, b, c) == Nsymbol(c, dual(b), a).

source
TensorKitSectors.Fsymbol — Function
Fsymbol(a::I, b::I, c::I, d::I, e::I, f::I) where {I <: Sector}

Return the F-symbol $F^{abc}_d$ that associates the two different fusion orders of sectors a, b and c into an ouput sector d, using either an intermediate sector $a ⊗ b → e$ or $b ⊗ c → f$:

a-<-μ-<-e-<-ν-<-d                                     a-<-λ-<-d
    ∨       ∨       -> Fsymbol(a,b,c,d,e,f)[μ,ν,κ,λ]      ∨
    b       c                                             f
                                                          v
                                                      b-<-κ
                                                          ∨
                                                          c

If FusionStyle(I) is UniqueFusion or SimpleFusion, the F-symbol is a number. Otherwise it is a rank 4 array of size (Nsymbol(a, b, e), Nsymbol(e, c, d), Nsymbol(b, c, f), Nsymbol(a, f, d)).

source
TensorKitSectors.Nsymbol — Function
Nsymbol(a::I, b::I, c::I) where {I <: Sector} -> Integer

The fusion multiplicity $N_c^{ab}$, indicating how many times sector c appears in the fusion product a ⊗ b.

The return type depends on the FusionStyle, where UniqueFusion and SimpleFusion return Bool values, while GenericFusion returns Int.

See also ⊗ to obtain the set of sectors c that appear in a ⊗ b.

source
TensorKitSectors.Rsymbol — Function
Rsymbol(a::I, b::I, c::I) where {I <: Sector}

Returns the R-symbol $R^{ab}_c$ that maps between $c → a ⊗ b$ and $c → b ⊗ a$ as in

a -<-μ-<- c                                 b -<-ν-<- c
     ∨        -> Rsymbol(a, b, c)[μ, ν]          v
     b                                           a

If FusionStyle(I) is UniqueFusion() or SimpleFusion(), the R-symbol is a number. Otherwise it is a square matrix with row and column size Nsymbol(a, b, c) == Nsymbol(b, a, c).

source
TensorKitSectors.Smatrix — Method
 Smatrix(::Type{I}) where {I <: Sector}

Return the S-matrix of the sector type I, which is a matrix containing the hopflinks of all pairs of sectors of type I, with the second sector being taken dual. The S-matrix is not normalized by the total quantum dimension here.

source
TensorKitSectors.Tmatrix — Method
Tmatrix(::Type{I}) where {I <: Sector}

Return the T-matrix of the sector type I, which is a diagonal matrix containing the twists of all sectors of type I.

source
TensorKitSectors.allunits — Method
allunits(I::Type{<:Sector}) -> Tuple{I}

Return a tuple with all units of the sector type I. For fusion categories, this will contain only one element.

source
TensorKitSectors.dim — Method
dim(::Type{I}) where {I <: Sector}

Return the total quantum dimension D of the sector type I, which is defined as the square root of the sum of the squares of the quantum dimensions of all sectors of type I, i.e. D = √(∑ₐ dₐ²).

source
TensorKitSectors.dimscalartype — Method
dimscalartype(::Type{<:Sector}) -> Type{<:Number}

Return the scalar type of the quantum dimensions associated to sectors of type I. In particular, this is the scalar type of dim.

source
TensorKitSectors.dual — Method
dual(a::Sector) -> Sector

Return the dual label of a, i.e. the unique label ā = dual(a) such that Nsymbol(a, ā, leftunit(a)) == 1 and Nsymbol(ā, a, rightunit(a)) == 1.

source
TensorKitSectors.findindex — Method
findindex(v::SectorValues{I}, c::I)

Reverse mapping between a value c::I and an index i::Integer ∈ 1:length(values(I)).

source
TensorKitSectors.frobenius_schur_indicator — Method
frobenius_schur_indicator(a::Sector)

Return the Frobenius-Schur indicator of a sector $νₐ ∈ \{1, 0, -1\}$, which distinguishes between real, complex and quaternionic representations.

See also frobenius_schur_phase for the category-theoretic version that appears in the context of line bending.

source
TensorKitSectors.frobenius_schur_phase — Method
frobenius_schur_phase(a::Sector)

Return the Frobenius-Schur phase $κₐ$ of a sector $a$, which is a complex phase that appears in the context of bending lines and is obtained from $F^{a a̅ a}_a$. When a == dual(a), it is restricted to $κₐ ∈ \{1, -1\}$ and coincides with the group-theoretic version frobenius_schur_indicator. When a != dual(a), the value of $κₐ$ can be gauged to be 1, though is not required to be.

source
TensorKitSectors.fusiontensor — Method
fusiontensor(a::I, b::I, c::I) where {I <: Sector} -> AbstractArray{T, 4}

Return the fusion tensor for the fusion a ⊗ b -> c. The dimensions of the returned array are (dim(a), dim(b), dim(c), Nsymbol(a, b, c)). The components of the fusion tensor are simply the Clebsch-Gordan coefficients, describing the unitary basis change from the tensor product of irreps a and b to the coupled irrep c.

source
TensorKitSectors.hexagon_equation — Method
hexagon_equation(a::I, b::I, c::I; kwargs...) where {I <: Sector} -> Bool

Check whether the hexagon equations hold for braiding the sector a around the fusion product of b and c along the two different paths. There are two hexagon equations, one for braiding a over b ⊗ c and one for braiding a under b ⊗ c.

If kwargs are provided, they are forwarded to isapprox when comparing the two sides of the hexagon equations.

source
TensorKitSectors.hopflink — Method

hopflink(a::I, b::I) where {I <: Sector}

Return the hopflink of sectors a and b, which is defined as the trace of the double braiding between a and b.

source
TensorKitSectors.invsqrtdim — Method
invsqrtdim(a::Sector)

Return the inverse square root of the (quantum) dimension of sector a.

This is a performance specialization that avoids computing inv(sqrt(1)) for sectors with UniqueFusion, preserving the number type (returning 1::Int instead of 1.0::Float64). For other sectors, it is equivalent to inv(sqrt(dim(a))).

source
TensorKitSectors.leftunit — Method
leftunit(a::Sector) -> Sector

Return the left unit element corresponding to a; this is necessary for multifusion categories, where the unit may not be unique. See also rightunit and unit.

source
TensorKitSectors.modulus — Method
modulus(n::TambaraYamagami{N, K}) -> N
modulus(::Type{<:TambaraYamagami{N, K}}) -> N

The order of the cyclic group, or the modulus of the charge labels.

source
TensorKitSectors.modulus — Method
modulus(c::ZNIrrep{N}) -> N
modulus(::Type{<:ZNIrrep{N}}) -> N

The order of the cyclic group, or the modulus of the charge labels.

source
TensorKitSectors.pentagon_equation — Method
pentagon_equation(a::I, b::I, c::I, d::I; kwargs...) where {I <: Sector} -> Bool

Check whether the pentagon equation holds for fusing the sectors a, b, c and d to each of their sectors along the two different fusion paths.

If kwargs are provided, they are forwarded to isapprox when comparing the two sides of the pentagon equation.

source
TensorKitSectors.rightunit — Method
rightunit(a::Sector) -> Sector

Return the right unit element corresponding to a; this is necessary for multifusion categories, where the unit may not be unique. See also leftunit and unit.

source
TensorKitSectors.sqrtdim — Method
sqrtdim(a::Sector)

Return the square root of the (quantum) dimension of sector a.

This is a performance specialization that avoids computing sqrt(1) for sectors with UniqueFusion, preserving the number type (returning 1::Int instead of 1.0::Float64). For other sectors, it is equivalent to sqrt(dim(a)).

source
TensorKitSectors.timereversed — Method
timereversed(a::Sector)

Return the time-reversed version of the sector a. If a is already a time-reversed sector, return the original sector.

source
TensorKitSectors.topological_central_charge — Method
topological_central_charge(::Type{I}) where {I <: Sector}

Return the topological central charge c of the braided sector type I, where c is determined mod 8. We choose convention by restrict the returning value as rational numbers in (-4, 4].

source
TensorKitSectors.topological_spin — Method
topological_spin(a::Sector)

Return the topological spin of a sector a. Here we assume the range of the output as rational numbers within (-1 / 2, 1 / 2].

source
TensorKitSectors.type_repr — Method
type_repr(T::Type)

Return a string representation of the type T, which is used to modify the default way in which Sector subtypes are displayed in other objects that depend on them.

source
TensorKitSectors.unit — Method
unit(::Sector) -> Sector
unit(::Type{<:Sector}) -> Sector

Return the unit element of this type of sector, provided it is unique.

source
TensorKitSectors.@NamedSector — Macro
@NamedSector{name₁::T₁, name₂::T₂, ...}

Convenience macro for constructing a NamedSector type with named components, analogous to @NamedTuple.

Examples

julia> @NamedSector{charge::U1Irrep, spin::SU2Irrep}
NamedSector{@NamedTuple{charge::U1Irrep, spin::SU2Irrep}}

julia> (@NamedSector{charge::U1Irrep, spin::SU2Irrep})(U1Irrep(1), SU2Irrep(1//2))
NamedSector(; charge=Irrep[U₁](1), spin=Irrep[SU₂](1/2))
source