How to find the number of proper divisors of an integer and other cute related questions

Question 1:

Find the number of proper divisors of 441000. (A proper divisor of a positive integer n is any divisor other than 1 and n):

Solution 1:

Any integer can be uniquely expressed as the product of powers of prime numbers (Fundamental theorem of arithmetic); thus, 441000 = (2^{3})(3^{2})(5^{3})(7^{2}). Any divisor, proper or improper, of the given number must be of the form (2^{a})(3^{b})(5^{c})(7^{d}) where 0 \leq a \leq 3, 0 \leq b \leq 2, 0 \leq c \leq 3, and 0 \leq d \leq 2. In this paradigm, the exponent a can be chosen in 4 ways, b in 3 ways, c in 4 ways, d in 3 ways. So, by the product rule, the total number of proper divisors will be (4)(3)(4)(3)-2=142.

Question 2:

Count the proper divisors of an integer N whose prime factorization is: N=p_{1}^{\alpha_{1}} p_{2}^{\alpha_{2}} p_{3}^{\alpha_{3}}\ldots p_{k}^{\alpha_{k}}

Solution 2:

By using the same reasoning as in previous question, the number of proper divisors of N is (\alpha_{1}+1)(\alpha_{2}+1)(\alpha_{3}+1)\ldots (\alpha_{k}+1)-2, where we deduct 2 because choosing all the factors means selecting the given number itself, and choosing none of the factors means selecting the trivial divisor 1.

Question 3:

Find the number of ways of factoring 441000 into 2 factors, m and n, such that m>1, n>1, and the GCD of m and n is 1.

Solution 3:

Consider the set A = {2^{3}, 3^{2}, 5^{3}, 7^{2}} associated with the prime factorization of 441000. It is clear that each element of A must appear in the prime factorization of m or in the prime factorization of n, but not in both. Moreover, the 2 prime factorizations must be composed exclusively of elements of A. It follows that the number of relatively prime pairs m, n is equal to the number of ways of partitioning A into 2 unordered nonempty, subsets (unordered as mn and nm mean the same factorization; recall the fundamental theorem of arithmetic).

The possible unordered partitions are the following:

A = \{ 2^{3}\} + \{ 3^{2}, 5^{3}, 7^{2}\} = \{3^{2}\}+\{ 2^{3}, 5^{3}, 7^{2}\} = \{ 5^{3}\} + \{ 2^{3}, 3^{2}, 7^{2}\} = \{ 7^{2}\}+\{ 2^{3}, 3^{2}, 5^{3}\},

and A = \{ 2^{3}, 3^{2}\} + \{ 5^{3}, 7^{2}\}=\{ 2^{3}, 5^{3}\} + \{3^{2}, 7^{2} \} = \{ 2^{3}, 7^{2}\} + \{ 3^{2}, 5^{3}\}

Hence, the required answer is 4+3=2^{4-1}+1=7.

Question 4:

Generalize the above problem by showing that any integer has 2^{k-1}-1 factorizations into relatively prime pairs m, n (m>1, n>1).

Solution 4:

Proof by mathematical induction on k:

For k=1, the result holds trivially.

For k=2, we must prove that a set of k distinct elements, Z = \{ a_{1}, a_{2}, a_{3}, \ldots, a_{k-1}, a_{k}\} has 2^{k-1}-1 sets. Now, one partition of Z is

Z = \{ a_{k}\} \bigcup \{ a_{1}, a_{2}, a_{3}, \ldots, a_{k-1}\} \equiv \{ a_{k}\} \bigcup W

All the remaining partitions may be obtained by first partitioning W into two parts — which, by the induction hypothesis, can be done in 2^{k-2}-1 ways — and then, including a_{k} in one part or other — which can be done in 2 ways. By the product rule, the number of partitions of Z is therefore

1 + (2^{k-2})(2)=2^{k-1}-1. QED.

Remarks: Question 1 can be done by simply enumerating or breaking it into cases. But, the last generalized problem is a bit difficult without the refined concepts of set theory, as illustrated; and of course, the judicious use of mathematical induction is required in the generalized case. 

Cheers,

Nalin Pithwa.

Some number theory problems: tutorial set II: RMO and INMO

1. A simplified form of Fermat’s theorem: If x, y, z, n are natural numbers, and n \geq z, prove that the relation x^{n} + y^{n} = z^{n} does not hold.

