G
Topic
First Poster
Last Poster
k a April Highlights and 2025 AoPS Online Class Information
jlacosta   0
Yesterday at 3:18 PM
Spring is in full swing and summer is right around the corner, what are your plans? At AoPS Online our schedule has new classes starting now through July, so be sure to keep your skills sharp and be prepared for the Fall school year! Check out the schedule of upcoming classes below.

WOOT early bird pricing is in effect, don’t miss out! If you took MathWOOT Level 2 last year, no worries, it is all new problems this year! Our Worldwide Online Olympiad Training program is for high school level competitors. AoPS designed these courses to help our top students get the deep focus they need to succeed in their specific competition goals. Check out the details at this link for all our WOOT programs in math, computer science, chemistry, and physics.

Looking for summer camps in math and language arts? Be sure to check out the video-based summer camps offered at the Virtual Campus that are 2- to 4-weeks in duration. There are middle and high school competition math camps as well as Math Beasts camps that review key topics coupled with fun explorations covering areas such as graph theory (Math Beasts Camp 6), cryptography (Math Beasts Camp 7-8), and topology (Math Beasts Camp 8-9)!

Be sure to mark your calendars for the following events:
[list][*]April 3rd (Webinar), 4pm PT/7:00pm ET, Learning with AoPS: Perspectives from a Parent, Math Camp Instructor, and University Professor
[*]April 8th (Math Jam), 4:30pm PT/7:30pm ET, 2025 MATHCOUNTS State Discussion
April 9th (Webinar), 4:00pm PT/7:00pm ET, Learn about Video-based Summer Camps at the Virtual Campus
[*]April 10th (Math Jam), 4:30pm PT/7:30pm ET, 2025 MathILy and MathILy-Er Math Jam: Multibackwards Numbers
[*]April 22nd (Webinar), 4:00pm PT/7:00pm ET, Competitive Programming at AoPS (USACO).[/list]
Our full course list for upcoming classes is below:
All classes run 7:30pm-8:45pm ET/4:30pm - 5:45pm PT unless otherwise noted.

Introductory: Grades 5-10

Prealgebra 1 Self-Paced

Prealgebra 1
Sunday, Apr 13 - Aug 10
Tuesday, May 13 - Aug 26
Thursday, May 29 - Sep 11
Sunday, Jun 15 - Oct 12
Monday, Jun 30 - Oct 20
Wednesday, Jul 16 - Oct 29

Prealgebra 2 Self-Paced

Prealgebra 2
Sunday, Apr 13 - Aug 10
Wednesday, May 7 - Aug 20
Monday, Jun 2 - Sep 22
Sunday, Jun 29 - Oct 26
Friday, Jul 25 - Nov 21

Introduction to Algebra A Self-Paced

Introduction to Algebra A
Monday, Apr 7 - Jul 28
Sunday, May 11 - Sep 14 (1:00 - 2:30 pm ET/10:00 - 11:30 am PT)
Wednesday, May 14 - Aug 27
Friday, May 30 - Sep 26
Monday, Jun 2 - Sep 22
Sunday, Jun 15 - Oct 12
Thursday, Jun 26 - Oct 9
Tuesday, Jul 15 - Oct 28

Introduction to Counting & Probability Self-Paced

Introduction to Counting & Probability
Wednesday, Apr 16 - Jul 2
Thursday, May 15 - Jul 31
Sunday, Jun 1 - Aug 24
Thursday, Jun 12 - Aug 28
Wednesday, Jul 9 - Sep 24
Sunday, Jul 27 - Oct 19

Introduction to Number Theory
Thursday, Apr 17 - Jul 3
Friday, May 9 - Aug 1
Wednesday, May 21 - Aug 6
Monday, Jun 9 - Aug 25
Sunday, Jun 15 - Sep 14
Tuesday, Jul 15 - Sep 30

Introduction to Algebra B Self-Paced

Introduction to Algebra B
Wednesday, Apr 16 - Jul 30
Tuesday, May 6 - Aug 19
Wednesday, Jun 4 - Sep 17
Sunday, Jun 22 - Oct 19
Friday, Jul 18 - Nov 14

Introduction to Geometry
Wednesday, Apr 23 - Oct 1
Sunday, May 11 - Nov 9
Tuesday, May 20 - Oct 28
Monday, Jun 16 - Dec 8
Friday, Jun 20 - Jan 9
Sunday, Jun 29 - Jan 11
Monday, Jul 14 - Jan 19

Intermediate: Grades 8-12

Intermediate Algebra
Monday, Apr 21 - Oct 13
Sunday, Jun 1 - Nov 23
Tuesday, Jun 10 - Nov 18
Wednesday, Jun 25 - Dec 10
Sunday, Jul 13 - Jan 18
Thursday, Jul 24 - Jan 22

Intermediate Counting & Probability
Wednesday, May 21 - Sep 17
Sunday, Jun 22 - Nov 2

