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
k i Adding contests to the Contest Collections
dcouchman   1
N Apr 5, 2023 by v_Enhance
Want to help AoPS remain a valuable Olympiad resource? Help us add contests to AoPS's Contest Collections.

Find instructions and a list of contests to add here: https://artofproblemsolving.com/community/c40244h1064480_contests_to_add
1 reply
dcouchman
Sep 9, 2019
v_Enhance
Apr 5, 2023
k i Zero tolerance
ZetaX   49
N May 4, 2019 by NoDealsHere
Source: Use your common sense! (enough is enough)
Some users don't want to learn, some other simply ignore advises.
But please follow the following guideline:


To make it short: ALWAYS USE YOUR COMMON SENSE IF POSTING!
If you don't have common sense, don't post.


More specifically:

For new threads:


a) Good, meaningful title:
The title has to say what the problem is about in best way possible.
If that title occured already, it's definitely bad. And contest names aren't good either.
That's in fact a requirement for being able to search old problems.

Examples:
Bad titles:
- "Hard"/"Medium"/"Easy" (if you find it so cool how hard/easy it is, tell it in the post and use a title that tells us the problem)
- "Number Theory" (hey guy, guess why this forum's named that way¿ and is it the only such problem on earth¿)
- "Fibonacci" (there are millions of Fibonacci problems out there, all posted and named the same...)
- "Chinese TST 2003" (does this say anything about the problem¿)
Good titles:
- "On divisors of a³+2b³+4c³-6abc"
- "Number of solutions to x²+y²=6z²"
- "Fibonacci numbers are never squares"


b) Use search function:
Before posting a "new" problem spend at least two, better five, minutes to look if this problem was posted before. If it was, don't repost it. If you have anything important to say on topic, post it in one of the older threads.
If the thread is locked cause of this, use search function.

Update (by Amir Hossein). The best way to search for two keywords in AoPS is to input
[code]+"first keyword" +"second keyword"[/code]
so that any post containing both strings "first word" and "second form".


c) Good problem statement:
Some recent really bad post was:
[quote]$lim_{n\to 1}^{+\infty}\frac{1}{n}-lnn$[/quote]
It contains no question and no answer.
If you do this, too, you are on the best way to get your thread deleted. Write everything clearly, define where your variables come from (and define the "natural" numbers if used). Additionally read your post at least twice before submitting. After you sent it, read it again and use the Edit-Button if necessary to correct errors.


For answers to already existing threads:


d) Of any interest and with content:
Don't post things that are more trivial than completely obvious. For example, if the question is to solve $x^{3}+y^{3}=z^{3}$, do not answer with "$x=y=z=0$ is a solution" only. Either you post any kind of proof or at least something unexpected (like "$x=1337, y=481, z=42$ is the smallest solution). Someone that does not see that $x=y=z=0$ is a solution of the above without your post is completely wrong here, this is an IMO-level forum.
Similar, posting "I have solved this problem" but not posting anything else is not welcome; it even looks that you just want to show off what a genius you are.

e) Well written and checked answers:
Like c) for new threads, check your solutions at least twice for mistakes. And after sending, read it again and use the Edit-Button if necessary to correct errors.



To repeat it: ALWAYS USE YOUR COMMON SENSE IF POSTING!


Everything definitely out of range of common sense will be locked or deleted (exept for new users having less than about 42 posts, they are newbies and need/get some time to learn).

The above rules will be applied from next monday (5. march of 2007).
Feel free to discuss on this here.
49 replies
ZetaX
Feb 27, 2007
NoDealsHere
May 4, 2019
Two Functional Inequalities
Mathdreams   6
N 11 minutes ago by Assassino9931
Source: 2025 Nepal Mock TST Day 2 Problem 2
Determine all functions $f : \mathbb{R} \rightarrow \mathbb{R}$ such that $$f(x) \le x^3$$and $$f(x + y) \le f(x) + f(y) + 3xy(x + y)$$for any real numbers $x$ and $y$.

