TITLE: How to prove that a tangent cuts through a point when it has an odd order?
QUESTION [5 upvotes]: I noticed that when a straight line which is a tangent to a polynomial at point $x_1$ is equated to the polynomial, we get a repeated root at point $x_1$.
Let's define a cubic function:
$$y=f(x)=ax^3+bx^2+cx+d$$
whose derivative is equal to:
$$\frac{dy}{dx}=3ax^2+2bx+c$$
At point $x_1$, the slope is $3ax_1^2+2bx_1+c$. The tangent for point $x_1$ is thus:
$$y-y_1=m(x-x_1)$$
$$\implies y-(ax^3_1+bx^2_1+cx_1+d)=(3ax_1^2+2bx_1+c)(x-x_1)$$
$$\implies y=(3ax_1^2+2bx_1+c)x-(2ax_1^3+bx_1^2-d)$$
This form of the tangent is general to every cubic. We can equate the tangent to the polnomial:
$$ax^3+bx^2+cx+d=(3ax_1^2+2bx_1+c)x-(2ax_1^3+bx_1^2-d)$$
$$\implies ax^3+bx^2-(3ax_1^2+2bx_1)x+(2ax_1^3+bx_1^2)=0$$
Since we know $x-x_1$ is a factor, we can factor it out.
$$\implies (x-x_1)[ax^2+bx+ax_1x-(2ax_1^2+bx_1)]=0$$
$$\implies (x-x_1)^2(ax+2ax_1+b)=0$$
Here the root is repeated. So going deeper into this I noticed that if $(x-x_1)$ is repeated thrice, then the tangent cuts through the line and that if it is repeated four times it touches the line. I came to the conjecture that if the root is repeated an even number times, the tangent will touch the curve, but if it is repeated an odd number of times, the tangent will cut through the curve. But how would one prove this conjecture?

REPLY [3 votes]: Let $p(x)$ be the polynomial in question, and $t(x)=mx+n$ the tangent to the polynomial at some point $(x_1,y_1)$.
Now, the following arguments are restricted to a small neighborhood of $(x_1,y_1)$. How small depends on $p(x)$. If we take for example $p(x) = x^2(x-0.001)$, then this polynomial has the $x$-axis as tangent on $p(x)$ at $(0,0)$, and this tangent is above the graph of $p(x)$ on both sides of $(0,0)$ 'near' that point, but the $x$-axis will cut trough the graph again at $(0.001,0)$. But this is the nature of tangents, they have 'meaning' for the curve only 'near' they point where they are taken.
So if the tangent $t(x)$ is above or below $p(x)$ depends on the sign of $p(x) - t(x)$: If that difference is below zero, the tangent is above, if it is above zero, the polynomial is above. 
The tangent 'cuts through' the polynomial if and only if the sign of $p(x) - t(x)$ changes when $x$ goes from smaller than $x_1$ to higher than $x_1$. Otherwise, it will stay on the same side.
So we have to analyze $p(x) - t(x)$, which is itself a polynomial! Since the polynomial and the tangent both go through $(x_1,y_1)$, we have $p(x_1) - t(x_1) = y_1-y_1=0$, so $x_1$ is a root of $p(x) - t(x)$. This means, 
$$p(x) - t(x) = (x-x_1)q(x)$$
For some polynomial $q(x)$. Now let's differentiate that equation, using the product rule on the right:
$$p'(x) - t'(x) =(x-x_1)q'(x) + 1\cdot q(x)$$
Now, $t(x)$ was not just any line through $(x_1,y_1)$, it was the tangent to $p(x)$ at that point. This means they have the same derivative in $(x_1,y_1)$ (which is just the constant $m$ for $t(x)$). If we take that into account and plug in $x=x_1$ in the above equation, we get:
$$p'(x_1) - t'(x_1) = 0 =(x_1-x_1)q'(x_1) + 1\cdot q(x_1) = q(x_1)$$
So we find $x_1$ is also a root of $q(x)$, and we get
$$p(x) - t(x) = (x-x_1)q(x) = (x-x_1)^2r(x)$$
with a new polynomial $r(x)$.
That is what you also found when you did the manual calculation for a polynomial of degree 3. $r(x)$ may or may not have $x_1$ as root. If it doesn't, this process stops here, if it does, we have 
$$p(x) - t(x) = (x-x_1)^2r(x) = (x-x_1)^3s(x)$$
a.s.o. until we finally reach a polynomial that does not have $x_1$ as a root (maybe until only a constant remains). So what we can say is there is some value $k \ge 2$ and some polynomial $u(x)$ such that
$$p(x) - t(x) = (x-x_1)^ku(x)$$
and $u(x_1) \ne 0$
That is exactly the term you arrived at as well. Now let's look at what this means for the sign of $p(x) - t(x)$ near $x_1$. $u(x_1) \ne 0$ and $u(x)$ being a polynomial means $u(x)$ is continuous, so in some (maybe small) neighborhood of $x_1$ it will not change it's sign. No matter if $x < x_1$ or $x > x_1$, near $x_1$ $u(x)$ will have the same sign. 
Let's now look at the remaining term, $(x-x_1)^k$. 
If $k$ is even, this function will also not change its sign, it will always be positive (or $0$ at $x_1$). In this case, the sign of $p(x) - t(x) = (x-x_1)^ku(x)$ will not change when $x$ changes from a value  $<x_1$ to a value $>x_1$, which, as you noticed, means that the tangent $t(x)$ will touch the polynomial $p(x)$ from one side.
If $k$ is odd, however, $(x-x_1)^k < 0$ for $x<x_1$ and $(x-x_1)^k > 0$ for $x>x_1$. So we get that in this case the sign of $p(x) - t(x) = (x-x_1)^ku(x)$
will change when $x$ changes from a value  $<x_1$ to a value $>x_1$, which, as you also noticed, means that the tangent $t(x)$ will cut trough the polynomial $p(x)$.