2. Distribution of numbers: Find ten numbers x_{1}, x_{2}, \ldots, x_{10} such that (a) the number x_{1} is contained in the closed interval [0,1] (b) the numbers x_{1} and x_{2} lie in different halves of the closed interval [0,1] (c) the numbers x_{1}, x_{2}, x_{3} lie in different thirds of the closed interval [0,1] (d) the numbers x_{1}, x_{2}, x_{3} and x_{4} lie in different quarters of the closed interval [0,1],  etc., and finally, (e) the numbers x_{1}, x_{2}, x_{3}, \ldots, x_{10} lie in different tenths of the closed interval [0,1]

3. Is generalization of the above possible?

4. Proportions: Consider numbers A, B, C, p, q, r such that: A:B =p, B:C=q, C:A=r, write the proportion A:B:C = \Box : \Box : \Box in such a way that in the empty squares, there will appear expressions containing p, q, r only; these expressions being obtained by cyclic permutation of one another expressions.

5. Give an elementary proof of the fact that the positive root of x^{5} + x = 10 is irrational.

I will give you sufficient time to try these. Later, I will post the solutions.

Cheers,

Nalin Pithwa.

Some number theory training questions: RMO and INMO

Question 1:

Let us write an arbitrary natural number (for example, 2583), and then add the squares of its digits. (2^{2}+5^{2}+8^{2}+3^{2}=102). Next, we do the same thing to the number obtained. Namely, 1^{2}+0^{2}+2^{2}=5. Now proceed further in the same way:

5^{2}=25, 2^{2}+5^{2}=29, 2^{2}+9^{2}=85, \ldots.

Prove that unless this procedure leads to number 1 (in which case, the number 1 will, of course, recur indefinitely), it must lead to the number 145, and the following cycle will repeat again and again:

145, 42, 20, 4, 16, 37, 58, 89.

Question 2:

Prove that the number 5^{5k+1} + 4^{5k+2} + 3^{5k} is divisible by 11 for every natural k.

Question 3:

The number 3^{105} + 4^{105} is divisible by 13, 49, 181 and 379, and is not divisible by either 5 or by 11. How can this result be confirmed?

Cheers,

Nalin Pithwa.

Some basics of Number Theory for RMO: part III: Fermat’s Little Theorem

Fermat’s Little Theorem:

The fact that there are only a finite number of essentially different numbers in arithmetic to a modulus m means that there are algebraic relations which are satisfied by every number in that arithmetic. There is nothing analogous to these relations in ordinary arithmetic.

Suppose we take any number x and consider its powers x, x^{2}, x^{3}, \ldots. Since there are only a finite number of possibilities of these to the modulus m, we must eventually come to one which we have met before, say x^{h} \equiv x^{k} {\pmod m}, where k <h. If x is relatively prime to m, the factor x^{k} can be cancelled, and it follows that x^{l} \equiv 1 {\pmod m}, where l \equiv {h-k}. Hence, every number x which is relatively prime to m satisfies some congruence of this form. The least exponent l for which x^{l} \equiv 1 {\pmod m} will be called the order of x to the modulus m. If x is 1, its order is obviously 1. To illustrate the definition, let us calculate the orders of a few numbers to the modulus 11. The powers of 2, taken to the modulus 11, are

2, 4, 8, 5, 10, 9, 7, 3, 6, 1, 2, 4, \ldots

Each one is twice the preceding one, with 11 or a multiple of 11 subtracted where necessary to make the result less than 11. The first power of 2 which is \equiv 1 is 2^{10}, and so the order of 2 \pmod {11} is 10. As another example, take the powers of 3:

3, 9, 5, 4, 1, 3, 9, \ldots

The first power of 3 which is equivalent to 1 is 3^{5}, so the order of 3 \pmod {11} is 5. It will be found that the order of 4 is again 5, and so also is that of 5.

It will be seen that the successive powers of x are periodic; when we have reached the first number l for which x^{l} \equiv 1, then x^{l+1} \equiv x and the previous cycle is repeated. It is plain that x^{n} \equiv 1 {\pmod m} if and only if n is a multiple of the order of x. In the last example, 3^{n} \equiv 1 {\pmod 11} if and only if n is a multiple of 5. This remains valid if n is 0 (since 3^{0} = 1), and it remains valid also for negative exponents, provided 3^{-n}, is interpreted as a fraction (mod 11) in the way explained earlier (an earlier blog article).

