Determine all prime numbers p such that the total number of positive divisors of A = p^2 + 1007 (including 1 and A) is 4 or less.
If p is odd, we know any odd squared equals 1 modulo 8 (including 1 squared). Since 1007 is 7 mod 8, then A=p^2+1007=0 mod 8, and thus A is divisible by 8. This means it has at least 8 factors, (1, 2, 4, 8, A/8, A/4, A/2, A) and so A has more than four positive divisors.
If p is even, it must be 2, and note 2^+1007 = 1011 =3*337, so it
has exactly 4 factors, 1, 3, 337, 3*337. Thus, p=2 is the only prime number so p^2+1007 has four or fewer positive divisors.

Posted by Gamer
on 20100705 14:34:43 