(Miroslav Marinov, Bulgaria)
6 replies
Mathdreams
Today at 1:34 PM
Assassino9931
11 minutes ago
Pythagorean new journey
XAN4   2
N 17 minutes ago by mathprodigy2011
Source: Inspired by sarjinius
The number $4$ is written on the blackboard. Every time, Carmela can erase the number $n$ on the black board and replace it with a new number $m$, if and only if $|n^2-m^2|$ is a perfect square. Prove or disprove that all positive integers $n\geq4$ can be written exactly once on the blackboard.
2 replies
XAN4
Today at 3:41 AM
mathprodigy2011
17 minutes ago
sqrt(2) and sqrt(3) differ in at least 1000 digits
Stuttgarden   2
N 18 minutes ago by straight
Source: Spain MO 2025 P3
We write the decimal expressions of $\sqrt{2}$ and $\sqrt{3}$ as \[\sqrt{2}=1.a_1a_2a_3\dots\quad\quad\sqrt{3}=1.b_1b_2b_3\dots\]where each $a_i$ or $b_i$ is a digit between 0 and 9. Prove that there exist at least 1000 values of $i$ between $1$ and $10^{1000}$ such that $a_i\neq b_i$.
2 replies
Stuttgarden
Mar 31, 2025
straight
18 minutes ago
combinatorics and number theory beautiful problem
Medjl   2
N 18 minutes ago by mathprodigy2011
Source: Netherlands TST for BxMo 2017 problem 4
A quadruple $(a; b; c; d)$ of positive integers with $a \leq b \leq c \leq d$ is called good if we can colour each integer red, blue, green or purple, in such a way that
$i$ of each $a$ consecutive integers at least one is coloured red;
$ii$ of each $b$ consecutive integers at least one is coloured blue;
$iii$ of each $c$ consecutive integers at least one is coloured green;
$iiii$ of each $d$ consecutive integers at least one is coloured purple.
Determine all good quadruples with $a = 2.$
2 replies
Medjl
Feb 1, 2018
mathprodigy2011
18 minutes ago
Squence problem
AlephG_64   1
N 43 minutes ago by RagvaloD
Source: 2025 Finals Portuguese Math Olympiad P1
Francisco wrote a sequence of numbers starting with $25$. From the fourth term of the sequence onwards, each term of the sequence is the average of the previous three. Given that the first six terms of the sequence are natural numbers and that the sixth number written was $8$, what is the fifth term of the sequence?
1 reply
AlephG_64
Yesterday at 1:19 PM
RagvaloD
43 minutes ago
50 points in plane
pohoatza   12
N an hour ago by de-Kirschbaum
Source: JBMO 2007, Bulgaria, problem 3
Given are $50$ points in the plane, no three of them belonging to a same line. Each of these points is colored using one of four given colors. Prove that there is a color and at least $130$ scalene triangles with vertices of that color.
12 replies
pohoatza
Jun 28, 2007
de-Kirschbaum
an hour ago
beautiful functional equation problem
Medjl   6
N an hour ago by Sadigly
Source: Netherlands TST for BxMO 2017 problem 2
Let define a function $f: \mathbb{N} \rightarrow \mathbb{Z}$ such that :
$i)$$f(p)=1$ for all prime numbers $p$.
$ii)$$f(xy)=xf(y)+yf(x)$ for all positive integers $x,y$
find the smallest $n \geq 2016$ such that $f(n)=n$
6 replies
Medjl
Feb 1, 2018
Sadigly
an hour ago
Line Combining Fermat Point, Orthocenter, and Centroid
cooljoseph   0
an hour ago
On triangle $ABC$, draw exterior equilateral triangles on sides $AB$ and $AC$ to obtain $ABC'$ and $ACB'$, respectively. Let $X$ be the intersection of the altitude through $B$ and the median through $C$. Let $Y$ be the intersection of the altitude through $A$ and line $CC'$. Let $Z$ be the intersection of the median through $A$ and the line $BB'$. Prove that $X$, $Y$, and $Z$ lie on a common line.

IMAGE
0 replies
cooljoseph
an hour ago
0 replies
complete integral values
Medjl   2
N an hour ago by Sadigly
Source: Netherlands TST for BxMO 2017 problem 1
Let $n$ be an even positive integer. A sequence of $n$ real numbers is called complete if for every integer $m$ with $1 \leq  m \leq  n$ either the sum of the first $m$ terms of the sum or the sum of the last $m$ terms is integral. Determine
the minimum number of integers in a complete sequence of $n$ numbers.
2 replies
Medjl
Feb 1, 2018
Sadigly
an hour ago
Geometry
youochange   4
N an hour ago by RANDOM__USER
m:}
Let $\triangle ABC$ be a triangle inscribed in a circle, where the tangents to the circle at points $B$ and $C$ intersect at the point $P$. Let $M$ be a point on the arc $AC$ (not containing $B$) such that $M \neq A$ and $M \neq C$. Let the lines $BC$ and $AM$ intersect at point $K$. Let $P'$ be the reflection of $P$ with respect to the line $AM$. The lines $AP'$ and $PM$ intersect at point $Q$, and $PM$ intersects the circumcircle of $\triangle ABC$ again at point $N$.