In fact, the negative powers of 3 (mod 11) are obtained by prolonging the series backwards, and the table of powers of 3 to the modulus 11 is:

\begin{array}{cccccccccccccc}    n & = & \ldots & -3 & -2 & -1 & 0 & 1 &2 & 3 & 4 & 5 & 6 & \ldots \\    3^{n} & \equiv & \ldots & 9 & 5 & 4 & 1 & 3 & 9 & 5 & 4 & 1 & 3 & \ldots \end{array}

Fermat discovered that if the modulus is a prime, say p, then every integer x not congruent to 0 satisfies

x^{p-1} \equiv 1 {\pmod p}….call this as equation A.

In view of what we have seen above, this is equivalent to saying that the order of any number is a divisor of p-1. The result A was mentioned by Fermat in a letter to Frenicle de Bessy of 18 October 1640, in which he also stated that he had a proof. But, as with most of Fermat’s discoveries, the proof was not published or preserved. The first known proof seems to have been given by Leibniz (1646-1716). He proved that x^{p} \equiv x {\pmod p}, which is equivalent to A, by writing x as a sum 1+ 1 + 1 + \ldots + 1 of x units (assuming x positive), and then expanding (1+1+ \ldots + 1)^{p} by the multinomial theorem. The terms 1^{p} + 1^{p} + \ldots + 1^{p} give x, and the coefficients of all the other terms are easily proved to be divisible by p.

Quite a different proof was given by Ivory in 1806. If x \not\equiv 0 {\pmod p}, the integers

x, 2x, 3x, \ldots, (p-1)x

are congruent in some order to the numbers

1, 2, 3, \ldots, p-1.

In fact, each of these sets constitutes a complete set of residues except that 0 (zero) has been omitted from each. Since the two sets are congruent, their products are congruent, and so

(x)(2x)(3x) \ldots ((p-1)x) \equiv (1)(2)(3)\ldots (p-1){(\pmod p)}

Cancelling the factors 2, 3, ….(p-1), as is permissible we obtain the above relation A.

One merit of this proof is that it can be extended so as to apply to the more general case when the modulus is no longer a prime.

The generalization of the result A to any modulus was first given by Euler in 1760. To formulate it, we must begin by considering how many numbers in the set 0, 1, 2, …, (m-1) are relatively prime to m. Denote this number by \phi(m). When m is a prime, all the numbers in the set except 0 (zero) are relatively prime to m, so that \phi(p) = p-1 for any prime p. Euler’s generalization of Fermat’s theorem is that for any modulus m,

x^{\phi(m)} = 1 {\pmod m}…relation B

provided only that x is relatively prime to m.

To prove this, it is only necessary to modify Ivory’s method by omitting from the numbers 0, 1, 2, \ldots, (m-1) not only the number 0, but all numbers which are not relatively prime to m. These remain \phi(m) numbers, say

a_{1}, a_{2}, \ldots, a_{\mu}, where \mu = \phi(m).

Then, the numbers

a_{1}x, a_{2}x, \ldots, a_{\mu}x

are congruent, in some order, to the previous numbers, and on multiplying and cancelling a_{1}, a_{2}, \ldots, a_{\mu} (as is permissible) we obtain x^{p} \equiv 1 {\pmod m}, which is relation B.

To illustrate this proof, take m=20. The numbers less than 20 and relatively prime to 20 are :

1, 3, 7, 9, 11, 13, 17, 19.

So that \phi(20) = 8. If we multiply these by any number x which is relatively prime to 20, the new numbers are congruent to the original numbers in some other order. For example, if x is 3, the new numbers are congruent respectively to

3, 9, 1, 7, 13, 19, 11, 17 {\pmod 20};

and the argument proves that 3^{8} \equiv 6561.

Reference:

  1. The Higher Arithmetic, H. Davenport, Eighth Edition.
  2. Elementary Number Theory, Burton, Sixth Edition.
  3. A Friendly Introduction to Number Theory, J. Silverman

Shared for those readers who enjoy expository articles.

Nalin Pithwa.

Some basics of RMO Number Theory: II. Linear Congruences

II. Linear congruences:

It is obvious that every integer is congruent (mod m) to exactly one of the numbers:

0, 1, 2, 3, 4, …, (m-1). ——- Note 1.

