Use adaptive quiz-based learning to study this topic faster and more effectively.

# Root of a function

The roots or the zeros of a numerical function $f$ form the set of values that solve the equation $f(x)=0$.

For instance, the roots of the second order expression $$f(x) = ax^2 + bx+c$$ with $a\ne 0$ depend on the sign of the discriminant $$\Delta = b^2 - 4 ac.$$

• If $\Delta\lt 0$, $f$ has no real root.
• If $\Delta = 0$, $f$ has a unique zero $-b / (2a)$, called a repeated root .
• If $\Delta\gt 0$, $f$ has two distinct real roots $$\displaystyle x_- = \frac{-b-\sqrt{\Delta}}{2a},\quad x_+ = \frac{-b+\sqrt{\Delta}}{2a}.$$

• $x^2+1=0$ has no real root, because $\Delta = -4\lt 0$.
• $x^2-2x+1=0$ has a repeated root $x=1$, because $\Delta = 0$.
• $x^2+2x=0$ has a two real roots, because $\Delta = 4 \gt 0$. The roots are $x_- = (-2-2)/2 = -2$ and $x_+=(-2+2)/2 = 0$.