[SciPy-dev] Difference between polynomial.trimcoef and trimseq

Anne Archibald peridot.faceted@gmail....
Sun Jan 24 01:44:20 CST 2010


2010/1/24 David Goldsmith <d.l.goldsmith@gmail.com>:

> PS: If I were to use chebyshev as my "template," what would you say is the
> next most useful/algorithmically-studied polynomial basis to implement?

There was extensive (and occasionally heated) discussion of other
polynomial representations around the time the Chebyshev routines were
being introduced. My point of view in that discussion was that there
should be a general framework for working with polynomials in many
representations, but the representations I thought might be worth
having were:

(a) Power basis.
(b) Chebyshev basis.
(c) Bases of other families of orthogonal polynomials.
(d) Lagrange basis (polynomials by value).
(e) Spline basis.

The need for polynomials expressed in terms of other families of
orthogonal polynomials is to some degree alleviated by the improved
orthogonal polynomial support that came in a little after the
discussion. Polynomials by value are a useful tool; if you choose the
right evaluation points they are competitive with Chebyshev
polynomials for many purposes, and they can do other things as well.
The spline basis would be nice, in that it would give people good
tools for manipulating functions represented by splines, but the
issues of numerical instability with degree raising and lowering
suggest to me that they're not going to be that useful as a generic
polynomial library.

So I think my vote would be for polynomials by value. Not that I'm
unbiased! I have a mostly-functional implementation:
http://github.com/aarchiba/scikits.polynomial
I can't vouch for its consistency with the current implementations, or
its completeness; it's been a while since I worked on it.

Anne


More information about the SciPy-Dev mailing list