Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

polypow

Polynomial Powers


Description

Power of a polynomial.

Usage

polypow(p, n)

Arguments

p

vector representing a polynomial.

n

positive integer, the exponent.

Details

Uses polymul to multiply the polynomial p n times with itself.

Value

Vector representing a polynomial.

Note

There is no such function in Matlab or Octave.

See Also

Examples

polypow(c(1, -1), 6)             #=> (x - 1)^6 = (1  -6  15 -20  15  -6   1)
polypow(c(1, 1, 1, 1, 1, 1), 2)  # 1 2 3 4 5 6 5 4 3 2 1

pracma

Practical Numerical Math Functions

v2.3.3
GPL (>= 3)
Authors
Hans W. Borchers [aut, cre]
Initial release
2021-01-22

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.