Homepage Solution manuals Ivan Niven An Introduction to the Theory of Numbers Exercise 1.3.41* (Primes and sum of consecutive integers.)

Exercise 1.3.41* (Primes and sum of consecutive integers.)

Prove that an odd integer n > 1 is a prime if and only if it is not expressible as a sum of three or more consecutive positive integers.

Answers

Proof. Let n > 1 be any odd integer.

  • We prove first that if n is a sum of three or more consecutive positive integers, then n is not a prime.

    By Exercise 40, if n is sum of k + 1 consecutive positives, with k 2 , then

    n = ( k + 1 ) ( 2 m + k ) 2 , m > 0 , k 2 .

    If k is odd, n = k + 1 2 ( 2 m + k ) , where k + 1 2 and 2 m + k are integers.
    If k is even, n = ( k + 1 ) 2 m + k 2 , where k + 1 and 2 m + k 2 are integers.

    Since m 1 and k 2 , k + 1 2 3 2 > 1 , and 2 m + k 2 3 2 > 1 . A fortiori 2 m + k > 1 and k + 1 > 1 . Hence in both cases n is composite.

  • Conversely, we show that if n > 1 is odd and composite, then n is a sum of three or more consecutive positive integers.

    Since n is odd and composite, n is a product of at least two odd primes:

    n = p 1 p 2 p l , p 1 p 2 p l l 2 ,

    where p 1 , p 2 , , p l are odd primes.

    Write p = p 1 the least prime divisor of n , and define

    k = p 1 , m = n p p 1 2 .

    Then

    ( k + 1 ) ( 2 m + k ) 2 = p ( m + p 1 2 ) = p n p = n ,

    where k , m are integers, and k 2 because p 3 is an odd prime.

    It remains to verify that m > 0 .

    m > 0 n p > p 1 2 p 1 < 2 n p p 2 n p ( because  p  and  2 n p  are integers ) p 2 2 n .

    This last inequality is true, because n is composite, so l 2 and by (1)

    n = p 1 p 2 p l p 1 p 2 p 1 2 = p 2 ,

    so p 2 n , a fortiori p 2 2 n . This proves m > 0 . Therefore

    n = ( k + 1 ) ( 2 m + k ) 2 , m > 0 , k 2 ,

    thus n is a sum of three or more consecutive positive integers.

Taking the negations, these two parts show that an odd integer n > 1 is a prime if and only if it is not expressible as a sum of three or more consecutive positive integers. □

User profile picture
2024-07-12 09:27
Comments