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

G
Topic
First Poster
Last Poster
k a May Highlights and 2025 AoPS Online Class Information
jlacosta   0
May 1, 2025
May is an exciting month! National MATHCOUNTS is the second week of May in Washington D.C. and our Founder, Richard Rusczyk will be presenting a seminar, Preparing Strong Math Students for College and Careers, on May 11th.

Are you interested in working towards MATHCOUNTS and don’t know where to start? We have you covered! If you have taken Prealgebra, then you are ready for MATHCOUNTS/AMC 8 Basics. Already aiming for State or National MATHCOUNTS and harder AMC 8 problems? Then our MATHCOUNTS/AMC 8 Advanced course is for you.

Summer camps are starting next month at the Virtual Campus in math and language arts that are 2 - to 4 - weeks in duration. Spaces are still available - don’t miss your chance to have an enriching summer experience. 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 upcoming events:
[list][*]May 9th, 4:30pm PT/7:30pm ET, Casework 2: Overwhelming Evidence — A Text Adventure, a game where participants will work together to navigate the map, solve puzzles, and win! All are welcome.
[*]May 19th, 4:30pm PT/7:30pm ET, What's Next After Beast Academy?, designed for students finishing Beast Academy and ready for Prealgebra 1.
[*]May 20th, 4:00pm PT/7:00pm ET, Mathcamp 2025 Qualifying Quiz Part 1 Math Jam, Problems 1 to 4, join the Canada/USA Mathcamp staff for this exciting Math Jam, where they discuss solutions to Problems 1 to 4 of the 2025 Mathcamp Qualifying Quiz!
[*]May 21st, 4:00pm PT/7:00pm ET, Mathcamp 2025 Qualifying Quiz Part 2 Math Jam, Problems 5 and 6, Canada/USA Mathcamp staff will discuss solutions to Problems 5 and 6 of the 2025 Mathcamp Qualifying Quiz![/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
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
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
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
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
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
Tuesday, May 6 - Aug 19
Wednesday, Jun 4 - Sep 17
Sunday, Jun 22 - Oct 19
Friday, Jul 18 - Nov 14

Introduction to Geometry
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

Paradoxes and Infinity
Mon, Tue, Wed, & Thurs, Jul 14 - Jul 16 (meets every day of the week!)

Intermediate: Grades 8-12

Intermediate Algebra
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
Sunday, Jun 1 - Aug 24
Wednesday, Jun 18 - Sep 3

Precalculus
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
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
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

AIME Problem Series A
Thursday, May 22 - Jul 31

AIME Problem Series B
Sunday, Jun 22 - Sep 21

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
Mon, Tue, Wed & Thurs, Jun 23 - Jun 26 (meets every day of the week!)
0 replies
jlacosta
May 1, 2025
0 replies
k i A Letter to MSM
Arr0w   23
N Sep 19, 2022 by scannose
Greetings.

I have seen many posts talking about commonly asked questions, such as finding the value of $0^0$, $\frac{1}{0}$,$\frac{0}{0}$, $\frac{\infty}{\infty}$, why $0.999...=1$ or even expressions of those terms combined as if that would make them defined. I have made this post to answer these questions once and for all, and I politely ask everyone to link this post to threads that are talking about this issue.
[list]
[*]Firstly, the case of $0^0$. It is usually regarded that $0^0=1$, not because this works numerically but because it is convenient to define it this way. You will see the convenience of defining other undefined things later on in this post.

[*]What about $\frac{\infty}{\infty}$? The issue here is that $\infty$ isn't even rigorously defined in this expression. What exactly do we mean by $\infty$? Unless the example in question is put in context in a formal manner, then we say that $\frac{\infty}{\infty}$ is meaningless.

[*]What about $\frac{1}{0}$? Suppose that $x=\frac{1}{0}$. Then we would have $x\cdot 0=0=1$, absurd. A more rigorous treatment of the idea is that $\lim_{x\to0}\frac{1}{x}$ does not exist in the first place, although you will see why in a calculus course. So the point is that $\frac{1}{0}$ is undefined.

[*]What about if $0.99999...=1$? An article from brilliant has a good explanation. Alternatively, you can just use a geometric series. Notice that
\begin{align*}
\sum_{n=1}^{\infty} \frac{9}{10^n}&=9\sum_{n=1}^{\infty}\frac{1}{10^n}=9\sum_{n=1}^{\infty}\biggr(\frac{1}{10}\biggr)^n=9\biggr(\frac{\frac{1}{10}}{1-\frac{1}{10}}\biggr)=9\biggr(\frac{\frac{1}{10}}{\frac{9}{10}}\biggr)=9\biggr(\frac{1}{9}\biggr)=\boxed{1}
\end{align*}
[*]What about $\frac{0}{0}$? Usually this is considered to be an indeterminate form, but I would also wager that this is also undefined.
[/list]
Hopefully all of these issues and their corollaries are finally put to rest. Cheers.

2nd EDIT (6/14/22): Since I originally posted this, it has since blown up so I will try to add additional information per the request of users in the thread below.

INDETERMINATE VS UNDEFINED

What makes something indeterminate? As you can see above, there are many things that are indeterminate. While definitions might vary slightly, it is the consensus that the following definition holds: A mathematical expression is be said to be indeterminate if it is not definitively or precisely determined. So how does this make, say, something like $0/0$ indeterminate? In analysis (the theory behind calculus and beyond), limits involving an algebraic combination of functions in an independent variable may often be evaluated by replacing these functions by their limits. However, if the expression obtained after this substitution does not provide sufficient information to determine the original limit, then the expression is called an indeterminate form. For example, we could say that $0/0$ is an indeterminate form.

But we need to more specific, this is still ambiguous. An indeterminate form is a mathematical expression involving at most two of $0$, $1$ or $\infty$, obtained by applying the algebraic limit theorem (a theorem in analysis, look this up for details) in the process of attempting to determine a limit, which fails to restrict that limit to one specific value or infinity, and thus does not determine the limit being calculated. This is why it is called indeterminate. Some examples of indeterminate forms are
\[0/0, \infty/\infty, \infty-\infty, \infty \times 0\]etc etc. So what makes something undefined? In the broader scope, something being undefined refers to an expression which is not assigned an interpretation or a value. A function is said to be undefined for points outside its domain. For example, the function $f:\mathbb{R}^{+}\cup\{0\}\rightarrow\mathbb{R}$ given by the mapping $x\mapsto \sqrt{x}$ is undefined for $x<0$. On the other hand, $1/0$ is undefined because dividing by $0$ is not defined in arithmetic by definition. In other words, something is undefined when it is not defined in some mathematical context.

WHEN THE WATERS GET MUDDIED

So with this notion of indeterminate and undefined, things get convoluted. First of all, just because something is indeterminate does not mean it is not undefined. For example $0/0$ is considered both indeterminate and undefined (but in the context of a limit then it is considered in indeterminate form). Additionally, this notion of something being undefined also means that we can define it in some way. To rephrase, this means that technically, we can make something that is undefined to something that is defined as long as we define it. I'll show you what I mean.

One example of making something undefined into something defined is the extended real number line, which we define as
\[\overline{\mathbb{R}}=\mathbb{R}\cup \{-\infty,+\infty\}.\]So instead of treating infinity as an idea, we define infinity (positively and negatively, mind you) as actual numbers in the reals. The advantage of doing this is for two reasons. The first is because we can turn this thing into a totally ordered set. Specifically, we can let $-\infty\le a\le \infty$ for each $a\in\overline{\mathbb{R}}$ which means that via this order topology each subset has an infimum and supremum and $\overline{\mathbb{R}}$ is therefore compact. While this is nice from an analytic standpoint, extending the reals in this way can allow for interesting arithmetic! In $\overline{\mathbb{R}}$ it is perfectly OK to say that,
\begin{align*}
a + \infty = \infty + a & = \infty, & a & \neq -\infty \\
a - \infty = -\infty + a & = -\infty, & a & \neq \infty \\
a \cdot (\pm\infty) = \pm\infty \cdot a & = \pm\infty, & a & \in (0, +\infty] \\
a \cdot (\pm\infty) = \pm\infty \cdot a & = \mp\infty, & a & \in [-\infty, 0) \\
\frac{a}{\pm\infty} & = 0, & a & \in \mathbb{R} \\
\frac{\pm\infty}{a} & = \pm\infty, & a & \in (0, +\infty) \\
\frac{\pm\infty}{a} & = \mp\infty, & a & \in (-\infty, 0).
\end{align*}So addition, multiplication, and division are all defined nicely. However, notice that we have some indeterminate forms here which are also undefined,
\[\infty-\infty,\frac{\pm\infty}{\pm\infty},\frac{\pm\infty}{0},0\cdot \pm\infty.\]So while we define certain things, we also left others undefined/indeterminate in the process! However, in the context of measure theory it is common to define $\infty \times 0=0$ as greenturtle3141 noted below. I encourage to reread what he wrote, it's great stuff! As you may notice, though, dividing by $0$ is undefined still! Is there a place where it isn't? Kind of. To do this, we can extend the complex numbers! More formally, we can define this extension as
\[\mathbb{C}^*=\mathbb{C}\cup\{\tilde{\infty}\}\]which we call the Riemann Sphere (it actually forms a sphere, pretty cool right?). As a note, $\tilde{\infty}$ means complex infinity, since we are in the complex plane now. Here's the catch: division by $0$ is allowed here! In fact, we have
\[\frac{z}{0}=\tilde{\infty},\frac{z}{\tilde{\infty}}=0.\]where $\tilde{\infty}/\tilde{\infty}$ and $0/0$ are left undefined. We also have
\begin{align*}
z+\tilde{\infty}=\tilde{\infty}, \forall z\ne -\infty\\
z\times \tilde{\infty}=\tilde{\infty}, \forall z\ne 0
\end{align*}Furthermore, we actually have some nice properties with multiplication that we didn't have before. In $\mathbb{C}^*$ it holds that
\[\tilde{\infty}\times \tilde{\infty}=\tilde{\infty}\]but $\tilde{\infty}-\tilde{\infty}$ and $0\times \tilde{\infty}$ are left as undefined (unless there is an explicit need to change that somehow). One could define the projectively extended reals as we did with $\mathbb{C}^*$, by defining them as
\[{\widehat {\mathbb {R} }}=\mathbb {R} \cup \{\infty \}.\]They behave in a similar way to the Riemann Sphere, with division by $0$ also being allowed with the same indeterminate forms (in addition to some other ones).
23 replies
Arr0w
Feb 11, 2022
scannose
Sep 19, 2022
k i Marathon Threads
LauraZed   0
Jul 2, 2019
Due to excessive spam and inappropriate posts, we have locked the Prealgebra and Beginning Algebra threads.

We will either unlock these threads once we've cleaned them up or start new ones, but for now, do not start new marathon threads for these subjects. Any new marathon threads started while this announcement is up will be immediately deleted.
0 replies
LauraZed
Jul 2, 2019
0 replies
k i Basic Forum Rules and Info (Read before posting)
jellymoop   368
N May 16, 2018 by harry1234
f (Reminder: Do not post Alcumus or class homework questions on this forum. Instructions below.) f
Welcome to the Middle School Math Forum! Please take a moment to familiarize yourself with the rules.

Overview:
[list]
[*] When you're posting a new topic with a math problem, give the topic a detailed title that includes the subject of the problem (not just "easy problem" or "nice problem")
[*] Stay on topic and be courteous.
[*] Hide solutions!
[*] If you see an inappropriate post in this forum, simply report the post and a moderator will deal with it. Don't make your own post telling people they're not following the rules - that usually just makes the issue worse.
[*] When you post a question that you need help solving, post what you've attempted so far and not just the question. We are here to learn from each other, not to do your homework. :P
[*] Avoid making posts just to thank someone - you can use the upvote function instead
[*] Don't make a new reply just to repeat yourself or comment on the quality of others' posts; instead, post when you have a new insight or question. You can also edit your post if it's the most recent and you want to add more information.
[*] Avoid bumping old posts.
[*] Use GameBot to post alcumus questions.
[*] If you need general MATHCOUNTS/math competition advice, check out the threads below.
[*] Don't post other users' real names.
[*] Advertisements are not allowed. You can advertise your forum on your profile with a link, on your blog, and on user-created forums that permit forum advertisements.
[/list]

Here are links to more detailed versions of the rules. These are from the older forums, so you can overlook "Classroom math/Competition math only" instructions.
Posting Guidelines
Update on Basic Forum Rules
What belongs on this forum?
How do I write a thorough solution?
How do I get a problem on the contest page?
How do I study for mathcounts?
Mathcounts FAQ and resources
Mathcounts and how to learn

As always, if you have any questions, you can PM me or any of the other Middle School Moderators. Once again, if you see spam, it would help a lot if you filed a report instead of responding :)

