Copyright | (c) Matthew Donadio 2002 |
---|---|

License | GPL |

Maintainer | m.p.donadio@ieee.org |

Stability | experimental |

Portability | portable |

Safe Haskell | Safe |

Language | Haskell98 |

Simple module for handling polynomials.

## Synopsis

- polyeval :: Num a => [a] -> a -> a
- polyadd :: Num a => [a] -> [a] -> [a]
- polyAddScalar :: Num a => a -> [a] -> [a]
- polysub :: Num a => [a] -> [a] -> [a]
- polyscale :: Num a => a -> [a] -> [a]
- polymult :: Num a => [a] -> [a] -> [a]
- polymultAlt :: Num a => [a] -> [a] -> [a]
- polydiv :: Fractional a => [a] -> [a] -> [a]
- polymod :: Fractional a => [a] -> [a] -> [a]
- polypow :: (Num a, Integral b) => [a] -> b -> [a]
- polysubst :: Num a => [a] -> [a] -> [a]
- polysubstAlt :: Num a => [a] -> [a] -> [a]
- polyPolySubst :: Num a => [a] -> [[a]] -> [a]
- polyderiv :: Num a => [a] -> [a]
- polyinteg :: Fractional a => [a] -> a -> [a]
- roots2poly :: Num a => [a] -> [a]

# Types

# Functions

polyAddScalar :: Num a => a -> [a] -> [a] Source #

polymultAlt :: Num a => [a] -> [a] -> [a] Source #

polydiv :: Fractional a => [a] -> [a] -> [a] Source #

Divide two polynomials

polymod :: Fractional a => [a] -> [a] -> [a] Source #

Modulus of two polynomials (remainder of division)

polypow :: (Num a, Integral b) => [a] -> b -> [a] Source #

Raise a polynomial to a non-negative integer power

polysubstAlt :: Num a => [a] -> [a] -> [a] Source #

polyPolySubst :: Num a => [a] -> [[a]] -> [a] Source #

Polynomial substitution `y(n) = x(w(n))`

where the coefficients of `x`

are also polynomials.

polyinteg :: Fractional a => [a] -> a -> [a] Source #

Polynomial integration

roots2poly :: Num a => [a] -> [a] Source #

Convert roots to a polynomial