A Condition on Prime Numbers

How many prime numbers p p are there such that 2 9 p + 1 29^p + 1 is a multiple of p p ?

Details and assumptions

You may choose to read the blog post on Euler's Theorem .


The answer is 3.

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.

17 solutions

Deep Chanda
May 20, 2014

Fermat's little theorem states that if p is a prime number, then for any integer a, the number a p a a^{p} - a is an integer multiple of p. In the notation of modular arithmetic, this is expressed as a p a ( m o d p ) a^{p}\equiv a \pmod p . Considering the question , 2 9 p 1 ( m o d p ) 29^{p}\equiv -1 \pmod p . But as, 2 9 p 29 ( m o d p ) 29^{p}\equiv 29 \pmod p . So we get , 30 0 ( m o d p ) 30\equiv 0 \pmod p . Finally, p = 2 , 3 , 5 p=2,3,5 ,i.e number of such primes is 3 3

Common mistakes

  1. For those who applied Fermat's Little Theorem using gcd ( a , p ) = 1 \gcd(a, p) = 1 , several forgot to check the case when a = 29 a = 29 .

Calvin Lin Staff - 7 years ago

According to Fermat's Little Theorem, a^p==a(mod p) whenever a is an integer and p is a prime.

So, 29^p==29(mod p)

But according to the condition, 29^p==-1(mod p)

So, -1==29(mod p) Or, 30==0(mod p)

In other words, p must divide 30. The primes that divide 30 are 2, 3, and 5. So the answer is 3.

Note:- Fermat's Little Theorem can be proved this way. If p divides a, a^p-a is obviously a multiple of p, so we are done. If p does not divide a, g.c.d(a, p)= 1. According to Euler's Theorem a^phi(p)==1(mod p) Or, a^(p-1)==1(mod p) Or a^p==a(mod p)

Lawrence Limesa
May 20, 2014

General form we need to know for this problem is:

n p n^p = n n (mod p p ) where n n is natural number and p p is prime number

from that form we can write: n p + 1 n^p + 1 = n + 1 n+1 (mod p p ) in the problem we know that n n = 29 so 2 9 p + 1 29^p + 1 = 30 ( mod p p ) = 0 ( mod p p ) because 2 9 p + 1 29^p + 1 must be divisible by p p

now we only need to find the prime factors of 30 which are 2,3 and 5 so there are 3 prime numbers fulfilling the requirements.

Rik Tomalin
May 20, 2014

29^p + 1 = kp 29^p + 1 = 0 mod p 29^(p-1) * 29 = 1 mod p 29 + 1 = 0 mod p 30 = 0 mod p

from this, possible values of p are 2, 3, and 5.

Zubin Arya
May 20, 2014

by fermats theorem 29^p is congruent to 29 modulo p hence we are left with 30 which has to be divisible by prime p and hence it may take on values 2,3 and 5 hence total 3 possible prime numbers

Tathagata Dutta
May 20, 2014

a^p \equiv a \pmod {p}. so, 29^p \equiv 29\pmod {p}. so, 29^p + 1 \equiv (29 + 1) = 30\pmod {p}. so, p must divide 30. But, 30 = 2 3 5. so, there are 3 prime no.s for which these conditions are satisfied. so, 2,3,5 are the primes.

Tobby Satyarama
May 20, 2014

by fermat's little theorem,

2 9 p + 1 30 ( m o d p ) 29^p + 1 \equiv 30 (mod p)

If 30 0 ( m o d p ) 30 \equiv 0 (mod p) , then p = 2, 3, 5.

Ahmad Zaky
May 20, 2014

Applying Fermat Little Theorem, we obtain 2 9 p + 1 m o d p 29 + 1 m o d p 30 m o d p 29^p + 1 \mod p \equiv 29 + 1 \mod p \equiv 30 \mod p . On the other side, 2 9 p + 1 29^p+1 is a multiple of p p . Hence, 2 9 p + 1 m o d p 0 29^p+1 \mod p \equiv 0 . Combining these yields 30 m o d p 0 30 \mod p \equiv 0 , which means that p p must be a divisor of 30. So, there are 3 prime numbers p p satisfying the problem (2, 3, and 5).

Yong See Foo
May 20, 2014

p 29 p \neq 29 because 2 9 29 + 1 1 ( m o d 29 ) 29^{29}+1\equiv 1 \pmod{29} . Then by Fermat's Little Theorem, 2 9 p + 1 30 ( m o d p ) 30 0 ( m o d p ) p 30 29^p+1\equiv 30 \pmod{p} \Rightarrow 30 \equiv 0 \pmod{p} \Rightarrow p|30 . So the only possible values of p p are 2 , 3 , 5 2,3,5 . It is trivial to check this solutions are valid. The answer is therefore 3 3 .

Tahmid Hasan
May 20, 2014

From Fermat's Little Theorem we get 2 9 p 29 ( ( m o d p ) ) 29^p \equiv 29(\pmod p) So 2 9 p + 1 30 ( ( m o d p ) ) 29^p+1 \equiv 30(\pmod p) Hence p 30 p|30 . So all possible values of p are 2,3,5. So there are 3 values.