Marathons!
Relays might be a better way to describe it, but these threads definitely go the distance! One person starts off by posting a problem, and the next person comes up with a solution and a new problem for another user to solve. Here's some of the frequently active marathons running in this forum:
[list][*]Algebra
[*]Prealgebra
[*]Proofs
[*]Factoring
[*]Geometry
[*]Counting & Probability
[*]Number Theory[/list]
Some of these haven't received attention in a while, but these are the main ones for their respective subjects. Rather than starting a new marathon, please give the existing ones a shot first.

You can also view marathons via the Marathon tag.

Think this list is incomplete or needs changes? Let the mods know and we'll take a look.
368 replies
jellymoop
May 8, 2015
harry1234
May 16, 2018
Proving radical axis through orthocenter
azzam2912   0
12 minutes ago
In acute triangle $ABC$ let $D, E$ and $F$ denote the feet of the altitudes from $A, B$ and $C$, respectively. Let line $DE$ intersect circumcircle $ABC$ at points $G, H$. Similarly, let line $DF$ intersect circumcircle $ABC$ at points $I, J$. Prove that the radical axis of circles $EIJ$ and $FGH$ passes through the orthocenter of triangle $ABC$
0 replies
azzam2912
12 minutes ago
0 replies
Ez induction to start it off
alexanderhamilton124   22
N 18 minutes ago by Adywastaken
Source: Inmo 2025 p1
Consider the sequence defined by \(a_1 = 2\), \(a_2 = 3\), and
\[
a_{2k+1} = 2 + 2a_k, \quad a_{2k+2} = 2 + a_k + a_{k+1},
\]for all integers \(k \geq 1\). Determine all positive integers \(n\) such that
\[
\frac{a_n}{n}
\]is an integer.

Proposed by Niranjan Balachandran, SS Krishnan, and Prithwijit De.
22 replies
alexanderhamilton124
Jan 19, 2025
Adywastaken
18 minutes ago
Weird Algebra?
JARP091   0
19 minutes ago
Source: Art and Craft of Problem Solving 2.2.16
For each positive integer \( n \), find positive integer solutions \( x_1, x_2, \ldots, x_n \) to the equation

