polyMul | R Documentation |
Multiplication of two polynomials.
polyMul(p, q)
p |
coefficients of first polynomial |
q |
coefficients of second polynomial |
inputs are vectors of coefficients a, b, c, ..., in order of power
ax^0 + bx^1 + cx^2 + ...
coefficients of the product in order of power
D.S. Stoffer
based on code from the polynom package https://CRAN.R-project.org/package=polynom
You can find demonstrations of astsa capabilities at FUN WITH ASTSA.
The most recent version of the package can be found at https://github.com/nickpoison/astsa/.
In addition, the News and ChangeLog files are at https://github.com/nickpoison/astsa/blob/master/NEWS.md.
The webpages for the texts and some help on using R for time series analysis can be found at https://nickpoison.github.io/.
a = 1:3 # 1 + 2x + 3x^2
b = 1:2 # 1 + 2x
polyMul(a, b)
# [1] 1 4 7 6
# 1 + 4x + 7x^2 + 6x^3
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.