For positive integers $n$ and $k \geq 2$, define $E_k(n)$ as the greatest exponent $r$ such that $k^r$ divides $n!$. Prove that there are infinitely many $n$ such that $E_{10}(n) > E_9(n)$ and infinitely many $m$ such that $E_{10}(m) < E_9(m)$.
Problem
Source: 2023 IMO Shortlist N3
Tags: IMO Shortlist, number theory, AZE BMO TST, AZE EGMO TST, TST, BRA Cono Sur TST
17.07.2024 15:00
I heard that this problem is not only very, very good, it also is not immediately trivialized by a theorem by some guy named Legendre. Indeed, I think that it is fair to say that after this and N2, olympiad NT is truly back!!!
17.07.2024 15:15
In fact, $E_{10}(n) - E_9(n)$ is unbounded both above and below.
17.07.2024 16:29
If we denote the sum of the digits of $n$ in base $k$ by $s_k(n)$, Legendre's formula yields \[E_{10}(n) = \nu_{5}(n!) = \frac{n-s_5(n)}{4}\quad \text{and}\quad E_9(n) = \left\lfloor\frac{1}{2}\nu_3(n!)\right\rfloor = \left\lfloor \frac{n-s_3(n)}{4}\right\rfloor.\]Now for any $t\in\mathbb{N}$, we may pick $n = 5^t$ to get $E_{10}(n) > E_9(n)$ and $n = 9^t$ to force $E_{10}(n) < E_9(n)$, the end.
17.07.2024 16:42
Let $s_b(n)$ denote the sum of digits of $n$ in base $b$. Then, by Legendre's formula \begin{align*} E_9(n) &= \left\lfloor\frac{E_3(n)}2\right\rfloor = \left\lfloor\frac{n-s_3(n)}{4}\right\rfloor \\ E_{10}(n) &= E_5(n) = \frac{n-s_5(n)}{4}. \end{align*} Thus, for positive terms, take $n=3^{2k}$, so $s_3(n)=1$, which means $E_9(n) = \tfrac{n-1}4$. However, $s_5(n)>1$, so $E_{10}(n) < \tfrac{n-1}4$. Hence, we have $E_{10}(n) < E_9(n)$. For negative terms, take $n=5^k$, so $s_5(n)=1$, which means $E_{10}(n) = \tfrac{n-1}4$. However, $s_3(n) > 1$, so $E_9(n) < \tfrac{n-1}4$. Hence, we have $E_9(n) < E_{10}(n)$.
17.07.2024 17:31
17.07.2024 18:47
Claim. Let $\nu_p(n)$ be the largest power of prime $p$ that divides a positive integer $n$. Then, $E_{10}(n) = \nu_5(n!)$ and $E_9(n) = \left \lfloor \dfrac{\nu_3(n!)}{2} \right \rfloor$. Proof. It is easy to see that $\nu_2(n!) \geq \nu_5(n!)$ for all positive integers $n$, so $$E_{10}(n) = \mathrm{min}(\nu_2(n!), \nu_5(n!)) = \nu_5(n!).$$Now, $9 = 3^2$, so if $\nu_3(n!)$ is even, the $3$s could pair among themselves to multiply to $9$, giving $E_9(n) = \dfrac{\nu_3(n!)}{2}$. Otherwise, if $\nu_3(n!)$ is odd, there exists an unpaired $3$, giving $E_9(n) = \dfrac{\nu_3(n!) - 1}{2}$. $\blacksquare$ For the sake of contradiction, suppose there exists a positive integer $C$ such that either $$\left \lfloor \dfrac{\nu_3(n!)}{2} \right \rfloor \geq \nu_5(n!)$$for all $n \geq C$ or $$\nu_5(n!) \geq \left \lfloor \dfrac{\nu_3(n!)}{2} \right \rfloor$$for all $n \geq C$. We work on each of these cases separately. For the former, consider some $m \geq C$ such that $m$ is a power of $5$. Then, by Legendre's formula, we have $$\dfrac{m-1}{4} \leq \left \lfloor \dfrac{m-s_3(m)}{4} \right \rfloor \leq \dfrac{m-s_3(m)}{4}$$where $s_3(m)$ denotes the sum of digits of $m$ in base $3$. It follows that $s_3(m) \leq 1$, which implies that either $m=0$ or $m$ is a power of $3$, and both possibilities are absurd. For the latter, consider some $k \geq C$ such that $k$ is an even power of $3$. Then, by Legendre's formula, $$\left \lfloor \dfrac{k-1}{4} \right \rfloor \leq \dfrac{k-s_5(k)}{4}.$$However, $k = 3^{2a} \equiv (-1)^{2a} \equiv 1 \pmod 4$ for some nonnegative integer $a$, so $\left \lfloor \dfrac{k-1}{4} \right \rfloor = \dfrac{k-1}{4}$. It again follows that $s_5(k) \leq 1$, or $k$ is a power of $5$, contradiction. Thus, we are done. $\blacksquare$
17.07.2024 18:57
This problem was proposed by Regis Prado Barbosa, from Brazil.
17.07.2024 19:55
Uhhh... By Legendres Formula, $v_p(n!) = \frac{n-s_p(n)}{p-1}$, where $s_p(n)$ is the sum of the digits of $n$ expressed in base $p$. Note that $E_{10}(n) = E_5(n) = v_5(n)$, and $E_9(n) = \left \lfloor \frac{E_3(n)}{2} \right \rfloor$. For the first part, we wish to prove that $$\frac{n-s_5(n)}{4} > \left \lfloor \frac{n-s_3(n)}{4} \right \rfloor$$for infinetly many positive integers $n$. Taking $n=5^a$, $a \in \mathbb{N}$ suffices. Clearly, $s_5(n) = 1$ and $s_3(n) > 1$, so the conclusion immediately follows (after all, the statement is true without the floors and adding the floor only adds potential to subtract from the RHS). For the second part, we wish to prove that $$\frac{n-s_5(n)}{4} < \left \lfloor \frac{n-s_3(n)}{4} \right \rfloor$$for infinetly many positive integers $n$. Taking $n=9^a$, $a \in \mathbb{N}$ suffices. Clearly, $s_3(n) = 1$. Additionally, because $n = 9^a$, $n-1 \equiv 0 \pmod{4}$ so the inequality rewrites to $$\frac{n-s_5(n)}{4} < \frac{n-1}{4}$$$$s_5(n) > 1$$which is obviously true as powers of $9$ are never powers of $5$. $\blacksquare$
18.07.2024 04:40
18.07.2024 15:27
We were asked to prove that $E_{10}(n) - E_9(n)$ is unbounded in both directions. However, this is relatively straightforward - in addition to what has been done with the powers of $3$ and $5$ we need only prove that the sum of digits of powers of $3$, $5$ is unbounded (but this is a short contradiction argument with a maximal digit sum).
18.07.2024 22:17
Claim: $n=5^k$ satisfies $E_{10}(n)>E_9(n)$, where $k$ is odd Proof: note that $E_{10}(n)=\min(E_{5}(n), E_{2}(n))=E_{5}(n)$, since $2$s appear more frequently than $5$s Get that $E_5(n)=5^{k-1}+5^{k-2}+...+1=\frac{5^k-1}{4}$ by legendre Also note that $E_9(n)=\lfloor \frac{E_3(n)}{2} \rfloor$ Let $f(x)=x-\lfloor x \rfloor$. Get that $E_3(n) = n/3+n/9+... - f(n/3) - f(n/9) ... < \frac{n}{2}-\frac{2}{3} < \frac{n-1}{2}$, since $5^k \equiv 5^{k \pmod 2} \equiv 5 \equiv 2 \pmod 3$, so $f(n/3)=\frac{2}{3}$ As a result, $E_9(n) < \frac{n-1}{4} = \frac{5^k-1}{4} = E_5(n) = E_{10}(n)$ Claim: $n=9^k$ satisfies $E_9(n) > E_{10}(n)$, where $k$ is odd Proof: Get that $E_3(n)=3^{2k-1}+3^{2k-2}+...+1=\frac{3^{2k}-1}{2}$ So $E_9(n)=\frac{3^{2k}-1}{4}$. Get that $E_{10}(n)=E_{5}(n)=n/5+n/25+...-f(n/5)-f(n/25)... < \frac{n}{4}-\frac{4}{5} < \frac{n-1}{4} < \frac{3^{2k}-1}{4} = E_9(n)$, since $9^\text{odd} \equiv (-1)^\text{odd} \equiv -1 \equiv 4 \pmod 5$, so $f(n/5)=\frac{4}{5}$.
18.07.2024 23:36
We claim that $n = 3^{4k + 2}$ satisfies $E_9(n) > E_{10}(n)$ as \[2E_9(n) = \left\lfloor\frac n3 \right\rfloor + \left\lfloor\frac n9 \right\rfloor + \cdots = \frac{n-1}{2} > \frac{n}{2} - \frac{8}{5} > 2E_{10}(n) = 2\left(\left\lfloor\frac n5 \right\rfloor + \cdots \right) \]as $n \equiv 4 \pmod 5$. $n=5^{2k+1}$ satsfies $E_{10}(n) > E_9(n)$ as \[2E_{10}(n) = 2(\left\lfloor\frac n5 \right\rfloor + \cdots) = \frac{n-1}{2} > \frac{n}{2} - \frac{4}{3} > 2E_{9}(n) = \left(\left\lfloor\frac n3 \right\rfloor + \cdots \right) \]as $n \equiv 2 \pmod 3$.
20.07.2024 01:12
For any positive integers $n$ and $k \ge 2$, define $E_k(n)$ to be the largest integer $r \ge 0$ such $k^r$ divides $n!$. Prove that the sequence \[ E_{10}(1) - E_9(1), E_{10}(2) - E_9 (2), E_{10} (3) - E_9 (3), \ldots, \]has infinitely many positive elements and infinitely many negative elements. Let $a_n = E_{10}(n) - E_9(n)$. Since $\nu_2(n!) \ge \nu_5(n!)$ for all positive integers $n$ and $9 = 3^2$, $E_{10}(n) = \nu_5(n!)$ and $E_9(n) = \left \lfloor \frac{\nu_3(n!)}{2} \right \rfloor $. Claim: $\nu_p(n!) \le \frac{n-1}{p - 1}$, with equality iff $n$ is a power of $p$ Proof: This holds because \[\nu_p(n!) = \frac{n - s_p(n)}{p - 1} \le \frac{n-1}{p-1},\]with equality iff $s_p(n) = 1$, which happens when $n$ is a power of $p$ (where $s_p(n)$ denotes the sum of digits of $n$ in base $p$). $\square$ If $n$ is a power of $5$ greater than $1$, then we have that $2\nu_5(n!) = \frac{2(n-1)}{4} = \frac{n-1}{2}$ and since $n$ isn't a power of $3$, $\nu_3(n!) < \frac{n-1}{2}$. Hence \[E_{10}(n) = \nu_5(n!) > \frac{\nu_3(n!)}{2} \ge E_9(n),\]so $a_n$ is positive whenever $n$ is a power of $5$ greater than $1$. It suffices to prove that $a_n$ has infinitely many negative elements. We claim that $a_n$ is negative if $n$ is a power of $9$ greater than $1$. Note that since $n$ isn't a power of $5$, $\nu_5(n!) < \frac{n-1}{4} $ and $\nu_3(n!) = \frac{n-1}{2}$. Since $n$ is a power of $9$, $n\equiv 1\pmod 4$, so $\nu_3(n!)$ is even. Thus, \[E_9(n) = \frac{n-1}{4} > \nu_5(n!) = E_{10}(n),\]so $a_n$ must be negative, as desired.
20.07.2024 19:24
21.07.2024 03:22
25.07.2024 08:39
Recall a result due to Legendre: $\nu_p(n!) = \frac{n-s_p(n)}{p-1} = \sum_{i \geq 1} \left\lfloor \frac{n}{p^i} \right\rfloor$ for all primes $p$ and integers $n$, where $s_p(n)$ denotes the sum of the digits of $n$ in base $p$. Note that $E_{10}(n) = \text{min} \{ \nu_2(n!), \nu_5(n!) \}$. But since $\nu_2(n!) = \sum_{i \geq 1} \left\lfloor \frac{n}{2^i} \right\rfloor \geq \sum_{i \geq 1} \left\lfloor \frac{n}{5^i} \right\rfloor = \nu_5(n!)$, we have $E_{10}(n) = \nu_5(n!)$. First we show that $E_{10}(5^k)>E_9(5^k)$ for all integers $k$. $E_{10}(5^k) = \frac{5^k-1}{4} > \frac{5^k-s_3(5^k)}{4} \geq \left\lfloor \frac{\nu_3(5^k!)}{2} \right\rfloor = E_9(5^k)$. Next we show that $E_9(9^k)>E_{10}(9^k)$ for all integers $k$. $E_9(9^k) = \left\lfloor \frac{\nu_3(9^k!)}{2} \right\rfloor = \frac{9^k-1}{4} > \frac{9^k-s_5(9^4)}{4} = E_{10}(9^k)$. Hence proved. $\square$
26.07.2024 15:04
youlost_thegame_1434 wrote: For positive integers $n$ and $k \geq 2$, define $E_k(n)$ as the greatest exponent $r$ such that $k^r$ divides $n!$. Prove that there are infinitely many $n$ such that $E_{10}(n) > E_9(n)$ and infinitely many $m$ such that $E_{10}(m) < E_9(m)$. Let $x=\min(v_2(n!),v_5(n!))$ and $y=v_3(n!)/2$. Let $s_n$ be the sum-of-digits base $n$ function. Suppose for some $n$, $v_5(n!)\geq v_2(n!)$ then $\frac 14 (n-s_5(n))\geq n-s_2(n)$ so $4s_2(n)\geq 3n+s_5(n)$. This isn't true for $n=2,3$ and for $n>4$ it's easy to prove $n>2s_2(n)$ by induction. Thus if $n\neq 1$ then $x=v_5(n!)=(n-s_5(n))/4$ and also $y= v_3(n!)/2=(n-s_3(n))/4$. Pick $n=5^k$ for $k=1,2,\dots$. Then $s_5(5^k)=1$ and $s_3(5^k)>1$ so $x=(5^k-1)/4>(5^k-s_3(5^k))=y$. And if we pick $n=3^k$ then similarly $y>x$. This clearly implies the claim of the problem.
26.07.2024 18:09
It can be easily derived that $$E_{10}(n)=v_5(n!)=\frac{n-s_5(n)}{4} \;\;\;\text{and}\;\;\; E_9(n)=\lfloor \frac{1}{2}v_3(n!) \rfloor=\lfloor \frac{n-s_3(n)}{4}\rfloor$$From here it is clear that choosing $n=5^k$ and $m=9^k$ both work.
27.07.2024 01:45
Note that $E_{10}(n)=\nu_5(n!)$ and $E_{9}(n)=\left\lfloor\frac{\nu_3(n!)}{2}\right\rfloor$. Claim: $E_{10}(m) > E_9(m)$ for $m=625^t$ where $t\in\mathbb{Z}_{>0}$. Proof. By Legendre's theorem, we have $$E_{10}(625^t)=\nu_5(625^t!)=\sum_{i=1}^{\infty} \left\lfloor\frac{625^t}{5^i}\right\rfloor=\sum_{i=0}^{4t-1} 5^i=\frac{625^t-1}{4}.$$Clearly there exists some integer $j$ such that $3^j < 625^t< 3^{j+1}$. Again, by Legendre's theorem, we have $$E_9(625^t)=\left\lfloor\frac{\nu_3(625^t!)}{2}\right\rfloor\leq \frac{\nu_3(625^t!)}{2}=\frac{1}{2}\sum_{i=1}^{\infty} \left\lfloor\frac{625^t}{3^i}\right\rfloor<\frac{1}{2}\sum_{i=1}^{j} \frac{625^t}{3^i}=\cfrac{625^t(1-\frac{1}{3^j})}{4},$$and since $\frac{625^t}{3^j}>1$, we get that $$E_{10}(625^t)=\frac{625^t-1}{4}>\cfrac{625^t(1-\frac{1}{3^j})}{4}>E_{9}(625^t)$$for all $t\in\mathbb{Z}_{>0}$ as claimed. Claim: $E_{10}(m) < E_9(m)$ for $m=81^t$ where $t\in\mathbb{Z}_{>0}$. Proof. By Legendre's theorem, we have $$\nu_3(81^t!)=\sum_{i=1}^{\infty} \left\lfloor\frac{81^t}{3^i}\right\rfloor=\sum_{i=0}^{4t-1} 3^i=\frac{81^t-1}{2},$$from which it follows that $E_{9}(81^t)=\frac{81^t-1}{4}$, because $4\mid 81^t-1$. Clearly there exists some integer $j$ such that $5^j < 81^t< 5^{j+1}$. Again, by Legendre's theorem, we have $$E_{10}(81^t)=\nu_5(81^t!)=\sum_{i=1}^{\infty} \left\lfloor\frac{81^t}{5^i}\right\rfloor<\sum_{i=1}^{j} \frac{81^t}{5^i}=\cfrac{81^t(1-\frac{1}{5^j})}{4},$$and since $\frac{81^t}{5^j}>1$, we get that $$E_{10}(81^t)<\cfrac{81^t(1-\frac{1}{5^j})}{4}<\frac{81^t-1}{4}=E_{9}(81^t)$$for all $t\in\mathbb{Z}_{>0}$ as claimed, and we are done. $\blacksquare$
18.08.2024 02:25
By Legendre's formula, \[E_{10}(n)=\nu_5(n)=\frac{n-s_5(n)}{4}\]and \[E_{9}(n)=\lfloor\nu_3(n)/2\rfloor=\left\lfloor\frac{n-s_3{n}}{4}\right\rfloor.\]Thus we can use the classes of examples $n=5^t$ and $n=9^t$, which clearly work. $\blacksquare$
14.09.2024 11:24
I will in fact prove that $E_{10}(n)-E_9(n)$ is unbounded both above and below. First I will show that it is unbounded above. We have that $E_{10}(n)=\nu_5(n!)$ and we have that $E_9(n)=\lfloor \frac{\nu_3(n!)}{2}\rfloor$. Now let $n=5^k$ for some $k$, from the application of the legendre formula we obtain $E_{10}(5^k)=\frac{5^k-1}{4}$ and we obtain that $E_9(5^k)=\frac{5^k-j}{4}$ where $j$ is equal to the sum of the digits of $5^k$ in base 3, as $5^k$ is not a power of $3$ we get $j\geq 2$, now to prove the unbounded section, suppose $5^k$ has $n$ digits in base $3$, there exists a $5^i$ such that $i>k$ and $5^i\equiv 5^k \pmod{3^n}$, thus the first $n$ digits of $5^i$ in base $3$ are the same as the first $n$ digits of $5^k$, however as $5^i>5^k$ there exists a digit $l$ after the $n$-th digit in base $3$ which is not zero, thus the digit sum of $5^i$ in base $3$, is strictly greater than the digit sum of $5^k$. Thus we get $E_{10}(n)-E_9(n)$ is unbounded above, proving unbounded below is similar except instead of $5^k$, $3^{2k}$ is used.
20.09.2024 00:56
Explicit examples which show unboundedness of $E_{10}(n) - E_9(n)$ in both directions. For very positive take $n = 5^{3^x}$, for very negative take $n = 3^{2 \cdot 5^x}$, where $x$ is as large as you wish.
16.12.2024 06:51
Note: \begin{align*} E_9(5^n) &\leq \frac 12\left(\frac{5^n - 1}3 + \frac{5^n - 1}9\cdots\right) = \frac{5^n - 1}2\left(\frac{1-\frac 1{3^k}}2\right) < \frac{5^n - 1}4 = E_{10}(5^n) \\ E_5(3^{2n}) &\leq \left(\frac{3^{2n} - 1}5 + \frac{3^{2n} - 1}{25} + \cdots\right) = (3^{2n} - 1)\left(\frac{1-\frac 1{5^k}}4\right) < \frac{3^{2n} - 1}4 = E_9(3^{2n}). \end{align*}(We technically didn't even need Legendre!)
16.12.2024 17:15
Even tho it is a imo sl problem...it actually requires the information that an olympiad student first learns about NT We claim that for $N=5^k$ inequality $E_9<E_{10}$ Proof: $E_10=E_5=\sum_{k\in Z^+}\lfloor \frac{5^k}{5}\rfloor =1+5^1+5^2+...+5^{k-1}+0+0+...=\frac{5^k-1}{4}$ $E_9$ same idea $E_9=\sum_{k\in Z}\lfloor \frac{5^k}{9}\rfloor $ this sum goes to $k=\lfloor \frac{b log(5)}{log(9)}\rfloor $ which yields $E_9<E_{10}$ If you do the same for $Z=9^k$ you get the desired result $\boxed{\lambda }$
02.01.2025 20:09
Legandre second form then construction