di-zhang-fdu/OlympiadExtended huggingface dataset:
Subfield: Geometry


Question: A bubble in the shape of a hemisphere of radius 1 is on a tabletop. Inside the bubble are five congruent spherical marbles, four of which are sitting on the table and one which rests atop the others. All marbles are tangent to the bubble, and their centers can be connected to form a pyramid with volume $V$ and with a square base. Compute $V$.

Solution:
The first step is to compute the radius $r$ of one of the marbles. The diagram below shows a cross-section through the centers of two diagonally opposite marbles.

<img_3908>

Triangle $B Q R$ appears to be equilateral, and in fact, it is. Reflect the diagram in the tabletop $\overline{A C}$ to obtain six mutually tangent congruent circles inside a larger circle:

<img_3444>

Because the circles are congruent, their centers are equidistant from $B$, and the distances between adjacent centers are equal. So $Q$ can be obtained as the image of $R$ under a rotation of $360^{\circ} / 6=60^{\circ}$ counterclockwise around $B$. Then $P Q=r \Rightarrow B Q=B R=2 r \Rightarrow B D=$ $3 r$, hence $r=1 / 3$. Notice too that the height of the pyramid is simply the radius $r$ and the diagonal of the square base is twice the altitude of the equilateral triangle $B Q R$, that is, $2 \cdot \frac{r \sqrt{3}}{2}=r \sqrt{3}$. So the area of the base is $3 r^{2} / 2$. Thus the volume of the pyramid is $(1 / 3)\left(3 r^{2} / 2\right)(r)=r^{3} / 2$. Because $r=1 / 3$, the volume is $\mathbf{1} / \mathbf{5 4}$.

Final answer: $\frac{1}{54}$
Subfield: Number Theory


Question: Compute the smallest positive integer base $b$ for which $16_{b}$ is prime and $97_{b}$ is a perfect square.

Solution:
Because 9 is used as a digit, $b \geq 10$. The conditions require that $b+6$ be prime and $9 b+7$ be a perfect square. The numbers modulo 9 whose squares are congruent to 7 modulo 9 are 4 and 5. So $9 b+7=(9 k+4)^{2}$ or $(9 k+5)^{2}$ for some integer $k$. Finally, $b$ must be odd (otherwise $b+6$ is even), so $9 b+7$ must be even, which means that for any particular value of $k$, only one of $9 k+4$ and $9 k+5$ is possible. Taking these considerations together, $k=0$ is too small. Using $k=1$ makes $9 k+4$ odd, and while $(9 \cdot 1+5)^{2}=196=9 \cdot 21+7$ is even, because $21+6=27$ is composite, $b \neq 21$. Using $k=2$ makes $9 k+4$ even, yielding $22^{2}=484=9 \cdot 53+7$, and $53+6=59$ is prime. Thus $b=\mathbf{5 3}$, and $53+6=59$ is prime while $9 \cdot 53+7=484=22^{2}$.

Final answer: 53
Subfield: Algebra


Question: For a positive integer $n$, let $C(n)$ equal the number of pairs of consecutive 1's in the binary representation of $n$. For example, $C(183)=C\left(10110111_{2}\right)=3$. Compute $C(1)+C(2)+$ $C(3)+\cdots+C(256)$.

Solution:
Group values of $n$ according to the number of bits (digits) in their binary representations:

| Bits | $C(n)$ values | Total |
| :---: | :---: | :---: |
| 1 | $C\left(1_{2}\right)=0$ | 0 |
| 2 | $C\left(10_{2}\right)=0$ <br> $C\left(11_{2}\right)=1$ | 1 |
| 3 | $C\left(100_{2}\right)=0$ $C\left(101_{2}\right)=0$ <br> $C\left(110_{2}\right)=1$ $C\left(111_{2}\right)=2$ | 3 |
| 4 | $C\left(1000_{2}\right)=0$ $C\left(1001_{2}\right)=0$ $C\left(1100_{2}\right)=1$ $C\left(1101_{2}\right)=1$ <br> $C\left(1010_{2}\right)=0$ $C\left(1011_{2}\right)=1$ $C\left(1110_{2}\right)=2$ $C\left(1111_{2}\right)=3$ | 8 |

