# If a and b are non-zero integers, is it possible for x^3-ax^2+(a^2-b)x+a(2b-a^2)=0 to have more than one Real root?

## See https://socratic.org/s/aB5FuCr4 to understand where this cubic comes from if it helps.

Jan 6, 2017

Yes, for example with $a = 1$ and $b = 20$ we get the cubic:

${x}^{3} - {x}^{2} - 20 x + 39 = 0$

which has three real roots.

#### Explanation:

${x}^{3} - a {x}^{2} + \left({a}^{2} - b\right) x + a \left(2 b - {a}^{2}\right) = 0$

The discriminant $\Delta$ of a cubic in the form:

$A {x}^{3} + B {x}^{2} + C x + D$

is given by the formula:

$\Delta = {B}^{2} {C}^{2} - 4 A {C}^{3} - 4 {B}^{3} D - 27 {A}^{2} {D}^{2} + 18 A B C D$

In our example:

$\left\{\begin{matrix}A = 1 \\ B = - a \\ C = {a}^{2} - b \\ D = a \left(2 b - {a}^{2}\right)\end{matrix}\right.$

So:

$\Delta = {\left(- a\right)}^{2} {\left({a}^{2} - b\right)}^{2} - 4 {\left({a}^{2} - b\right)}^{3} - 4 {\left(- a\right)}^{3} \left(a \left(2 b - {a}^{2}\right)\right) - 27 {\left(a \left(2 b - {a}^{2}\right)\right)}^{2} + 18 \left(- a\right) \left({a}^{2} - b\right) \left(a \left(2 b - {a}^{2}\right)\right)$

$\textcolor{w h i t e}{\Delta} = - 16 {a}^{6} + 72 {a}^{4} b - 83 {a}^{2} {b}^{2} + 4 {b}^{3}$

Note that:

• The sign of $a$ does not affect the discriminant.

• The term of highest degree in $a$ is $- 16 {a}^{6}$. So when $a$ is large compared with $b$, the discriminant will be negative and the cubic will have only one real root.

• The term of highest degree in $b$ is $4 {b}^{3}$. So when $b$ is large and positive compared with $a$, the discriminant will be positive and the cubic will have three real roots.

So try $a = 1$ and $b = 20$

Then $\Delta = - 16 + 72 \left(20\right) - 83 \left(400\right) + 4 \left(8000\right) = 224 > 0$

So our example cubic is:

${x}^{3} - {x}^{2} - 20 x + 39 = 0$

which does indeed have three real roots.

graph{x^3-x^2-20x+39 [-10, 10, -10, 75]}