For, we can express the integer in the form qm+r, where 0 \leq r <m, and then, it is congruent to r {\pmod m}. Obviously, there are other sets of numbers, besides the set in Note 1, which have the same property, e.g., any integer is congruent (mod 5) to exactly one of the numbers 0, 1, -1, 2, -2. Any such set of numbers is said to constitute a complete set of residues to the modulus m. Another way of expressing the definition is to say that a complete set of residues (mod m) is any set of m numbers, no two of which are congruent to one another.

A linear congruence, by analogy with a linear equation in elementary algebra, means a congruence of the form

ax \equiv b {\pmod m} —- Note 2.

It is an important fact that any such congruence is soluble for x, provided that a is relatively prime to m. The simplest way of proving this is to observe that if x runs through the numbers of a complete set of residues, then the corresponding values of ax also constitute a complete set of residues. For there are m of these numbers, and no two of them are congruent, since ax_{1} \equiv ax_{2} {\pmod m} would involve x_{1} \equiv x_{2} {\pmod m}, by the cancellation of the factor a (permissible since a is relatively prime to m). Since the numbers ax form a complete set of residues, there will be exactly one of them congruent to the given number b.

As an example, consider the congruence 3x \equiv 5 {\pmod {11}},

If we give x the values 0, 1, 2, …, 10 (a complete set of residues to the modulus 11), 3x takes the values 0, 3, 6, …30. These form another complete set of residues (mod 11), and in fact, they are congruent respectively to

0, 3, 6, 9, 1, 4, 7, 10, 2, 5, 8.

The value 5 occurs when x=9, and so x=9 is a solution of the congruence. Naturally, any number congruent to 9 (mod 11) will also satisfy the congruence; but, nevertheless, we say that the congruence has one solution, meaning that there is one solution in any complete set of residues. In other words, all solutions are mutually congruent. The same applies to the general congruence (Note 2); such a congruence (provided that a is relatively prime to m) is precisely equivalent to the congruence x \equiv x_{0} {\pmod m}, where x_{0} is one particular solution.

There is another way of looking at the linear congruence (in note 2). It is equivalent to the equation ax = b + my, or ax - my =b. It can be proved that such a linear diophantine equation is soluble for x and y if a and m are relatively prime, and that fact provides another proof of the existence of a solution of linear congruence. But, the proof given above is simpler, and illustrates the advant4ages gained by using the congruence notation.

The fact that the congruence (in note 2) has a unique solution, in the sense explained above, suggests that one may use this solution as an interpretation for the fraction \frac{b}{a} to the modulus m. When we do this, we obtain an arithmetic (mod m) in which addition, subtraction and multiplication are always possible, and division is also possible if the divisor is relatively prime to m. In this arithmetic there are only a finite number of essentially distinct numbers, namely m of them, since two numbers which are mutually congruent (mod m) are treated as the same. If we take the modulus m to be 11, as an illustration, a few examples of “arithmetic mod 11” are :

5 + 7 \equiv 1; 5 \times 6 \equiv 8; \frac{5}{3} \equiv 9 \equiv -2.

Any relation connecting integers or fractions in the ordinary sense remains true when interpreted in this arithmetic. For example, the relation \frac{1}{2} + \frac{2}{3} = \frac{7}{6}

becomes (mod 11)

6 + 8 \equiv 3,

because the solution of 2x \equiv 1 is x \equiv 6, that of 3x \equiv 2 is x \equiv 8, and that of 6x \equiv 7 is x \equiv 3. Naturally the interpretation given to a fraction depends on the modulus, for instance \frac{2}{3} = 8 {\pmod 11}, but \frac{2}{3} \equiv 3 {\pmod 7}. The only limitation on such calculations is that just mentioned, namely that the denominator of any fraction must be relatively prime to the modulus. If the modulus is a prime (as in the above examples with 11), the limitation takes the very simple form that the denominator must not be congruent to 0 (mod m), and this is exactly analogous to the limitation in ordinary arithmetic that the denominator must not be equal to 0. We will say more about this later.

Reference: The Higher Arithmetic, H. Davenport, 8th edition.

Shared for my students/readers who love to read expository articles….

Regards,

Nalin Pithwa.

 

Some Basics for RMO Number Theory: Congruences

I. The congruence notation:

It often happens that for the purposes of a particular calculation, two numbers which differ by a multiple of some fixed number are equivalent, in the sense that they produce the same result. For example, the value of (-1)^{n} depends only on whether n is odd or even, so that two values of n which differ by a multiple of 2 give the same result. Or again, if we are concerned only with the last digit of a number, then for that purpose two numbers which differ by a multiple of 10 are effectively the same.

The congruence notation, introduced by Gauss, serves to express in a convenient form the fact that the two integers a and b differ by a multiple of a fixed natural number m. We say that a is congruent to b with respect to the modulus m, or in symbols,

a \equiv b {\pmod m}

The meaning of this, then, is simply that a-b is divisible by m. The notation facilitates calculations in which numbers differing by a multiple of m are effectively the same, by stressing the analogy between congruence and equality. Congruence, in fact, means “equality except for the addition of some multiple of m”.

A few examples of valid congruences are :

63 \equiv 0 {\pmod 3}; 7 \equiv -1 {\pmod 8}; 5^{2} \equiv -1 {\pmod {13}}

A congruence to the modulus 1 is always valid, whatever the two numbers may be, since every number is a multiple of 1. Two numbers are congruent with respect to the modulus 2 if they are of the same parity, that is, both even or both odd.

Two congruences can be added, subtracted or multiplied together, in just the same way as two equations, provided all the congruences have the same modulus. If

a \equiv \alpha {\pmod m} and b \equiv \beta {\pmod m}

then:

a + b \equiv {\alpha + \beta} {\pmod m}

a - b \equiv {\alpha - \beta}{\pmod m}

ab \equiv {\alpha\beta} {\pmod m}

The first two of these statements are immediate: for example, (a+b) - (\alpha + \beta) is a multiple of m because a- \alpha and b - \beta are both multiples of m. The third is not quite so immediate because ab - \alpha \beta = (a-\alpha)b, and a - \alpha is a multiple of m. Next, ab \equiv \alpha \beta, for a similar reason. Hence, ab \equiv {\alpha \beta} {\pmod m}.

A congruence can always be multiplied throughout by any integer; if a \equiv {\alpha} {\pmod m} the10n ka \equiv {k\alpha} {\pmod m}. Indeed this is a special case of the third result above, where b and \beta are both k. But, it is not always legitimate to cancel a factor from a congruence. For example, 42 \equiv 12 {\pmod 10}, but it is not permissible to cancel the factor 6 from the numbers 42 and 12, since this would give the false result 7 \equiv 2 {\pmod 10}. The reason is obvious: the first congruence states that 42-12 is a multiple of 10, but this does not imply that \frac{1}{6}(42-12) is a multiple of 10. The cancellation of a factor from a congruence is legitimate if the factor is relatively prime to the modulus. For, let the given congruence be ax \equiv ay {\pmod m}, where is the factor to be cancelled, and we suppose that a is relatively prime to m. The congruence states that a(x-y) is divisible by m, and hence, (x-y) is divisible by m.

An illustration of the use of congruences is provided by the well-known rules for the divisibility of a number by 3 or 9 or 11. The usual representation of a number n by digits in the scale of 10 is really a representation of n in the form

n = a + 10b + 100c + \ldots

where a, b, c, … are the digits of the number, read from right to left, so that a is the number of units, b the number of tens, and so on. Since 10 \equiv 1 {\pmod 9}, we have also 10^{2} \equiv 1 {\pmod 9}, and 10^3 \equiv 1 {\pmod 9}, and so on. Hence, it follows from the above representation of n that

n \equiv {a+b+c+\ldots} {\pmod 9}

In other words, any number n differs from the sum of its digits by a multiple of 9, and in particular n is divisible by 9 if and only if the sum of its digits is divisible by 9. The same applies with 3 in place of 9 throughout.

The rule for 11 is based on the fact that 10 \equiv -1 {\pmod 11} so that 10^2 \equiv {+1} {\pmod 11}, and so on. Hence,

n \equiv {a-b+c- \ldots} {\pmod 11}

It follows that n is divisible by 11 if and only if a-b+c-\ldots is divisible by 11. For example, to test the divisibility of 958 by 11 we form 1-8+5-9, or -11. Since this is divisible by 11, so is 9581.

Ref: The Higher Arithmetic by H. Davenport, Eighth Edition, Cambridge University Press.

Cheers,

Nalin Pithwa.