R: Polynomial Transformation

polytrans {pracma} | R Documentation

## Polynomial Transformation

### Description

Transform a polynomial.

### Usage

    polytrans(p, q)

### Arguments

`p, q` | vectors representing two polynomials.

### Details

Transforms polynomial `p` replacing occurences of `x` with another polynomial `q` in `x`.

### Value

Vector representing a polynomial.

### Note

There is no such function in Matlab or Octave.

### See Also

`polypow`

### Examples

    # (x+1)^2 + (x+1) + 1
    polytrans(c(1, 1, 1), c(1, 1))    #=> 1 3 3
    polytrans(c(1, 1, 1), c(-1, -1))  #=> 1 1 1

[Package pracma version 2.0.4 Index]