combinat-0.2.10.1: Generate and manipulate various combinatorial objects.
Safe HaskellSafe-Inferred
LanguageHaskell2010

Math.Combinat.RootSystems

Description

Naive (very inefficient) algorithm to generate the irreducible (Dynkin) root systems

Based on https://en.wikipedia.org/wiki/Root_system

Synopsis

Half-integers

newtype HalfInt Source #

The type of half-integers (internally represented by their double)

TODO: refactor this into its own module

Constructors

HalfInt Int 

Vectors of half-integers

safeZip :: (a -> b -> c) -> [a] -> [b] -> [c] Source #

Dynkin diagrams

data Dynkin Source #

Constructors

A !Int 
B !Int 
C !Int 
D !Int 
E6 
E7 
E8 
F4 
G2 

Instances

Instances details
Show Dynkin Source # 
Instance details

Defined in Math.Combinat.RootSystems

Eq Dynkin Source # 
Instance details

Defined in Math.Combinat.RootSystems

Methods

(==) :: Dynkin -> Dynkin -> Bool #

(/=) :: Dynkin -> Dynkin -> Bool #

The roots of root systems

ambientDim :: Dynkin -> Int Source #

The ambient dimension of (our representation of the) system (length of the vector)

Positive roots

findPositiveHyperplane :: [HalfVec] -> [Double] Source #

Finds a vector, which is hopefully not orthognal to any root (generated by the given simple roots), and has positive dot product with each of them.

Operations on half-integer vectors

bracket :: HalfVec -> HalfVec -> HalfInt Source #

bracket b a = (a,b)/(a,a)

mirror :: HalfVec -> HalfVec -> HalfVec Source #

mirror b a = b - 2*(a,b)/(a,a) * a

cartanMatrix :: [HalfVec] -> Array (Int, Int) Int Source #

Cartan matrix of a list of (simple) roots

printMatrix :: Show a => Array (Int, Int) a -> IO () Source #

Mirroring

mirrorClosure :: [HalfVec] -> Set HalfVec Source #

We mirror stuff until there is no more things happening (very naive algorithm, but seems to work)

E6, E7 and E8

simpleRootsE6_123 :: [HalfVec] Source #

This is a basis of E6 as the subset of the even E8 root system where the first three coordinates agree (they are consolidated into the first coordinate here)

simpleRootsE7_12 :: [HalfVec] Source #

This is a basis of E8 as the subset of the even E8 root system where the first two coordinates agree (they are consolidated into the first coordinate here)

simpleRootsE7_diag :: [HalfVec] Source #

This is a basis of E7 as the subset of the even E8 root system for which the sum of coordinates sum to zero