Plan ahead for the next school year. Schedule your class today!

G
Topic
First Poster
Last Poster
k a July Highlights and 2025 AoPS Online Class Information
jwelsh   0
Jul 1, 2025
We are halfway through summer, so be sure to carve out some time to keep your skills sharp and explore challenging topics at AoPS Online and our AoPS Academies (including the Virtual Campus)!

[list][*]Over 60 summer classes are starting at the Virtual Campus on July 7th - check out the math and language arts options for middle through high school levels.
[*]At AoPS Online, we have accelerated sections where you can complete a course in half the time by meeting twice/week instead of once/week, starting on July 8th:
[list][*]MATHCOUNTS/AMC 8 Basics
[*]MATHCOUNTS/AMC 8 Advanced
[*]AMC Problem Series[/list]
[*]Plus, AoPS Online has a special seminar July 14 - 17 that is outside the standard fare: Paradoxes and Infinity
[*]We are expanding our in-person AoPS Academy locations - are you looking for a strong community of problem solvers, exemplary instruction, and math and language arts options? Look to see if we have a location near you and enroll in summer camps or academic year classes today! New locations include campuses in California, Georgia, New York, Illinois, and Oregon and more coming soon![/list]

MOP (Math Olympiad Summer Program) just ended and the IMO (International Mathematical Olympiad) is right around the corner! This year’s IMO will be held in Australia, July 10th - 20th. Congratulations to all the MOP students for reaching this incredible level and best of luck to all selected to represent their countries at this year’s IMO! Did you know that, in the last 10 years, 59 USA International Math Olympiad team members have medaled and have taken over 360 AoPS Online courses. Take advantage of our Worldwide Online Olympiad Training (WOOT) courses
and train with the best! Please note that early bird pricing ends August 19th!
Are you tired of the heat and thinking about Fall? You can plan your Fall schedule now with classes at either AoPS Online, AoPS Academy Virtual Campus, or one of our AoPS Academies around the US.

Our full course list for upcoming classes is below:
All classes start 7:30pm ET/4:30pm PT unless otherwise noted.

Introductory: Grades 5-10

Prealgebra 1 Self-Paced

Prealgebra 1
Wednesday, Jul 16 - Oct 29
Sunday, Aug 17 - Dec 14
Tuesday, Aug 26 - Dec 16
Friday, Sep 5 - Jan 16
Monday, Sep 8 - Jan 12
Tuesday, Sep 16 - Jan 20 (4:30 - 5:45 pm ET/1:30 - 2:45 pm PT)
Sunday, Sep 21 - Jan 25
Thursday, Sep 25 - Jan 29
Wednesday, Oct 22 - Feb 25
Tuesday, Nov 4 - Mar 10
Friday, Dec 12 - Apr 10

Prealgebra 2 Self-Paced

Prealgebra 2
Friday, Jul 25 - Nov 21
Sunday, Aug 17 - Dec 14
Tuesday, Sep 9 - Jan 13
Thursday, Sep 25 - Jan 29
Sunday, Oct 19 - Feb 22
Monday, Oct 27 - Mar 2
Wednesday, Nov 12 - Mar 18

Introduction to Algebra A Self-Paced

Introduction to Algebra A
Tuesday, Jul 15 - Oct 28
Sunday, Aug 17 - Dec 14
Wednesday, Aug 27 - Dec 17
Friday, Sep 5 - Jan 16
Thursday, Sep 11 - Jan 15
Sunday, Sep 28 - Feb 1
Monday, Oct 6 - Feb 9
Tuesday, Oct 21 - Feb 24
Sunday, Nov 9 - Mar 15
Friday, Dec 5 - Apr 3

Introduction to Counting & Probability Self-Paced

Introduction to Counting & Probability
Wednesday, Jul 2 - Sep 17
Sunday, Jul 27 - Oct 19
Monday, Aug 11 - Nov 3
Wednesday, Sep 3 - Nov 19
Sunday, Sep 21 - Dec 14 (1:00 - 2:30 pm ET/10:00 - 11:30 am PT)
Friday, Oct 3 - Jan 16
Sunday, Oct 19 - Jan 25
Tuesday, Nov 4 - Feb 10
Sunday, Dec 7 - Mar 8

