bundles / numpy latest / numpy / polynomial / polynomial / polysub
function
numpy.polynomial.polynomial:polysub
source: build-install/usr/lib/python3.14/site-packages/numpy/polynomial/polynomial.py :251
Signature
def polysub ( c1 , c2 ) Summary
Subtract one polynomial from another.
Extended Summary
Returns the difference of two polynomials c1 - c2. The arguments are sequences of coefficients from lowest order term to highest, i.e., [1,2,3] represents the polynomial 1 + 2*x + 3*x**2.
Parameters
c1, c2: array_like1-D arrays of polynomial coefficients ordered from low to high.
Returns
out: ndarrayOf coefficients representing their difference.
Examples
from numpy.polynomial import polynomial as P c1 = (1, 2, 3) c2 = (3, 2, 1) P.polysub(c1,c2) P.polysub(c2, c1) # -P.polysub(c1,c2)✓
See also
Aliases
-
numpy.polynomial.Polynomial._sub -
numpy.polynomial.polynomial.polysub