knots-0.1.0.1: Khovanov homology computations

Safe HaskellNone
LanguageHaskell98

Knots.Graded

Synopsis

Documentation

data Graded a Source

Constructors

Graded 

Fields

grade :: Int
 
components :: Map Int a
 

Instances

Functor Graded 
Foldable Graded 
Eq a => Eq (Graded a) 
Read a => Read (Graded a) 
Show a => Show (Graded a) 
(Monoid a, AbelianGroup a) => Monoid (Graded a) 
Default (Graded a) 
AbelianGroup a => AbelianGroup (Graded a) 
Ring r => Ring (Graded r)

This is practically multiplication of polynomials in one variable, if we interpret the keys of the components map as exponents. If we write r[X] for the ring of polynomials over r, then the grade can be interpreted as the degree of the variable X. This should justify how the instance is defined.

graded :: Int -> [(Int, a)] -> Graded a Source