Introduction to Number Theory
Tuesday, Jul 15 - Sep 30
Wednesday, Aug 13 - Oct 29
Friday, Sep 12 - Dec 12
Sunday, Oct 26 - Feb 1
Monday, Dec 1 - Mar 2

Introduction to Algebra B Self-Paced

Introduction to Algebra B
Friday, Jul 18 - Nov 14
Thursday, Aug 7 - Nov 20
Monday, Aug 18 - Dec 15
Sunday, Sep 7 - Jan 11
Thursday, Sep 11 - Jan 15
Wednesday, Sep 24 - Jan 28
Sunday, Oct 26 - Mar 1
Tuesday, Nov 4 - Mar 10
Monday, Dec 1 - Mar 30

Introduction to Geometry
Monday, Jul 14 - Jan 19
Wednesday, Aug 13 - Feb 11
Tuesday, Aug 26 - Feb 24
Sunday, Sep 7 - Mar 8
Thursday, Sep 11 - Mar 12
Wednesday, Sep 24 - Mar 25
Sunday, Oct 26 - Apr 26
Monday, Nov 3 - May 4
Friday, Dec 5 - May 29

Paradoxes and Infinity
Mon, Tue, Wed, & Thurs, Jul 14 - Jul 16 (meets every day of the week!)
Sat & Sun, Sep 13 - Sep 14 (1:00 - 4:00 PM PT/4:00 - 7:00 PM ET)

Intermediate: Grades 8-12

Intermediate Algebra
Sunday, Jul 13 - Jan 18
Thursday, Jul 24 - Jan 22
Friday, Aug 8 - Feb 20
Tuesday, Aug 26 - Feb 24
Sunday, Sep 28 - Mar 29
Wednesday, Oct 8 - Mar 8
Sunday, Nov 16 - May 17
Thursday, Dec 11 - Jun 4

Intermediate Counting & Probability
Sunday, Sep 28 - Feb 15
Tuesday, Nov 4 - Mar 24

Intermediate Number Theory
Wednesday, Sep 24 - Dec 17

Precalculus
Wednesday, Aug 6 - Jan 21
Tuesday, Sep 9 - Feb 24
Sunday, Sep 21 - Mar 8
Monday, Oct 20 - Apr 6
Sunday, Dec 14 - May 31

Advanced: Grades 9-12

Calculus
Sunday, Sep 7 - Mar 15
Wednesday, Sep 24 - Apr 1
Friday, Nov 14 - May 22

Contest Preparation: Grades 6-12

MATHCOUNTS/AMC 8 Basics
Tues & Thurs, Jul 8 - Aug 14 (meets twice a week!)
Sunday, Aug 17 - Nov 9
Wednesday, Sep 3 - Nov 19
Tuesday, Sep 16 - Dec 9
Sunday, Sep 21 - Dec 14 (1:00 - 2:30 pm ET/10:00 - 11:30 am PT)
Monday, Oct 6 - Jan 12
Thursday, Oct 16 - Jan 22
Tues, Thurs & Sun, Dec 9 - Jan 18 (meets three times a week!)

MATHCOUNTS/AMC 8 Advanced
Tues & Thurs, Jul 8 - Aug 14 (meets twice a week!)
Sunday, Aug 17 - Nov 9
Tuesday, Aug 26 - Nov 11
Thursday, Sep 4 - Nov 20
Friday, Sep 12 - Dec 12
Monday, Sep 15 - Dec 8
Sunday, Oct 5 - Jan 11
Tues, Thurs & Sun, Dec 2 - Jan 11 (meets three times a week!)
Mon, Wed & Fri, Dec 8 - Jan 16 (meets three times a week!)

AMC 10 Problem Series
Tues & Thurs, Jul 8 - Aug 14 (meets twice a week!)
Sunday, Aug 10 - Nov 2
Thursday, Aug 14 - Oct 30
Tuesday, Aug 19 - Nov 4
Mon & Wed, Sep 15 - Oct 22 (meets twice a week!)
Mon, Wed & Fri, Oct 6 - Nov 3 (meets three times a week!)
Tue, Thurs & Sun, Oct 7 - Nov 2 (meets three times a week!)