Intermediate Number Theory
Friday, Apr 11 - Jun 27
Sunday, Jun 1 - Aug 24
Wednesday, Jun 18 - Sep 3

Precalculus
Wednesday, Apr 9 - Sep 3
Friday, May 16 - Oct 24
Sunday, Jun 1 - Nov 9
Monday, Jun 30 - Dec 8

Advanced: Grades 9-12

Olympiad Geometry
Tuesday, Jun 10 - Aug 26

Calculus
Tuesday, May 27 - Nov 11
Wednesday, Jun 25 - Dec 17

Group Theory
Thursday, Jun 12 - Sep 11

Contest Preparation: Grades 6-12

MATHCOUNTS/AMC 8 Basics
Wednesday, Apr 16 - Jul 2
Friday, May 23 - Aug 15
Monday, Jun 2 - Aug 18
Thursday, Jun 12 - Aug 28
Sunday, Jun 22 - Sep 21
Tues & Thurs, Jul 8 - Aug 14 (meets twice a week!)

MATHCOUNTS/AMC 8 Advanced
Friday, Apr 11 - Jun 27
Sunday, May 11 - Aug 10
Tuesday, May 27 - Aug 12
Wednesday, Jun 11 - Aug 27
Sunday, Jun 22 - Sep 21
Tues & Thurs, Jul 8 - Aug 14 (meets twice a week!)

AMC 10 Problem Series
Friday, May 9 - Aug 1
Sunday, Jun 1 - Aug 24
Thursday, Jun 12 - Aug 28
Tuesday, Jun 17 - Sep 2
Sunday, Jun 22 - Sep 21 (1:00 - 2:30 pm ET/10:00 - 11:30 am PT)
Monday, Jun 23 - Sep 15
Tues & Thurs, Jul 8 - Aug 14 (meets twice a week!)

AMC 10 Final Fives
Sunday, May 11 - Jun 8
Tuesday, May 27 - Jun 17
Monday, Jun 30 - Jul 21

AMC 12 Problem Series
Tuesday, May 27 - Aug 12
Thursday, Jun 12 - Aug 28
Sunday, Jun 22 - Sep 21
Wednesday, Aug 6 - Oct 22

AMC 12 Final Fives
Sunday, May 18 - Jun 15

F=ma Problem Series
Wednesday, Jun 11 - Aug 27

WOOT Programs
Visit the pages linked for full schedule details for each of these programs!


MathWOOT Level 1
MathWOOT Level 2
ChemWOOT
CodeWOOT
PhysicsWOOT

Programming

Introduction to Programming with Python
Thursday, May 22 - Aug 7
Sunday, Jun 15 - Sep 14 (1:00 - 2:30 pm ET/10:00 - 11:30 am PT)
Tuesday, Jun 17 - Sep 2
Monday, Jun 30 - Sep 22

Intermediate Programming with Python
Sunday, Jun 1 - Aug 24
Monday, Jun 30 - Sep 22

USACO Bronze Problem Series
Tuesday, May 13 - Jul 29
Sunday, Jun 22 - Sep 1

Physics

Introduction to Physics
Wednesday, May 21 - Aug 6
Sunday, Jun 15 - Sep 14
Monday, Jun 23 - Sep 15

Physics 1: Mechanics
Thursday, May 22 - Oct 30
Monday, Jun 23 - Dec 15

Relativity
Sat & Sun, Apr 26 - Apr 27 (4:00 - 7:00 pm ET/1:00 - 4:00pm PT)
Mon, Tue, Wed & Thurs, Jun 23 - Jun 26 (meets every day of the week!)
0 replies
jlacosta
Yesterday at 3:18 PM
0 replies
Complex numbers
RenheMiResembleRice   0
2 minutes ago
Solve the following attached.
0 replies
RenheMiResembleRice
2 minutes ago
0 replies
2 var inquality
sqing   1
N 5 minutes ago by lbh_qys
Source: Own
Let $ a,b> 0 $ and $ a+b= 2 . $ Prove that
$$ \frac{a^5}{a^5+ b^3}+ \frac{b^5}{b^5+ a^3}\leq 1$$$$ \frac{a^6}{a^5+ b^3}+ \frac{b^6}{b^5+ a^3}\leq 2$$
1 reply
2 viewing
sqing
15 minutes ago
lbh_qys
5 minutes ago
Harmonic Series and Infinite Sequences
steven_zhang123   2
N 8 minutes ago by NTstrucker
Source: China TST 2025 P19
Let $\left \{ x_n \right \} _{n\ge 1}$ and $\left \{ y_n \right \} _{n\ge 1}$ be two infinite sequences of integers. Prove that there exists an infinite sequence of integers $\left \{ z_n \right \} _{n\ge 1}$ such that for any positive integer \( n \), the following holds:

