# Canonical form: canonical_form

### 5.12.7 Canonical form: canonical_form

The canonical form of a second degree polyomial in a variable x is the form a(x−c)2+b.

The canonical_form command finds the canonical form of a second degree polynomial.

- canonical_form takes one argument:
  p, a second degree polynomial.
- canonical_form(p) returns the canonical form of p.

#### Examples.

- Input:
  canonical_form(x^2-6*x+1)
  Output:

  | ⎛ ⎝ | x−3 | ⎞ ⎠ | 2−8

- Input:
  canonical_form(2*t^2+3*t+8)
  Output:

  2

  ⎛
  ⎜
  ⎜
  ⎝

  t+

  3
  4

  ⎞
  ⎟
  ⎟
  ⎠

  2

  +

  55
  8