\[
\frac{1}{x_1} + \frac{1}{x_2} + \cdots + \frac{1}{x_n} + \frac{1}{x_1 x_2 \cdots x_n} = 1
\]
0 replies
JARP091
19 minutes ago
0 replies
Parallel lines in incircle configuration
GeorgeRP   2
N 23 minutes ago by bin_sherlo
Source: Bulgaria IMO TST 2025 P1
Let $I$ be the incenter of triangle $\triangle ABC$. Let $H_A$, $H_B$, and $H_C$ be the orthocenters of triangles $\triangle BCI$, $\triangle ACI$, and $\triangle ABI$, respectively. Prove that the lines through $H_A$, $H_B$, and $H_C$, parallel to $AI$, $BI$, and $CI$, respectively, are concurrent.
2 replies
GeorgeRP
4 hours ago
bin_sherlo
23 minutes ago
MathCounts National Sets
UberPiggy   14
N Today at 5:15 AM by MathRook7817
Hi, does anyone happen to have MathCounts National round test problems from 2018-2024? I found 2000-2017 online but can't find anything past that year.
14 replies
UberPiggy
Mar 28, 2025
MathRook7817
Today at 5:15 AM
MOPAMCAIMEUSAMOAMC
JustKeepRunning   9
N Today at 4:28 AM by Craftybutterfly
Alex is training to make $\text{MOP}$. Currently he will score a $0$ on $\text{the AMC,}\text{ the AIME,}\text{and the USAMO}$. He can expend $3$ units of effort to gain $6$ points on the $\text{AMC}$, $7$ units of effort to gain $10$ points on the $\text{AIME}$, and $10$ units of effort to gain $1$ point on the $\text{USAMO}$. He will need to get at least $200$ points on $\text{the AMC}$ and $\text{AIME}$ combined and get at least $21$ points on $\text{the USAMO}$ to make $\text{MOP}$. What is the minimum amount of effort he can expend to make $\text{MOP}$?
9 replies
JustKeepRunning
Jul 27, 2019
Craftybutterfly
Today at 4:28 AM
2025 Mathcounts Nationals Journal
Andyluo   12
N Today at 4:24 AM by jkim0656
Friday May 9th

I spent my evening after school, packing for the trip, using the checklist given by my coach.
I didn’t do much preparation, as I was mostly chilling out for the upcoming days.

I also played basketball with my cousin, Kevin, who met Gotham Chess and stayed at his home!


Saturday, May 10th

I woke up at 5:30 AM, ate a light breakfast, and headed out to the airport with my luggage.

I met my teacher, but was surprised that Archishman split up with his own family.
Waiting for the TSA was pretty boring, but we soon got through, and after I found our gate.

A couple of minutes pass by, as I review an AOPS mock where I meet Archischman;
Afterward, we chill out, watch the rube goldberg machine in the airport, and wait to board the plane.

During the plane ride, I played games; however, during our descent, I heard a loud crack, and our plane started wobbling, and we heard cracking sounds in the seats. Fortunately, we were able to land and were able to attend the competition the next day.

After this, heading out, we went to the shuttle; however, we had 35 minutes. We tried to solve the Jane Street card puzzle but failed, and ended up socializing.

After we arrived at the hotel, we received a MASSIVE amount of stuff, like calculators, shirts, coupons, plaques, stickers, etc.
I also saw and got a signature from Richard Rusczyk, which was really cool.

Then, we went to a restaurant named “Chinatown Garden”, with the worst food I’ve ever had.

We then chilled in our rooms, studied for a bit, and started organizing plans for pin trading.

Our goal was to scam as many people as possible by doing 2:1 trades, as we had a “limited”
amount of pins. (We even got 5:1 and 10:1 trades)
A Virginia kid scammed me with a STEM pin, so I chased him down and got our pin back.

We got through around half the states organizing in and out of what pins we had.

Finally, we got some food from the buffet (which was surprisingly decent) and had a good time trading some more.

We ended the day with a short and brief CDR, where we had some fun, and then we went to sleep to anticipate the next day.

At night, I showered and sang karaoke with Archi.

Sunday, May 11th

Getting ready, I found out that a mock (outside the box) was recently released and took it through breakfast.

Then, once we got there at 8:30, there was a mob of parents taking pictures, and music played.

Then every team did introductions/attendance and their chants, most of which were really cringe.

I took the test; however was too slow on the sprint round and got a predicted 16.

On the target round, I was able to get through and got a 12, despite barely not solving p8 to my frustration.

Team round we did decently, scoring a 14/20, which was one of the best scores around us, that even orz states like Texas and Washington didn’t beat.

Predicted Scores:
Caleb and I got a similar score (around 28), and Henry got around 35, and Archi sold on the target and got a 24.

After this, we teamed up with North Carolina (chill af) and went to a pho shop (54 Restaurant), which tasted amazing. (A far contrast from Chinatown Garden)

Then, we went to an aerospace museum, where we played Brawl Stars and went around. Eventually, we saw models of blackholes and air vacuums, and played a flight simulator.

Then we went to our hotel, chilled, and watched basketball games.

After, we went to an Indian restaurant named “Himilayan Doko” which was really delicious!

Then we raided different rooms, from NC, HAWAII, Idaho, Virgin Islands, and accidentally a random dudes room who was ticked at us.

Finally, we chilled and went to sleep, though I tried to get Henry and Archi to sleep since they were being annoying.

Monday, May 12th

We start the day forming my pin badge, and then we went to get some breakfast.

After that, we met in the breakfast area with 2 teams for table, and I actually got a 10:1 pin trade which was pretty cool.

After that, we lined up and got our thunderstick/clapping machines, and ran through the entrance of the CDR.

Sadly, we didn’t win anything, but it was cool seeing the results.

Then, we started to watch the CDR, which was really exciting.
It got really interesting when everyone saw Nathan Liu cook his opponent in half a second.

In the semifinals, it was insane, and Advait and Nathan, buzzed every question that was around mid-sprint level.

Then, it finished with Nathan beating Brandon with a 2-second solve, absolute insanity.

Finally, we went back to our rooms and got lunch in the hotel.
A few hours later, we received our scores, and I had bombed, scoring a 26 with 7 sillies. (ouch)

Unfortunately, my teammates Henry and Archishman sillied a bunch of questions.

After, we played Brawl Stars, and went to explore the hotel, where we went up a random staircase and got stuck. We went to the roof, but got scared and yelled out for help on the gym floor. Thankfully, we got back, and I went and reviewed the test.

After we reviewed the test, and went to the Mathcounts Party.

The food was mid, but the games were pretty fun.

We met a bunch of people, played air hockey, foosball, and basketball, while listening to the not so great music in the background.

Then we went back to our rooms at 8PM, to put our pins on, and I got 38/56!

Finally, we met up in a room with a bunch of Cali, and NC kids, and talked about the test, the people, and played Brawl Stars. Even Josh Frost came up to us and asked us how the trip was.

Tuesday, May 13th

I started the day waking up at 6:20, and packed up and ate breakfast. After that, Henry was late, so we packed food for him and went to the bus shuttle.

Eventually, we arrived at the airport, went through security (which was suspiciously fast), and played Brawl Stars. We also ate five guys fries, which was pretty good. Eventually, we had to part our ways with Henry and headed out to our flights, which marked the end of the trip.

Conclusion:

Although we didn’t do amazingly well in the contest, going to DC was an amazing experience. I got to meet people who were passionate about math, and hang out with them, goofing around.

This was the best math contest experience that I’ll likely ever have, and I’m glad I went through it.
12 replies
Andyluo
Yesterday at 4:43 PM
jkim0656
Today at 4:24 AM
9 MathandAI4Girls!!!
Inaaya   26
N Today at 2:22 AM by fossasor
How many problems did y'all solve this year?
I clowned and started the pset the week before :oops:
Though I think if i used the time wisely, I could have at least solved 11 of them
ended up with 9 :wallbash_red:
26 replies
Inaaya
May 7, 2025
fossasor
Today at 2:22 AM
The daily problem!
Leeoz   161
N Today at 1:38 AM by Math-lover1
Every day, I will try to post a new problem for you all to solve! If you want to post a daily problem, you can! :)

Please hide solutions and answers, hints are fine though! :)

Problems usually get harder throughout the week, so Sunday is the easiest and Saturday is the hardest!

