see also: eisenstein criterion in algebra, the rational root theorem (or rational root test) states a constraint on rational solutions (or roots) of a polynomial equation :a_nx^n+a_{n-1}x^{n-1}+\cdots+a_0 = 0\,\! with integer coefficients. if a0 and a'n are nonzero, then each rational solution x, when written as a fraction x&nbsp;=&nbsp;p/q in lowest terms (i.e., the greatest common divisor of p and q is 1), satisfies * p is an integer factor of the constant term a0, and * q is an integer factor of the leading coefficient a'n. the rational root theorem is a special case (for a single linear factor) of gauss's lemma on the factorization of polynomials. the integral root theorem is a special case of the rational root theorem if the leading coefficient&nbsp;a'n&nbsp;=&nbsp;1. == proofs == ===a proof=== let p(x) = a'n'x'n + a'n&minus;1x'n&minus;1 + ... + a1x + a0 for some a0, ..., a'n â z, and suppose p(p/q) = 0 for some coprime p, q â z: :p\left(\tfrac{p}{q}\right) = a_n\left(\tfrac{p}{q}\right)^n + a_{n-1}\left(\tfrac{p}{q}\right)^{n-1} + \cdots + a_1\left(\tfrac{p}{q}\right) + a_0 = 0. if we multiply both sides by q'n, shift the constant term to the right hand side, and factor out p on the left hand side, we get :\qquad p(a_np^{n-1} + a_{n-1}qp^{n-2} + \cdots + a_1q^{n-1}) = -a_0q^n. we see that p times the integer quantity in parentheses equals &minus;a0q'n, so p divides a0q'n. but p is coprime to q and therefore to q'n, so by (the generalized form of) euclid's lemma it must divide the remaining factor a0 of the product. if we instead shift the leading term to the right hand side and factor out q on the left hand side, we get :\qquad q(a_{n-1}p^{n-1} + a_{n-2}qp^{n-2} + \cdots + a_0q^{n-1}) = -a_np^n. and for similar reasons, we can conclude that q divides a'n. === proof using gauss's lemma === should there be a nontrivial factor dividing all the coefficients of the polynomial, then one can divide by the greatest common divisor of the coefficients so as to obtain a primitive polynomial in the sense of gauss's lemma; this does not alter the set of rational roots and only strengthens the divisibility conditions. that lemma says that if the polynomial factors in , then it also factors in  as a product of primitive polynomials. now any rational root  corresponds to a factor of degree 1 in  of the polynomial
Polynomials Root-finding_algorithms Theorems_in_algebra