## p. y (Roots)

The roots of the polynomial y

• given as a list of its coefficients in ascending powers of its exponents

Example:

• x² - 8x +15 = (x-5)(x-3)

the roots of the polynomial are: 5 and 3

```   c=: 15 _8 1             NB. coefficients (in ascending powers)
]z=: p. c
+-+---+
|1|5 3|
+-+---+```

Verb p. is self-inverse

```   p. z
15 _8 1```

In the "roots" format m;r , m is a scaling factor, needed in order to recover the original polynomial.

```   p. 1 ; 5 3
15 _8 1
p. 2 ; 5 3
30 _16 2```

### Common uses

1. To find the roots of a given polynomial.

2. Convert a polynomial into its different forms.

## x p. y (Polynomial)

Evaluate a given polynomial x in y for given value(s) of y

```   c=: 15 _8 1   NB. poly defined in terms of its coefficients
]z=: p. c     NB. (m;r) format: multiplier and roots
+-+---+
|1|5 3|
+-+---+

y=: i. 6
c p. y
15 8 3 0 _1 0
z p. y
15 8 3 0 _1 0```

### Common uses

Handier than evaluating a polynomial by multiplying a list of coefficients by a list of exponents

```   c=: 15 _8 1
y=: 5

+/ c * y^i.3
0```