Past Problems!
161 replies
Leeoz
Mar 21, 2025
Math-lover1
Today at 1:38 AM
MAP Goals
Antoinette14   14
N Today at 1:27 AM by Schintalpati
What's yall's MAP goals for this spring?
Mine's a 300 (trying to beat my brother's record) but since I'm at a 285 rn, 290+ is more reasonable.
14 replies
Antoinette14
May 8, 2025
Schintalpati
Today at 1:27 AM
Berkeley mini Math Tournament Online is June 7
BerkeleyMathTournament   8
N Today at 12:55 AM by jb2015007
Berkeley mini Math Tournament is a math competition hosted for middle school students once a year. Students compete in multiple rounds: individual round, team round, puzzle round, and relay round.

BmMT 2025 Online will be held on June 7th, and registration is OPEN! Registration is $8 per student. Our website https://berkeley.mt/events/bmmt-2025-online/ has more details about the event, past tests to practice with, and frequently asked questions. We look forward to building community and inspiring students as they explore the world of math!

3 out of 4 of the rounds are completed with a team, so it’s a great opportunity for students to work together. Beyond getting more comfortable with math and becoming better problem solvers, our team is preparing some fun post-competition activities!

Registration is open to students in grades 8 or below. You do not have to be local to the Bay Area or California to register for BmMT Online. Students may register as a team of 1, but it is beneficial to compete on a team of at least 3 due to our scoring guideline and for the experience.

We hope you consider attending, or if you are a parent or teacher, that you encourage your students to think about attending BmMT. Thank you, and once again find more details/register at our website.
8 replies
BerkeleyMathTournament
May 1, 2025
jb2015007
Today at 12:55 AM
Mathcounts Nationals Written Score Hub
DhruvJha   52
N Today at 12:55 AM by c_double_sharp
Put in your estimated score on the written nats comp on Sunday after the comp so we can get a good idea of the cdr quals are
52 replies
DhruvJha
May 10, 2025
c_double_sharp
Today at 12:55 AM
problemo
hashbrown2009   5
N Today at 12:49 AM by ZMB038
if x/(3^3+4^3) + y/(3^3+6^3) =1

and

x/(5^3+4^3) + y/(5^3+6^3) =1

find the 2 values of x and y.
5 replies
hashbrown2009
Mar 30, 2025
ZMB038
Today at 12:49 AM
Camp Conway acceptance
fossasor   22
N Today at 12:48 AM by ZMB038
Hello! I've just been accepted into Camp Conway, but I'm not sure how popular this camp actually is, given that it's new. Has anyone else applied/has been accepted/is going? (I'm trying to figure out to what degree this acceptance was just lack of qualified applicants, so I can better predict my chances of getting into my preferred math camp.)
22 replies
fossasor
Feb 20, 2025
ZMB038
Today at 12:48 AM
The Bank of Bath
TelMarin   100
N Apr 17, 2025 by Ihatecombin
Source: IMO 2019, problem 5
The Bank of Bath issues coins with an $H$ on one side and a $T$ on the other. Harry has $n$ of these coins arranged in a line from left to right. He repeatedly performs the following operation: if there are exactly $k>0$ coins showing $H$, then he turns over the $k$th coin from the left; otherwise, all coins show $T$ and he stops. For example, if $n=3$ the process starting with the configuration $THT$ would be $THT \to HHT  \to HTT \to TTT$, which stops after three operations.

(a) Show that, for each initial configuration, Harry stops after a finite number of operations.

(b) For each initial configuration $C$, let $L(C)$ be the number of operations before Harry stops. For example, $L(THT) = 3$ and $L(TTT) = 0$. Determine the average value of $L(C)$ over all $2^n$ possible initial configurations $C$.

Proposed by David Altizio, USA
100 replies
TelMarin
Jul 17, 2019
Ihatecombin
Apr 17, 2025
The Bank of Bath
G H J
Source: IMO 2019, problem 5
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
AnSoLiN
71 posts
#98 • 1 Y
Y by ImSh95
Let $f_{xyd}(n)$ where $x,y\in\{H,T\}$ and $d\in\{L=\text{Left},R=\text{Right}\}$ be defined as the sum of the number of the operations for all initial configuration with the following operation: if there are exactly $k>0$ coins showing $x$, then he turns over the $k^\text{th}$ from the $d$ until all coins show $y$. Let $f^*_{xyd}(n)$ be the same as $f_{xyd}(n)$ except $(k+1)^\text{th}$ coin is turned over. Only $f_{HTL}$, $f_{THL}$, $f_{HTR}$, $f_{THR}$, $f^*_{HHL}$, $f^*_{TTL}$, $f^*_{HHR}$, $f^*_{TTR}$ make sense. Problem asks for $\alpha_n=\dfrac{f_{HTL}(n)}{2^n}$

Divide $2^n$ initial configurations into two classes, those that end with a $H$ and those that end with a $T$. Sum of the number of operations for $2^{n-1}$ initial configurations that end with a $T$ is clearly $f_{HTL}(n-1)$ as the last $T$ affects nothing. For the initial configurations that end with a $H$, to touch the last $H$, all coins should be showing $H$. After that point, it takes $n$ steps to make all of them $T$. To get to the point that all coins show $H$, we need a total of $f^*_{HHL}(n-1)$ operations, since the last $H$ contributes 1 to the total number of $H$s.

$$f_{HTL}(n)=f_{HTL}(n-1)+f^*_{HHL}(n-1)+2^{n-1}\cdot n$$$$f_{HHL}^*(n-1)\overset{(1)}{=}f_{TTL}^*(n-1)\overset{(2)}{=}f_{TTR}^*(n-1)\overset{(3)}{=}f_{HTL}(n-1)$$
(1) Initial configurations are symmetric wrt $H$ and $T$.
(2) Initial configurations are symmetric wrt $L$ and $R$ when $x=y$.
(3) The $k^\text{th}$ coin from left, where $k$ is the number of $H$s is the same as the $(l+1)^{th}$ coin from right, where $l$ is the number of $T$s.

Therefore, $f_{HTL}(n)=2\cdot f_{HTL}(n-1)+2^{n-1}\cdot n$ and $\alpha_n=\alpha_{n-1}+\dfrac{n}{2}$. Clearly, $\alpha_n=\dfrac{n^2+n}{4}$.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
john0512
4188 posts
#99
Y by
We first compute $L(1)=1/2, L(2)=3/2, L(3)=3, L(4)=5$ by going through all possible cases. This leads us to the following claim:

Claim: $L(n)=\frac{n(n+1)}{4}.$ We will show this by induction. We have already seen that this is satisfied for $n=1,2,3,4.$

Case 1: The string starts with H. Then, the expected number of moves is $L(n-1)+1$ since it will take on average $L(n-1)$ moves to make everything after it T and 1 additional move to finish.

Case 2: The string ends with T. Then, the expected number of moves is $L(n-1)$ since the final $T$ has no effect.

Case 3: The string starts with H and ends with T. Then, the expected number of moves is $L(n-2)+1$, since it takes $L(n-2)$ moves to convert the middle part into T's and one more move to finish.

Case 4: The string starts with T and ends with H. Then, it will take $L(n-2)$ moves to turn it into $TTT\cdots H$, and then another $n-1$ moves to turn it into $HHH\cdots H$, and $n$ moves to finish, so it will take expected $L(n-2)+2n-1$ moves.

Note that by PIE, (Case 1 + Case 2 - Case 3) covers all cases where it either starts with H or ends with T. Therefore, (Case 1 + Case 2 - Case 3 + Case 4) exactly covers all possible cases. Therefore, we have $$L(n)=\frac{1}{2}(L(n-1)+1)+\frac{1}{2}(L(n-1))-\frac{1}{4}(L(n-2)+1)+\frac{1}{4}(L(n-2)+2n-1).$$By our inductive hypothesis, we plug in $L(n-2)=\frac{(n-2)(n-1)}{4}$ and $L(n-1)=\frac{(n-1)n}{4},$ we get $$L(n)=\frac{n(n+1)}{4},$$so we are done by induction. Note that this also solves part (a) since if any case is infinite, then the expected value is infinite, contradiction.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
huashiliao2020
1292 posts
#100
Y by
ah... the Bank of Bath problem. not sure why it's named that, nor why i feel like it had to say Oslo in it somewhere, and also glad that i solved it because i thought it was notorious for being some 50 MOHS but apparently not

