Find the number of ordered pairs of positive integers with prime, such that is an integer.
Fun fact: is the th prime number.
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
First, an important correction. The given Fun Fact is wrong as 3581 is the 501-st prime number not 500-th.
a + b = p (prime) (a + b) divides (ab + 1) ==> p divides {a(p - a) + 1} = a*p - (a^2 - 1)
Therefore, p must divide (a^2 - 1) = (a - 1)*(a + 1) where 1 <= a <= (p - 1). p divides (a - 1) only when a = 1 and p divides (a + 1) only when a = (p - 1).
Thus, for each prime p the good ordered pairs would be = {(1, p-1); (p-1, 1)}. We know (p-1) = 1 for p = 2. Thus, there is only one ordered pair for 2 which is (1, 1). For all the other primes, there are 2 ordered pairs each.
So, the expected number of ordered pairs = 1 + (500 - 1)*2 = 999