Let $B_{n}$ be the set of $n$-bit integers, and let $c_{n}=\sum_{k \in B_{n}} C(k)$ be the sum of the $C$-values for all $n$-bit integers. Observe that the integers in $B_{n+1}$ can be obtained by appending a 1 or a 0 to the integers in $B_{n}$. Appending a bit does not change the number of consecutive 1's in the previous (left) bits, but each number in $B_{n}$ generates two different numbers in $B_{n+1}$. Thus $c_{n+1}$ equals twice $2 c_{n}$ plus the number of new 11 pairs. Appending a 1 will create a new pair of consecutive 1's in (and only in) numbers that previously terminated in 1. The number of such numbers is half the number of elements in $B_{n}$. Because there are $2^{n-1}$ numbers in $B_{n}$, there are $2^{n-2}$ additional pairs of consecutive 1's among the elements in $B_{n+1}$. Thus for $n \geq 2$, the sequence $\left\{c_{n}\right\}$ satisfies the recurrence relation

$$
c_{n+1}=2 c_{n}+2^{n-2}
$$

(Check: the table shows $c_{3}=3$ and $c_{4}=8$, and $8=2 \cdot 3+2^{3-1}$.) Thus

$$
\begin{aligned}
& c_{5}=2 \cdot c_{4}+2^{4-2}=2 \cdot 8+4=20, \\
& c_{6}=2 \cdot c_{5}+2^{5-2}=2 \cdot 20+8=48, \\
& c_{7}=2 \cdot c_{6}+2^{6-2}=2 \cdot 48+16=112, \text { and } \\
& c_{8}=2 \cdot c_{7}+2^{7-2}=2 \cdot 112+32=256 .
\end{aligned}
$$

Because $C(256)=0$, the desired sum is $c_{1}+c_{2}+c_{3}+c_{4}+c_{5}+c_{6}+c_{7}+c_{8}$, which equals 448 .

Final answer: 448
Subfield: Combinatorics


Question: A set $S$ contains thirteen distinct positive integers whose sum is 120 . Compute the largest possible value for the median of $S$.

Solution:
Let $S_{L}$ be the set of the least six integers in $S$, let $m$ be the median of $S$, and let $S_{G}$ be the set of the greatest six integers in $S$. In order to maximize the median, the elements of $S_{L}$ should be as small as possible, so start with $S_{L}=\{1,2,3,4,5,6\}$. Then the sum of $S_{L}$ 's elements is 21, leaving 99 as the sum of $m$ and the six elements of $S_{G}$. If $m=11$ and $S_{G}=\{12,13,14,15,16,17\}$, then the sum of all thirteen elements of $S$ is 119 . It is impossible to increase $m$ any further, because then the smallest set of numbers for $S_{G}$ would be $\{13,14,15,16,17,18\}$, and the sum would be at least 126 . To get the sum to be exactly 120, simply increase either 6 to 7 or 17 to 18 . The answer is $\mathbf{1 1 .}$

Final answer: 11
Subfield: Number Theory


Question: Let $T=11$. Compute the least positive integer $b$ such that, when expressed in base $b$, the number $T$ ! ends in exactly two zeroes.

Solution:
For any integers $n$ and $b$, define $d(n, b)$ to be the unique nonnegative integer $k$ such that $b^{k} \mid n$ and $b^{k+1} \nmid n$; for example, $d(9,3)=2, d(9,4)=0$, and $d(18,6)=1$. So the problem asks for the smallest value of $b$ such that $d(T !, b)=2$. If $p$ is a prime and $p \mid b$, then $d(T !, b) \leq d(T !, p)$, so the least value of $b$ such that $d(T !, b)=2$ must be prime. Also, if $b$ is prime, then $d(T !, b)=\lfloor T / b\rfloor+\left\lfloor T / b^{2}\right\rfloor+\left\lfloor T / b^{3}\right\rfloor+\cdots$. The only way that $d(T, b)$ can equal 2 is if the first term $\lfloor T / b\rfloor$ equals 2 and all other terms equal zero. (If $T \geq b^{2}$, then $b \geq 2$ implies $T / b \geq b \geq 2$, which would mean the first two terms by themselves would have a sum of at least 3.) Thus $2 b \leq T<3 b$, hence $b \leq T / 2$ and $T / 3<b$. For $T=11$, the only such $b$ is 5 .

