oalg-base-1.1.4.0: Algebraic structures on oriented entities and limits as a tool kit to solve algebraic problems.
Copyright(c) Erich Gut
LicenseBSD3
Maintainerzerich.gut@gmail.com
Safe HaskellSafe-Inferred
LanguageHaskell2010

OAlg.Entity.Sum.SumSymbol

Contents

Description

free sums with symbols in a.

Synopsis

SumSymbol

newtype SumSymbol r a Source #

free sum with symbols in a.

Constructors

SumSymbol (Sum r (R a)) 

Instances

Instances details
(Semiring r, Show a) => Show (SumSymbol r a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Methods

showsPrec :: Int -> SumSymbol r a -> ShowS #

show :: SumSymbol r a -> String #

showList :: [SumSymbol r a] -> ShowS #

(Entity a, Entity r) => Eq (SumSymbol r a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Methods

(==) :: SumSymbol r a -> SumSymbol r a -> Bool #

(/=) :: SumSymbol r a -> SumSymbol r a -> Bool #

(Entity a, Entity r, Ord r, Ord a) => Ord (SumSymbol r a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Methods

compare :: SumSymbol r a -> SumSymbol r a -> Ordering #

(<) :: SumSymbol r a -> SumSymbol r a -> Bool #

(<=) :: SumSymbol r a -> SumSymbol r a -> Bool #

(>) :: SumSymbol r a -> SumSymbol r a -> Bool #

(>=) :: SumSymbol r a -> SumSymbol r a -> Bool #

max :: SumSymbol r a -> SumSymbol r a -> SumSymbol r a #

min :: SumSymbol r a -> SumSymbol r a -> SumSymbol r a #

(Distributive r, Total r, Commutative r, Entity a) => Validable (SumSymbol r a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Methods

valid :: SumSymbol r a -> Statement Source #

(Semiring r, Commutative r, Entity a) => Entity (SumSymbol r a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

(Distributive r, Total r, Commutative r, Ord a, Abelian r, Entity a) => Abelian (SumSymbol r a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Methods

negate :: SumSymbol r a -> SumSymbol r a Source #

(-) :: SumSymbol r a -> SumSymbol r a -> SumSymbol r a Source #

ztimes :: Z -> SumSymbol r a -> SumSymbol r a Source #

(Distributive r, Total r, Commutative r, Ord a, Entity a) => Additive (SumSymbol r a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Methods

zero :: Root (SumSymbol r a) -> SumSymbol r a Source #

(+) :: SumSymbol r a -> SumSymbol r a -> SumSymbol r a Source #

ntimes :: N -> SumSymbol r a -> SumSymbol r a Source #

(Semiring r, Commutative r, Entity a) => Fibred (SumSymbol r a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Associated Types

type Root (SumSymbol r a) Source #

Methods

root :: SumSymbol r a -> Root (SumSymbol r a) Source #

(Semiring r, Commutative r, Entity a, Ord a) => Euclidean (SumSymbol r a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Methods

(<!>) :: SumSymbol r a -> SumSymbol r a -> Scalar (SumSymbol r a) Source #

(Semiring r, Commutative r, Entity a, Ord a) => Vectorial (SumSymbol r a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Associated Types

type Scalar (SumSymbol r a) Source #

Methods

(!) :: Scalar (SumSymbol r a) -> SumSymbol r a -> SumSymbol r a Source #

type Root (SumSymbol r a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

type Root (SumSymbol r a) = ()
type Scalar (SumSymbol r a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

type Scalar (SumSymbol r a) = r

ssypsq :: Semiring r => SumSymbol r a -> PSequence a r Source #

the underlying partial sequence.

ssylc :: Semiring r => SumSymbol r a -> LinearCombination r a Source #

the underlying linear combination.

sumSymbol :: (Semiring r, Commutative r, Entity a, Ord a) => [(r, a)] -> SumSymbol r a Source #

the induced free sum given by a list of scalars and symbols.

sy :: (Semiring r, Commutative r, Entity a, Ord a) => a -> SumSymbol r a Source #

the induced free sum given by the symbol.

ssyMap :: (Semiring r, Commutative r, Entity y, Ord y) => (x -> y) -> SumSymbol r x -> SumSymbol r y Source #

mapping of free sums

ssySum :: (Semiring r, Commutative r, Entity y, Ord y) => (x -> LinearCombination r y) -> SumSymbol r x -> SumSymbol r y Source #

additive homomorphism given by a mapping of a symbol in x to a linear combination of y.

ssyJoin :: (Semiring r, Commutative r, Entity x, Ord x) => SumSymbol r (SumSymbol r x) -> SumSymbol r x Source #

joining a free sum of free sums to a free sum.

ssyprj :: (Semiring r, Commutative r, Ord a, Entity a) => Set a -> SumSymbol r a -> SumSymbol r a Source #

the projectin of a free sum according to the given set of symbols.

Definition Let x be in SumSymbol r a and s a Set of symbols in a, then x is called representable according to s iff all symbols of ssylc x are elements of s.

Property Let s be a set of symbols in a and x be representable in SumSymbol r a according to s, then ssyprj x == x.

Examples

>>> ssyprj (Set [A,D,E]) (3!sy D) :: SumSymbol Z Symbol
SumSymbol[3!D]
>>> ssyprj (Set [A,D,E]) (2!sy B) :: SumSymbol Z Symbol
SumSymbol[]
>>> ssyprj (Set [A,D,E]) (3!sy D + sy A - 5!sy E) :: SumSymbol Z Symbol
SumSymbol[A+3!D+-5!E]
>>> ssyprj (Set [A,D,E]) (2!sy D + 7!sy B - sy E + sy F) :: SumSymbol Z Symbol
SumSymbol[2!D+-1!E]

R

newtype R a Source #

adjoining the root ().

Constructors

R a 

Instances

Instances details
Show a => Show (R a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Methods

showsPrec :: Int -> R a -> ShowS #

show :: R a -> String #

showList :: [R a] -> ShowS #

Eq a => Eq (R a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Methods

(==) :: R a -> R a -> Bool #

(/=) :: R a -> R a -> Bool #

Ord a => Ord (R a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Methods

compare :: R a -> R a -> Ordering #

(<) :: R a -> R a -> Bool #

(<=) :: R a -> R a -> Bool #

(>) :: R a -> R a -> Bool #

(>=) :: R a -> R a -> Bool #

max :: R a -> R a -> R a #

min :: R a -> R a -> R a #

Validable a => Validable (R a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Methods

valid :: R a -> Statement Source #

Entity a => Entity (R a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Entity a => Fibred (R a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

Associated Types

type Root (R a) Source #

Methods

root :: R a -> Root (R a) Source #

OrdRoot (R a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

type Root (R a) Source # 
Instance details

Defined in OAlg.Entity.Sum.SumSymbol

type Root (R a) = ()