Prove that the point $Q$ lies on the circumcircle of $\triangle ANK$.
4 replies
youochange
Today at 11:27 AM
RANDOM__USER
an hour ago
interesting ineq
nikiiiita   5
N 2 hours ago by nikiiiita
Source: Own
Given $a,b,c$ are positive real numbers satisfied $a^3+b^3+c^3=3$. Prove that:
$$\sqrt{2ab+5c^{2}+2a}+\sqrt{2bc+5a^{2}+2b}+\sqrt{2ac+5b^{2}+2c}\le3\sqrt{3\left(a+b+c\right)}$$
5 replies
nikiiiita
Jan 29, 2025
nikiiiita
2 hours ago
Path within S which does not meet itself
orl   5
N 2 hours ago by atdaotlohbh
Source: IMO 1982, Day 2, Problem 6
Let $S$ be a square with sides length $100$. Let $L$ be a path within $S$ which does not meet itself and which is composed of line segments $A_0A_1,A_1A_2,A_2A_3,\ldots,A_{n-1}A_n$ with $A_0=A_n$. Suppose that for every point $P$ on the boundary of $S$ there is a point of $L$ at a distance from $P$ no greater than $\frac {1} {2}$. Prove that there are two points $X$ and $Y$ of $L$ such that the distance between $X$ and $Y$ is not greater than $1$ and the length of the part of $L$ which lies between $X$ and $Y$ is not smaller than $198$.
5 replies
orl
Nov 11, 2005
atdaotlohbh
2 hours ago
Romanian National Olympiad 1997 - Grade 9 - Problem 4
Filipjack   0
2 hours ago
Source: Romanian National Olympiad 1997 - Grade 9 - Problem 4
Consider the numbers $a,b, \alpha, \beta \in \mathbb{R}$ and the sets $$A=\left \{x \in \mathbb{R} : x^2+a|x|+b=0 \right \},$$$$B=\left \{ x \in \mathbb{R} : \lfloor x \rfloor^2 + \alpha \lfloor x \rfloor + \beta = 0\right \}.$$If $A \cap B$ has exactly three elements, prove that $a$ cannot be an integer.
0 replies
Filipjack
2 hours ago
0 replies
s(n) and s(n+1) divisible by m
Miquel-point   1
N 2 hours ago by RagvaloD
Source: Romanian IMO TST 1981, Day 2 P2
Let $m$ be a positive integer not divisible by 3. Prove that there are infinitely many positive integers $n$ such that $s(n)$ and $s(n+1)$ are divisible by $m$, where $s(x)$ is the sum of digits of $x$.

Dorel Miheț
1 reply
Miquel-point
4 hours ago
RagvaloD
2 hours ago
Japanese Triangles
pikapika007   67
N Apr 2, 2025 by quantam13
Source: IMO 2023/5
Let $n$ be a positive integer. A Japanese triangle consists of $1 + 2 + \dots + n$ circles arranged in an equilateral triangular shape such that for each $i = 1$, $2$, $\dots$, $n$, the $i^{th}$ row contains exactly $i$ circles, exactly one of which is coloured red. A ninja path in a Japanese triangle is a sequence of $n$ circles obtained by starting in the top row, then repeatedly going from a circle to one of the two circles immediately below it and finishing in the bottom row. Here is an example of a Japanese triangle with $n = 6$, along with a ninja path in that triangle containing two red circles.
IMAGE
In terms of $n$, find the greatest $k$ such that in each Japanese triangle there is a ninja path containing at least $k$ red circles.
67 replies
pikapika007
Jul 9, 2023
quantam13
Apr 2, 2025
Japanese Triangles
G H J
G H BBookmark kLocked kLocked NReply
Source: IMO 2023/5
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
ZNatox
67 posts
#61
Y by
And yet another solution to this beautiful problem!

Number the rows $0,1, \cdots , n-1$.

Denote by $c_i$ the position of the red circle in the $i$th row. ($0\le c_i \le i$)

Notice that we can get from a red circle $c_i$ to another one $c_j$ with $j>i$, if and only if $c_i-c_j\ge i-j$, that is if $i-c_i\ge j-c_j$. Let $y_i=i-c_i, 0\le y_i\le i$, we want to find $i_1<i_2<\cdots <i_k$ with $y_{i_1}\le \cdots \le y_{i_k}$.

The problem becomes:

> Let $(y_i)$ with $0\le i\le n-1$ be a sequence of integers such that $0\le y_i\le i$ (we'll call such a sequence a beautiful sequence of rank $n$). Find the maximal $k$ such that there must exists a nondecreasing subsequence of $y_i$ of size at least $k$.

We omit the upper bound since it is similar to the other posts. As for the lower bound, we only need to prove it for powers of $2$, that is if we are given a beautiful sequence of rank $2^i$ then it must contain a nondecreasing subsequence of size $i+1$. We can argue this by induction. The case $n=1$ is trivial.

Suppose we know the result for all smaller $<n$, and suppose for the sake of contradiction that there is a counterexample for $n$
The main claim is that for every $0\le i\le n-1$ every number $a \in [2^i, 2^{i+1}-1]$ must appear in the sequence for at most $n-i-1$ times. Otherwise, we can form an non-decreasing subsequence of length $n+1$
by taking a non-decreasing subsequence of length $i+1$ in $[0,2^i-1]$ followed by all occurrence of $a$

Summing the number of appearance over all such $a$, we conclude that the number of non-zero terms in the sequence is at most $\sum_{i = 0}^{n - 1} (n - i - 1) \cdot 2^i = \sum_{j = 0}^{n - 2} \sum_{i = 0}^j 2^i = \sum_{j = 0}^{n - 2} (2^{j + 1} - 1) = 2^n - n - 1.$

However, this means that $0$ must appear at least $n+1$ times, so all occurrence of $0$ forms a non-decreasing subsequence, contradiction.

Source: https://math.stackexchange.com/questions/4752434/maximal-non-decreasing-subsequence
This post has been edited 2 times. Last edited by ZNatox, Aug 17, 2023, 12:53 PM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
math90
1475 posts
#62 • 1 Y
Y by CT17
It is a stronger version of this problem.
This post has been edited 4 times. Last edited by math90, Sep 12, 2023, 5:29 PM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Joider
136 posts
#63
Y by
\begin{align*}
\MoveEqLeft \sum_{j=1}^{i+1} 2^{a_{i+1,j}} -\sum_{j=1}^{i} 2^{\max\{a_{i+1,j}, a_{i+1,j+1}\}} \\
&= \begin{multlined}[t] \left(i+1+\sum_{b=1}^\infty 2^{b-1} \lvert \{ j : a_{i+1,j} \geq b\}\rvert\right) \\ - \left(i+\sum_{b=1}^\infty 2^{b-1} \lvert \{ j : \max\{a_{i+1,j}, a_{i+1,j+1}\} \geq b\}\rvert\right)\end{multlined} \\
& = 1 + \sum_{b=1}^\infty 2^{b-1} (1+\lvert \{ j :\max\{a_{i+1,j}, a_{i+1,j+1}\} < b\}\rvert- \lvert \{ j : a_{i+1,j} < b\}\rvert) \\
&\leq 1 + \sum_{b = 1}^{\min_j \{a_{i+1,j}\}} 2^{b-1} \\
&= 2^{\min_j \{a_{i+1,j}\}}.
\end{align*}
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Fibonacci_11235
43 posts
#66
Y by
Who is the proposer?
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
CBMaster
85 posts
#67
Y by
Cool problem! Posting for storage...

The answer is $k = \lfloor \log_2 n \rfloor + 1$. Examples showing this bound is tight is suggested in solutions like #8 already, so I'll only prove that there is ninja path pass through at least $k = \lfloor \log_2 n \rfloor + 1$ circles.

It's sufficient to show that for $2^k\leq n< 2^{k+1}$, there is ninja path containing at least $k+1$ red circles. Let's prove it by induction. Level the rows $1$ to $n$ from top to bottom.

Pick one red circle $C$, and define it's good ninja path as ninja path starting at top red circle and ends at $C$. Let length of $C$ as maximum number of red circles in ninja path among all good ninja paths of it.

Claim. Number of length $t$ red circle is at most $2^{t-1}$ for all $1\leq t\leq k$.

Proof. For $t=1$ it's obvious because only top red circle has length $1$. For $t\geq 2$, by induction there is red circle $C_0$ such that it's row number is at most $2^{t-1}$ and length is at least $t$(think row $1, ..., 2^{t-1}$). Let it's row number $s$, and in row $s$, there is $x$, $y$ circles in left/right side of $C_0$.

Think about subtriangle such that top circle is $C_0$. And define $P_0$ the good ninja path of $C_0$ containing at least $t$ red circles. For each red circles in subtriangle different from $C_0$, think about ninja path from $C_0$ and ends at it. Combining this with $P_0$, we get good ninja path containing at least $t+1$ red circles. This means there is no red circles of length $t$ in subtriangle, other than $C_0$.

Furthermore, think about $x$ leftmost rows parallel to left side of original triangle(we call it left rows), and $y$ rightmost rows parallel to right side of original triangle(we call it right rows).
Since length $t$ red circle different from $C_0$ is in left row or right row, number of length $t$ red circle is at most $|($length t red circles in left rows$)|+|($length t red circles in right rows$)|+1$(as $C_0$ can be length $t$).

But no two length $t$ red circles is in same left or right row, since it does, lower circle has length at least $t+1$(think good ninja path connects top red circle, upper circle, lower circle). So each left/right rows has at most $1$ length $t$ red circle. So number of length $t$ red circle is at most $x+y+1=(s-1)+1=s\leq 2^{t-1}$. So claim is proved.

By claim, number of length $\leq k$ red circle is at most $2^0+2^1+...+2^{k-1}=2^k-1$. It is less than $n$ and since there is $n$ red circles, there must be red circle $C_1$ with length at least $k+1$. Pick good ninja path ends at $C_1$ and has at least $k+1$ red circles, we're done!!
This post has been edited 12 times. Last edited by CBMaster, Apr 29, 2024, 5:52 AM
Reason: .
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Phorphyrion
395 posts
#68
Y by
Fibonacci_11235 wrote:
Who is the proposer?

Merlijn Staps.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
math90
1475 posts
#69
Y by
Answer: $\lceil\log_2(n+1)\rceil$.

Construction is same as others have done above. Now we prove the lower bound. Motivation is ISL 2019/C9 which uses the same function.

For $1 \leq j \leq i \leq n$, let $a_{i,j}$ be the maximum number of red circles in any path starting from the top of the triangle and ends at the $j$th circle in the $i$th row.

Claim. For every positive integer $n$, we have $\sum_{i=1}^n 2^{-a_{n,i}}<1$.
Proof. By induction on $n$. The base case $n=1$ is true since $a_{1,1}=1$ so $2^{-a_{1,1}}=\frac{1}{2}<1$. For the induction step, assume the statement is true for $n$ and we will prove it for $n+1$. Observe that we have
$$a_{n+1,i}=\max\{a_{n,i},a_{n,i-1}\}+r_{n+1,i},$$where $a_{n,0}=a_{n,n+1}=0$ and $r_{n+1,i}=1$ if the $i$-th ball in the $n+1$-th row is colored red, and $r_{n+1,i}=0$ otherwise.
Let $p\in[1,n]$ such that $a_{n,p}=\max_{1\le i\le n}a_{n,i}$. Hence $\sum_{i=1}^n 2^{-a_{n,i}}\le 1-2^{-a_{n,p}}$. Since one of $r_{n+1,i}$ is strictly positive, we have:
\begin{align*}
\sum_{i=1}^{n+1}2^{-a_{n+1,i}}&\le\sum_{i=1}^p 2^{-a_{n,i}-r_{n+1,i}}+\sum_{i=p+1}^{n+1}2^{-a_{n,i-1}-r_{n+1,i}}\\
&<\sum_{i=1}^p 2^{-a_{n,i}}+\sum_{i=p+1}^{n+1}2^{-a_{n,i-1}}\\
&=\sum_{i=1}^n 2^{-a_{n,i}}+2^{-a_{n,p}}\\
&\le 1.
\end{align*}
This proves the induction step. $\square$

Now to prove the bound, let $n$ be a positive integer and let $M=\max_{1\le i\le n} a_{n,i}$. Then
$$1>\sum_{i=1}^n 2^{-a_{n,i}}\ge\sum_{i=1}^n 2^{-M}= n 2^{-M}.$$Hence $2^M>n$ so $2^M\ge n+1$ and $M\ge\lceil\log_2(n+1)\rceil$.
This post has been edited 8 times. Last edited by math90, May 10, 2024, 7:03 AM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Cali.Math
128 posts
#70
Y by
We uploaded our solution https://calimath.org/pdf/IMO2023-5.pdf on youtube https://youtu.be/tL6-102WzmM.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
sami1618
884 posts
#71
Y by
Cali.Math wrote:

Great video! If you are planning on making a video going over probabilistic methods could you cover some of the topics involving variance as used in CTST 2023?
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
YaoAOPS
1501 posts
#72 • 1 Y
Y by GeoKing
old sol uploaded now.


We claim that $k = \left\lfloor \log_2(n) \right\rfloor$.

Claim: This can be constructed.
Proof. Disect the rows of the triangle into collections of rows $[2^k, 2^{k+1} - 1]$.
Then for each collection, space the red circles such that the adjacent rows have elements spaced two apart.
Then any ninja path only contains at most one element from each collection. $\blacksquare$

Claim: If $n = 2^a$, then some ninja path has $k$ elements.
Proof. Add an $n+1$st row of just white circles.
We write a number in each circle as follows, first writing a zero in each circle of the newly added row.
Then for all other circles, write the maximum of the two circles below it, adding $1$ if this circle is also red. It remains to show that the top circle's number is at least $\left\lfloor \log_2(n) \right\rfloor$.
Define $R_k$ as the multiset of $k$ numbers in the $k$th row. Order multisets $a_k \ge a_{k-1} \ge \dots \ge a_2 \ge a_1$ based off the ordinal $a_k \omega^k + a_{k-1} \omega^{k-1} + \dots + a_1 \omega$.
We can model this by taking the following process: Start out with $C_{n+1}$ with $n+1$ zeros. Then to get $C_k$ from $C_{k+1}$, add $1$ to some element of $C_{k+1}$ then discard the smallest element of $C_k$.
We can check that $R_k \ge C_k$ inductively for some process generating some $C_k$.
It thus remains to show that $C_1$ contains an element at least $a$ than $C_n$ or $C_{2^a}$. We prove this inductively.
Note that if we consider a processes starting at $C_k$ have the same number of elements, and some other $C_k' < C_k$ with the same sum, then there exists a process starting from $C_k$ that can be mimiced from $C_k'$ such that $C_i \ge C_i'$ for all $i = k-1, k-2, \dots, 1$.
It then follows that we can WLOG assume that the process means that for $2^{a-1} \le i \le 2^a = n$, that $C_i$ consists of $2^a - i$ ones and $2i - 2^a$ zeros.
Notably, it follows that $C_{2^{a-1}}$ is just $2^{a-1}$ ones. Inductively, the maximum element of $C_1$ is at least $a-1$ more than the maximum element of $C_{2^{a-1}}$, which finishes. $\blacksquare$
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
alba_tross1867
44 posts
#74
Y by
My solution is similar to many above so I won't post it but my motivation looks way too different, since I focused on $f(c)$ where $c$ is a circle in a japanese triangle to be a function that computes the maximal number of red circles that can be on a ninja path passing through $c$ in a scenario where the the given japanese triangle is meant to minimise $max(f)$ over the $i$-th row. You observe that the value of $f$ kind of "propagates" and increases by $1$ unescapably at rows $i=2^{t}$. From which follows a construction for an upper bound.
This post has been edited 1 time. Last edited by alba_tross1867, Aug 8, 2024, 7:41 PM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
bobthesmartypants
4337 posts
#75
Y by
Good problem.

Define a red circle to cover a target circle if a ninja path exists from the red circle to the target circle. Define a level to be a set of red circles that cover all red circles excluding themselves and any red circles that cover one of them. Note that a ninja path can pass through at most one red circle in a level, as no red circle in a level covers another red circle.

Lemma: if a level contains a red circle on row $i$, then it contains at most $i$ red circles.

Proof: In order to not cover each other, each red circle in the level must inhabit a unique diagonal not covered by the red circle on row $i$. There are only $i-1$ diagonals left, so there can only be $i-1$ additional red circles in the level.

Claim: for a Japanese triangle of size $n$, we can partition the red circles into at least $\lfloor \log_2n\rfloor +1$ disjoint levels.

Proof: First, we show a partition exists. We iteratively construct each level by taking the highest uncategorized red circle, and adding uncategorized red circles not covered by this level to the level as we move down the rows until there are none left to add.

[asy]
size(7cm);
  pair X = dir(240); pair Y = dir(0);
  path c = scale(0.5)*unitcircle;
  int[] t = {0,1,1,3,0,3,0};
  pen[] color = {lightred, lightgreen, lightblue, lightblue, lightgreen, orange, lightblue};
  for (int i=0; i<=6; ++i) {
    for (int j=0; j<=i; ++j) {
      filldraw(shift(i*X+j*Y)*c, (t[i]==j) ? color[i] : white);
      draw(shift(i*X+j*Y)*c);
    }
  }
  draw((0,0)--(X+Y)--(2*X+Y)--(3*X+2*Y)--(4*X+2*Y)--(5*X+3*Y)--(6*X+3*Y),linewidth(1.5));
  label("Level 0", (5, 0), p=red);
  label("Level 1", (5, 0) + X+Y*0.5, p=green);
  label("Level 2", (5, 0) + 2*X+Y, p=blue);
  label("Level 3", (5, 0) + 5*X+Y*2.5, p=orange);
[/asy]

Next we show that we can create at least $\lfloor \log_2n\rfloor +1$ disjoint levels. Label the levels as $0, 1, 2, \ldots$ ordered by their highest row. I claim level $k$ must start at row $2^k$ or higher. This can be seen inductively, as level $0$ starts unambiguously at row $2^0=1$, and if we assume level $k-1$ starts on row $r \le 2^{k-1}$, then by our lemma it can at best contain the next $r\le 2^{k-1}$ rows, leaving row $2r\le 2^k$ for level $k$ to claim. What this means for us is that when $n=2^k$, we must create a new level $k$ netting $k+1$ levels total. This solves to $\lfloor \log_2n\rfloor +1$ levels total.

To finish off the proof, note that each level $i$, by definition, covers level $i+1$. Thus, for any red circle in level $i+1$, there exists a red circle in level $i$ that covers it; a.k.a there exists a ninja path starting at level $0$ that passes through one red circle from each level, for a total of $\lfloor \log_2n\rfloor +1$ red circles.

Equality can be constructed by any setup where level $k$ contains red circles from rows $2^k, \ldots, 2^{k+1}-1$. Many examples have been given above.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
HamstPan38825
8857 posts
#76
Y by
The answer is $k = \lfloor \log_2 n \rfloor + 1$ red circles.

The main idea is the following. For each circle in position $j$ of row $i$ (from now on we denote by $(i, j)$), define $g(i, j)$ to be the maximum number of red circles a ninja path terminating at $(i, j)$ may contain. In particular,
  • $g(i, j) = \operatorname{max}(g(i-1, j-1), g(i-1, j))$ if $(i, j)$ is colored white, and
  • $g(i, j) = \operatorname{max}(g(i-1, j-1), g(i-1, j)) + 1$ if $(i, j)$ is colored red.
By convention, $g(i, j) = 0$ for $j = 0$ or $j = i+1$.

Construction: In row $2^k + r$ for $ 0\leq r < 2^k$, color circle $\left(2^k+r, 2r+1\right)$ red. Calculating the values of $g(i, j)$ shows that $g(i, j) \leq k+1$ for row $2^k+r$.

Bound: The bound is a delicious induction argument. For each $k$, let $f(k)$ denote the minimum positive integer $n$ such that in any Japanese triangle with $n$ rows, there exists a ninja path through at least $k$ red circles. The construction implies that $f(k) \geq 2^{k-1}$ for each $k$. I contend:

Claim: In any Japanese triangle with $n= f(k)$ rows, the sum of $g(n, j)$ for all $1 \leq j \leq n$ is at least $n(k-1) + 1$.

Proof: We prove the first claim by induction on $k$, with the base case $k=2$ clear. Consider any Japanese triangle with $2n$ rows, and let $S(n)$ denote the sum of $g(n, j)$ for all $1 \leq j \leq n$.

For all $m \geq f(k)$, I claim that the inequality $S(m+1) \geq S(m) + k + 1$ holds. To see this, let $j$ be the maximal index such that $g(m, j) \geq k$. Then, before picking a red circle, $g(m+1, \ell) \geq g(m, \ell)$ for all $\ell \leq j$, $g(m+1, \ell+1) \geq g(m, \ell)$ for all $\ell > j$. Therefore
\begin{align*}
S(m+1) - S(m) &= \sum_{\ell=1}^j \left(g(m+1, \ell) - g(m, \ell)\right) + g(m+1, \ell + 1) + \sum_{\ell = j+1}^m \left(g(m+1, \ell + 1) - g(m, \ell)\right)\\
&\geq k + 1
\end{align*}because $g(m+1, \ell + 1) \geq k$ and $S$ increases by exactly one when we color a red circle.

Thus, \[S(2n) \geq S(n) + n(k+1) = 2nk + 1. \ \ (*)\]So in any Japanese triangle with $2n$ rows, there exists a $g(2n, j) \geq k + 1$; so in fact, $f(k+1) \leq 2f(k)$ for every positive integer $k$. Because $f(2) = 2$ and $f(k) \geq 2^{k-1}$, it follows that $f(k) = 2^{k-1}$ precisely; thus in fact $f(k+1) = 2f(k)$, so $(*)$ reads the induction hypothesis for $f(k+1)$. The claim follows. $\blacksquare$

It is evident that the claim also solves the problem, so we are done.

Remark: The induction argument in the bound proof is an example of strengthening the inductive hypothesis; but unlike most examples, it makes no explicit reference to what the size of $f(k+1)$ should be. In a sense, we take an inductive step into nowhere by picking $2n$, then realize that the inductive hypothesis itself proves to us that we have indeed landed at $f(k+1)$. Really cool stuff.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
lksb
164 posts
#77
Y by
numbersandnumbers wrote:
The answer is $k = \lfloor \log_2 n \rfloor + 1$. To prove that one can't do better, note that it suffices to find a construction for $n = 2^m-1$ that has no path with more than $m$ circles. This is doable by placing the red cells "diagonally" such that no path intersects more than one red cell in rows $1$, $2$, $3$ through $4$, ..., $2^{m-1}$ to $2^m - 1$. An example with $m = 4$ is shown below:
[asy]
unitsize(5mm);
for (int i = 1; i < 2; ++i) {
int j = 2*(i-1);
fill(shift(i*dir(240)+j*dir(0))*scale(0.5)*unitcircle,lightred);
}
for (int i = 2; i < 4; ++i) {
int j = 2*(i-2);
fill(shift(i*dir(240)+j*dir(0))*scale(0.5)*unitcircle,lightred);
}
for (int i = 4; i < 8; ++i) {
int j = 2*(i-4);
fill(shift(i*dir(240)+j*dir(0))*scale(0.5)*unitcircle,lightred);
}
for (int i = 8; i < 16; ++i) {
int j = 2*(i-8);
fill(shift(i*dir(240)+j*dir(0))*scale(0.5)*unitcircle,lightred);
}
for (int i = 1; i < 16; ++i) {
for (int j = 0; j < i; ++j) {
draw(shift(i*dir(240)+j*dir(0))*scale(0.5)*unitcircle);
}
}
[/asy]

Now we show that $k = \lfloor \log_2 n \rfloor + 1$ is always achievable. To do this, for $1 \leq j \leq i \leq n$, let $a_{i,j}$ be the maximum number of red circles in any path starting from the $j$th circle in the $i$th row and going to the bottom of the triangle. We have the recurrence
\[a_{i,j} = \max\{a_{i+1,j}, a_{i+1,j+1}\} + \begin{cases*} 1 & the $j$th circle in the $i$th row is colored \\ 0 & else \end{cases*}\]and we wish to show that $a_{1,1} \geq \lfloor \log_2 n\rfloor + 1$.

To do this, our main claim is that
\[\sum_{j=1}^{i} 2^{a_{i,j}} \geq \sum_{j=1}^{i+1} 2^{a_{i+1,j}}\]for all $i$. This will finish, since we can compute that $\sum_{j=1}^{n} 2^{a_{n,j}} = n+1$, and chaining together these inequalities shows that $2^{a_{1,1}} \geq n+ 1$.

To prove the inequality, pick a specific $i$. For a given $b$, the number of $j$ with $a_{i+1,j} < b$ is strictly greater than the number of $j$ with $\max\{a_{i+1,j}, a_{i+1,j+1}\} < b$, unless the former quantity is zero. Therefore
\begin{align*}
\MoveEqLeft \sum_{j=1}^{i+1} 2^{a_{i+1,j}} -\sum_{j=1}^{i} 2^{\max\{a_{i+1,j}, a_{i+1,j+1}\}} \\
&= \begin{multlined}[t] \left(i+1+\sum_{b=1}^\infty 2^{b-1} \lvert \{ j : a_{i+1,j} \geq b\}\rvert\right) \\ - \left(i+\sum_{b=1}^\infty 2^{b-1} \lvert \{ j : \max\{a_{i+1,j}, a_{i+1,j+1}\} \geq b\}\rvert\right)\end{multlined} \\
& = 1 + \sum_{b=1}^\infty 2^{b-1} (1+\lvert \{ j :\max\{a_{i+1,j}, a_{i+1,j+1}\} < b\}\rvert- \lvert \{ j : a_{i+1,j} < b\}\rvert) \\
&\leq 1 + \sum_{b = 1}^{\min_j \{a_{i+1,j}\}} 2^{b-1} \\
&= 2^{\min_j \{a_{i+1,j}\}}.
\end{align*}On the other hand, if $j^*$ is the location of the colored circle in row $i$,
\[ \sum_{j=1}^{i} 2^{a_{i,j}} -\sum_{j=1}^{i} 2^{\max\{a_{i+1,j}, a_{i+1,j+1}\}} = 2^{\max\{a_{i+1,j^*}, a_{i+1,j^*+1}\}} \geq 2^{\min_j \{a_{i+1,j}\}}.\]Subtracting these two inequalities yields the claim.

crazy LaTeX
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
quantam13
108 posts
#78
Y by
Amazing problem! I got quite a few solutions, but my favorite one is the following: Create a binary tree on the red circles in the obvious manner. Each vertex has atmost 2 children so the depth of the tree is atleast $1+\lfloor \log_2n\rfloor$ !! :cool:
Z K Y
N Quick Reply
G
H
=
a