AMC 10 Final Fives
Friday, Aug 15 - Sep 12
Sunday, Sep 7 - Sep 28
Tuesday, Sep 9 - Sep 30
Monday, Sep 22 - Oct 13
Sunday, Sep 28 - Oct 19 (1:00 - 2:30 pm ET/10:00 - 11:30 am PT)
Wednesday, Oct 8 - Oct 29
Thursday, Oct 9 - Oct 30

AMC 12 Problem Series
Wednesday, Aug 6 - Oct 22
Sunday, Aug 10 - Nov 2
Monday, Aug 18 - Nov 10
Mon & Wed, Sep 15 - Oct 22 (meets twice a week!)
Tues, Thurs & Sun, Oct 7 - Nov 2 (meets three times a week!)

AMC 12 Final Fives
Thursday, Sep 4 - Sep 25
Sunday, Sep 28 - Oct 19
Tuesday, Oct 7 - Oct 28

AIME Problem Series A
Thursday, Oct 23 - Jan 29

AIME Problem Series B
Tuesday, Sep 2 - Nov 18

F=ma Problem Series
Tuesday, Sep 16 - Dec 9
Friday, Oct 17 - Jan 30

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, Aug 14 - Oct 30
Sunday, Sep 7 - Nov 23
Tuesday, Dec 2 - Mar 3

Intermediate Programming with Python
Friday, Oct 3 - Jan 16

USACO Bronze Problem Series
Wednesday, Sep 3 - Dec 3
Thursday, Oct 30 - Feb 5
Tuesday, Dec 2 - Mar 3

Physics

Introduction to Physics
Tuesday, Sep 2 - Nov 18
Sunday, Oct 5 - Jan 11
Wednesday, Dec 10 - Mar 11

Physics 1: Mechanics
Sunday, Sep 21 - Mar 22
Sunday, Oct 26 - Apr 26
0 replies
jwelsh
Jul 1, 2025
0 replies
Find all functions with ...
Math2030   1
N a minute ago by JARP091
Problem 3.43 (Czech–Austrian–Polish–Slovak Match 2024).} Find all functions $f : \mathbb{R} \to \mathbb{R}$ satisfying
\[
f(x^2 + y^2) = f(x - y)f(x + y) + \alpha y f(y), \quad \forall x, y \in \mathbb{R}
\](where $\alpha \ne 0$ is a fixed real constant).
1 reply
Math2030
35 minutes ago
JARP091
a minute ago
ABC is similar to XYZ
Amir Hossein   58
N 8 minutes ago by Kempu33334
Source: China TST 2011 - Quiz 2 - D2 - P1
Let $AA',BB',CC'$ be three diameters of the circumcircle of an acute triangle $ABC$. Let $P$ be an arbitrary point in the interior of $\triangle ABC$, and let $D,E,F$ be the orthogonal projection of $P$ on $BC,CA,AB$, respectively. Let $X$ be the point such that $D$ is the midpoint of $A'X$, let $Y$ be the point such that $E$ is the midpoint of $B'Y$, and similarly let $Z$ be the point such that $F$ is the midpoint of $C'Z$. Prove that triangle $XYZ$ is similar to triangle $ABC$.
58 replies
Amir Hossein
May 20, 2011
Kempu33334
8 minutes ago
A nice property of triangle with incircle (I)
TUAN2k8   1
N 8 minutes ago by Royal_mhyasd
Source: own
Let \( ABC \) be a non-isosceles triangle with incircle (\( I \)). Denote by \( D, E, F \) the points where (\( I \)) touches \( BC, CA, AB \), respectively. The A-excircle of \( ABC \) is tangent to \( BC \) at \( G \). The lines \( IB \) and \( IC \) meet \( AG \) at \( M \) and \( N \), respectively.

a) Prove that the circumcircles of triangles \( MBF \), \( NCE \), and \( BIC \) are concurrent at a point.