\[
\sum_{k|n} k \cdot z_k^{\frac{n}{k}} = \left( \sum_{k|n} k \cdot x_k^{\frac{n}{k}} \right) \cdot \left( \sum_{k|n} k \cdot y_k^{\frac{n}{k}} \right).
\]
2 replies
steven_zhang123
Mar 29, 2025
NTstrucker
8 minutes ago
Finding pairs of complex numbers with a certain property
Ciobi_   1
N 12 minutes ago by NTstrucker
Source: Romania NMO 2025 10.4
Find all pairs of complex numbers $(z,w) \in \mathbb{C}^2$ such that the relation \[|z^{2n}+z^nw^n+w^{2n} | = 2^{2n}+2^n+1 \]holds for all positive integers $n$.
1 reply
Ciobi_
Yesterday at 1:22 PM
NTstrucker
12 minutes ago
No more topics!
Israel Number Theory
mathisreaI   62
N Mar 31, 2025 by cursed_tangent1434
Source: IMO 2022 Problem 5
Find all triples $(a,b,p)$ of positive integers with $p$ prime and \[ a^p=b!+p. \]
62 replies
mathisreaI
Jul 13, 2022
cursed_tangent1434
Mar 31, 2025
Israel Number Theory
G H J
Source: IMO 2022 Problem 5
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Celestin
2 posts
#58 • 1 Y
Y by cubres
The mistake done was on solutions(3,4,4) but this (3,4,3)
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Sammy27
81 posts
#59 • 2 Y
Y by Eka01, cubres
Solution
This post has been edited 2 times. Last edited by Sammy27, Oct 3, 2024, 10:00 AM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
sami1618
880 posts
#60 • 1 Y
Y by cubres
The only solutions are $\boxed{(a,b,p)=(2,2,2),(3,4,3)}$:

Case 1: $p=2$
We have that $4\nmid a^2-2\Rightarrow b<4$ which leads to $(2,2,2)$ being the only answer. Now assume that $p$ is odd.

Case 2: $p\leq b$
We get $p|a$ so let $a=kp$. Now we get $k^pp^p-p=b!$. Since $p^2\nmid k^pp^p-p$ we must have $b<2p\Rightarrow k<p$. If $k\neq 1$ taking modulo $k$ gives $b<k$, a contradiction. If $k=1$ we get that $p^p-p=b!$. Then $v_2(p^{p}-p)=v_2(p^{p-1}-1)=2v_2(p-1)+v_2(p+1)-1=v_2(b!)$. But $v_2(n!)\leq 2v_2(n)-1$ so $b$ is at most $p+1$. A quick size argument gives the above answer.

Case 3: $b<p$
Then we must have $a<p$. Taking mod $a$ we get that $b<a$, a size contradiction.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
xProblemDestroyer1434
3 posts
#61 • 1 Y
Y by cubres
Solution
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
BlazingMuddy
281 posts
#62 • 1 Y
Y by cubres
The number $p$ does not have to be prime; we only need $p \geq 2$. The solution does become more tedious, unfortunately. For convenience, we change the letter $p$ to $c$. That is...
Quote:
Find all triplets $(a, b, c)$ of positive integers such that $c > 1$ and
\[ a^c = b! + c. \]

Answer. $(a, b, c) \in \{(2, 2, 2), (3, 4, 3)\}$.

Clearly these two triplets work, so now we prove that no other triplets work. Some parts of the solution is taken from the official solution. Note that clearly $a > 1$.

Lemma 1.
Let $p$ be a prime such that $p \mid a$. Then $\nu_p(c) = \nu_p(b!)$.
Proof

Lemma 2.
If $b \geq c$, then $(a, b, c) \in \{(2, 2, 2), (3, 4, 3)\}$.
Proof

It remains to show that $b \geq c$. We suppose for the sake of contradiction that $b < c$.

Lemma 3.
We have $a \leq b$ and $a \mid c$.
Proof

We now analyze the prime divisors of $a$. Let $p$ be the smallest prime divisor of $a$, and let $k = \nu_p(c)$.

First, we show that $k \geq 2$. By Lemma 3, $k \geq 1$. If $k = 1$, then Lemma 1 yields $\nu_p(b!) = 1$, so $b \leq 2p - 1$. By AM-GM inequality, $b! \leq p^{2p - 1}$. On the other hand, $p \leq a < c$ and $p \mid a \mid c$, so $a^c - c \geq p^{2p} - p > p^{2p - 1}$; a contradiction. This shows that $k \geq 2$.

