User:LightCMM/sandbox

Rational Root Theorem

For a polynomial -

\begin{align} \text{Given: } &P(x) = a_nx^n+a_{n-1} x^{n-1} + \dots + a_1x +a_0 \text{ where } a \neq 0 \\ &\text{p and q have no common factor other than 1}\\ &P(\frac{p}{q}) = 0 \\ &x = \frac{p}{q} \end{align} $$



\begin{align} \text{Prove:  }&p \text{ is a factor of } a_0\\ &q \text{ is a factor of } a_n \end{align} $$



\begin{align} \text{Show that p is a factor of } a_0\\ \end{align} $$



\begin{align} 0 &= a_n(\frac{p}{q})^n + a_{n-1}(\frac{p}{q})^{n-1} + \dots a_1(\frac{p}{q}) + a_0\\ -a_0 &= a_n(\frac{p}{q})^n + a_{n-1}(\frac{p}{q})^{n-1} + \dots a_1(\frac{p}{q})\\ -a_0q^n &= q^n\left(a_n(\frac{p}{q})^n + a_{n-1}(\frac{p}{q})^{n-1} + \dots a_1(\frac{p}{q})\right)\\ -a_0q^n &= a_np^n + a_{n-1}p^{n-1}q + \dots a_1pq^{n-1}\\ -a_0q^n &= p(a_np^n + a_{n-1}p^{n-1}q + \dots a_1pq^{n-1})\\ \end{align} $$



\begin{align} \text{Show that q is a factor of } a_n\\ \end{align} $$



\begin{align} 0 &= a_n(\frac{p}{q})^n + a_{n-1}(\frac{p}{q})^{n-1} + \dots a_1(\frac{p}{q}) + a_0\\ -a_n(\frac{p}{q})^n &= a_{n-1}(\frac{p}{q})^{n-1} + \dots a_1(\frac{p}{q}) + a_0\\ q^n\left(-a_n(\frac{p}{q})^n\right) &= q^n\left(a_{n-1}(\frac{p}{q})^{n-1} + \dots a_1(\frac{p}{q}) + a_0\right)\\ q^n\left(-a_n(\frac{p}{q})^n\right) &= a_{n-1}p^{n+1}q + a_{n-2}p^{n-2}q^2 + \dots a_1pq^{n-1} + a_0q^n\\ -a_np^n &= q(a_{n-1}p^{n+1}+a_{n-2}p^{n-2}q + \dots a_1pq^{n-2}+a_0q^{n-1} \end{align} $$