mpolynomials-0.1.0.0: Simple multivariate polynomials.
Safe HaskellNone
LanguageHaskell2010

MultiPol

Synopsis

Documentation

data Polynomial a Source #

Instances

Instances details
(C a, Eq a) => C a (Polynomial a) Source # 
Instance details

Defined in MultiPol

Methods

(*>) :: a -> Polynomial a -> Polynomial a #

(C a, Eq a) => Eq (Polynomial a) Source # 
Instance details

Defined in MultiPol

Methods

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

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

Show a => Show (Polynomial a) Source # 
Instance details

Defined in MultiPol

(C a, Eq a) => C (Polynomial a) Source # 
Instance details

Defined in MultiPol

(C a, Eq a) => C (Polynomial a) Source # 
Instance details

Defined in MultiPol

data CompactPolynomial a Source #

Instances

Instances details
(C a, Eq a) => C a (CompactPolynomial a) Source # 
Instance details

Defined in MultiPol

(C a, Eq a) => Eq (CompactPolynomial a) Source # 
Instance details

Defined in MultiPol

(Eq a, Show a, C a) => Show (CompactPolynomial a) Source # 
Instance details

Defined in MultiPol

(C a, Eq a) => C (CompactPolynomial a) Source # 
Instance details

Defined in MultiPol

(C a, Eq a) => C (CompactPolynomial a) Source # 
Instance details

Defined in MultiPol

data Monomial a Source #

Constructors

Monomial 

Fields

Instances

Instances details
Eq a => Eq (Monomial a) Source # 
Instance details

Defined in MultiPol

Methods

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

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

Show a => Show (Monomial a) Source # 
Instance details

Defined in MultiPol

Methods

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

show :: Monomial a -> String #

showList :: [Monomial a] -> ShowS #

lone :: (C a, Eq a) => Int -> Polynomial a Source #

Polynomial x_n

constant :: (C a, Eq a) => a -> Polynomial a Source #

Constant polynomial

terms :: (C a, Eq a) => Polynomial a -> [Monomial a] Source #

List of the terms of a polynomial

(*^) :: (C a, Eq a) => a -> Polynomial a -> Polynomial a Source #

Scale polynomial by a scalar

(^+^) :: (C a, Eq a) => Polynomial a -> Polynomial a -> Polynomial a Source #

Addition of two polynomials

(^-^) :: (C a, Eq a) => Polynomial a -> Polynomial a -> Polynomial a Source #

Substraction

(^*^) :: (C a, Eq a) => Polynomial a -> Polynomial a -> Polynomial a Source #

Multiply two polynomials

(^**^) :: (C a, Eq a) => Polynomial a -> Int -> Polynomial a Source #

Power of a polynomial

evalPoly :: (C a, Eq a) => Polynomial a -> [a] -> a Source #

Evaluates a polynomial

prettyPol :: (C a, Eq a) => (a -> String) -> String -> Polynomial a -> String Source #

Pretty form of a polynomial