Vector Space Categories
Vector spaces in TensorCategories are of the abstract type
abstract type VectorSpaceObject <: Object end
All objects with vector space structure like hom-spaces are and should be implemented as a subtype of this type. They always need the following fields:
basis::Vector
parent::Category
Finite Dimensional VectorSpaces
The simplest example to provide are the finite dimensional vector spaces over a field. This category has type
VectorSpaces <: TensorCategory
and can be constructed like so:
F = GF(5,2)
Vec = VectorSpaces(F)
Category of finite dimensional VectorSpaces over Finite field of degree 2 and characteristic 5
Objects of this category are of the type
VSObject <: VectorSpaceObject
Every vector space object is defined by a basis and a base field provided by the parent category.
TensorCategories.VectorSpaceObject
— TypeVectorSpaceObject
An object in the category of finite dimensional vector spaces.
TensorCategories.VectorSpaceObject
— MethodVectorSpaceObject(Vec::VectorSpaces, n::Int64)
VectorSpaceObject(K::Field, n::Int)
VectorSpaceObject(Vec::VectorSpaces, basis::Vector)
VectorSpaceObject(K::Field, basis::Vector)
The n-dimensional vector space with basis v1,..,vn (or other specified basis)
Morphisms in this Category are defined only by matrices of matching dimensions. They are typed as
VSMorphism <: Morphism
and constructed giving a domain, codomain and matrix element.
TensorCategories.Morphism
— MethodMorphism(X::VectorSpaceObject, Y::VectorSpaceObject, m::MatElem)
Return a morphism in the category of vector spaces defined by m.
Graded Vector Spaces
Very similar we have the category of finite dimensional (twisted) $G$-graded vector spaces for a finite group $G$. We have the type
GradedVectorSpaces <: VectorSpaces
and they are constructed in straightforward manner
G = symmetric_group(6)
VecG = GradedVectorSpaces(G)
Category of G-graded vector spaces over Field of algebraic numbers where G is Sym(6)
To add a non-trivial associator (twist) there is another constructor.
TensorCategories.TwistedGradedVectorSpaces
— FunctionTwistedGradedVectorSpaces(G::GAPGroup, i::Int)
Construct the category of twisted graded vectorspaces with the i-th 3-cocycle.
Graded vector spaces decompose into direct sums of vector spaces for each element in $G$.
GVSObject <: VectorSpaceObject
G = symmetric_group(5)
g,s = gens(G)
V1 = VectorSpaceObject(QQ,5)
V2 = VectorSpaceObject(QQ, [:v, :w])
W = VectorSpaceObject(g => V1, s => V2, g*s => V1⊗V2)
Graded vector space of dimension 17 with grading
PermGroupElem[(1,2,3,4,5), (1,2,3,4,5), (1,2,3,4,5), (1,2,3,4,5), (1,2,3,4,5), (1,2), (1,2), (2,3,4,5), (2,3,4,5), (2,3,4,5), (2,3,4,5), (2,3,4,5), (2,3,4,5), (2,3,4,5), (2,3,4,5), (2,3,4,5), (2,3,4,5)]
Morphisms are implemented analogously by pairs of group elements and vector space objects.
GVSMorphism <: Morphism
The constructor is given by
TensorCategories.Morphism
— Methodfunction Morphism(V::GVSObject, Y::GVSObject, m::MatElem)
Return the morphism $V → W$defined by $m$.
Functionality
(Graded) vector spaces form a fusion category. Thus the methods for direct sums, tensor products, dual, one and zero object are all implemented.
AbstractAlgebra.Generic.dim
— Methoddim(V::VectorSpaceObject) = length(V.basis)
Return the vector space dimension of $V$.
AbstractAlgebra.direct_sum
— Methodfunction direct_sum(V::GVSObject, W::GVSObject)
Return the direct sum object $V⊕W$.
AbstractAlgebra.direct_sum
— Methoddirect_sum(f::VectorSpaceMorphism{T},g::VectorSpaceMorphism{T}) where T
Return the direct sum of morphisms of vector spaces.
AbstractAlgebra.direct_sum
— Methoddirect_sum(X::VectorSpaceObject{T}, Y::VectorSpaceObject{T}) where {T}
Direct sum of vector spaces together with the embedding morphisms.
AbstractAlgebra.is_isomorphic
— Methodfunction is_isomorphic(V::GVSObject, W::GVSObject)
Check whether $V$and $W$are isomorphic as $G$-graded vector spaces and return an isomorphism in the positive case.
AbstractAlgebra.is_isomorphic
— Methodis_isomorphic(V::VSObject, W::VSObject)
Check whether $V$ and $W$are isomorphic. Return the isomorphisms if existent.
AbstractAlgebra.kernel
— Methodfunction kernel(f::GVSMorphism)
Return the graded vector space kernel of $f$.
Base.one
— Methodfunction one(C::GradedVectorSpaces)
Return $k$ as the one dimensional graded vector space.
Base.one
— Methodone(Vec::VectorSpaces) = VectorSpaceObject(base_ring(Vec),1)
Return the one-dimensional vector space.
Base.zero
— Methodfunction zero(C::GradedVectorSpaces)
Return the zero diemsnional graded vector space.
Base.zero
— Methodzero(Vec::VectorSpaces) = VectorSpaceObject(base_ring(Vec), 0)
Return the zero-dimensional vector space.
Hecke.cokernel
— Methodfunction cokernel(f::GVSMorphism)
Return the graded vector space cokernel of $f$.
Hecke.decompose
— Methodfunction decompose(V::GVSObject)
Return a vector with the simple objects together with their multiplicities $[V:Xi]$.
Hecke.dual
— Methodfunction dual(V::GVSObject)
Return the graded dual vector space of $V$.
Hecke.id
— Methodid(X::VectorSpaceObject{T}) where T
Return the identity on the vector space $X$.
Hecke.tensor_product
— Methodfunction tensor_product(V::GVSObject, W::GVSObject)
Return the tensor product $V⊗W$.
Hecke.tensor_product
— Methodtensor_product(f::VectorSpaceMorphism, g::VectorSpaceMorphism)
Return the tensor product of vector space morphisms.
Hecke.tensor_product
— Methodtensor_product(X::VectorSpaceObject{T}, Y::VectorSpaceObject{T}) where {T,S1,S2}
Return the tensor product of vector spaces.
TensorCategories.Hom
— Methodfunction Hom(V::GVSObject, W::GVSObject)
Return the space of morphisms between graded vector spaces $V$ and $W$.
TensorCategories.Hom
— MethodHom(X::VectorSpaceObject, Y::VectorSpaceObject)
Return the Hom($X,Y$`) as a vector space.
TensorCategories.associator
— Methodfunction associator(U::GVSObject, V::GVSObject, W::GVSObject)
return the associator isomorphism $(U⊗V)⊗W → U⊗(V⊗W)$.
TensorCategories.associator
— Methodassociator(X::VectorSpaceObject, Y::VectorSpaceObject, Z::VectorSpaceObject)
Return the associator isomorphism a::(X⊗Y)⊗Z -> X⊗(Y⊗Z).
TensorCategories.ev
— Methodfunction ev(V::GVSObject)
Return the evaluation map $V*⊗V → 𝟙$.
TensorCategories.simples
— Methodfunction simples(C::GradedVectorSpaces)
Return a vector containing the simple objects of $C$.