Final answer: 5
Subfield: Algebra


Question: Let $T=5$. Suppose that $a_{1}=1$, and that for all positive integers $n, a_{n+1}=$ $\left\lceil\sqrt{a_{n}^{2}+34}\right\rceil$. Compute the least value of $n$ such that $a_{n}>100 T$.

Solution:
Start by computing the first few terms of the sequence: $a_{1}=1, a_{2}=\lceil\sqrt{35}\rceil=6, a_{3}=$ $\lceil\sqrt{70}\rceil=9$, and $a_{4}=\lceil\sqrt{115}\rceil=11$. Note that when $m \geq 17,(m+1)^{2}=m^{2}+2 m+1>$ $m^{2}+34$, so if $a_{n} \geq 17, a_{n+1}=\left[\sqrt{a_{n}^{2}+34}\right\rceil=a_{n}+1$. So it remains to continue the sequence until $a_{n} \geq 17: a_{5}=13, a_{6}=15, a_{7}=17$. Then for $n>7, a_{n}=17+(n-7)=n+10$, and $a_{n}>100 T \Rightarrow n>100 T-10$. With $T=5, n>490$, and the least value of $n$ is 491 .

Final answer: 491
Subfield: Geometry


Question: Compute the smallest $n$ such that in the regular $n$-gon $A_{1} A_{2} A_{3} \cdots A_{n}, \mathrm{~m} \angle A_{1} A_{20} A_{13}<60^{\circ}$.

Solution:
If the polygon is inscribed in a circle, then the arc $\overparen{A_{1} A_{13}}$ intercepted by $\angle A_{1} A_{20} A_{13}$ has measure $12\left(360^{\circ} / n\right)$, and thus $\mathrm{m} \angle A_{1} A_{20} A_{13}=6\left(360^{\circ} / n\right)$. If $6(360 / n)<60$, then $n>6(360) / 60=$ 36. Thus the smallest value of $n$ is $\mathbf{3 7}$.

Final answer: 37
Subfield: Geometry


Question: Let $T=37$. A cube has edges of length $T$. Square holes of side length 1 are drilled from the center of each face of the cube through the cube's center and across to the opposite face; the edges of each hole are parallel to the edges of the cube. Compute the surface area of the resulting solid.

Solution:
After the holes have been drilled, each face of the cube has area $T^{2}-1$. The three holes meet in a $1 \times 1 \times 1$ cube in the center, forming six holes in the shape of rectangular prisms whose bases are $1 \times 1$ squares and whose heights are $(T-1) / 2$. Each of these holes thus contributes $4(T-1) / 2=2(T-1)$ to the surface area, for a total of $12(T-1)$. Thus the total area is $6\left(T^{2}-1\right)+12(T-1)$, which can be factored as $6(T-1)(T+1+2)=6(T-1)(T+3)$. With $T=37$, the total surface area is $6(36)(40)=\mathbf{8 6 4 0}$.

Final answer: 8640
Subfield: Algebra


Question: Let $T=8640$. Compute $\left\lfloor\log _{4}\left(1+2+4+\cdots+2^{T}\right)\right\rfloor$.

Solution:
Let $S=\log _{4}\left(1+2+4+\cdots+2^{T}\right)$. Because $1+2+4+\cdots+2^{T}=2^{T+1}-1$, the change-of-base formula yields

$$
S=\frac{\log _{2}\left(2^{T+1}-1\right)}{\log _{2} 4}
$$



Let $k=\log _{2}\left(2^{T+1}-1\right)$. Then $T<k<T+1$, so $T / 2<S<(T+1) / 2$. If $T$ is even, then $\lfloor S\rfloor=T / 2$; if $T$ is odd, then $\lfloor S\rfloor=(T-1) / 2$. With $T=8640$, the answer is 4320 .

Final answer: 4320
Subfield: Algebra


Question: In ARMLopolis, every house number is a positive integer, and City Hall's address is 0. However, due to the curved nature of the cowpaths that eventually became the streets of ARMLopolis, the distance $d(n)$ between house $n$ and City Hall is not simply the value of $n$. Instead, if $n=3^{k} n^{\prime}$, where $k \geq 0$ is an integer and $n^{\prime}$ is an integer not divisible by 3 , then $d(n)=3^{-k}$. For example, $d(18)=1 / 9$ and $d(17)=1$. Notice that even though no houses have negative numbers, $d(n)$ is well-defined for negative values of $n$. For example, $d(-33)=1 / 3$ because $-33=3^{1} \cdot-11$. By definition, $d(0)=0$. Following the dictum "location, location, location," this Power Question will refer to "houses" and "house numbers" interchangeably.

Curiously, the arrangement of the houses is such that the distance from house $n$ to house $m$, written $d(m, n)$, is simply $d(m-n)$. For example, $d(3,4)=d(-1)=1$ because $-1=3^{0} \cdot-1$. In particular, if $m=n$, then $d(m, n)=0$.
Compute $d(6), d(16)$, and $d(72)$.

Solution:
Factoring, $6=2 \cdot 3^{1}, 16=16 \cdot 3^{0}$, and $72=8 \cdot 3^{2}$, so $d(6)=1 / 3, d(16)=1$, and $d(72)=1 / 9$.

Final answer: $\frac{1}{3},1,\frac{1}{9}$
Subfield: Algebra


Question: In ARMLopolis, every house number is a positive integer, and City Hall's address is 0. However, due to the curved nature of the cowpaths that eventually became the streets of ARMLopolis, the distance $d(n)$ between house $n$ and City Hall is not simply the value of $n$. Instead, if $n=3^{k} n^{\prime}$, where $k \geq 0$ is an integer and $n^{\prime}$ is an integer not divisible by 3 , then $d(n)=3^{-k}$. For example, $d(18)=1 / 9$ and $d(17)=1$. Notice that even though no houses have negative numbers, $d(n)$ is well-defined for negative values of $n$. For example, $d(-33)=1 / 3$ because $-33=3^{1} \cdot-11$. By definition, $d(0)=0$. Following the dictum "location, location, location," this Power Question will refer to "houses" and "house numbers" interchangeably.

Curiously, the arrangement of the houses is such that the distance from house $n$ to house $m$, written $d(m, n)$, is simply $d(m-n)$. For example, $d(3,4)=d(-1)=1$ because $-1=3^{0} \cdot-1$. In particular, if $m=n$, then $d(m, n)=0$.
Of the houses with positive numbers less than 100, find, with proof, the house or houses which is (are) closest to City Hall.

Solution:
If $n=3^{k} m$ where $3 \nmid m$, then $d(n)=1 / 3^{k}$. So the smallest values of $d(n)$ occur when $k$ is largest. The largest power of 3 less than 100 is $3^{4}=81$, so $d(81)=1 / 3^{4}=1 / 81$ is minimal.

Final answer: 81
Subfield: Algebra


Question: In ARMLopolis, every house number is a positive integer, and City Hall's address is 0. However, due to the curved nature of the cowpaths that eventually became the streets of ARMLopolis, the distance $d(n)$ between house $n$ and City Hall is not simply the value of $n$. Instead, if $n=3^{k} n^{\prime}$, where $k \geq 0$ is an integer and $n^{\prime}$ is an integer not divisible by 3 , then $d(n)=3^{-k}$. For example, $d(18)=1 / 9$ and $d(17)=1$. Notice that even though no houses have negative numbers, $d(n)$ is well-defined for negative values of $n$. For example, $d(-33)=1 / 3$ because $-33=3^{1} \cdot-11$. By definition, $d(0)=0$. Following the dictum "location, location, location," this Power Question will refer to "houses" and "house numbers" interchangeably.

Curiously, the arrangement of the houses is such that the distance from house $n$ to house $m$, written $d(m, n)$, is simply $d(m-n)$. For example, $d(3,4)=d(-1)=1$ because $-1=3^{0} \cdot-1$. In particular, if $m=n$, then $d(m, n)=0$.
Find all the houses at a distance of $1 / 9$ from house number 17.

Solution:
If $d(n, 17)=1 / 9$, then $9 \mid(n-17)$ and $27 \nmid(n-17)$. So $n=17+9 k$ where $k \in \mathbb{Z}$ is not divisible by 3 .

Final answer: $n=17+9 k$ where $k \in \mathbb{Z}$ is not divisible by 3
Subfield: Number Theory


Question: In ARMLopolis, every house number is a positive integer, and City Hall's address is 0. However, due to the curved nature of the cowpaths that eventually became the streets of ARMLopolis, the distance $d(n)$ between house $n$ and City Hall is not simply the value of $n$. Instead, if $n=3^{k} n^{\prime}$, where $k \geq 0$ is an integer and $n^{\prime}$ is an integer not divisible by 3 , then $d(n)=3^{-k}$. For example, $d(18)=1 / 9$ and $d(17)=1$. Notice that even though no houses have negative numbers, $d(n)$ is well-defined for negative values of $n$. For example, $d(-33)=1 / 3$ because $-33=3^{1} \cdot-11$. By definition, $d(0)=0$. Following the dictum "location, location, location," this Power Question will refer to "houses" and "house numbers" interchangeably.

Curiously, the arrangement of the houses is such that the distance from house $n$ to house $m$, written $d(m, n)$, is simply $d(m-n)$. For example, $d(3,4)=d(-1)=1$ because $-1=3^{0} \cdot-1$. In particular, if $m=n$, then $d(m, n)=0$.


The neighborhood of a house $n$, written $\mathcal{N}(n)$, is the set of all houses that are the same distance from City Hall as $n$. In symbols, $\mathcal{N}(n)=\{m \mid d(m)=d(n)\}$. Geometrically, it may be helpful to think of $\mathcal{N}(n)$ as a circle centered at City Hall with radius $d(n)$.
Find all the houses in $\mathcal{N}(6)$.

Solution:
Because $d(6)=1 / 3, \mathcal{N}(6)$ is the set of all houses $n$ such that $d(n)=1 / 3$, equivalently, where $n=3 k$ and $k$ is not divisible by 3 .

Final answer: $n=3 k$ and $k$ is not divisible by 3
Subfield: Number Theory


Question: In ARMLopolis, every house number is a positive integer, and City Hall's address is 0. However, due to the curved nature of the cowpaths that eventually became the streets of ARMLopolis, the distance $d(n)$ between house $n$ and City Hall is not simply the value of $n$. Instead, if $n=3^{k} n^{\prime}$, where $k \geq 0$ is an integer and $n^{\prime}$ is an integer not divisible by 3 , then $d(n)=3^{-k}$. For example, $d(18)=1 / 9$ and $d(17)=1$. Notice that even though no houses have negative numbers, $d(n)$ is well-defined for negative values of $n$. For example, $d(-33)=1 / 3$ because $-33=3^{1} \cdot-11$. By definition, $d(0)=0$. Following the dictum "location, location, location," this Power Question will refer to "houses" and "house numbers" interchangeably.

Curiously, the arrangement of the houses is such that the distance from house $n$ to house $m$, written $d(m, n)$, is simply $d(m-n)$. For example, $d(3,4)=d(-1)=1$ because $-1=3^{0} \cdot-1$. In particular, if $m=n$, then $d(m, n)=0$.


The neighborhood of a house $n$, written $\mathcal{N}(n)$, is the set of all houses that are the same distance from City Hall as $n$. In symbols, $\mathcal{N}(n)=\{m \mid d(m)=d(n)\}$. Geometrically, it may be helpful to think of $\mathcal{N}(n)$ as a circle centered at City Hall with radius $d(n)$.
Suppose that $n$ is a house with $d(n)=1$. Compute $\mathcal{N}(n)$.

Solution:
$\mathcal{N}(n)=\left\{m \in \mathbb{Z}^{+} \mid 3 \nmid m\right\}$

Final answer: $\mathcal{N}(n)=\left\{m \in \mathbb{Z}^{+} \mid 3 \nmid m\right\}$
Subfield: Number Theory


Question: In ARMLopolis, every house number is a positive integer, and City Hall's address is 0. However, due to the curved nature of the cowpaths that eventually became the streets of ARMLopolis, the distance $d(n)$ between house $n$ and City Hall is not simply the value of $n$. Instead, if $n=3^{k} n^{\prime}$, where $k \geq 0$ is an integer and $n^{\prime}$ is an integer not divisible by 3 , then $d(n)=3^{-k}$. For example, $d(18)=1 / 9$ and $d(17)=1$. Notice that even though no houses have negative numbers, $d(n)$ is well-defined for negative values of $n$. For example, $d(-33)=1 / 3$ because $-33=3^{1} \cdot-11$. By definition, $d(0)=0$. Following the dictum "location, location, location," this Power Question will refer to "houses" and "house numbers" interchangeably.

Curiously, the arrangement of the houses is such that the distance from house $n$ to house $m$, written $d(m, n)$, is simply $d(m-n)$. For example, $d(3,4)=d(-1)=1$ because $-1=3^{0} \cdot-1$. In particular, if $m=n$, then $d(m, n)=0$.


The neighborhood of a house $n$, written $\mathcal{N}(n)$, is the set of all houses that are the same distance from City Hall as $n$. In symbols, $\mathcal{N}(n)=\{m \mid d(m)=d(n)\}$. Geometrically, it may be helpful to think of $\mathcal{N}(n)$ as a circle centered at City Hall with radius $d(n)$.
Suppose that $n$ is a house with $d(n)=1 / 27$. Determine the ten smallest positive integers $m$ (in the standard ordering of the integers) such that $m \in \mathcal{N}(n)$.

Solution:
Here, $\mathcal{N}(n)=\{m \mid m=27 k$, where $3 \nmid k\}$. The ten smallest elements of $\mathcal{N}(n)$ are 27, $54,108,135,189,216,270,297,351$, and 378.

Final answer: 27,54,108,135,189,216,270,297,351,378
Subfield: Number Theory


Question: In ARMLopolis, every house number is a positive integer, and City Hall's address is 0. However, due to the curved nature of the cowpaths that eventually became the streets of ARMLopolis, the distance $d(n)$ between house $n$ and City Hall is not simply the value of $n$. Instead, if $n=3^{k} n^{\prime}$, where $k \geq 0$ is an integer and $n^{\prime}$ is an integer not divisible by 3 , then $d(n)=3^{-k}$. For example, $d(18)=1 / 9$ and $d(17)=1$. Notice that even though no houses have negative numbers, $d(n)$ is well-defined for negative values of $n$. For example, $d(-33)=1 / 3$ because $-33=3^{1} \cdot-11$. By definition, $d(0)=0$. Following the dictum "location, location, location," this Power Question will refer to "houses" and "house numbers" interchangeably.

Curiously, the arrangement of the houses is such that the distance from house $n$ to house $m$, written $d(m, n)$, is simply $d(m-n)$. For example, $d(3,4)=d(-1)=1$ because $-1=3^{0} \cdot-1$. In particular, if $m=n$, then $d(m, n)=0$.


The neighborhood of a house $n$, written $\mathcal{N}(n)$, is the set of all houses that are the same distance from City Hall as $n$. In symbols, $\mathcal{N}(n)=\{m \mid d(m)=d(n)\}$. Geometrically, it may be helpful to think of $\mathcal{N}(n)$ as a circle centered at City Hall with radius $d(n)$.
Notice that $d(16)=d(17)=1$ and that $d(16,17)=1$. Is it true that, for all $m, n$ such that $d(m)=d(n)=1$ and $m \neq n, d(m, n)=1$ ? Either prove your answer or find a counterexample.

Solution:
The statement is false. $d(n, m)<1$ if $3 \mid(n-m)$, so for example, if $n=2$ and $m=5$.
Subfield: Number Theory


Question: In ARMLopolis, every house number is a positive integer, and City Hall's address is 0. However, due to the curved nature of the cowpaths that eventually became the streets of ARMLopolis, the distance $d(n)$ between house $n$ and City Hall is not simply the value of $n$. Instead, if $n=3^{k} n^{\prime}$, where $k \geq 0$ is an integer and $n^{\prime}$ is an integer not divisible by 3 , then $d(n)=3^{-k}$. For example, $d(18)=1 / 9$ and $d(17)=1$. Notice that even though no houses have negative numbers, $d(n)$ is well-defined for negative values of $n$. For example, $d(-33)=1 / 3$ because $-33=3^{1} \cdot-11$. By definition, $d(0)=0$. Following the dictum "location, location, location," this Power Question will refer to "houses" and "house numbers" interchangeably.

Curiously, the arrangement of the houses is such that the distance from house $n$ to house $m$, written $d(m, n)$, is simply $d(m-n)$. For example, $d(3,4)=d(-1)=1$ because $-1=3^{0} \cdot-1$. In particular, if $m=n$, then $d(m, n)=0$.


The neighborhood of a house $n$, written $\mathcal{N}(n)$, is the set of all houses that are the same distance from City Hall as $n$. In symbols, $\mathcal{N}(n)=\{m \mid d(m)=d(n)\}$. Geometrically, it may be helpful to think of $\mathcal{N}(n)$ as a circle centered at City Hall with radius $d(n)$.
Suppose that $d(m)=d(n)=1 / 3^{k}$ and that $m \neq n$. Determine the possible values of $d(m, n)$.

Solution:
If $d(m)=d(n)=1 / 3^{k}$, rewrite $m=3^{k} m^{\prime}$ and $n=3^{k} n^{\prime}$ where $m^{\prime}$ and $n^{\prime}$ are not divisible by 3 . Then $m-n=3^{k}\left(m^{\prime}-n^{\prime}\right)$. If $3 \mid\left(m^{\prime}-n^{\prime}\right)$, then $d(m, n)<1 / 3^{k}$. If $3 \nmid\left(m^{\prime}-n^{\prime}\right)$, then $d(m, n)=1 / 3^{k}$. So the set of possible values of $d(m, n)$ is $\left\{3^{-q} \mid q \geq k, q \in \mathbb{Z}^{+}\right\}$.

Final answer: $\{3^{-q} \mid q \geq k, q \in \mathbb{Z}^{+}\}$
Subfield: Number Theory


Question: In ARMLopolis, every house number is a positive integer, and City Hall's address is 0. However, due to the curved nature of the cowpaths that eventually became the streets of ARMLopolis, the distance $d(n)$ between house $n$ and City Hall is not simply the value of $n$. Instead, if $n=3^{k} n^{\prime}$, where $k \geq 0$ is an integer and $n^{\prime}$ is an integer not divisible by 3 , then $d(n)=3^{-k}$. For example, $d(18)=1 / 9$ and $d(17)=1$. Notice that even though no houses have negative numbers, $d(n)$ is well-defined for negative values of $n$. For example, $d(-33)=1 / 3$ because $-33=3^{1} \cdot-11$. By definition, $d(0)=0$. Following the dictum "location, location, location," this Power Question will refer to "houses" and "house numbers" interchangeably.

Curiously, the arrangement of the houses is such that the distance from house $n$ to house $m$, written $d(m, n)$, is simply $d(m-n)$. For example, $d(3,4)=d(-1)=1$ because $-1=3^{0} \cdot-1$. In particular, if $m=n$, then $d(m, n)=0$.


The neighborhood of a house $n$, written $\mathcal{N}(n)$, is the set of all houses that are the same distance from City Hall as $n$. In symbols, $\mathcal{N}(n)=\{m \mid d(m)=d(n)\}$. Geometrically, it may be helpful to think of $\mathcal{N}(n)$ as a circle centered at City Hall with radius $d(n)$.
Suppose that $d(17, m)=1 / 81$. Determine the possible values of $d(16, m)$.

Solution:
Because $d(17, m)=1 / 81,17-m=81 l$, where $l \in \mathbb{Z}$ and $3 \nmid l$. So $m=17-81 l$ and $16-m=81 l-1$. Hence $3 \nmid 16-m$, and $d(16, m)=d(16-m)=1$.

Final answer: 1