We claim the expected value of the process, $p_n$, is $\frac{n(n+1)}{4}$. We will proceed by induction, with base case $p_1=\frac12$. Here's the subcases in the induction:

(1) Ends in tails: This has average $p_{n-1}$.
(2) Starts in heads: This has average $p_{n-1}+1$ (since we can ignore the first coin and the process is the same, plus 1 when you need to flip the first at the end).
(3) Starts in tails, ends in heads: This is the same as starting in heads, ending in tails (call this situation (4)), because indices in the middle string are the same, except when you flip the first heads, instead of being all tails, it is HTT...TH, which takes another 2(n-1) flips (easily checked manually, by say induction on the number of Ts).

Then $$2^np_n=(1)+(2)+(3)-(4)=2^{n-1}p_{n-1}+2^{n-1}(p_{n-1}+1)+2^{n-2}((3)-(4))=2^np_{n-1}+2^{n-1}+2^{n-1}(n-1)\implies p_n=p_{n-1}+\frac n2=\frac{n(n+1)}{4},$$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.
bryanguo
1032 posts
#106 • 1 Y
Y by aryabhata000
solved and wrote up (a) before (b) but whatever

We first prove that the procedure always terminates. For sake of convenience, denote $H=1$ and $T=0.$ We use induction to prove that for any starting position, the sequence eventually becomes a string of $1$'s followed by a string of $0$'s, which obviously terminates.

For base case $n=1,$ this is obviously true. For inductive step, assume that for $k$ coins, our hypothesis holds. Then, for $k+1$ coins, consider cases depending on if the first coin is $1$ or $0.$

If the first coin is $1,$ the rest of the coins represent a binary string of length $k,$ which from inductive assumption we know terminates. In this situation, all the indices of the binary string of length $k$ after the first coin flip are shifted up by $1,$ but since the first coin is has value $1,$ the total number of $1$'s is also shifted up by $1.$ Therefore, the procedure in this case will be identical to the procedure for the binary string of length $k$ until the final step, at which we change the $1$ at the first index to a $0.$ Thus all strings starting with a $1$ terminate.

If the first coin is $0,$ insert a coin in front of the first coin with label $1.$ Then, since we know any string starting with a $1$ terminates with the string after the initial $1$ terminating completely first, it follows the string of length $k$ after the $1$ we inserted must terminate, as desired. It remains to determine the average number of steps it takes for the process to terminate, over all configurations.

Let $f(n)$ be the average number of steps it takes for the process to terminate for a string of length $n.$ We prove that $f(n)=\tfrac{n(n+1)}{4}.$ Testing the first few cases, we find $f(1)=\tfrac{1}{2},$ $f(2)=\tfrac{3}{2},$ $f(3)=3,$ $f(4)=5.$ Proceed by strong induction. The base cases are evident as described. For inductive step, assume $f(k)=\tfrac{k(k+1)}{4}$ for a string of length $k.$ Then we prove that this holds for $k+1.$ Consider the following cases:
  • If the sequence starts with a $1,$ then we have $f(k)+1.$
  • If the sequence ends with a $0,$ then we have $f(k).$
  • If the sequence starts with a $1$ and ends with a $0,$ observe the trailing zero once again does not do anything. The starting $1$ also does not change the operations performed of the $k$ trailing digits. Then in this case we have $f(k-1)+1,$ where the $+1$ accounts for the deletion of the initial $1.$
  • If the sequence starts with a $0$ and ends with a $1,$ observe that the final $1$ shifts the total number of $1$'s in the string up by $1,$ and the initial $0$ increases the index of each of the trailing $k$ numbers by $1.$ Thus it takes $f(k-1)$ operations to get to a string of $0$'s followed by one $1.$ At this point, it takes $2k+1$ operations to complete the process. Thus in this case we have $f(k-1)+2k+1.$
Now, by Principle of Inclusion and Exclusion,
\begin{align*}
f(k+1)&=\frac{1}{2}(f(k)+1)+\frac{1}{2}(f(k))-\frac{1}{4}(f(k-1)+1)+\frac{1}{4}(f(k-1)+2k+1) \\
&=\frac{(k+1)(k+2)}{4}.
\end{align*}This completes the induction.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Mr.Sharkman
500 posts
#107
Y by
I thought this one was really nice
Solution
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
shendrew7
796 posts
#108
Y by
Let the desired answer be $a_n$, which we will prove is $\boxed{\frac{n^2+n}{4}}$ through recursion. Note the ending state contains all tails.

It's easy to get the base cases $a_1 = \tfrac 12$ and $a_2 = \tfrac 32$. For $n \ge 3$, we use casework on the first and last flip:
  • Starts with $T$, ends in $H$: Notice the ending $H$ will never be changed until all $n$ flips are heads, and this stage cannot be reached without changing the leading $T$, which only occurs after we have the middle $n-2$ flips are tails as well. Hence we expect $a_{n-2} + (n-1) + n$ moves in this case.
  • Start with $H$ or ends in $T$: We use PIE:
    • Starts with $H$: Never gets changed until the final $n-1$ coins are tails, so we expect $a_{n-1}+1$.
    • Ends with $T$: Never changed, so we expect $a_{n-1}$.
    • Both: Using our previous analysis, we get $a_{n-2}+1$.
Thus our recursion is
\[a_n = \tfrac 14 (a_{n-2} + 2n-1) + \tfrac 12 (a_{n-1}+1) + \tfrac 12 (a_{n-1}) - \tfrac 14 (a_{n-2}+1) = a_{n-1} + \tfrac n2,\]
from which we get the desired closed form. $\blacksquare$
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
blueprimes
355 posts
#109
Y by
Not sure if anybody posted this sol yet

Let $E(n)$ be the wanted expected value, we claim that $E(n) = \dfrac{n(n +1)}{4}$ which is indeed finite and thus all configurations terminate. To prove this we induct, the $n = 1$ case is obvious. Now assume this is true for some $n$, and consider an arbitrary sequence $S$ of $n + 1$ coins.

First, we consider when the last coin is $H$. Define the inverse of a row of coins as the result when all the coins are flipped and orderly reversed. For example, the inverse of $HHTTH$ is $THHTT$. Moreover, let $P$ be the sequence of the first $n$ coins in $S$, and let $Q$ be the inverse of $P$.

If a row of coins has $h$ instances of $H$, define the operations:
  • $f$ as flipping coin $h$.
  • $g$ as flipping coin $h + 1$.
Claim 1: $g^k(P)$ is the inverse of $f^k(Q)$ for all positive integers $k$.

Proof. It is sufficient to show for $k = 1$, then iterating yields the claim. Suppose $P$ has $h$ instances of $H$. Then $g(P)$ has coin $h + 1$ flipped, so its inverse is $Q$ with coin $(n + 1) - (h + 1) = n - h$ flipped. On the other hand, $Q$ has $n - h$ instances of $H$, so $f(Q)$ is $T$ with coin $n - h$ flipped. So they are equivalent.

Note that the inverse of the all-$H$ sequence is all-$T$. Now since applying $f$ onto $S$ applies $g$ onto $P$, the number of steps until it reaches the all-$H$ sequence is the same number of steps for $Q$ to reach the all-$T$ sequence. But since the inverse property is a bijection, the average number of such steps is simply $E_n$. There is an additional $n + 1$ steps to go from all-$H$ to all-$T$, so the cumulative expected value is $E_n + n + 1$.

