Random polynomials

### 11.1.27 Random polynomials

The randpoly or randPoly command generates random polynomials.

- randpoly takes two optional arguments:
  - Optionally x, the name of a variable (by default x).
  - Optionally n, an integer (by default 10).
  The order of the arguments is not important.
- randpoly(⟨ x,n ⟩) returns a monic polynomial in the variable x of degree n, having as coefficients random integers evenly distributed on −99,…,+99.

#### Examples

randpoly(t,4)

t4+86 t3−97 t2−82 t+7 |  |  |  |  |  |  |  |  |  |

randpoly(4)

x4−27 x3+26 x2−89 x+63 |  |  |  |  |  |  |  |  |  |

randpoly(4,u)

u4−49 u3−86 u2−64 u−30 |  |  |  |  |  |  |  |  |  |