b) Let \( L \) and \( K \) be the midpoints of \( AG \) and \( BC \), respectively, and let \( J \) be the orthocenter of triangle \( IMN \). Show that the points \( L, K, J \) are collinear.
1 reply
TUAN2k8
Today at 1:18 AM
Royal_mhyasd
8 minutes ago
S lies on bisector of <BAC , BP = CQ
parmenides51   2
N 13 minutes ago by SuperBarsh
Source: Mexican Geometry Olympiad 2021 p4 - II Olimpiada de Geometria https://artofproblemsolving.com/community/c2746625_
Let $ABC$ be a triangle and let $P$ and $Q$ be points on the segments $AB$ and $AC$ respectively such that $BP = CQ$. Let $R$ be the intersection point of segments $BQ$ and $CP$ and let $S$ be the second intersection point of the circumcircles of $BPR$ and $CQR$. Prove that $S$ lies on the bisector of the angle $\angle BAC$.
2 replies
parmenides51
Dec 31, 2021
SuperBarsh
13 minutes ago
No more topics!
Easy Number Theory
jj_ca888   13
N May 28, 2025 by cursed_tangent1434
Source: SMO 2020/1
The sequence of positive integers $a_0, a_1, a_2, \ldots$ is recursively defined such that $a_0$ is not a power of $2$, and for all nonnegative integers $n$:

(i) if $a_n$ is even, then $a_{n+1} $ is the largest odd factor of $a_n$
(ii) if $a_n$ is odd, then $a_{n+1} = a_n + p^2$ where $p$ is the smallest prime factor of $a_n$

Prove that there exists some positive integer $M$ such that $a_{m+2} = a_m $ for all $m \geq M$.

Proposed by Andrew Wen
13 replies
jj_ca888
Aug 28, 2020
cursed_tangent1434
May 28, 2025
Easy Number Theory
G H J
G H BBookmark kLocked kLocked NReply
Source: SMO 2020/1
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
jj_ca888
2725 posts
#1
Y by
The sequence of positive integers $a_0, a_1, a_2, \ldots$ is recursively defined such that $a_0$ is not a power of $2$, and for all nonnegative integers $n$:

(i) if $a_n$ is even, then $a_{n+1} $ is the largest odd factor of $a_n$
(ii) if $a_n$ is odd, then $a_{n+1} = a_n + p^2$ where $p$ is the smallest prime factor of $a_n$

Prove that there exists some positive integer $M$ such that $a_{m+2} = a_m $ for all $m \geq M$.

Proposed by Andrew Wen
This post has been edited 5 times. Last edited by jj_ca888, Aug 28, 2020, 6:39 PM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
i3435
1353 posts
#2 • 1 Y
Y by Mango247
Sol
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
gnoka
245 posts
#3
Y by
Excuse me, what is the full name of SMO?
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
brianzjk
1201 posts
#4 • 1 Y
Y by gnoka
gnoka wrote:
Excuse me, what is the full name of SMO?

Summer Math Olympiad
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
gnoka
245 posts
#5
Y by
brianzjk wrote:
gnoka wrote:
Excuse me, what is the full name of SMO?

Summer Math Olympiad

thanks very much
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
rcorreaa
238 posts
#6
Y by
Assume WLOG $a_1$ is odd. Observe that if $p_1$ is the smallest prime factor $a_1 \implies p_1|a_2=a_1+p_1^2 \implies p_1|a_n \quad \forall n \in \mathbb{N}.$ Hence if $p_n$ is the smallest odd prime factor of $a_n$, we have that $p_0 \geq p_1 \geq p_2 \geq ... \implies$ since this sequence is bounded below, we have that it is eventually constant, i.e., there exists an $N$ such that for all $n \geq N, p_{n+1}=p_n. \quad (*)$

