New in version 1.4.0.
numpy.polynomial.polynomial
This module provides a number of objects (mostly functions) useful for dealing with polynomials, including a Polynomial class that encapsulates the usual arithmetic operations. (General information on how this module represents and works with polynomial objects is in the docstring for its “parent” sub-package, numpy.polynomial).
Polynomial
numpy.polynomial
Polynomial(coef[, domain, window])
A power series class.
polydomain
polyzero
polyone
polyx
polyadd(c1, c2)
polyadd
Add one polynomial to another.
polysub(c1, c2)
polysub
Subtract one polynomial from another.
polymulx(c)
polymulx
Multiply a polynomial by x.
polymul(c1, c2)
polymul
Multiply one polynomial by another.
polydiv(c1, c2)
polydiv
Divide one polynomial by another.
polypow(c, pow[, maxpower])
polypow
Raise a polynomial to a power.
polyval(x, c[, tensor])
polyval
Evaluate a polynomial at points x.
polyval2d(x, y, c)
polyval2d
Evaluate a 2-D polynomial at points (x, y).
polyval3d(x, y, z, c)
polyval3d
Evaluate a 3-D polynomial at points (x, y, z).
polygrid2d(x, y, c)
polygrid2d
Evaluate a 2-D polynomial on the Cartesian product of x and y.
polygrid3d(x, y, z, c)
polygrid3d
Evaluate a 3-D polynomial on the Cartesian product of x, y and z.
polyder(c[, m, scl, axis])
polyder
Differentiate a polynomial.
polyint(c[, m, k, lbnd, scl, axis])
polyint
Integrate a polynomial.
polyfromroots(roots)
polyfromroots
Generate a monic polynomial with given roots.
polyroots(c)
polyroots
Compute the roots of a polynomial.
polyvalfromroots(x, r[, tensor])
polyvalfromroots
Evaluate a polynomial specified by its roots at points x.
polyvander(x, deg)
polyvander
Vandermonde matrix of given degree.
polyvander2d(x, y, deg)
polyvander2d
Pseudo-Vandermonde matrix of given degrees.
polyvander3d(x, y, z, deg)
polyvander3d
polycompanion(c)
polycompanion
Return the companion matrix of c.
polyfit(x, y, deg[, rcond, full, w])
polyfit
Least-squares fit of a polynomial to data.
polytrim(c[, tol])
polytrim
Remove “small” “trailing” coefficients from a polynomial.
polyline(off, scl)
polyline
Returns an array representing a linear polynomial.