document.write( "Question 1040183: Suppose that the roots of x^2+px+q=0 are rational numbers and p,q are integer, then show that the roots are integers.
\n" ); document.write( "Plzz help thanks in advance
\n" ); document.write( "

Algebra.Com's Answer #654994 by Edwin McCravy(20054)\"\" \"About 
You can put this solution on YOUR website!
\r\n" );
document.write( "x²+px+q = 0\r\n" );
document.write( "\r\n" );
document.write( "The solutions are\r\n" );
document.write( "\r\n" );
document.write( "\"%28-p+%2B+sqrt%28+p%5E2-4q+%29%29%2F2+\" and \"%28-p+-+sqrt%28+p%5E2-4q+%29%29%2F2+\"\r\n" );
document.write( "\r\n" );
document.write( "\r\n" );
document.write( "We know that the solutions are rational, so the\r\n" );
document.write( "discriminant p²-4q is the square of an integer n,\r\n" );
document.write( "then\r\n" );
document.write( "\r\n" );
document.write( "     p²-4q = n²        and the solutions are\r\n" );
document.write( "     p²-n² = 4q        \"%28-p%2Bn%29%2F2\" and \"%28-p-n%29%2F2\"\r\n" );
document.write( "(p-n)(p+n) = 4q\r\n" );
document.write( "\r\n" );
document.write( "1. The right side 4q is even so the left side (p-n)(p+n) is even.\r\n" );
document.write( "2. The sum or difference of two even integers is even.\r\n" );
document.write( "3. The sum or difference of two odd integers is even.\r\n" );
document.write( "4. The sum or difference of an even and an odd integer is odd.\r\n" );
document.write( "5. The product of two even integers is even.\r\n" );
document.write( "6. The product of two odd integers is odd.\r\n" );
document.write( "7. If an integer is odd, so is its opposite.\r\n" );
document.write( "8. An even integer divided by 2 is an integer.\r\n" );
document.write( "\r\n" );
document.write( "Case 1. p is even and n is odd\r\n" );
document.write( "Then by 4, p-n and p+n are both odd.\r\n" );
document.write( "Then by 6, (p-n)(p+n) is odd.\r\n" );
document.write( "That contradicts 1.  Thus case 1 is ruled out.\r\n" );
document.write( "\r\n" );
document.write( "Case 2. p is odd and n is even\r\n" );
document.write( "Then by 4, p-n and p+n are both odd.\r\n" );
document.write( "Then by 6, (p-n)(p+n) is odd.\r\n" );
document.write( "That contradicts 2.  Thus case 2 is ruled out.\r\n" );
document.write( "\r\n" );
document.write( "Case 3. p and n are both even\r\n" );
document.write( "Then because of 2 and 7,\r\n" );
document.write( "-p+n and -p-n are both even\r\n" );
document.write( "Therefore, by 8, \"%28-p%2Bn%29%2F2\" and \"%28-p-n%29%2F2\" are both\r\n" );
document.write( "integers.  The proof is complete for case 3.\r\n" );
document.write( "\r\n" );
document.write( "Case 4. p and n are both odd\r\n" );
document.write( "Then because of 3 and 7\r\n" );
document.write( "-p+n and -p-n are both even\r\n" );
document.write( "Therefore, by 8, \"%28-p%2Bn%29%2F2\" and \"%28-p-n%29%2F2\" are both\r\n" );
document.write( "integers.  The proof is complete for case 4.\r\n" );
document.write( "\r\n" );
document.write( "Edwin
\n" ); document.write( "
\n" );