Now, observe that if $a_n$ is odd and composite, $\implies a_{n+1}=a_n+p_n^2 \leq a_n + (\sqrt{a_n}^2)=2a_n \implies a_{n+2}= \frac{a_{n+1}}{2^{v_2(a_{n+1})}} < a_n \implies a_{n+2} < a_n$. Thus, if $a_n$ is composite for all odd $a_n$, $a_n$ is eventually negative, which is clearly a contradiction. Hence, there exists $m_0$ such that $a_{m_0}=q_0$, where $q_0$ is an odd prime number.
$\implies a_{m_0+1}=q_0(q_0+1) \implies a_{m_0+2}= \frac{q_0(q_0+1)}{2^{v_2(q_0+1)}}$.

If $\frac{q_0+1}{2^{v_2(q_0+1)}} >1 \implies$ we find $m_1>m_0$ such that $a_{m_1}$ is an odd prime, and defining $q_n$ in a similar way as previously, keep doing this until $\frac{q_n+1}{2^{v_2(q_n+1)}}=1$ or $m_n \geq N$ (from $(*)$). In both cases we are done! :-D

$\blacksquare$
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
amuthup
779 posts
#7
Y by
Suppose FTSOC that such an $M$ does not exist, and assume $a_0$ is odd. Let $b_i=a_{2i}$ for all $i$, and let $p_i$ denote the smallest prime factor of $b_i.$

$\textbf{Claim: }$ For all $i,$ there exists $j>i$ such that $p_i>p_j.$

$\emph{Proof: }$ If $b_i=p_i,$ then we have $$b_{i+1}=\frac{p_i(p_i+1)}{2^{\nu_2(p_i+p_{i}^2)}}.$$
  • If $p_i+1$ is a power of $2,$ then $b_{i+1}=b_{i},$ contradiction.
  • Otherwise, $p_i+1$ has a prime factor smaller than $p_i.$.

