Stay ahead of learning milestones! Enroll in a class over the summer!

G
Topic
First Poster
Last Poster
k a April Highlights and 2025 AoPS Online Class Information
jlacosta   0
Apr 2, 2025
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
Apr 2, 2025
0 replies
NEPAL TST 2025 DAY 2
Tony_stark0094   6
N 11 minutes ago by GeoKing
Consider an acute triangle $\Delta ABC$. Let $D$ and $E$ be the feet of the altitudes from $A$ to $BC$ and from $B$ to $AC$ respectively.

Define $D_1$ and $D_2$ as the reflections of $D$ across lines $AB$ and $AC$, respectively. Let $\Gamma$ be the circumcircle of $\Delta AD_1D_2$. Denote by $P$ the second intersection of line $D_1B$ with $\Gamma$, and by $Q$ the intersection of ray $EB$ with $\Gamma$.

If $O$ is the circumcenter of $\Delta ABC$, prove that $O$, $D$, and $Q$ are collinear if and only if quadrilateral $BCQP$ can be inscribed within a circle.

$\textbf{Proposed by Kritesh Dhakal, Nepal.}$
6 replies
Tony_stark0094
Saturday at 8:40 AM
GeoKing
11 minutes ago
Combinatorics or algebra?
persamaankuadrat   1
N 18 minutes ago by removablesingularity
Source: OSNK 2024
How many sequences of $\left(a_{1},a_{2},a_{3},a_{4},a_{5},a_{6} \right)$ where the $a_{i}$ are positive integers such that each $1 \le a_{i} \le 4$ and none of two consecutive terms when summed are equal to $4$.
1 reply
persamaankuadrat
Yesterday at 6:34 AM
removablesingularity
18 minutes ago
one cyclic formed by two cyclic
CrazyInMath   21
N 21 minutes ago by MarkBcc168
Source: EGMO 2025/3
Let $ABC$ be an acute triangle. Points $B, D, E$, and $C$ lie on a line in this order and satisfy $BD = DE = EC$. Let $M$ and $N$ be the midpoints of $AD$ and $AE$, respectively. Suppose triangle $ADE$ is acute, and let $H$ be its orthocentre. Points $P$ and $Q$ lie on lines $BM$ and $CN$, respectively, such that $D, H, M,$ and $P$ are concyclic and pairwise different, and $E, H, N,$ and $Q$ are concyclic and pairwise different. Prove that $P, Q, N,$ and $M$ are concyclic.
21 replies
CrazyInMath
Yesterday at 12:38 PM
MarkBcc168
21 minutes ago
Mock 22nd Thailand TMO P5
korncrazy   1
N 22 minutes ago by EeEeRUT
Source: own
Find all functions $f:\mathbb{R}^+\rightarrow\mathbb{R}$ such that $f(1)=0$ and $$f(x)f(y)f(z)=f(x^2)+f(y^2)+f(z^2)$$for all positive real numbers $x,y,z$ such that $xyz=1$.
1 reply
+1 w
korncrazy
Yesterday at 6:54 PM
EeEeRUT
22 minutes ago
No more topics!
Easy complete system of residues problem in Taiwan TST
Fysty   5
N Mar 30, 2025 by AllenZhuang
Source: 2025 Taiwan TST Round 1 Independent Study 1-N
Find all positive integers $n$ such that there exist two permutations $a_0,a_1,\ldots,a_{n-1}$ and $b_0,b_1,\ldots,b_{n-1}$ of the set $\lbrace0,1,\ldots,n-1\rbrace$, satisfying the condition
$$ia_i\equiv b_i\pmod{n}$$for all $0\le i\le n-1$.

Proposed by Fysty
5 replies
Fysty
Mar 5, 2025
AllenZhuang
Mar 30, 2025
Easy complete system of residues problem in Taiwan TST
G H J
G H BBookmark kLocked kLocked NReply
Source: 2025 Taiwan TST Round 1 Independent Study 1-N
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Fysty
13 posts
#1
Y by
Find all positive integers $n$ such that there exist two permutations $a_0,a_1,\ldots,a_{n-1}$ and $b_0,b_1,\ldots,b_{n-1}$ of the set $\lbrace0,1,\ldots,n-1\rbrace$, satisfying the condition
$$ia_i\equiv b_i\pmod{n}$$for all $0\le i\le n-1$.