Next, we do some estimates. We start by showing that $c$ is a power of $p$. If not, then $c \geq 2p^k$ and
\[ b! = a^c - c \geq p^{2p^k} - 2p^k > p^{2p^k - 1}. \]On the other hand, $\nu_p(b!) = k$, so $b \leq p(k + 1) - 1$. Some trivial estimates yield
\[ b! \leq (p(k + 1) - 1)! \leq p^p (2p)^p (3p)^p \ldots ((k + 1)p)^p = (k + 1)!^p p^{p(k + 1) - 1}. \]Thus we get
\[ p^{2p^k} < (k + 1)!^p p^{p(k + 1)} \iff p^{2p^{k - 1} - (k + 1)} < (k + 1)!. \]Trivially estimating $(k + 1)! \leq p^{0 + 1 + \ldots + k}$ yields
\[ 2p^{k - 1} - (k + 1) < \binom{k + 1}{2} \implies 2p^{k - 1} < \binom{k + 2}{2}, \]which is false for $p \geq 3$ and $k \geq 2$. However, if $p = 2$, then $c \geq 3 \cdot 2^k$ and repeating the same argument yields $3 \cdot 2^{k - 1} < \binom{k + 2}{2}$, which is again a contradiction for any $k \geq 2$. Thus, $c$ is a power of $p$. Since $\nu_p(c) = k$, we have $c = p^k$.

Since $a \mid c$, now $a$ is also a power of $p$. If $a \neq p$, then $a \geq p^2$ and $a^c - c \geq p^{2p^k} - p^k \geq p^{2p^k - 1}$. Repeating the above process gives a contradiction if $p > 2$, so now assume that $p = 2$. Then $a \geq 4$, $c$ is a power of $2$, and the above estimate gives
\[ 2^{2^k - (k + 1)} = 2^{2 \cdot 2^{k - 1} - (k + 1)} < (k + 1)!. \]The estimate $(k + 1)! \leq 2^{0 + 1 + \ldots + k}$ gives $2^k - (k + 1) < \binom{k + 1}{2}$, so $2^k < \binom{k + 2}{2}$. This is false for $k \geq 4$, so $k \leq 3$. Since $a \geq 4$ and $a < c = 2^k$ with $k \leq 3$, then we get $a = 4$ and $c = 8$, which does not work since $4^8 - 8 > 5!$ and $4^8 - 8 \not\equiv 0 \pmod{5}$.

Thus, $a = p$ and $c = p^k$ for some $k \geq 2$. Repeating the same procedure yields
\[ p^{p^k - 1} < p^{p^k} - p^k = b! < (p(k + 1) - 1)! < (k + 1)!^p p^{p(k + 1) - 1} \implies p^{p^{k - 1} - (k + 1)} < (k + 1)!. \]Again, use the esimate $(k + 1)! \leq p^{0 + 1 + \ldots + k}$. This time, we get
\[ p^{k - 1} < \binom{k + 2}{2}, \]which implies either $(p, k) \in \{(5, 2), (3, 2)\}$ or $p = 2$ and $k \leq 6$. Plugging into the previous inequality shows that $(p, k) = (5, 2)$ does not work and $p = 2$ forces $k \leq 4$, so $(p, k) \in \{(3, 2), (2, 2), (2, 3), (2, 4)\}$. That is, $(a, c) \in \{(3, 9), (2, 4), (2, 8), (2, 16)\}$. Working mod $5$ implies that $b < 5$ if $(a, c) \neq (2, 16)$, and direct computation shows that none of the three works. Finall, if $(a, c) = (2, 16)$, then $a^c - c = 65520$, which is not a factorial.