Now when the last coin is $T$, it is unaffected, and the average over all these cases is $E_n$.

We have $E_{n + 1} = \dfrac{1}{2}(E_n + E_n + n + 1) = \dfrac{n(n + 1)}{4} + \dfrac{n + 1}{2} = \dfrac{(n + 1)(n + 2)}{4}$ and the induction is finished. It is done.
This post has been edited 1 time. Last edited by blueprimes, Sep 19, 2024, 7:19 PM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Maximilian113
575 posts
#110
Y by
We claim that the expected value of $L(C)$ over all possible $2^n$ configurations of length $n$ is $\frac{n(n+1)}{4}.$ This will prove part (a), since this value is finite, and finish part (b).

Let $e_n$ be the answer for $n,$ $a_n$ be the expected value for a sequence of length $n$ that ends with $H,$ and let $b_n$ be the expected value for a sequence of length $n$ that ends with $T.$ Observe that $e_n = \frac12 (a_n+b_n).$

Now, suppose that $n \geq 3.$ Clearly, from $a_n,$ if the sequence starts at $T$ we can ignore the front and end of the sequence temporarily, and we will have on average $e_{n-2}$ operations for the middle $n-2$ coins to all become $T.$ Then, there will be $n-1$ operations to turn everything into $H,$ and finally $n$ operations to turn everything into $T.$

However, if from $a_n$ the sequence starts at $H,$ we are essentially in the same situation as $a_{n-1}$ by ignoring the first coin, and then one more operation is required to turn the first $H$ into a $T.$ Therefore, $$a_n=\frac12 (e_{n-2}+2n-1)+\frac12 (a_{n-1}+1) = n+\frac12 e_{n-2}+\frac12 a_{n-1}.$$
Meanwhile, it is easy to see that $$b_n=e_{n-1}=\frac12 (a_{n-1}+b_{n-1}).$$
Therefore, $$a_n = n+\frac12(b_{n-1}+a_{n-1})=n+b_n.$$Substituting this into the second recurrence yields $$2b_n = n-1+2b_{n-1} \implies 2(b_n-b_{n-1})=n-1 \implies 2(b_n-b_2)=(n-1)+(n-2)+\cdots+3+2.$$Therefore, $b_n=\frac{n(n-1)}{4}.$ From here, we have that $$e_n=\frac12(n+2b_n)=\frac{n(n+1)}{4}.$$QED
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
cursed_tangent1434
634 posts
#111
Y by
First we compute the following.

Claim : The number of steps it takes to reach $n$ $T$s from $n$ $H$s is exactly $n$.

Proof : Clearly in each step the last coin turns from $H$ to $T$ since we go from $n$ $H$s to $0$ $H$s. Thus, we take
\[HH\dots H \longrightarrow HH \longrightarrow \dots 
    \longrightarrow HT \dots H TT\dots T \longrightarrow TT\dots TT\]which takes exactly $n$ steps.

Let $M_n$ be the total sum of steps taken over all $2^n$ configurations to terminate. Now, we make the following key observation.

Claim : Let a certain pair of configurations of coins
\[[a_1 a_2 \dots a_{n-1}] H - [b_1 b_2 \dots b_{n-1}] T 
    \]be \textit{paired} if for the first $n-1$ coins, exactly one of $a_i$ and $b_{n-i-1}$ is tails and the other is head.
We claim that a pair of configurations remain paired until they reach their ends states (all $H$ and all $T$).


Proof : Assume that before a certain move these are paired. Then, note that if we have $i$ Heads in $[a_1 a_2 \dots a_{n-1}] H$, then we have $n-1-i$ Heads in $[b_1 b_2 \dots b_{n-1}]T$ since the places which have Heads in the configuration paired to this has exactly $i-1$ Heads in places besides the final $H$.
Now, note that this means we swap Position $i$ and Position $n-i-1$ respectively of these two configurations. Thus, before the move one of Position $i$ and $n-i-1$ had Heads and the other Tails, and since both are flipped in this move, this condition still holds.

Thus, if a pair of configurations is paired (each configuration has a unique partner obviously) then they are paired until the end.

Thus, the sum of moves taken by the configurations ending with $H$ to reach the all $H$ state is equal to the total number of moves taken by a configuration ending with $T$ to reach the all $T$ state. But this is just $M_{n-1}$. Thus, the sum of steps taken by all configurations ending with $H$ to reach all $H$ is $M_{n-1}$ from which each configuration takes exactly $n$ steps to finish. Thus, we have a total number of steps,
\[M_{n} = 2M_{n-1} + 2^{n-1}n\]Now, it is easy to show that this recursion gives,
\[M_n = 2^{n-2}n(n+1)\]which makes the average number of steps taken to reach termination state over all $2^n$ configurations just
\[\frac{2^{n-2}n(n+1)}{2^n} = \boxed{\frac{n^2+n}{4}}\]
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
eg4334
637 posts
#112
Y by
Phenomenal problem, I think my solution is different than most above and very weird. I claim the answer is $\boxed{\frac{n(n+1)}{4}}$. In particular, I will prove that the sum of the number of operations over all permutations is $2^n \frac{n(n+1)}{4}$, implying the result.

\begin{tabular}{|c c c c c c c c|} 
 \hline
 HHH & HTH & THH & TTH & HHT & HTT & THT & TTT \\ [0.5ex] 
 \hline \hline

 HHT & HHH & TTH & HTH & HTT & TTT & HHT & . \\ 
 \hline
HTT & HHT & HTH & HHH & TTT & . & HTT & .\\
\hline
TTT & HTT & HHH & HHT & . & . & TTT & .\\
\hline
. & TTT & HHT & HTT & . & . & . & . \\
\hline
. & . & HTT & TTT & . & . & . & . \\
\hline
. & . & TTT & . & . & . &. & . \\
\hline
\end{tabular}Above is the table for $n=3$. I proceed part a) using induction. The base case is trivial. If the statement is true for $k$, then it is obviously true for $k+1$ in the cases where the string ends in a tail. This is because we can essentially ignore the tail at the end, reducing the string length down. For the ones that end in heads, looking at the table above we can make a crucial claim.

Claim: For those which end in heads, the string of sequences until it reaches the all heads position is identical to one that ends in tails except with the sequences flipped across the midpoint of the sequence not including the last head and with the heads and tails inverted.
Proof: First let's understand the claim. Looking at $TTH$ for example, the sequence up to $HHH$ is identical to that of $HHT$ up to $TTT$. However, every step of the sequence has the last coin different and the rest are reflected and inverted. For example, the $TT$ are related to $HH$ in that the $TT$ is reflected across its midline to obtain $TT$ and then the heads and tails are inverted. As another example, notice how $TTHH$ gets to $HHHH$ in the same amount of flips as $THHT$ gets to $TTTT$. This is because $TTH$ reflected is $HTT$ which when inverted becomes $THH$ as desired. To prove this claim, let there be $x$ heads in the first $n-1$ coins of a sequence that ends in heads. Then, the resulting sequence will consist of us flipping the $x+1$th coin. In our reflected and inverted sequence that ends in tails, we now have $n-1-x$ heads. Thus, we flip the $n-1-x$th coin. Note that these are symmetric across the midline because $$(x+1) + (n-1-x) = (1) + (n-1)$$Therefore, the sequences will always be analogous under our reflection and inversion and thus will take the same amount of flips to get to either all $H$ or all $T$'s. $\blacksquare$

