HaskellForMaths-0.4.8: Combinatorics, group theory, commutative algebra, non-commutative algebra

Safe HaskellNone
LanguageHaskell98

Math.Algebras.TensorAlgebra

Description

A module defining the tensor algebra, symmetric algebra, exterior (or alternating) algebra, and tensor coalgebra

Synopsis

Documentation

data TensorAlgebra a Source

A data type representing basis elements of the tensor algebra over a set/type. Elements of the tensor algebra are linear combinations of iterated tensor products of elements of the set/type. If V = Vect k a is the free vector space over a, then the tensor algebra T(V) = Vect k (TensorAlgebra a) is isomorphic to the infinite direct sum:

T(V) = k ⊕ V ⊕ V⊗V ⊕ V⊗V⊗V ⊕ ...

Constructors

TA Int [a] 

Instances

(Eq k, Num k, Ord a) => Algebra k (TensorAlgebra a) 
Eq a => Eq (TensorAlgebra a) 
Ord a => Ord (TensorAlgebra a) 
Show a => Show (TensorAlgebra a) 
Mon (TensorAlgebra a) 

injectTA :: Num k => Vect k a -> Vect k (TensorAlgebra a) Source

Inject an element of the free vector space V = Vect k a into the tensor algebra T(V) = Vect k (TensorAlgebra a)

injectTA' :: (Eq k, Num k) => a -> Vect k (TensorAlgebra a) Source

Inject an element of the set/type A/a into the tensor algebra T(A) = Vect k (TensorAlgebra a).

liftTA :: (Eq k, Num k, Ord b, Show b, Algebra k b) => (Vect k a -> Vect k b) -> Vect k (TensorAlgebra a) -> Vect k b Source

Given vector spaces A = Vect k a, B = Vect k b, where B is also an algebra, lift a linear map f: A -> B to an algebra morphism f': T(A) -> B, where T(A) is the tensor algebra Vect k (TensorAlgebra a). f' will agree with f on A itself (considered as a subspace of T(A)). In other words, f = f' . injectTA

liftTA' :: (Eq k, Num k, Ord b, Show b, Algebra k b) => (a -> Vect k b) -> Vect k (TensorAlgebra a) -> Vect k b Source

Given a set/type A/a, and a vector space B = Vect k b, where B is also an algebra, lift a function f: A -> B to an algebra morphism f': T(A) -> B. f' will agree with f on A itself. In other words, f = f' . injectTA'

fmapTA :: (Eq k, Num k, Ord b, Show b) => (Vect k a -> Vect k b) -> Vect k (TensorAlgebra a) -> Vect k (TensorAlgebra b) Source

Tensor algebra is a functor from k-Vect to k-Alg. The action on objects is Vect k a -> Vect k (TensorAlgebra a). The action on arrows is f -> fmapTA f.

fmapTA' :: (Eq k, Num k, Ord b, Show b) => (a -> b) -> Vect k (TensorAlgebra a) -> Vect k (TensorAlgebra b) Source

If we compose the free vector space functor Set -> k-Vect with the tensor algebra functor k-Vect -> k-Alg, we obtain a functor Set -> k-Alg, the free algebra functor. The action on objects is a -> Vect k (TensorAlgebra a). The action on arrows is f -> fmapTA' f.

bindTA :: (Eq k, Num k, Ord b, Show b) => Vect k (TensorAlgebra a) -> (Vect k a -> Vect k (TensorAlgebra b)) -> Vect k (TensorAlgebra b) Source

bindTA' :: (Eq k, Num k, Ord b, Show b) => Vect k (TensorAlgebra a) -> (a -> Vect k (TensorAlgebra b)) -> Vect k (TensorAlgebra b) Source

data SymmetricAlgebra a Source

A data type representing basis elements of the symmetric algebra over a set/type. The symmetric algebra is the quotient of the tensor algebra by the ideal generated by all differences of products u⊗v - v⊗u.

Constructors

Sym Int [a] 

Instances

toSym :: (Eq k, Num k, Ord a) => Vect k (TensorAlgebra a) -> Vect k (SymmetricAlgebra a) Source

Algebra morphism from tensor algebra to symmetric algebra. The kernel of the morphism is the ideal generated by all differences of products u⊗v - v⊗u.

liftSym :: (Eq k, Num k, Ord b, Show b, Algebra k b) => (Vect k a -> Vect k b) -> Vect k (SymmetricAlgebra a) -> Vect k b Source