Too many repeat of estimations :( Someone please simplify this proof.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
InftyByond
197 posts
#63 • 1 Y
Y by cubres
plz help im cooked
can anybody read this solution and tell me how correct (and maybe a score out of 7)

$$a^p-a=b!+p-a$$So by FLT we get $$a(a^{p-1}-1)\equiv 0 \equiv b!+p-a \mod p.$$Thus, $$b!\equiv a \mod p.$$We may then conclude that if $b>p,$ then $b! \equiv 0 \mod p$.
If $b\leq p$, then we know that $$a^p\geq 2^p \geq 2p \geq b!+p$$which shows that the only solution in this case is $b=a=p=2$.

So we may now assume that $b! \equiv 0 \mod p$, and consequently $a \equiv 0 \mod p$.
Thus $\nu_p(a^p-p)=1$, and thus $\frac{b!}{p}$ cannot be divisible by $p$.
Replacing $a$ with $kp$ gives us $$a^p-p=k^pp^p-p=p(k^pp^{p-1}-1)=b!$$Dividing both sides by $p$ and taking mod $p$ gives that the right side must be equal to $(b-p)!\equiv 1 \mod p$.

We show that there are no solutions for $p \geq 5$.
We first show that $a=p$.
If $a=kp$ where $k>1$, then we know that another prime divides $a$, and if it divides $b!$ then we arrive at a contradiction.
So this means that $k>2p$.
Then we get $a^p>2^pp^2p>b!+p$, so $a=p$.
Then $p^p= (2p-1)!+p$.
$$p^p-p=(2p-1)!$$The right side is clearly greater than the left side for all values $p\geq 5$, so we only require to test $p=3$.
Then we get $(3, 4, 3)$ is another solution.

So the only solutions that are possible are $(2, 2, 2)$, and $(3, 4, 3)$.
The proof is complete.
This post has been edited 2 times. Last edited by InftyByond, Sep 11, 2024, 12:37 AM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
megarnie
5551 posts
#64 • 1 Y
Y by cubres
Resolving

The only solutions are $(2,2,2)$ and $(3,4,3)$, which clearly work. Now we show they are the only ones.
Claim: If $p = 2$, $a = b = 2$.
Proof: Assume $p = 2$. We have $a^2 = b! + 2$. If $b \ge 4$, then $4\mid b!$, so $a^2 \equiv 2 \pmod 4$, a contradiction. Thus, $b \le 3$ and we can check $b \in \{1,2,3\}$ and get that $a = b = 2$ is the only working solution. $\square$

Henceforth assume $p > 2$.

Claim: $b! > p$.
Proof: Note that $a = 1$ is obviously not possible. So $b! + p = a^p \ge 2^p > 2p$, meaning $b! > p$. $\square$
Claim: $b \ge p$.
Proof: Suppose not. Since $b! > p > 2$, $b  \ge3$. Note that \[a^p b! + p \le 2b! < (b+1)! < (b+1)^p, \]so $a < b + 1\implies a \le b$. Thus, $a\mid b!$. Since $a\mid a^p$, $a\mid a^p - b! = p$, so $a \in \{1,p\}$. Since $a \le b < p$, $a < p$, so $a = 1$, absurd. $\square$

Claim: $p\mid a$ and $b< 2p$
Proof: Firstly, \[b \ge p\implies p\mid b! \implies p\mid b! + p = a^p\implies p\mid a\]
Now, if $b \ge 2p$, then $p^2 \mid b!$, so $\nu_p(b! + p) = 1$, meaning $\nu_p(a^p) = 1$, contradiction since $p^p \mid a^p$. $\square$

Case 1: $a\ne p$
Then $a > p$. Let $a = xp$ for some $x > 1$.

Claim: $x \ge p$.
Proof: Let $q$ be a prime divisor of $x$. We show that $q \ge p$, which finishes. Suppose otherwise. Then note that $q\mid b! + p$ but $q \nmid p$ (as $q \ne p$), so $q\nmid b! \implies b < q < p$, absurd. $\square$

We now have $a^p  \ge (p^2)^p = p^{2p}$, so $p^{2p} \le b! + p < (b+1)! \le (2p)!$. However, note that \[(2p)! = p \cdot \prod_{i=1}^{p - 1}  i(2p - i) \le p \cdot \prod_{i=1}^{p - 1} p^2 = p^{2p - 1} \]by AM-GM, a contradiction.

Case 2: $ a=p$
Then $b! = p^p - p = p(p^{p - 1} - 1)$. Note that \[\nu_2(b!) \ge \nu_2((p)!) = p - s_2(p) \ge p - \log_2(p + 1),\]where $s_2$ is the sum of digits in base $2$. Now, by LTE \[\nu_2(p (p^{p - 1} - 1) ) = \nu_2(p^{p - 1} - 1^{p - 1}) = 2 \nu_2(p - 1) < 2 \log_2(p ) \]
Combining gives that $p - \log_2(p + 1) < 2 \log_2(p)$, so \[ 2\log_2(p) + \log_2(p + 1) > p\implies \log_2(p^2(p + 1)) > p\]
Thus, $2^p < p^2(p + 1)$.

Claim: $2^x > x^2(x+1)$ for all integers $x \ge 11$.
Proof: Let $f(x) = x^2(x+1)$. We wish to show $2^x > f(x) \forall x \ge 11$. We go by induction on $x$. The base case $x = 11$ is obviously true. . Suppose it's true for $11, 12,\ldots, n$. We have \[ \frac{f(n+1)}{f(n)} = \left( \frac{n+1}{n} \right) ^2 \cdot \frac{n+2}{n+1} = \left( 1 + \frac 1n \right)^2 \cdot \left( 1 + \frac{1}{n+1} \right) \le \frac{12}{11} ^2 \cdot \left( \frac{13}{12} \right) < 2 \]
Now, we have \[2^{n+1} = 2^n \cdot 2 > f(n) \cdot 2 > f(n) \cdot \frac{f(n+1)}{f(n)} = f(n+1),\]as desired. $\square$

This immediately implies that $p < 11$, so $p\in \{3,5,7\}$.

Note that if $p = 7$, then since $b \ge 7$, $5\mid b! = 7^7 - 7$, which is a contradiction as $7^7 \equiv 3 \pmod 5$.

Now if $p = 5$, we have $b! = 5^5 - 5 = 3120$, which isn't a factorial. Therefore, $p = 3$ and $b! = 3^3 - 3 = 24\implies b = 4$.

Hence $(a,b,p) = (3,4,3)$, as desired.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
onyqz
195 posts
#65 • 1 Y
Y by cubres
storage
solution
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
EVKV
43 posts
#66 • 1 Y
Y by cubres
If b≥2p no sol
By mod p then mod p²

If b<p
And a>p then no sol
As a^p≥ (p+1)^p> (p-1)! +p≥b! +p

a≤b
Then a|p
Umpossible

So b<a<p

a^p> b! +p

So

b,a≥p

If p= b
And a>b
umpossible

if a<b also impossible
By mod p

p^p = p! +p might work

p^(p-1) > p!

(p+1)! > p! +p

So together p^p> p! +p
For p>2
Which gives 1 sol by bounding
2,2,2

If p<a,b<2p

a^p is not divisible by p
But b! +p is
so umpossible

a<p b>p has same problem

p<b<2p
a≥2p so a=kp
(kp)^p = b! +p
k=por k≥2p
If k≥2p
At a min
(2p)^p * p^(p) > b! + p

So k= p

If k= p
p^(2p) > b! + p
So only one final case remaining

a= p
p^p = b! +p
Take some odd prime q dividing p-1

2(vq(p-1)) = vq(b!)

If q||p-1
2= vq(b!)>4
So umpossible

q^k||(p-1)
2k = vq(b!) > k + k-1 +k-2 ...... =
(k+1)k /2
2> k+1/2
3>k
Let k= 2
4 = vq(b!)≥ 2+1
vq(b!) = 3 , 5..... So no 4
Umpossible
Thus there is no q

So 2^k = p^(p-1) -1

So only p,2 divide b!

So b≤4

Now done

3,4,3

Final solution (a,b,c) =(3,4,3),(2,2,2)
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
cubres
101 posts
#67
Y by
Storage - grinding IMO problems
This post has been edited 1 time. Last edited by cubres, Dec 30, 2024, 7:49 PM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Scilyse
387 posts
#68 • 1 Y
Y by cubres
The solutions are $(2, 2, 2)$ and $(3, 4, 3)$.

If $b \geq 2p$, then $p \mid b! + p$, so $p \mid a^p$, so $p \mid a$. But $\nu_p(a^p) \geq p \geq 2$ and $\nu_p(b! + p) = \min\{\nu_p(b!), \nu_p(p)\} = 1$ since $2 \leq \nu_p(b!) \neq \nu_p(p) = 1$, contradiction.

If $p \leq b < 2p$, then once again $p \mid a$.
  • If $a \geq 2p^2$, then
    \begin{align*}
a^p \geq (2p^2)^p = 2^p p^{2p} &= \underbrace{p \cdot p \cdot \dots \cdot p}_{p \text{ times}} \cdot \underbrace{2p \cdot 2p \cdot \dots \cdot 2p}_{p \text{ times}} \\
&> 2 \cdot 2 \cdot 3 \cdot 4 \cdot 5 \cdot \dots \cdot 2p \\
&= 2 \cdot (2p)! \\
&> (2p)! + p \\
&> b! + p,
\end{align*}contradiction.
  • If $p^2 \leq a < 2p^2$, then let $a = kp$ for an integer $p \leq k < 2p$. Now
    \begin{align*}
b! + p = a^p = (kp)^p = k^p p^p &= \underbrace{p \cdot p \cdot \dots \cdot p}_{p \text{ times}} \cdot \underbrace{k \cdot k \cdot \dots \cdot k}_{p \text{ times}} \\
&> 2 \cdot 2 \cdot 3 \cdot 4 \cdot 5 \cdot \dots \cdot k \cdot 1 \cdot 1 \cdot \dots \cdot 1 \\
&= 2k! \\
&\geq k! + p.
\end{align*}Therefore, $b! + p > k! + p$, so $b > k$, so $k \mid b!$. Now observe that $k \mid a \mid a^p = b! + p$, so $k \mid p$. Since $p \leq k$, this implies that $k = p$. Hence, $p^{2p} = b! + p$.
    • If $b \geq p + 1$, then taking both sides modulo $p + 1$ yields
      \begin{align*}
(-1)^{2p} &\equiv -1 \pmod{p + 1} \\
1 &\equiv -1 \pmod{p + 1},
\end{align*}contradiction as $p + 1 \geq 3$.
    • If $b = p$, then we claim $p! + p < p^{2p}$ which yields a contradiction. Indeed,
      \begin{align*}
p^{2p} &= \underbrace{p^2 \cdot p^2 \cdot \dots \cdot p^2}_{p \text{ times}} \\
&> 2 \cdot 2 \cdot 3 \cdot 4 \cdot 5 \cdot \dots \cdot p \\
&= 2p! \\
&\geq p! + p,
\end{align*}as desired.
  • If $a < p^2$, then let $a = kp$ for an integer $1 \leq k < p \leq b$ so that $k \mid b!$ as above. Now observe that $k \mid a \mid a^p = b! + p$, so $k \mid p$. Since $k < p$, this implies that $k = 1$. Hence, $p^p - p = b!$.
    • If $p = 2$, then $(a, b, p) = (2, 2, 2)$, which works.
    • Otherwise, $p$ is odd. On one hand, \begin{align*}\nu_2(p^p - p) = \nu_2(p^{p - 1} - 1^{p - 1}) = \nu_2(p^2 - 1) + \nu_2\left(\frac{p - 1}{2}\right) \leq \log_2((p^2 - 1)(p - 1)) - 1 < 3 \log_2 p - 1.\end{align*}On the other hand, \[\nu_2(b!) = b - s_2(b) \geq b - (\log_2 b + 1) = \log_2\left(\frac{2^b}{b}\right) - 1.\]Since $\frac{2^x}{x}$ is increasing on $[2, \infty)$, we have \[\log_2\left(\frac{2^b}{b}\right) - 1 \geq \log_2\left(\frac{2^p}{p}\right) - 1 = p - \log_2 p - 1.\]Hence $3 \log_2 p - 1 > p - \log_2 p - 1$, or equivalently, $2^p < p^4$. This fails for all $p \geq 17$, so it suffices to check $p \in \{3, 5, 7, 11, 13\}$.
      • If $p = 3$, then $(a, b, p) = (3, 4, 3)$, which works.
      • If $p = 5$, then $b! = 3120$, bad.
      • If $p = 7$, then $b! = 823536$, bad.
      • If $p = 11$, then $b! = 285311670600$, which is contained between $14! = 87178291200$ and $15! = 1307674368000$, bad.
      • If $p = 13$, then $b! = 302875106592240$, which is contained between $16! = 20922789888000$, $17! = 355687428096000$, bad.
If $2 \leq b < p$, then obviously $a < p$ as $p \nmid a$ and if $a \geq p$ then \[b! + p \leq \frac{b}{2} \cdot b^{b - 1} + p \leq b^b < p^p \leq a^p,\]contradiction.
  • If $a < b$, then $a \mid b!$ and $a \mid a^p \mid b! + p$, so $a \mid p$, which implies that $a = 1$. This obviously yields no solutions.
  • If $a \geq b$, then (noting that $a \geq 2$ here)
    \begin{align*}
a^p &= (a - 1) \cdot a^{p - 1} + a^{p - 1} \\
&\geq (a - 1) \cdot \underbrace{a \cdot a \cdot \dots \cdot a}_{p - 1 \text{ times}} + p \\
&\geq 1 \cdot 2 \cdot 3 \cdot 4 \cdot \dots \cdot b \cdot 1 \cdot 1 \cdot \dots \cdot 1 + p \\
&= b! + p.
\end{align*}The condition $a = b = 2$, derived from the equality case of the second inequality, is necessary for equality to hold throughout. But this implies that $p = 2$, contradicting the assumption that $b < p$.
Lastly, if $b = 1$, then $a^p = p + 1$. Of course, if $a = 1$, then $p = 0$, which is impossible, and if $a \geq 2$, then we can induct on $p$ to get that $a^p > p + 1$. Hence, there are no solutions in this case.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
SimplisticFormulas
85 posts
#69 • 1 Y
Y by cubres
doesn’t feel too tough for n4

We claim that $(a,b,p)=(2,2,2)$ and $(3,4,3)$ are the only solutions.
Firstly, we show that $b \le 2p$. Indeed, assume the contrary. Then $p \mid p+ b!=a^p \implies p \mid a \implies p^p \mid a^p$. But $p^2 \nmid p + b!$ since $p^2 \nmid p$, giving us the desired contradiction.

Next, we shall prove that $p \mid a$. Indeed, assume otherwise. Then any prime factor $q$ of a must not $b!$ since $q \mid b!+p$ but $q \nmid p$. So $b<q \le a$, But note that $p=a^p - b! >a^p -b^p>p$, which is absurd.

Now, note that $a \le b$. If this is not the case then $p=a^p - b! >a^p -b^p>p$, which is contradictory. This shows that $a=p$.
Hence, $b!= p^p-p=p(p^{p-1}-1)$, so $b> \ge p$ From here it’s basically same as $(iii)$ of @Leartia.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Ilikeminecraft
330 posts
#70
Y by
If $p = 2,$ we have $a = 2, b = 2.$ If $p = 3,$ $a = 3, b = 3.$ Thus, assume that $p\geq5.$

First, notice that if $b \geq2p,$ then $\nu_p(b!) \geq2,$ while $\nu_p(a^p - p) \leq 1.$ Hence, $b < 2p.$ We also have that if $b = 2p - 1, $ then by Wilsons theorem, $\frac{b! + p}{p} \equiv 2\pmod p,$ and hence can't work.

Now, AFTSOC that $b < p.$ Thus, $a^p - p = b! \leq b^p\implies a \leq b.$ Thus, taking modulo $a,$ we have that $0 \equiv a^p \equiv b! + p \equiv p \pmod a.$ Thus, $a \mid p\implies a = p$ or $a = 1.$ If $a = p,$ then $a \leq b < p = a,$ which is a contradiction.

Thus, $p\leq b < 2p - 1.$ By the upper bound, we have that $b! + p < (2p - 1)! + p < (1\cdot(2p - 1))(2\cdot(2p - 2))\cdot p < (p^2)^p$ By taking modulo $p - 1,$ we have that $a^p \equiv 1 \pmod {p - 1}.$ Thus, $\operatorname{ord}_{p - 1}(a) \mid (\phi(p - 1), p) = 1 \implies a \equiv 1 \pmod {p - 1}.$ Thus, $a \equiv p \pmod{p^2 - p}\implies a = p.$

Thus, we are solving $p^p - p = b!.$ By taking $\nu_2,$ we have that $\nu_2(p^p - p) = \nu_2(p - 1) + \nu_2(p-1) \leq 2\log_2(p -1),$ and $\nu_2(p!) \geq p-\log_2(p+1)$ by legrende. It is obvious that $\nu_2(p!)>\nu_2(p^p-p)$ for $p\geq 10$ from this bound. Manually checking $p = 5, 7$ is trivial.
This post has been edited 1 time. Last edited by Ilikeminecraft, Mar 14, 2025, 6:06 AM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
ray66
26 posts
#71
Y by
There are 3 cases.

First if $p>b$, then $a^p = b! + p$, so $a$ is not divisible by any prime $\le b$, and $a \neq 1$, so the LHS becomes too large because $a^p > a^b > b^p > b!+p$.

Next if $1 < p \le \frac{b}{2}$, then $p | a$ because $p$ divides both the RHS and LHS, but the RHS has 1 factor of $p$ because $2p\le b$, so there are no solutions.

Next if $\frac{b}{2} < p \le b$, then $a=p$ because if $a \ge 2p > b$, the LHS grows too fast. Then $b! = p^p-p$ and $\frac{b!}{p}=p^{p-1}-1$. LTE gives $\nu_2(b!) = \nu_2(p-1) + \nu_2(p-1) + \nu_2(p+1)-1$ but this means that $b \le 6$. From here we can check that $(2,2,2)$ and $(3,4,3)$ work
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
cursed_tangent1434
565 posts
#72
Y by
The only solutions are $(2,2,2)$ and $(3,4,3)$ which clearly work. We start off with some bounding.

Claim : We have $p \le b < 2p$.

Proof : If $b \ge 2p$ note that $p\mid b!+p$ and hence $p\mid a^p$ so $p\mid a$. But then,
\[p^2 \mid a^p - b! = p\]which is a very clear contradiction. Further, if $b<p$ and $a \le b$ then there exists some prime $r<p$ such that $r\mid a$ (clearly $a>1$) so
\[r \mid a^p - b!=p\]which is again a contradiction. Thus we must have $a>b$ but then,
\[a^p \ge (b+1)^p \ge b^p + p\cdot b^{p-1} \ge b^p+p > b!+p\]which is also a contradiction. Thus, there is no possibility for $b$ to violate these bounds, proving the claim.

Claim : We have $a=p$ exactly.

Proof : Since $b \ge p$ we note that,
\[p\mid b!+p=a^p\]so $p\mid a$. Now, say there exists a prime $r<p$ such that $r \mid a$. But then,
\[r \mid a^p-b! =p\]which is a clear contradiction. Thus, such a prime $r$ cannot exist, implying that $a \ge p^2$, which is impossible since
\[a^p\ge p^{2p} \ge (2p)! +p > b! +p\]for all primes $p \ge 3$ (we deal with $p=2$ separately later) or $a=p$ which is the only remaining possibility.

Now, if $p=2$ we have
\[a^2=b!+2 \equiv 2 \pmod{4}\]for all $b \ge 4$ which is impossible, implying that $b \in \{1,2,3\}$ of which only $b=2$ works yielding the solution set $(a,b,p)=(2,2,2)$.

Thus, we are left to sort out the equation,
\[p^p-p=b!\]for all primes $ p >2$. Note that if $p=3$ we have $b=4$ yeilding the solution set $(a,b,p)=(3,4,3)$ so we consider $p>3$ in what follows. By the Lifting the Exponent Lemma,
\[\nu_2(p^{p-1}-1) = 2\nu_2(p-1)+\nu_2(p+1)-1 \le \max(2\nu_2(p-1)+\nu_2(p+1)+1) \le 2\log_2(p-1)\]However, by Legendre's Formula we have
\[\nu_2(b!) \ge \nu_2(p!) \ge \lfloor{\frac{p}{2}}\rfloor\]Further,
\[\lfloor{\frac{p}{2}}\rfloor > 2\log_2(p-1) \]for all $p \ge 10$. Thus, we must have $p \in \{5,7\}$ which are fairly easy to check by hand.
Z K Y
N Quick Reply
G
H
=
a