Now part a) is done, because we have shown that all of the ones ending in $H$ get to all $H$ in the same amount of flips that the ones ending in $T$ take to get to all $T$ (note that once we get all $H$ the sequence is guarenteed to finish). To do part b), proceed again by induction: $$\frac{n(n+1)}{4} \cdot 2^n \cdot 2 + 2^n (n+1) = 2^{n+1} \cdot \frac{(n+1)(n+2)}{4}$$is an identity so we are done (the $n+1$ comes from the $n+1$ moves it takes to get from all $H$ to the finish).
This post has been edited 1 time. Last edited by eg4334, Dec 23, 2024, 10:04 PM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
abeot
126 posts
#113 • 1 Y
Y by centslordm
I claim the answer is $\frac{n(n+1)}{4}$, which would imply the process terminates. We prove the statement by induction on $n$, with base case $n = 1$ trivial. Hence, assume $n \ge 2$, and let the answer for $n = m$ be $a_m$, so $a_1 = \frac 12$.

Claim: If the last coin is $T$, then the process takes an average of $a_{n-1}$ steps.
Proof. The last coin never changes; if it could, take the first instance it becomes heads. Then the previous instance must have had $n$ heads, contradicting minimality of time.
Thus, by the inductive hypothesis on the first $n-1$ coins, it takes $a_{n-1}$ steps, on average. $\square$

Claim: If the last coin is $H$, then the process takes $a_{n-1} + n$ steps.
Proof. Let the first $n-1$ coins be $s_1$, $s_2$, \dots, $s_{n-1}$. Define coins $t_1$, $t_2$, \dots, $t_{n-1}$ such that \[ s_i \text{ heads } \iff t_{n-1-i} \text{ for all } i = 1, 2, \dots, n-1 \](in the natural binary string interpretation, $t$ is the reverse of the inverse of $s$).
The key fact is that the condition on the $t_i$ holds. Suppose initially, $k$ of the $s_i$ are heads. Then $n-1-k$ of the $t_i$ are heads. Flip $s_k$ and $t_{n-1-k}$, and note
  • If $s_k$ was heads then $t_{n-1-k}$ was tails. After the flip, then $s_k$ is tails and $t_{n-1-k}$ is heads.
  • If $s_k$ has tails then $t_{n-1-k}$ was heads. After the flip, then $s_k$ is heads and $t_{n-1-k}$ is tails.
Either way, the condition still holds. Yet we know the $t_i$ must become all tails with an average of $a_{n-1}$ steps, by the inductive hypothesis. Thus, the $s_i$ become all heads in an average of $a_{n-1}$ steps.
So after an average of $a_{n-1}$ steps, all the $n$ coins are heads. Clearly after $n$ steps then we arrive at all tails. $\square$

We finish by computing \[ a_n = \frac{2^{n-1}}{2^n}\cdot a_{n-1} + \frac{2^{n-1}}{2^n}\cdot (a_{n-1} + n) = a_{n-1} + \frac n2 = \frac{n(n+1)}{4} \]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.
mathwiz_1207
100 posts
#114
Y by
Beautiful problem! We will first prove that no matter what, the sequence terminates. Define a reduction as a sequence of moves which changes exactly $1$ coin with $H$ facing up into a $T$ facing up, and leaving all other coins unchanged. We claim that in any situation, if there are $k > 0$ coins, we can obtain a reduction.

Define a coin at index $i$ to be the $i^{th}$ coin from the left. Assume that the coins with $H$ facing upwards have indices of $a_1, a_2, \dots a_k$, with
\[a_1 < a_2 < \dots < a_k\]Obviously, $a_k \geq k$. Now, let $a_j$ be the index of the first coin with $H$ facing upwards and $a_j \geq k$ (there exists such a $j$ since $a_k \geq k$). If $a_j = k$, we immediately obtain a reduction. Otherwise, consider the following sequence of moves (the subscript represents the index of the coin):
\[\underset{k}TT\dots T \underset{a_j}{H} \rightarrow \underset{k}HT\dots T \underset{a_j}{H}\]Now, there are $k + 1$ coins, so we move from
\[\underset{k}HT\dots T \underset{a_j}{H} \rightarrow \underset{k}{H}H\dots T \underset{a_j}H\]We see that we keep doing the moves until we reach
\[\underset{k}HH\dots H \underset{a_j}{H}\]this takes ($a_j - k$) steps. There are now $k + a_j - k = a_j$ coins with $H$ facing up, so doing a move now gets us to
\[\underset{k}HH\dots H \underset{a_j}{H} \rightarrow \underset{k}HH\dots H\underset{a_j}T\]Once again, we can keep doing moves until we eventually reach
\[\underset{k}TT\dots T \underset{a_j}{T}\]which takes $(a_j - k + 1)$ moves. Therefore, this sequence of moves is indeed a reduction, since the coin at index $a_j$ is now a $T$, and everything else is unchanged. Therefore, we can keep performing reductions until we obtain no heads.

Now, notice that each reduction takes exactly $2(a_j - k) + 1$ moves if there are $k$ coins. Therefore, to go from $k$ coins to $0$ coins, it would take
\[2\sum_{i=1}^k a_ i - 2\sum_{i=1}^ki + k = 2\sum_{i=1}^k a_ i - k^2\]steps. Now, if we sum this over all possible arrangements of the $k$ coins, this is equal to
\[-k^2 \cdot {n \choose k} + 2\sum_{i=1}^ni\cdot{n - 1 \choose k - 1} = n(n+1){n -1 \choose k-1} - nk{n-1 \choose k-1}\]Now, summing this over all possible values of $k$,
\begin{align*}
S &= \sum_{k=0}^n\left[n(n+1){n -1 \choose k-1} - nk{n-1 \choose k-1}\right] \\
&= n(n+1)\sum_{k=0}{n-1 \choose k -1} - n \sum_{k=0}^n k {n-1 \choose k - 1} \\
&= n(n+1)\cdot 2^{n-1} - n \cdot (n+1)2^{n-2} \\
&= n(n+1) \cdot 2^{n-2} \\
\end{align*}Therefore, the average number of steps over all $2^n$ sequences is
\[\frac{n(n+1) \cdot 2^{n-2}}{2^n} = \boxed{\frac{n(n+1)}{4}}\]and we are done.
This post has been edited 1 time. Last edited by mathwiz_1207, Jan 15, 2025, 2:44 AM
Reason: formatting
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
zuat.e
59 posts
#115
Y by
Solution: $\frac{n(n+1)}{4}$

For the first part, suppose we are making moves until we have to turn a $T$ into an $H$ (if not we'd eventually have $HHHH \dots H$, which will clearly terminate).

After that first move, we will create a chain of $H$'s until we get to an $H$, which will be turned into a $T$ (say $k$ $H$'s), hence we will then have a chain of, at least, $k+1$ $T$'s until we reach a $T$ which will be transformed into an $H$ and so we will have a chain of at least $k+2$ $H$'s before we have to turn again...
The length of the chain is strictly increasing (except if it terminates), but its length must be $\leq n$, so it must terminate.

For the second part, we prove by induction that the average is $av=\frac{n(n+1)}{4}$. We have to prove some claims before though.

Claim 1: There're $n2^{n-1}$ $T$'s over all $2^n$ configurations

Proof:
There are $n2^n$ total letters and half are $T$'s and half are $H$'s, hence the total amount of $T$'s is $T_t=n2^{n-1}$.

