[u]Set 1 
[/u]

[b]1.1[/b] Compute the number of real numbers x such that the sequence $x$, $x^2$, $x^3$,$ x^4$, $x^5$, $...$ eventually repeats. (To be clear, we say a sequence “eventually repeats” if there is some block of consecutive digits that repeats past some point—for instance, the sequence $1$, $2$, $3$, $4$, $5$, $6$, $5$, $6$, $5$, $6$, $...$ is eventually repeating with repeating block $5$, $6$.)


[b]1.2[/b] Let $T$ be the answer to the previous problem. Nicole has a broken calculator which, when told to multiply $a$ by $b$, starts by multiplying $a$ by $b$, but then multiplies that product by b again, and then adds $b$ to the result. Nicole inputs the computation “$k \times k$” into the calculator for some real number $k$ and gets an answer of $10T$. If she instead used a working calculator, what answer should she have gotten?


[b]1.3[/b] Let $T$ be the answer to the previous problem. Find the positive difference between the largest and smallest perfect squares that can be written as $x^2 + y^2$ for integers $x, y$ satisfying $\sqrt{T} \le x \le T$ and $\sqrt{T} \le y \le T$.


PS. You should use hide for answers. 
### Problem 1.1
To determine the number of real numbers \( x \) such that the sequence \( x, x^2, x^3, x^4, x^5, \ldots \) eventually repeats, we need to consider the behavior of the sequence.

1. If \( x = 0 \), the sequence is \( 0, 0, 0, \ldots \), which is trivially repeating.
2. If \( x = 1 \), the sequence is \( 1, 1, 1, \ldots \), which is also trivially repeating.
3. If \( x = -1 \), the sequence is \( -1, 1, -1, 1, \ldots \), which repeats with period 2.
4. If \( |x| > 1 \) and \( x \neq -1 \), the sequence \( x, x^2, x^3, \ldots \) grows without bound and does not repeat.
5. If \( 0 < |x| < 1 \), the sequence \( x, x^2, x^3, \ldots \) converges to 0 and does not repeat.
6. If \( x \) is a complex number with magnitude 1 (i.e., \( x = e^{i\theta} \) for some real \(\theta\)), the sequence \( x, x^2, x^3, \ldots \) will eventually repeat if \(\theta\) is a rational multiple of \(\pi\).

Thus, the only real numbers \( x \) for which the sequence eventually repeats are \( x = 0, 1, -1 \). Therefore, there are 3 such real numbers.

### Problem 1.2
Let \( T = 3 \) (the answer from Problem 1.1).

Nicole's broken calculator performs the operation \( k \times k \) as follows:
\[ k \times k \rightarrow k^2 \rightarrow k^2 \times k \rightarrow k^3 \rightarrow k^3 + k \]

Given that the result is \( 10T = 30 \), we have:
\[ k^3 + k = 30 \]

To find the correct result using a working calculator, we need to solve for \( k \) and then compute \( k^2 \).

1. Solve \( k^3 + k = 30 \):
   \[ k^3 + k - 30 = 0 \]

   By trial and error or using numerical methods, we find that \( k = 3 \) is a solution.

2. Compute \( k^2 \) using a working calculator:
   \[ k^2 = 3^2 = 9 \]

### Problem 1.3
Let \( T = 3 \) (the answer from Problem 1.1).

We need to find the positive difference between the largest and smallest perfect squares that can be written as \( x^2 + y^2 \) for integers \( x, y \) satisfying \( \sqrt{T} \le x \le T \) and \( \sqrt{T} \le y \le T \).

1. Since \( \sqrt{3} \approx 1.732 \), the integer values for \( x \) and \( y \) are \( 2 \le x \le 3 \) and \( 2 \le y \le 3 \).

2. Calculate \( x^2 + y^2 \) for all combinations of \( x \) and \( y \):
   - \( x = 2, y = 2 \): \( 2^2 + 2^2 = 4 + 4 = 8 \)
   - \( x = 2, y = 3 \): \( 2^2 + 3^2 = 4 + 9 = 13 \)
   - \( x = 3, y = 2 \): \( 3^2 + 2^2 = 9 + 4 = 13 \)
   - \( x = 3, y = 3 \): \( 3^2 + 3^2 = 9 + 9 = 18 \)

3. The smallest perfect square is \( 9 \) (achieved by \( x = 3, y = 0 \) or \( x = 0, y = 3 \)).
4. The largest perfect square is \( 18 \) (achieved by \( x = 3, y = 3 \)).

The positive difference between the largest and smallest perfect squares is:
\[ 18 - 9 = 9 \]

The final answer is \( \boxed{9} \)