Ivan Stošić
May 20, 2014

All congruences are modulo p.

Here we should find all primes p p such that

2 9 p + 1 0 29^p + 1 \equiv 0

From Euler's theorem we know that for each prime p 29 p \neq 29

2 9 p 29 29^p \equiv 29

And thus,

29 + 1 0 29 + 1 \equiv 0

This means that p can only be a divisor of 30. What if p = 29 p = 29 ? We can easily conclude that p = 29 p = 29 is not a solution, because 2 9 29 + 1 1 29^{29} + 1 \equiv 1 . Since 30 has 3 unique prime divisors (2,3,5), the solution is 3.

Avinash Pandey
May 20, 2014

Let p p be a prime and a a be a positive integer co-prime to p p . Then according to Fermat's Theorem : a p 1 1 ( m o d p ) a^{p-1} \equiv 1 \pmod{p} or a p a ( m o d p ) a^{p} \equiv a \pmod{p} or a p + 1 a + 1 ( m o d p ) a^p + 1 \equiv a+1 \pmod{p} . The question asks us to count number of primes which satisfy 2 9 p + 1 0 ( m o d p ) 29^p + 1 \equiv 0 \pmod{p} . But 2 9 p + 1 30 ( m o d p ) , p 29 29^p + 1 \equiv 30 \pmod{p} , p \neq 29 . Combining these two, we have now that 30 0 ( m o d p ) 30 \equiv 0 \pmod{p} . The only prime divisors of 30 30 are 2 , 3 2, 3 and 5 5 . Each one of these is co-prime to 29 29 . And for obvious reasons 2 9 29 + 1 0 ( m o d 29 ) 29^{29} + 1 \equiv 0 \pmod{29} is a false statement. So three integers satisfy the given condition.

Nathan Soedjak
May 20, 2014

First of all, it is clear that p = 29 p=29 does not satisfy the condition.

Assuming now that p 29 p\not = 29 , by Euler's Theorem we have 2 9 p 1 1 ( m o d p ) 29^{p-1}\equiv 1\pmod{p} . (Note that we can do this because here 29 and p p are relatively prime.) Multiplying both sides of the congruence by 29 yields 2 9 p 29 ( m o d p ) 29^p\equiv 29\pmod{p} . (We could also have gotten this by Fermat's Little Theorem, but it is a special case of Euler's Theorem, anyway.) Adding 1 to both sides gives 2 9 p + 1 30 ( m o d p ) 29^p+1\equiv 30\pmod{p} . Thus 2 9 p + 1 29^p+1 is a multiple of p p if and only if 30 0 ( m o d p ) 30\equiv 0\pmod{p} . This occurs if and only p p divides 30. Finally since 30 = 2 3 5 30=2\cdot 3\cdot 5 , there are only 3 \boxed{3} primes that satisfy the required condition.

Bryan Lee
May 20, 2014

Firstly, note that p=29 fails. Since 29 is a prime, by definition, g c d ( 29 , p ) = 1 gcd({29},{p}) = 1 for any prime p.

By Euler's Theorem, 2 9 p 1 1 ( m o d p ) 29^{p-1} \equiv 1 \pmod{p} for all p. Then for the condition to be fulfilled, ie. p 2 9 p + 1 p \mid 29^{p} +1 , 2 9 p + 1 2 9 p 1 29 + 1 29 + 1 30 ( m o d p ) 0 ( m o d p ) 29^{p} +1 \equiv 29^{p-1} * 29 + 1 \equiv 29 + 1 \equiv 30 \pmod{p} \equiv 0 \pmod{p} .

So p divides 30. Thus only 3 values of p fulfil the equation: 2,3 and 5.

Andrei Sontag
May 20, 2014

_ _Fermat Theorem __: Give p p a prime, and x x a coprime with p p , then x p 1 1 m o d p x^{p-1} \equiv 1 \mod p .

This way, we have that: 2 9 p + 1 = 2 9 p 1 × 29 + 1 1 × 29 + 1 30 m o d p 29^p+1 = 29^{p-1}\times 29 + 1 \equiv 1\times 29 +1 \equiv 30 \mod p

And so p 30 p|30 therefore p { 2 , 3 , 5 } p \in \{2,3,5\} .

ANSWER : 3

Calvin Lin Staff
May 13, 2014

Since p p is prime, ϕ ( p ) = p 1 \phi(p)=p-1 . By Euler's Theorem, we have 2 9 p 1 1 ( m o d p ) 29^{p-1} \equiv 1 \pmod{p} . Hence, 0 2 9 p + 1 29 + 1 30 ( m o d p ) 0 \equiv 29^p + 1 \equiv 29+1 \equiv 30 \pmod{p} . Thus, p p must divide 30 30 , so p = 2 , 3 , 5 p=2, 3, 5 are the only possibilities.

Hence there are 3 3 prime numbers that satisfy the conditions.

Xin Liang Chia
May 20, 2014

Since 29^p +1 must be np So, p must be divisor of (29+1),it is 1,2,3,5,6,10,15,30 Conclution, answer with prime number is 2,3,5

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...