Claim 2: Suppose we add a final $H$ to a configuration $c$, which takes $k$ steps, then this new configuration will take $k+2t+1$ steps, where $t$ is the amount of $T$'s on $c$. Moreover, if we instead add a final $T$, the amount of steps doesn't change
Proof:
We prove by strong induction on $n$ an stronger result actually: if we add $l$ $H$'s, then we will have $k+2tl+l$. If $l=1$, the claim is achieved. Case $n=2$ is trivial. Suppose it for $1,2, \dots ,n$ and consider a configuration of $(n+1)$ coins: if it finishes on an $H$, it will have $2t+1$ more than the previous $(n-1)$ configuration (which will have $(k-2t-1)$, hence in that $(n-1)$ config, we add $(l+1)$ $H$'s, getting $k+2tl+l$, as desired.
If it finishes on a $T$'s eliminate them all and suppose that config takes $k$ steps. We add an $l$ $H$, so we have $k+l+2l(t-1)$ as a result. Then, we add that remaining $T$ we removed before, which will increase the number of steps by 2 for each $H$, summing a total of $k+2lt+l$.
The adding of the 2 for each $H$ is due to the following:
Let's consider the first configuration without that $T$: Whenever it gets to the $H$ that will go in the place of the $T$, it will go down $a_1$ steps, then it will go up $a_1+1$ steps, then it will go down $a_2$ and up $a_2 +1$, \dots for all $l$ $H$'s, summing in that part up to $2\sum_{i=1}^la_i+l$.
Whilst in the other configuration (with the $T$), it happens the following. As the $T$ doesn't affect the number of $H$'s, it will all go in the same way until we reach that $T$, which will turn into an $H$, then the next $H$ will turn into an $H$ and go down $a_1+1$ steps and up $(a_1+1)+1=a_1+2$, again down $a_2+1$ and up $a_2+2$, summing in that part up to $2\sum_{i=1}^la_i+3l$, as desired.

Now, we finish by induction. Suppose $av(n)=\frac{n(n+1)}{4}$, then by adding a final $H$ and $T$ to every of the $2^n$ configurations, we have:
$av(n+1)=av(n)+\frac{2T_t+2^n}{2^{n+1}}=\frac{n(n+1)}{4}+\frac{n+1}{2}=\frac{(n+1)(n+2)}{4}$, as desired.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
de-Kirschbaum
201 posts
#116
Y by
Let $H=1, T=0$. We will prove that there exists a bijection between the cases where the rightmost bit is $1$ and the cases where the rightmost bit is $0$.

We will construct a operation preserving bijection $$f:\textrm{binary sequences of length n ending in 1} \to \textrm{binary sequences of length n starting with 0}$$
Where we flip each bit in the sequence and then flip the entire sequence, so for example $f(0001)=0111$ via $0001 \rightarrow 1110 \rightarrow 0111$. This $f$ is clearly invertible so this must be a bijection. Then, we perform the same process but we add 1 to the number of 1s in the sequence since we are now guaranteed a $0$ in the first digit. For example, $0111 \rightarrow 0110$. This modification is the same as the old process because all the 1s used to be 0s, so pretransformation we would flip the $s$th bit where $s$ is the number of 1s on the board and $s\leq n-1$. Now we are flipping the $n-s+1 \geq 1$st bit which is the $s$th bit counting from the right to left, and clearly flipping the sequence back once again shows these are the same bits. The first bit (which is the last bit pretransform) is never touched.

Noting these two properties we can prove that this bijection is indeed operation preserving: ie $A \rightarrow B \iff f(A) \rightarrow f(B)$. If $A \rightarrow B$, suppose the $s$th bit gets flipped, then we know that from $f(A) \rightarrow f(B)$ the $n-s+1$st bit gets flipped. Undoing the transformation we see that $f(B)$ gives $B$. Similarly, we can see that if $f(A) \rightarrow f(B)$ then $A \rightarrow B$.

Note that $f(1111\ldots 1)=000\ldots0$ and the new process is just the old process on the $n-1$ bits indexed from 2 to $n$.

Now we will prove termination. Let us denote directed graph $G_i$ as the states tree of this process for $i$ coins. Drawing the base case $i=1,2$ we see that the $G_1, G_2$ are cycleless.

Assume that $G_k$ is cycleless. Then $G_{k+1}$ has two components. The states tree for all sequences ending in 0 is the same as the states tree $G_{k}$ just with a 0 tagged onto the end of each vertex. The states tree of the transformed sequences ending in 1 is the same as the states tree $G_{k}$ just with a 0 tagged onto the beginning of each vertex. The two states trees are glued together via $1111\ldots 11 \rightarrow 1111 \ldots 10$. Thus, $G_k$ is cycleless.

This means that if we let $E[X_n]$ be the expected number of steps taken for $n$ coins, then $$E[X_n]=\frac{2E[X_{n-1}]+n}{2}=E[X_{n-1}]+\frac{n}{2}$$with $E[X_1]=\frac{1}{2}$ so substituting we see that $E[X_n]=\frac{n(n+1)}{4}$.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Ihatecombin
60 posts
#117
Y by
It suffices to prove part (b) by itself, since solving part (b) will clearly imply part (a). We claim the average value of \(L(c)\) is equal to \(\frac{n(n+1)}{4}\). We shall prove this by strong induction, the base case where \(n=1\) and \(n=2\) is easy. Define \(S(n)\) as the sum over all of the \(2^n\) \(L(c)\) where \(C\) is some arbitrary configuration of length \(n\).

We shall split the \(2^n\) configurations into \(3\) cases, namely the case where \(T\) is at the end of the configuration, the case where the first letter is \(H\) and the last \(H\), finally the case where \(T\) is the first letter and \(H\) is at the end.

Claim 1: The sum of the \(L(C)\) for the case where \(C\) has \(T\) as a final letter is \(S(n-1)\)
Proof:
Obvious. Since the amount of \(H\) can be at most \(n-1\), the final coin will never be flipped. $\blacksquare$

Claim 2: The sum of the \(L(C)\) for the case where \(C\) has \(H\) as a final letter and \(H\) as a first letter is \(S(n-1) - S(n-2) + 2^{n-2}\)
Proof:
Notice that the first coin will be flipped if and only if the state of the configuration is all \(T\). So we can just ignore the \(H\) as the first letter momentarily and
sum of moves that is required over all the \(2^{n-1}\) configurations of \(n-1\) coins with the final coin being \(H\).

We know that the sum of scores where the final coin is arbitrary is \(S(n-1)\), we also know that the sum of moves that is required over all the \(2^{n-1}\) configurations of \(n-1\) coins with the final coin being \(T\) is \(S(n-2)\) (since we can just ignore that final coin).
Thus the sum of the moves that is required over all the \(2^{n-1}\) configurations of \(n-1\) coins with the final coin being \(H\) is \(S(n-1) - S(n-2)\), notice that at this point all the coins will be of the form \(HTTT \cdots T\), thus they only require one move to make all the coins be flipped on the \(T\) side, since there are \(2^{n-2}\) coins which have \(H\) as a final and first letter, it follows that our claim is true. $\blacksquare$

Claim 3: The sum of the \(L(C)\) for the case where \(C\) has \(H\) as a final letter and \(T\) as a first letter is \(S(n-2) + 2^{n-2}(2n-1)\)
Proof:
Notice that the final letter can be converted into a \(T\) if the series of coins is of the form \(HHHH \cdots HHH\), since the only way for the first coin to be flipped is if the series of coins is of the form \(TTTTT \cdots TTH\), this motivates us to count the amount of moves required to make all initial configurations of coins in this class become of the form \(TTTTT \cdots TTH\). Since the final letter \(H\) will never be flipped before the coin becomes of the form \(TTTTT \cdots TTH\), it is obvious that this sum will be \(S(n-2)\).

Once a series of coins has reached this point, there are clearly exactly \(2n-1\) moves needed for it to become \(TTT \cdots TTT\) since all the coins have to become \(H\) first and then they have to become all \(T\), this requires exactly \(2n-1\) moves from this position, note that there are \(2^{n-2}\) coins in this class.
Thus the total sum for series of this class is \(S(n-2) + 2^{n-2}(2n-1)\). $\blacksquare$

Thus by summing the results of our \(3\) claims we obtain a recursion relation for our function \(S(n)\), which is
\[S(n) = 2S(n-1) + 2^{n-2} \cdot 2n \ \text{for all \(n \geq 3\)}, \quad S(1) = 1, \quad S(2) = 6\]It is easy to see that this is fulfilled by \(S(n) = (n)(n+1) \cdot 2^{n-2}\).
Z K Y
N Quick Reply
G
H
=
a