Proposed by Fysty
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
AshAuktober
983 posts
#2 • 3 Y
Y by Want-to-study-in-NTU-MATH, megarnie, truongphatt2668
This should work... (writeup converted to LaTeX by ChatGPT, I hope there's no errors)
We replace \( a_i \) and \( b_i \) with \( \sigma(i) \) and \( \tau(i) \) respectively. Then the condition is
\[
i\sigma(i) \equiv \tau(i) \pmod{n}, \quad i = 0,1,\dots,n-1.
\]
\textbf{Claim 1:} \( \gcd(\sigma(i),n) = \gcd(\tau(i),n) = \gcd(i,n) \).

\textbf{Proof:} Strong induction on \( \gcd(\tau(i),n) \), letting it vary over divisors of \( n \).

For example, the base case is when \( \gcd(\tau(i),n) = 1 \). Then it is true that \( \gcd(i\sigma(i),n) = 1 \), implying
\[
\gcd(i,n) = \gcd(\sigma(i),n) = 1,
\]as desired.

In particular, this provides a bijection between \( i, \sigma(i) \), and \( \tau(i) \) coprime to \( n \).

Now, if \( \gcd(\tau(i),n) = d \), then \( \gcd(i,n) \) and \( \gcd(\sigma(i),n) \) divide \( d \).

But from the induction hypothesis that for all \( c < d \) with \( c \mid d \),
\[
\gcd(i,n) = c \iff \gcd(\sigma(i),n) = c \iff \gcd(\tau(i),n) = c,
\]we must have
\[
\gcd(i,n) = \gcd(\sigma(i),n) = d.
\]Again, we get this to be an equivalence, i.e.,
\[
\gcd(i,n) = d \iff \gcd(\sigma(i),n) = d \iff \gcd(\tau(i),n) = d.
\]\(\square\)

\textbf{Claim 2:} \( n \) is square-free.

\textbf{Proof:} Assume \( p^2 \mid n \) for some prime \( p \). Choosing \( i = p \), we get
\[
\gcd(\tau(i),n) = \gcd(\sigma(i),n) = p.
\]So \( p^2 \mid i\sigma(i) \) but \( p^2 \nmid \tau(i) \), a contradiction to them being equivalent modulo \( p^2 \). \(\square\)



\textbf{Claim 3:} \( p \mid n \Rightarrow p = 2 \).

\textbf{Proof:} For any \(p \mid n\), let
\[
A_p \overset{\text{def}}{=} \{ i \in \{1, 2, \dots, n-1\} : \gcd(i,n) = n/p \}.
\]
\[ = \left\{ \frac{n}{p}, \frac{2n}{p}, \dots, \frac{(p-1)n}{p} \right\}.
\]Note that \( i \in A_p \iff \sigma(i) \in A_p \iff \tau(i) \in A_p \).

Now, we have
\[
\prod_{i \in A_p} i\sigma(i) \equiv \prod_{i \in A_p} \tau(i) \pmod{n}.
\]Since \( \sigma \) and \( \tau \) are bijections over \( A_p \), we get
\[
\prod_{i \in A_p} i\sigma(i) \equiv \left( \prod_{i \in A_p} i \right)^2 \equiv \left(\left( \frac{n}{p} \right)^{p-1} (p-1)!\right)^2 \pmod{n}.
\]Similarly,
\[
\prod_{i \in A_p} \tau(i) \equiv \prod_{i \in A_p} i \equiv \left( \frac{n}{p} \right)^{p-1} (p-1)! \pmod{n}.
\]Thus,
\[
\left(\left( \frac{n}{p} \right)^{p-1} (p-1)!\right)^2 \equiv \left( \frac{n}{p} \right)^{p-1} (p-1)! \pmod{n}.
\]In particular, this equivalence also holds modulo $p$.
Simplifying using Fermat's and Wilson's theorems (noting that \(n\) is squarefree),
\[
(1 \cdot (-1))^2 \equiv 1 \cdot -1 \implies 1 \equiv -1 \implies 2 \equiv 0
,\]where congruences are modulo $p$. Thus $p \mid 2 \implies p = 2$.

From Claims 2 and 3, we have \( n \in \{1,2\} \).

For \( n = 1 \), consider \( \sigma(0) = 0, \tau(0) = 0 \).

For \( n = 2 \), consider \( \sigma(0) = 0, \tau(0) = 0 \), \( \sigma(1) = \tau(1) = 1 \).

Thus, \( n = 1, 2 \) are the only solutions. \(\blacksquare\)
This post has been edited 3 times. Last edited by AshAuktober, Mar 5, 2025, 8:10 AM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
megarnie
5560 posts
#3 • 3 Y
Y by AshAuktober, imagien_bad, shafikbara48593762
The answer is $n = 1$ and $n = 2$. To show these work, set $a_i = i$ for each $0 \le i \le n - 1$. Now assume $n > 2$. We will show that $n$ doesn't work.

Claim: $\gcd(a_i, n) = \gcd(b_i, n)$ for each $0 \le i \le n -1$.
Proof: For $i \in [0,n-1]$, let $f(i) = \gcd(b_i, n) - \gcd(a_i,n)$. Since $b_i \equiv i a_i \pmod n$, $\gcd(b_i, n) = \gcd(i a_i, n) \ge \gcd(a_i, n)$, implying $f(i) \ge 0$. However, since $(a_i)_{i=0}^{n-1}, (b_i)_{i=0}^{n-1}$ are permutations of the same set, summing the equality $f(i) = \gcd(b_i, n) - \gcd(a_i, n)$ over $0 \le i \le n - 1$ gives $\sum_{i=0}^{n-1} f(i) = 0$. Since $f$ is always nonnegative, $f$ must be identically zero, as desired. $\square$

Claim: $\gcd(i, n) = \gcd(b_i, n)$ for each $0 \le i \le n -1$.
Proof: For $i \in [0,n-1]$, let $g(i) = \gcd(b_i, n) - \gcd(i,n)$. Since $b_i \equiv i a_i \pmod n$, $\gcd(b_i, n) = \gcd(i , n) \ge \gcd(i, n)$, implying $g(i) \ge 0$. However, since $(i)_{i=0}^{n-1}, (b_i)_{i=0}^{n-1}$ are permutations of the same set, summing the equality $g(i) = \gcd(b_i, n) - \gcd(i, n)$ over $0 \le i \le n - 1$ gives $\sum_{i=0}^{n-1} g(i) = 0$. Since $g$ is always nonnegative, $g$ must be identically zero, as desired. $\square$

Thus, we can conclude $\gcd(i,n) = \gcd(a_i, n) = \gcd(b_i, n)$ for each $i$.

Claim: $n$ is squarefree.
Proof: If $p^2 \mid n$, then if we set $i = p$, note that $\gcd(i, n) = \gcd(a_i, n) = \gcd(b_i, n) = p$, but then $\gcd(i a_i, n)$ is a multiple of $p^2$, so $p^2$ must divide $b$, a contradiction. $\square$

Claim: $n$ is a power of $2$.
Proof: Assume not. Let $p$ be an odd prime dividing $n$ and $S$ be the set of all integer $0 \le x \le n - 1$ so that $\gcd(x,n) = \frac np$. We note that $S = \left \{ \frac np, 2 \cdot  \frac np, \ldots, (p-1) \cdot \frac np \right \}$.

For each $i \in S$, let $c_i = \frac{a_i p}{n}$ and $d_i = \frac{b_i p}{n}$. Note that $i c_i \equiv d_i \pmod p$ and $(c_i)_{i \in S}$ and $(d_i)_{i \in S}$ are permutations of $ 1, 2, \ldots, p - 1$.

Multiplying the congruences together over all $i \in S$ gives that\[\prod_{i \in S} i \prod_{i \in S} c_i \equiv \prod_{i\in S} d_i \pmod p\]Since $(c_i)_{i\in S}$ and $(d_i)_{i\in S}$ are permutations of $1, 2, \ldots, p - 1$, we have $\prod_{i\in S} c_i \equiv \prod_{i \in S} d_i \equiv  (p-1)! \equiv -1 \pmod p$ by Wilson's Theorem.

We can also compute $\prod_{i\in S} i =  \left( \frac np  \right)^{|S|} \cdot 1 \cdot 2 \cdot \cdots (p-1) = \left( \frac np \right)^{p - 1} \cdot (p-1)!$. Since $n$ is squarefree, $p \nmid \frac np$, so this evaluates to $1 \cdot (p-1)! \equiv -1 \pmod p$ by FLT and Wilson's Theorem.

Hence $(-1) \cdot (-1) \equiv -1 \pmod p$, which implies $p \mid 2$, a contradiction because $p$ is odd. $\square$

Combining the two claims gives that $n \in \{1,2\}$, as desired.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
popop614
270 posts
#4 • 1 Y
Y by megarnie
The answer is $n=1$ and $n=2$; taking $a_i = i$ suffices.

Claim. $d \mid a_i \iff d \mid b_i \iff d \mid i$ for all $d \mid n$.

Proof. Let $d$ be a divisor of $n$. Notice that there are exactly $n/d$ $b_i$ which are divisible by $d$, and these are given by $b_{d i}$ for $0 \le i < n/d$. This establishes $d \mid b_i \iff d \mid i$. In particular, $d \mid a_i$ implies $d \mid ia_i = b_i$ implies $d \mid i$, hence the $n/d$ values of $a_i$ that are divisible by $d$ are also given by $a_{di}$. We are done.

Corollary. $a_{di}$ is a permutation of $d[n/d] - d$.

Now let $n$ have an odd prime divisor $p$. Let $m = n/p$, and note that the sequences $c_i = a_{mi}/m$ and $d_i = b_{mi}/m$ are well defined and permutations of $[n]-1$. In particular,
\begin{align*}
mi a_{mi} &\equiv b_{mi} \pmod{n} \\
mi c_i &\equiv d_i \pmod{p}.
\end{align*}Taking a product over $1 \le i \le p-1$ gives
\[ m^{p-1} (p-1)!^2 \equiv (p-1)! \pmod p \implies m^{p-1} \equiv -1 \pmod{p}. \]Clearly this is impossible.

Now let $4 \mid n$, and replace $p$ with $4$ above. Then, note that $\{c_0, c_2\} = \{d_0, d_2 \} = \{0, 2\}$, hence $\{c_1,c_3 \} = \{d_1, d_3 \} = \{1, 3\}$, so \[  m^2 \cdot 3 \cdot 3 \equiv 3 \pmod{4}, \qquad m^2 \equiv 3 \pmod{4},\]absurd. This proves that all $n > 3$ fail.

Notational Abuse
This post has been edited 3 times. Last edited by popop614, Mar 7, 2025, 1:05 AM
Reason: adfsafsd
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
hectorleo123
341 posts
#5
Y by
This is here
This post has been edited 1 time. Last edited by hectorleo123, Mar 29, 2025, 8:02 PM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
AllenZhuang
1 post
#6
Y by
megarnie wrote:
Claim: $n$ is a power of $2$.
Proof: Assume not. Let $p$ be an odd prime dividing $n$ and $S$ be the set of all integer $0 \le x \le n - 1$ so that $\gcd(x,n) = \frac np$. We note that $S = \left \{ \frac np, 2 \cdot  \frac np, \ldots, (p-1) \cdot \frac np \right \}$.

For each $i \in S$, let $c_i = \frac{a_i p}{n}$ and $d_i = \frac{b_i p}{n}$. Note that $i c_i \equiv d_i \pmod p$ and $(c_i)_{i \in S}$ and $(d_i)_{i \in S}$ are permutations of $ 1, 2, \ldots, p - 1$.
.

Why $(c_i)_{i \in S}$ and $(d_i)_{i \in S}$ are permutations of $ 1, 2, \ldots, p - 1$?
This post has been edited 1 time. Last edited by AllenZhuang, Mar 30, 2025, 7:24 AM
Reason: Grammar issue
Z K Y
N Quick Reply
G
H
=
a