### 11.3.6 Exact bounds for complex roots of a polynomial

The complexroot command finds bounds for the complex roots of a polynomial.

- complexroot takes two mandatory arguments and two optional arguments:
  - P, a polynomial.
  - ε, a postive real number.
  - Optionally, α, β, two complex numbers.
- complexroot(P,ε) returns a list of vectors, where the elements of each vector are one of:
  - an interval (the boundaries of this interval are the opposite vertices of a rectangle with sides parallel to the axis and containing a complex root of the polynomial) and the multiplicity of this root.

    Suppose the interval is [a1+i b1,a2+i b2] then |a1−a2|<ε, |b1−b2|<ε and the root a+i b satisfies a1≤ a ≤ a2 and b1≤ b ≤ b2.

  - the value of an exact complex root of the polynomial and the multiplicity of this root.
- complexroot(P,ε,α,β) returns a list of vectors as above, but only for the roots lying in the rectangle with sides parallel to the axis having α,β as opposite vertices.

#### Examples

Find the roots of x3+1.

complexroot(x^3+1,0.1)

⎡
⎢
⎢
⎢
⎢
⎣

−1 | 1

| ⎡ ⎣ | 0.499999046325680..0.500000953674320 | ⎤ ⎦ | − | ⎡ ⎣ | 0.866024494171135..0.866026401519779 | ⎤ ⎦ | i

1

| ⎡ ⎣ | 0.499999046325680..0.500000953674320 | ⎤ ⎦ | + | ⎡ ⎣ | 0.866024494171135..0.866026401519779 | ⎤ ⎦ | i

1

⎤
⎥
⎥
⎥
⎥
⎦

Hence, for x3+1, −1 is a root of multiplicity 1, a+i b is a root of multiplicity 1 with 0.499999046325680 ≤ a ≤ 0.500000953674320 and −0.866026401519779 ≤ b ≤ −0.866024494171135, and c+i d is a root of multiplicity 1 with 0.499999046325680 ≤ c ≤ 0.500000953674320 and 0.866024494171135 ≤ d ≤ 0.866026401519779.

Find the roots of x3+1 lying inside the rectangle with opposite vertices −1,1+2i.

complexroot(x^3+1,0.1,-1,1+2*i)

⎡
⎢
⎢
⎣

−1 | 1

| ⎡ ⎣ | 0.499999046325680..0.500000953674320 | ⎤ ⎦ | + | ⎡ ⎣ | 0.866024494171135..0.866026401519779 | ⎤ ⎦ | i

1

⎤
⎥
⎥
⎦