liftSym' :: (Eq k, Num k, Ord b, Show b, Algebra k b) => (a -> Vect k b) -> Vect k (SymmetricAlgebra a) -> Vect k b Source

fmapSym :: (Eq k, Num k, Ord b, Show b) => (Vect k a -> Vect k b) -> Vect k (SymmetricAlgebra a) -> Vect k (SymmetricAlgebra b) Source

fmapSym' :: (Eq k, Num k, Ord b, Show b) => (a -> b) -> Vect k (SymmetricAlgebra a) -> Vect k (SymmetricAlgebra b) Source

bindSym :: (Eq k, Num k, Ord b, Show b) => Vect k (SymmetricAlgebra a) -> (Vect k a -> Vect k (SymmetricAlgebra b)) -> Vect k (SymmetricAlgebra b) Source

bindSym' :: (Eq k, Num k, Ord b, Show b) => Vect k (SymmetricAlgebra a) -> (a -> Vect k (SymmetricAlgebra b)) -> Vect k (SymmetricAlgebra b) Source

data ExteriorAlgebra a Source

A data type representing basis elements of the exterior algebra over a set/type. The exterior algebra is the quotient of the tensor algebra by the ideal generated by all self-products u⊗u and sums of products u⊗v + v⊗u

Constructors

Ext Int [a] 

Instances

(Eq k, Num k, Ord a) => Algebra k (ExteriorAlgebra a) 
Eq a => Eq (ExteriorAlgebra a) 
Ord a => Ord (ExteriorAlgebra a) 
Show a => Show (ExteriorAlgebra a) 

toExt :: (Eq k, Num k, Ord a) => Vect k (TensorAlgebra a) -> Vect k (ExteriorAlgebra a) Source

Algebra morphism from tensor algebra to exterior algebra. The kernel of the morphism is the ideal generated by all self-products u⊗u and sums of products u⊗v + v⊗u

signedSort :: (Ord t1, Num t) => t -> Bool -> [t1] -> [t1] -> (t, [t1]) Source

liftExt :: (Eq k, Num k, Ord b, Show b, Algebra k b) => (Vect k a -> Vect k b) -> Vect k (ExteriorAlgebra a) -> Vect k b Source

liftExt' :: (Eq k, Num k, Ord b, Show b, Algebra k b) => (a -> Vect k b) -> Vect k (ExteriorAlgebra a) -> Vect k b Source

fmapExt :: (Eq k, Num k, Ord b, Show b) => (Vect k a -> Vect k b) -> Vect k (ExteriorAlgebra a) -> Vect k (ExteriorAlgebra b) Source

fmapExt' :: (Eq k, Num k, Ord b, Show b) => (a -> b) -> Vect k (ExteriorAlgebra a) -> Vect k (ExteriorAlgebra b) Source

bindExt :: (Eq k, Num k, Ord b, Show b) => Vect k (ExteriorAlgebra a) -> (Vect k a -> Vect k (ExteriorAlgebra b)) -> Vect k (ExteriorAlgebra b) Source

bindExt' :: (Eq k, Num k, Ord b, Show b) => Vect k (ExteriorAlgebra a) -> (a -> Vect k (ExteriorAlgebra b)) -> Vect k (ExteriorAlgebra b) Source

data TensorCoalgebra c Source

Constructors

TC Int [c] 

Instances

(Eq k, Num k, Ord c) => Coalgebra k (TensorCoalgebra c) 
Eq c => Eq (TensorCoalgebra c) 
Ord c => Ord (TensorCoalgebra c) 
Show c => Show (TensorCoalgebra c) 

projectTC :: (Eq k, Num k, Ord b) => Vect k (TensorCoalgebra b) -> Vect k b Source

coliftTC :: (Eq k, Num k, Coalgebra k c, Ord d) => (Vect k c -> Vect k d) -> Vect k c -> Vect k (TensorCoalgebra d) Source

coliftTC' :: (Coalgebra k b, Ord c, Num k, Monad m, Eq k) => Int -> (m b -> Vect k c) -> Vect k b -> Vect k (TensorCoalgebra c) Source

cobindTC :: (Eq k, Num k, Ord c, Ord d) => (Vect k (TensorCoalgebra c) -> Vect k d) -> Vect k (TensorCoalgebra c) -> Vect k (TensorCoalgebra d) Source