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

# Roots and inequalities

## 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$.

## Nonlinear inequalities in one-dimension

Inequalities involving numerical functions can be rewritten as $$f(x)\lt 0,\qquad f(x)\le 0$$

The inequality $g(x)\gt 1$ can be written as $1-g(x)\lt 0$.

For a quadratic function with $a\gt 0$ and discriminant $\Delta = b^2-4ac\gt0$, the roots are $\displaystyle x_\pm = \frac{-b\pm\sqrt{\Delta}}{2a}$. So, we have $$f(x) = ax^2 + bx + c = a(x-x_-)(x-x_+).$$ So $f\lt 0$ on $(x_-,x_+)$ and $f \ge 0$ on $(-\infty,x_-]\cup[x_+,+\infty)$.

To compute the sign of a function, we decompose it as the product or ratio of simple functions. Take $f=g/h$, with $g$ and $h$ having distinct non stationary zeros (if $g(x)=0$ then $g'(x)\ne0$). Then, $f$ alternates sign at the roots of $g$ and $h$. Its limit at $\pm\infty$ gives the sign at $\pm\infty$.

$f(x)=(x^2-1)/x$ changes sign at $-1$, $0$ and $1$. Its limit at $-\infty$ is $-1$. Hence it is strictly negative on $(-\infty,-1)\cup(0,1)$.

Sign of the function $f(x) = \frac{x^2-1}{x}$