On the other hand, if $b_i$ is composite, write $b_i=kp_i$ for some $k>p_i$ (check that $k=p_i$ is impossible). Then, note that $$b_{i+1}=\frac{kp_{i}+p_{i}^2}{2^{\nu_2(kp_{i}+p_{i})^2}}\le\frac{kp_{i}+p_{i}^2}{2}<kp_{i}=b_i.$$Continuing in this manner, we will eventually reach $b_{i'}$ which is at most $p_i^2.$
  • If $b_{i'}=p_{i}^2,$ then $b_{i'}=b_{i'+2},$ contradiction.
  • If $b_{i'}=p_i,$ we are done by our previous work.
  • Otherwise, $b_{i'}$ has a prime factor smaller than $p_i,$ as desired.
$\blacksquare$

Since the set of odd primes has a minimum, we are done.
This post has been edited 3 times. Last edited by amuthup, Apr 3, 2021, 3:26 AM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
mathleticguyyy
3216 posts
#8 • 1 Y
Y by centslordm
Let $A_{x}=a_{2x}$.

$p$ represents any generic prime. Note that the smallest prime divisor of the sequence cannot increase. Also, if $A_i$ isn't $p$ or $p^2$, $A_{i+1}$ strictly decreases. Hence, we will eventually reach a number of the form $p$ or $p^2$; in the latter case we are done, and in the former case, notice that the smallest prime factor will strictly decrease, and if we never hit $p^2$, we will eventually get to $A_i=p=2^k-1$ since $3=2^2-1$, at which we achieve the periodicity.
This post has been edited 1 time. Last edited by mathleticguyyy, Jan 15, 2022, 3:19 AM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
IAmTheHazard
5007 posts
#9
Y by
Obviously the smallest odd prime factor of $a_n$ is nonincreasing, hence eventually constant. Suppose that for every $n>N_0$, the least prime divisor of $a_n$ is a fixed prime $p$. If $a_n>p^2$, then advancing two moves starting with (ii) (so then we do (i), and go back to (ii), etc.) will go from $a_n$ to at most $\tfrac{a_n+p^2}{2}$, hence $a_n$ will strictly decrease. Suppose that for all $n>N_1>N_0$ we have $a_n \leq p^2$. Then $a_n/p \in \{1,p\}$ for size reasons, else $p$ is not the minimal prime divisor. If $a_n/p=1 \implies a_n=p$, then we go from $p \to p^2 \to \tfrac{p(p+1)}{2^{\nu_2(p+1))}}$. Since this final fraction is strictly less than $p^2$, we must have $\tfrac{p+1}{2^{\nu_2(p+1)}}=1$, else this term has a smaller prime divisor than $p$, in which case our fraction just equals $p$ so we have the desired periodicity. If $a_n/p=p \implies a_n=p^2$ (the easy case) we go $p^2 \to 2p^2 \to p^2$ so we're done here as well. $\blacksquare$
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
GrantStar
826 posts
#10 • 1 Y
Y by OronSH
Solved with OronSH

Note that the smallest prime factor of each term is non increasing. Thus, after some point, it remains constant, say this is after the term $a_n=p\cdot k$ with $p$ being said factor (WLOG $k$ is odd, otherwise (i) is applied). We take $3$ cases.
  • If $k=1$, then $a_{i+1}=p(p+1)$. By assumption, $p+1$ thus must be a power of $2$, hence $a_{i+2}=p$ again.
  • If $k=p$ then It oscillates between $p^2$ and $2p^2$
  • If $k>p$, then $a_{i+2}\leq \frac{p(p+k)}{2}<pk=a_i$. Thus the sequence is decreasing and thus either hits $p$ or $p^2$.
This post has been edited 1 time. Last edited by GrantStar, Jan 8, 2024, 12:07 AM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
HamstPan38825
8904 posts
#11
Y by
For each $n$, let $p_n$ denote the smallest prime factor of $a_n$. Observe that the $\{a_n\}$ alternate parity, so we will assume WLOG that $a_n \equiv n \pmod 2$.

Claim. $\{p_n\}$ is nondecreasing.

Proof. Clearly $p_n \neq 2$, so if $a_n$ is even, then $p_n \mid a_{n+1}$. If $a_n$ is odd, then $a_{n+1} = a_n + p_n^2$ is still a multiple of $p_n$ too. $\blacksquare$

It follows that there is some $N$ such that for all $n > N$, $p_n = p$ is constant.

Claim. There is some $n > N$ such that $a_n \leq p^2$.

Proof. If otherwise, then note that $a_{2n+1} \leq \frac 12 a_{2n}$ as $a_{2n}$ is always even, so
\[a_{2n+1} \leq \frac 12 a_{2n} = \frac 12 (a_{2n-1} + p^2) < a_{2n-1}\]meaning that $\{a_{2n+1}\}$ is strictly decreasing. So it must drop below $p^2$ at some point, contradiction. $\blacksquare$

Consider the $a_n$ described by the claim. Clearly $p \mid a_n$, but if $a_n = pk$ for $2 \leq k \leq p-1$, then there is a smaller prime factor of $a_n$ than $p$, contradiction. Hence either $a_n = p$ or $a_n = p^2$.

If $a_n = p^2$, then $a_{n+1} = 2p^2$ and $a_{n+2} = p^2$, and the conclusion follows immediately. If $a_n = p$, either $p+1$ is a power of two, or it has an odd prime factor less than $p$. The latter case yields a contradiction, and the former case yields $a_{n+2} = p$, so again $\{a_n\}$ is periodic with period $2$. This finishes the problem.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
bin_sherlo
755 posts
#12
Y by
This is a similar one.
Let $p_i$ be the smallest odd prime divisor of $a_i$. First, if $a_n$ is even then $p_n|a_{n+1}$ hence $p_{n+1}\leq p_n$. Also if $a_n$ is odd, then $a_{n+1}=p_n(p_n+\frac{a_n}{p_n})$ which implies $p_{n+1}\leq p_n$ again. Since $\{p_i\}$ is nondecreasing and is a set of primes, this seuqence must be constant evantually. Let this constant prime be $p$. Let $p_n=p$ for $n\geq T$. Consider some constant $C>a_i$ for $i\geq T^T$. If $a_l$ is even, then $a_{l+1}<a_l$ and if $a_l$ is odd, then $a_{l+1}=p^2+a_l<2C$ and $a_{l+2}\leq \frac{a_{l+1}}{2}=\frac{p^2+a_l}{2}<C$ hence $a_i<2C$ for all $i$. Note that there is an $a_k$ repeating at least twice (actually for infinitely many times) and $a_k=a_l$ causes $a_{k+i}=a_{l+i}$ hence this sequence becomes periodic. Let $a_i=pb_i$ for $i\geq T$.
\[2^{r_1}pk_1\rightarrow pk_1\rightarrow 2^{r_2}pk_2\rightarrow pk_2\rightarrow \dots \rightarrow 2^{r_m}pk_m\rightarrow pk_m\rightarrow 2^{r_1}pk_1\]Also we have the equations $p(p+k_i)=2^{r_{i+1}}pk_{i+1}$ or $p+k_i=2^{r_{i+1}}k_{i+1}$. By adding these we get $pm\geq k_1+\dots + k_m$ and since $k_i=1$ or $k_i\geq p+1$, we observe that there must exist some $k_i=1$. WLOG $k_1=1$. However, $p+1=2^{r_2}k_2\geq 2k_2$ thus, $k_2=1$. Similarily, $k_1=k_2=\dots =k_m=1$. So the length of the period must be $2$ where $p$ is a prime with $p+1=2^n$ as desired.$\blacksquare$
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
joshualiu315
2535 posts
#13
Y by
Begin by noticing that we only need $a_{i+2} = a_i$ for any $i$. Take an arbitrary term $a_k = px$ where $a_k$ is odd and $p$ is the smallest prime factor of $a_k$. Note that $a_{k+2} = \tfrac{p(x+p)}{2} > a_k$ unless $x=1$ or $x=p$. Hence, the sequence is decreasing until one of the terms is $p^2$ or $p$.

If $a_k = p^2$, then $a_{k+2}=a_k=p^2$. If $a_k=p$, then $a_{k+1} = p(p+1)$; we have $a_{k+2} < a_k$ unless $p+1$ is a power of $2$, at which point the sequence satisfies $a_{k+2} = a_k$. Thus, the primes decrease until $p=3$, at which point $p+1$ is a power of $2$, implying periodicity. $\blacksquare$
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
cursed_tangent1434
737 posts
#14
Y by
Working towards a contradiction, assume there exists some positive integral value of $a_0$ which is not a power of 2, for which the sequence does not eventually satisfy the desired condition. First, observe that no term of the sequence may be a power of 2. This is because, if $p\mid a_i$ is the smallest odd prime divisor of $a_i$ then $p \mid a_{i+1}=a_i+p^2$ and $p \mid \frac{a_i}{2^r} \in \mathbb{Z}$ for any positive integer $r$. Further observe that the parity of the terms of the sequence alternate between consecutive terms. We now prove our key claim.

Claim : For all positive integers $n$ such that $a_n$ is odd, either $a_{n+2}<a_n$ or the smallest prime divisor of $a_{n+2}$ is strictly smaller than the smallest prime divisor of $a_n$.

Proof : If $a_n$ has atleast two (not necessarily distinct) prime factors of which $p$ is the smallest,
\[a_{n+2} = \frac{a_n+p^2}{2^{\nu_2(a_n+p^2)}} \le \frac{a_n+p^2}{2} \le a_n\]since $a_n\ge p^2$ due to our assumption that $a_n$ has atleast two prime factors, with equality only if $a_n=p^2$. But then, $a_{n+1}=2p^2$ and $a_{n+2}=p^2=a_n$ contradicting our assumption. Hence, the inequality here is strict.

Else $a_n$ has exactly one prime factor, so $a_{n+1}=a_n^2+a_n=a_n(a_n+1)$. But clearly, $a_{n}+1$ is either a power of two, which makes $a_{n+2}=a_n$ a contradiction to our assumption, or $a_{n}+1$ has some odd prime factor, and hence, the smallest prime factor of $a_{n+2}$ is less than $a_n$ which proves the claim.

However, since both $a_n$ and the smallest prime factor of $a_n$ are bounded below, they cannot decrease for ever implying that our assumption that no pair of terms $a_{m+2}=a_m$ exist where $a_m$ is odd is false. Moreover, if one such pair exists it is easy to see that the periodicity holds for all succeeding terms which proves the desired result.
Z K Y
N Quick Reply
G
H
=
a