Maths Olympiad Prep

Track / Stage 8 / 73 of 180 #1773 of 1964

Problem 1773

IMO Shortlist mid-range; USAMO P2/P5
Number theory Difficulty 8.1 Find the answer imo_shortlist

Each positive integer aa undergoes the following procedure in order to obtain the number d=d(a)d = d\left(a\right):

(i) move the last digit of aa to the first position to obtain the numb er bb;
(ii) square bb to obtain the number cc;
(iii) move the first digit of cc to the end to obtain the number dd.

(All the numbers in the problem are considered to be represented in base 1010.) For example, for a=2003a=2003, we get b=3200b=3200, c=10240000c=10240000, and d=02400001=2400001=d(2003)d = 02400001 = 2400001 = d(2003).)

Find all numbers aa for which d(a)=a2d\left( a\right) =a^2.

*

A number or a short expression. Spacing, $ signs and \frac vs / are all fine.

Official solution

Given the problem, we want to find all positive integers a a such that the procedure outlined results in d(a)=a2 d(a) = a^2 . Let's break down the steps of the procedure and solve for a a .

### Procedure Analysis

1. Step (i): Move the last digit of a a to the first position to obtain the number b b .

Let's represent the number a a with its digits as a=d1d2dk a = d_1d_2\ldots d_k . After moving the last digit to the front, we have:

b=dkd1d2dk1 b = d_kd_1d_2\ldots d_{k-1}

2. Step (ii): Square b b to obtain the number c c .

c=b2 c = b^2

3. Step (iii): Move the first digit of c c to the end to obtain the number d d .

Suppose c=e1e2em c = e_1e_2\ldots e_m . Then,

d=e2e3eme1 d = e_2e_3\ldots e_me_1

### Condition

We need d=a2 d = a^2 .

### Finding Solutions

Let's consider possible forms of a a :

- When a a has a single digit, the manipulation of digits will be straightforward:

- If a=2 a = 2 :
- b=2 b = 2
- c=4 c = 4 (since b2=22=4 b^2 = 2^2 = 4 )
- d=4 d = 4 . Since a2=4 a^2 = 4 , this is a solution.

- If a=3 a = 3 :
- b=3 b = 3
- c=9 c = 9 (since b2=32=9 b^2 = 3^2 = 9 )
- d=9 d = 9 . Since a2=9 a^2 = 9 , this is also a solution.

- For multi-digit numbers ending with 1, let's represent a a in the form:
a=22n times1 a = \underbrace{2\dots2}_{n \text{ times}}1

In this form:
- Last digit 1 1 moves to the front: b=122n b = 1\underbrace{2\dots2}_n
- Squaring b b ,
- The number d d would again align with the transformation, maintaining the a2=d a^2 = d relationship for such a form.

### Conclusion

The numbers a a satisfying d(a)=a2 d(a) = a^2 are:

a=22n01,a=2,a=3. a = \underbrace{2\dots2}_{n \ge 0}1, \quad a = 2, \quad a = 3.

So, the complete set of solutions is:

a=22n01,a=2,a=3. \boxed{a = \underbrace{2\dots2}_{n \ge 0}1, \quad a = 2, \quad a = 3.}

Source: Omni-MATH, licensed Apache-2.0. Statement and solution reproduced as published; topic, difficulty and ordering added by this site.