In algebra, the rational root theorem (or rational root test, rational zero theorem, rational zero test or theorem) states a constraint on rational solutions of a polynomial equation with integer coefficients and . Solutions of the equation are also called roots or zeroes of the polynomial on the left side. The theorem states that each rational solution , written in lowest terms so that and are relatively prime, satisfies: is an integer factor of the constant term , and is an integer factor of the leading coefficient . 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 the special case of the rational root theorem when the leading coefficient is . Application The theorem is used to find all rational roots of a polynomial, if any. It gives a finite number of possible fractions which can be checked to see if they are roots. If a rational root is found, a linear polynomial can be factored out of the polynomial using polynomial long division, resulting in a polynomial of lower degree whose roots are also roots of the original polynomial. Cubic equation The general cubic equation with integer coefficients has three solutions in the complex plane. If the rational root test finds no rational solutions, then the only way to express the solutions algebraically uses cube roots. But if the test finds a rational solution , then factoring out leaves a quadratic polynomial whose two roots, found with the quadratic formula, are the remaining two roots of the cubic, avoiding cube roots. Proofs Elementary proof Let with Suppose for some coprime : To clear denominators, multiply both sides by : Shifting the term to the right side and factoring out on the left side produces: Thus, divides . But is coprime to and therefore to , so by Euclid's lemma must divide the remaining factor . On the other hand, shifting the term to the right side and factoring out on the left side produces: Reasoning as before, it follows that divides . 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