|
Data.Number.ER.RnToRm.UnitDom.ChebyshevBase.Polynom.Basic | Portability | portable | Stability | experimental | Maintainer | mik@konecny.aow.cz |
|
|
|
Description |
Internal module for Data.Number.ER.RnToRm.UnitDom.ChebyshevBase.Polynom.
Definition of the polynomial datatype and simple related functions.
|
|
Synopsis |
|
data ERChebPoly box b = ERChebPoly {} | | type TermKey box = box | | chplConstTermKey :: DomainBox box varid d => box | | chplIsConstTermKey :: DomainBox box varid d => box -> Bool | | chplTermOrder :: (DomainBox box varid d, Num d) => box -> d | | chplTermArity :: DomainBox box varid d => box -> Int | | chplGetDegree :: (ERRealBase b, DomainBox box varid d, Num d, Ord d) => ERChebPoly box b -> d | | chplGetConst :: (ERRealBase b, DomainBox box varid d, Num d, Ord d) => ERChebPoly box b -> Maybe b | | chplConst :: (ERRealBase b, DomainBox box varid Int, Ord box) => b -> ERChebPoly box b | | chplVar :: (ERRealBase b, DomainBox box varid Int, Ord box) => varid -> ERChebPoly box b | | chplAffine :: (ERRealBase b, DomainBox box varid Int, Ord box) => b -> Map varid b -> ERChebPoly box b | | chplRemoveZeroTermsUp :: (ERRealBase b, DomainBox box varid Int, Ord box) => ERChebPoly box b -> ERChebPoly box b | | chplCountTerms :: (ERRealBase b, DomainBox box varid Int, Ord box) => ERChebPoly box b -> Int | | chplShow :: (ERRealBase b, DomainBox box varid Int, Ord box) => Int -> Bool -> Bool -> ERChebPoly box b -> String | | chebToXBasis :: (ERRealBase b, DomainBox box varid Int, Ord box) => Map (TermKey box) b -> Map (TermKey box) b | | termXterms :: (DomainBox box varid Int, Ord box) => TermKey box -> Map (TermKey box) Integer | | chebyXCoeffsLists :: (Num d1, Enum d1, Num d2, Enum d2) => [[(d1, d2)]] | | chebyXCoeffs :: (Num d, Enum d) => [[d]] |
|
|
Documentation |
|
|
A polynomial represented by its coefficients it the Chebyshev basis.
The polynomials are never to be used outside the domain [-1,1]^n.
All operations are rounded in such a way that the resulting polynomial
is a point-wise upper or lower bound of the exact result.
| Constructors | | Instances | Typeable2 ERChebPoly | (ERRealBase rb, RealFrac rb, DomainBox box varid Int, Ord box, DomainBoxMappable boxb boxras varid rb ([] (ERInterval rb)), DomainBoxMappable boxra boxras varid (ERInterval rb) ([] (ERInterval rb)), DomainIntBox boxra varid (ERInterval rb)) => ERUnitFnBase boxb boxra varid rb (ERInterval rb) (ERChebPoly box rb) | (Eq box, Eq b) => Eq (ERChebPoly box b) | (Data box, Data b, Ord box) => Data (ERChebPoly box b) | (Ord box, Ord b) => Ord (ERChebPoly box b) | (ERRealBase b, DomainBox box varid Int, Ord box) => Show (ERChebPoly box b) | (Ord a, Binary a, Binary b) => Binary (ERChebPoly a b) |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Inspect all terms of the polynomial and return the
degree of the highest degree term.
|
|
|
If the polynomial is constant, return the constant,
otherwise return Nothing.
|
|
|
|
|
Make a basic x polynomial for a given variable number.
|
|
|
Construct an affine polynomial.
|
|
|
|
|
|
|
:: (ERRealBase b, DomainBox box varid Int, Ord box) | | => Int | number of decimal digits to show
| -> Bool | whether to show granularity
| -> Bool | show the polynomial also in its native Chebyshev basis
| -> ERChebPoly box b | | -> String | | Convert a polynomial to a string representation,
using the ordinary x^n basis.
|
|
|
|
:: (ERRealBase b, DomainBox box varid Int, Ord box) | | => Map (TermKey box) b | polynomial in Chebyshev basis
| -> Map (TermKey box) b | approxition of the equivalent polynomial in X^n basis
| conversion of polynomials from Chebyshev basis to the X^n basis
(not exact - suffering from rounding in the coefficient conversions)
|
|
|
|
:: (DomainBox box varid Int, Ord box) | | => TermKey box | a Chebyshev term represented by the Chebyshev degrees
for each variable in the term
| -> Map (TermKey box) Integer | the polynomial equivalent to the given Chebyshev term
(using integer coefficients)
| conversion of one Chebyshev term to the X^n basis
|
|
|
|
Chebyshev polynomials expressed as associative lists power -> coeff
|
|
|
Chebyshev polynomials expressed as lists of integer coefficients for powers 0,1,2...
|
|
Produced by Haddock version 2.4.2 |