Largest prime is large

Find the smallest prime number N N such that the following is true:

The largest prime factor of N 1 N-1 is A A ;
The largest prime factor of A 1 A-1 is B B ;
The largest prime factor of B 1 B-1 is 7 7 .


The answer is 347.

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.

8 solutions

Calvin Lin Staff
May 13, 2014

We will first obtain the answer, and then justify it.

Because 7 7 is a factor of B 1 B-1 , B = 7 k + 1 B=7k+1 . Note that because B B is prime and greater than 2 2 , k k must be even. Checking for primality, B B can be 29 , 43 , 71 , 113 , 29,43,71,113, \ldots .

If B = 29 , B=29, then likewise A = 29 k + 1 A = 29k+1 where k k is even. The smallest few possible A A are 59 , 233 , 349 , 59,233,349, \ldots .

If B = 43 , B=43, then likewise A = 43 k + 1 A = 43k+1 where k k is even. The smallest few possible A A are 173 , 431 , 173,431, \ldots .

If B = 71 , B=71, then likewise A = 71 k + 1 A = 71k+1 where k k is even. then the smallest possible A A is 569 , 569, \ldots .

So A = 59 , 173 , 233 , A=59,173,233, \ldots are the values that are at most 347. If A = 59 , A=59, then the smallest possible N N is 709. 709. If A = 173 , A=173, then the smallest possible N N is 347. 347. If A = 233 , A=233, then the smallest possible N N is 467. 467. So it seems like the smallest value of N N is 347. 347.

To prove that 347 is the smallest possible, suppose that N N is smaller. Because A N 1 2 , A\leq \frac{N-1}{2}, we have A 345 1 2 = 172 , A\leq \frac{345-1}{2}=172, so A 171 A \leq 171 . This implies B 85 B\leq 85 . But we already checked all B B and A A in this range when we backtracked from 7 7 to find our answer.

So the final answer is 347. 347.

Tejas Kasetty
May 20, 2014

Starting with B B , since B 1 B-1 has its highest prime factor as 7 7 , B B can be written as B 1 = 7 n B-1=7n or B = 7 n + 1 ( 1 ) B=7n+1 \ldots (1) . Similarly for A A , A = B m + 1 ( 2 ) A=Bm+1\ldots (2) and N = A p + 1 ( 3 ) N=Ap+1\ldots (3) .

Considering equation ( 1 ) (1)

We know that B is prime, then n n should be even.This is the condition, and the value of n n should be such that B B is prime. Considering the vlaues of n n , n = 2 , B = 15 n=2, B=15 not a prime.

n = 4 , B = 29 n=4, B=29 prime,

n = 6 , B = 43 n=6, B=43 prime,

n = 8 , B = 57 n=8, B=57 not a prime,

n = 10 , B = 71 n=10,B=71 prime.

But since they have asked the smallest prime number N , lets consider B = 29 B=29 (smallest value of B) : A = 29 m + 1 A=29m+1 where m is an even natural number such that A is prime. When

m = 2 , A = 59 m=2, A=59 prime.

m = 4 , A = 117 m=4, A=117 not a prime.

so, considering A = 59 A=59 : N = 59 p + 1 N=59p+1 where p is an even natural number such that N is prime. when

p = 2 , N = 119 p=2,N=119 , not prime,

p = 4 , N = 237 p=4,N=237 not prime,

p = 6 , N = 355 p=6,N=355 not prime

p = 8 , N = 473 p=8,N=473 not prime

p = 10 , N = 591 p=10,N=591 not prime

p = 12 , N = 709 p=12,N=709 prime.

So, when B = 29 B=29 we get the value of N to be 709 709 .

Now, when B = 43 B=43 (next value of B) : A = 43 m + 1 A=43m+1 , using the similar procedure we find that ,

m = 2 , A = 87 m=2, A=87 not prime.

m = 4 , A = 173 m=4, A=173 which is the smallest value of A being prime.

So, for A = 173 A=173 : N = 173 p + 1 N=173p+1

The prime values of N is for

p = 2 , N = 347 p=2,N= 347 which is prime.

So, we got value of N which is prime and smaller than 709 709 . Now, consider B = 71 B=71 , then value of A will be for

m = 2 , A = 143 m=2, A=143 which is not a prime.

m = 4 , A = 285 m=4, A=285 not a prime.

We can see that all the further taken for A A will give a value of N N larger than 347 347 . This also true for further value of B B

From this we can come to the conclusion that 347 347 is the smallest prime number with the above property or condition. So, the answer is N = 347 \boxed {N=347}

One has to justify that 347 is the smallest possible. The vague phrase "We can see that all the further taken for A A will give a value of N N larger than 347 347 . This also true for further value of B B " does not qualify as a mathematical justification. Not being able to fill in this crucial detail was a very common mistake. Another mistake was accidentally missing the case B=29 altogether, thus getting the right answer for the wrong reasons.

Calvin Lin Staff - 7 years ago
Carlo Maino
May 20, 2014

Summarize the information given in 3 equations and several conditions as follows:

1) N-1=A a
2) A-1=B
b
3) B-1=7*n

And the conditions are: a,b,n are positive integers; N,A,B are prime.

Starting from equation 3), rearrange this to get:

4) B=7*n+1

Now find the multiples of 7 then add 1 to each:

7*1+1=8

7*2+1=15

7*3+1=22

7*4+1=29

7*5+1=43

7*6+1=43

You do this until you find a prime (since B needs to be prime). As you will notice there are multiple primes, try the smallest first and then the following ones, with the following method:

Using B=29. (7*4+1=29)

Repeat the same process for B=29 using:

5) A=B*b+1

Therefore:

29*1+1=30

29*2+1=59

And 59 is the lowest prime you can make with equation 7), therefore A=59.

For the final step rearrange equation 1):

6) N=A*a+1

Therefore:

59*1+1=60

59*2+1=119

59*3+1=178

59*4+1=237

59*5+1=296

59*6+1=355

. . .

59*12+1=709

This is the lowest value for N you can get with B=29. At first glance it may seem that this has to be the lowest possible value for N, since the lowest possible value for B has been used. However there is the possibility that another value for B will yield a lower value for N.

Therefore, you must repeat the same process for greater values of B as well.

Starting with B=42 (from B=7*6+1) N=347, which is the correct answer.

Note: to be sure you should try every prime number, B, resulting from B=7*n+1. You only have to try values for n up to 35 since after that the resulting values of N would be greater than 1000.

"You only have to try values for n up to 35 since after that the resulting values of N would be greater than 1000." Attempt at justification, but not complete: there is not obvious reason for this assertion.

Calvin Lin Staff - 7 years ago
Abdeslem Smahi
Jan 22, 2016

Using Python 2.7.4

def isPrime(n):
    for i in range(2,int(n**0.5)+1):
        if n%i==0:
             return False
    return True

def max_prime_factor(n):
    largest_factor = 1
    i = 2
    while i * i <= n:
        if n % i == 0:
            largest_factor = i
            while n % i == 0:
                n //= i
        i = 3 if i == 2 else i + 2
    if n > 1
        largest_factor = n
    return largest_factor
while True:
    if isPrime(n):
        A=max_prime_factor(n-1)
        B=max_prime_factor(A-1)
        if max_prime_factor(B-1)==7:
                  print n
              break
n+=1
Deepak Jindal
May 20, 2014

B=7t+1 (t is smallest product of prime numbers that make B a prime no.) thus if t=6, B=43 now A=43m+1 (") thus if m=4,A=173 which is a prime no. now N=173k+1 (") thus if k=2,N=347

Case B=29 is missed altogether

Calvin Lin Staff - 7 years ago
Rayner Chuang
May 20, 2014

Basically, we must first realise that all N, A, and B are prime numbers. To find the smallest possible prime number N, we are inclined to think that A and B are also at the minimum.

B can be expressed in the form of 7p+1. The smallest prime number that fits into this condition would be 43. Hence B is 43.

We then substitute B as a factor of A-1, so A is expressed as 43q+1. By listing, we will find that 347 is the smallest value that is a prime number. Therefore, N has a value of 347.

"B can be expressed in the form of 7p+1. The smallest prime number that fits into this condition would be 43. " Case B=29 was missed altogether, so the correct answer was obtained for a wrong reason.

Calvin Lin Staff - 7 years ago
Akshay Arora
May 20, 2014

The first statement tells us that A must be a prime number and the second statement that B is also a prime number. Now the solution must be worked from last statement,i.e, largest prime factor of B-1 is 7, it means that 7 x+1=B (A MULTIPLE OF SEVEN PLUS ONE IS A PRIME NUMBER), where x is a natural number. Since we have to deal with smallest of numbers in this problem, the smallest possibility of B is 43. Now, similarly for the second statement, 43 y+1=A, and from the table of prime numbers, we get to know that the smallest possibility of A is 173. similarly for the first statement, 173*z+1=N, and the smallest possibility in this case is 347, which is N. Hence the answer, N=347

"the smallest possibility of B is 43. " So, 29 was missed altogether... correct answer for incorrect reason.

Calvin Lin Staff - 7 years ago
Meike Rouwenhorst
May 20, 2014

7 has to be a prime factor of B-1. So B can be written as 7b+1. B is the largest prime divisor of A-1, so b has to be an even number and b has to be less than 7, since 7 is the largest prime factor of B-1. For b is 4 B equals the prime number 29. For b = 6 B = 43

Suppose B = 29 is a prime divisor of A-1, then A can be written as 29a + 1 with a less than 29. For a = 2 A = 59, for a = 8 A = 233 and for a = 12 A = 349. Suppose B = 43 then A might be equal to 173 or 431. Since the answer N = An + 1 has to be less or equal 999, larger prime divisors then 499 are irrelevant.

If 59 is the largest prime factor of N-1, then N can be written as 59n + 1. For N a prime number the smallest number of n has to be 12, then N = 709. If 233 is the largest prime factor of N-1, then N = 233n + 1. The smallest number of n then is 2, and N = 467, which is smaller than 709. But if B = 173 then N = 173n + 1 with smallest n equals 2 provides N = 347. Which has to be the smallest prime number since all other options are excluded.

"b has to be less than 7" not necessarily: all of its prime factors must be less than 7, but it may be greater.

"Since the answer N = An + 1 has to be less or equal 999, larger prime divisors then 499 are irrelevant." The 999 restriction is not explicit in the problem, so it cannot be really used.

Calvin Lin Staff - 7 years ago

0 pending reports

×

Problem Loading...

Note Loading...

Set Loading...