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
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
Equilateral pentagon with four right angles
Miquel-point   1
N a few seconds ago by loup blanc
Source: KoMaL B. 5396
An equilateral pentagon in the three-dimensional space has four right angles. What can be its fifth angle?

Proposed by Péter Dombi, Pécs
1 reply
Miquel-point
Jun 11, 2024
loup blanc
a few seconds ago
2024 PMO Part II #2
orangefronted   3
N 4 minutes ago by BinariouslyRandom
Determine all positive integers $k$ less than 2024 for which $4n+1$ and $kn+1$ are relatively prime for all integers $n$.
3 replies
orangefronted
Jan 16, 2024
BinariouslyRandom
4 minutes ago
Right tetrahedron of fixed volume and min perimeter
Miquel-point   1
N 12 minutes ago by Mathzeus1024
Source: Romanian IMO TST 1981, Day 4 P3
Determine the lengths of the edges of a right tetrahedron of volume $a^3$ so that the sum of its edges' lengths is minumum.

1 reply
+1 w
Miquel-point
Apr 6, 2025
Mathzeus1024
12 minutes ago
Functional equation
shactal   2
N 22 minutes ago by shactal
Source: Own
Hello, I found this functional equation that I can't solve, and I haven't got any hints. Could someone try and find the solution, it's actually quite difficult:
Find all continuous functions $f:\mathbb{R}\to \mathbb{R}$ such that, for all $x, y \in \mathbb{R} $,
$$
f(x + f(y)) + f(y + f(x)) = f(x \, f(y) + y \, f(x)) + f(x + y)$$Thank you.
2 replies
1 viewing
shactal
Yesterday at 11:15 PM
shactal
22 minutes ago
At least One pair with square of distance multiple of 2016
Johann Peter Dirichlet   5
N 39 minutes ago by ja.
Source: 38th Brazilian MO (2016) - First Day, Problem 2
Find the smallest number \(n\) such that any set of \(n\) ponts in a Cartesian plan, all of them with integer coordinates, contains two poitns such that the square of its mutual distance is a multiple of \(2016\).
5 replies
Johann Peter Dirichlet
Nov 23, 2016
ja.
39 minutes ago
A symmetric inequality in n variables (3)
Nguyenhuyen_AG   1
N an hour ago by lbh_qys
Let $a_1,a_2,\ldots,a_n (n \geqslant 1)$ be non-negative real numbers. Prove that
\[\sum_{i=1}^n \frac{\displaystyle a_i^2 \left( \sum_{j=1}^n a_j - a_i \right)^2}{\displaystyle \sum_{j=1}^n a_j^2 - a_i^2} \geq \left(\sum_{i=1}^n a_i\right)^2 - \sum_{i=1}^n a_i^2.\]Assume all denominators are non-zero.
1 reply
Nguyenhuyen_AG
3 hours ago
lbh_qys
an hour ago
shortlisted problems being used in undergraduate competition
enter16180   0
an hour ago
Hello, I am posting here to let know ( clarified after a post in College Math forum) that Problem 10 of Open Mathematical Olympiad for University Students ( OMOUS-2025) held at Ashgabat, Turkmenistan on 13-18 April, 2025 is found to be A6 Shortlisted Problems IMO-2024.
Following is discussion on College Math Forum
https://artofproblemsolving.com/community/c7h3551018_omous2025_team_competition_p10


Image of problem from competition for reference below.
0 replies
enter16180
an hour ago
0 replies
Four variables
Nguyenhuyen_AG   0
an hour ago
Let $a,\,b,\,c,\,d$ non-negative real numbers. Prove that
\[\frac{abc}{(a+b+c)^3}+\frac{bcd}{(b+c+d)^3}+\frac{cda}{(c+d+a)^3}+\frac{dab}{(d+a+b)^3} \leqslant \frac{(a+b+c+d)^2}{27(a^2+b^2+c^2+d^2)}.\]
0 replies
Nguyenhuyen_AG
an hour ago
0 replies
Probability Inequality
EthanWYX2009   0
an hour ago
Source: 2024 June 谜之竞赛-5
Determine the minimum real number \(\lambda\) such that for any $2024$ real numbers \(a_1, a_2, \cdots, a_{2024}\) satisfying
\[\sum_{i=1}^{2024} a_i = 0,\quad\sum_{i=1}^{2024} a_i^2 = 1,\]there exists a non-empty subset \(I\) of \(\{1, 2, \cdots, 2024\}\) for which
\[\sum_{i\in I} a_i \leq \lambda \cdot \min\{|I|, 2024 - |I|\}.\]Proposed by Tianqin Li, High School Affiliated to Renmin University of China
0 replies
EthanWYX2009
an hour ago
0 replies
Elegant Geometry Problem
EthanWYX2009   0
2 hours ago
Source: 2024 June 谜之竞赛-2
Let \( I \) be the incenter of \(\triangle ABC\). The incircle tangents to \( AC \), \( AB \) at \( E \), \( F \), respectively. Let \( EF \) intersect \( BC \) at \( P \). \(\odot BEP\) and \(\odot CFP\) intersect again at \( Q \). Let \( M \) be the midpoint of the arc \( BC \) of \(\odot ABC\). \(\odot MPQ\) intersects \(\odot ABC\) again at \( R \). Let \( H \) be the orthocenter of \(\triangle BIC\).

Prove that the intersection point of \( HR \) and \( QI \) lies on \(\odot MPQ\).

Proposed by Bohan Zhang, Shanghai Minban Huayu Middle School
0 replies
+1 w
EthanWYX2009
2 hours ago
0 replies
Non-polynomial sequences satifying m+n|a_m+a_n?
TUAN2k8   0
2 hours ago
Source: own
Consider a sequence of integers \((a_n)_{n>0}\) such that for every pair of distinct positive integers \((m, n)\), \(m + n\) is a divisor of \(a_m + a_n\).

a) Prove that \(a_n\) is divisible by \(n\) for every positive integer \(n\).

b) Does there exist a sequence \((a_n)_{n>0}\) that is not a polynomial in \(n\) (i.e., there does not exist a polynomial \(P(X) \in \mathbb{R}[X]\) such that \(a_n = P(n)\) for all \(n \in \mathbb{Z}_+\)) and satisfies the given condition?
0 replies
TUAN2k8
2 hours ago
0 replies
Fraction Part Inequality
EthanWYX2009   0
2 hours ago
Source: 2023 November 谜之竞赛-1
Let \( x \) be a real number.[list]
[*]Determine the maximum value of $ \left| \sum_{k=1}^{1012} \left(\{(2k-1)x\} - \{2kx\}\right) \right| $;
[*]Determine the maximum value of $\left| \sum_{k=1}^{1012} \left(\{kx\} - \{(k+1012)x\}\right) \right|$. [/list]
Proposed by Site Mu, Beijing 101 Middle School
0 replies
EthanWYX2009
2 hours ago
0 replies
Tricky Geometry
zqy648   1
N 2 hours ago by EthanWYX2009
Source: 2023 October 谜之竞赛-5
Given triangle \( ABC \), let \( P \) be a moving point inside the triangle such that \( \angle ABP = \angle ACP \). \( BP \), \( CP \) intersect \( AO \) at \( E \), \( F \) respectively, where \( O \) is the circumcenter of \( \triangle ABC \). The circle with diameter \( AP \) meet the circumcircle of \( \triangle BPC \) at another point \( Q \).

Show that there exist two fixed circles tangent to the circumcircle of \( \triangle QEF \).

Created by Sheng Lu
IMAGE
1 reply
zqy648
Jul 19, 2025
EthanWYX2009
2 hours ago
Help me prove these lemmas
dimi07   0
2 hours ago
In the name of God, the most Merciful, the most Compassionate.
Let $a,b,c$ $\in$ $\mathbb{Z}$,then prove the following
\[
a\mid c, b\mid c \implies lcm(a,b)\mid c.
\]And also prove that
\[
c\mid a,c\mid b \implies c\mid gcd(a,b)
\]And by the help of God I finish this question.
0 replies
dimi07
2 hours ago
0 replies
Sum of whose elements is divisible by p
nntrkien   47
N Jul 14, 2025 by mudkip42
Source: IMO 1995, Problem 6, Day 2, IMO Shortlist 1995, N6
Let $ p$ be an odd prime number. How many $ p$-element subsets $ A$ of $ \{1,2,\dots,2p\}$ are there, the sum of whose elements is divisible by $ p$?
47 replies
nntrkien
Aug 8, 2004
mudkip42
Jul 14, 2025
Sum of whose elements is divisible by p
G H J
Source: IMO 1995, Problem 6, Day 2, IMO Shortlist 1995, N6
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Spectator
657 posts
#35 • 4 Y
Y by OronSH, KevinYang2.71, KnowingAnt, cubres
Let $A(x,y)$ be the generating function
\[A(x,y) = (1+yx)(1+yx^2)\cdots(1+yx^{2p})\]We apply the roots of unity filter on $x$ to get
\[\frac{A(1,y)+A(w,y)+\cdots+A(w^{p-1},y)}{p} = \frac{(1+y)^{2p}+(p-1)(1+yw)\cdots(1+yw^{2p})}{p}\]We call this function on $y$, $B(y)$. Note that
\[(1+w)(1+w^2)\cdots(1+w^{p}) = 2\]Then, we apply the roots of unity filter on $y$ to get
\begin{align*}
    \frac{B(1)+B(w)+B(w^2)+\cdots B(w^{p-1})}{p} &= \frac{p+p\binom{2p}{p}+p+2^{2}(p-1)(p)}{p^2}
\end{align*}But, we need to subtract $2$ because it counts the empty set and the set with size $2p$. This gives us
\[\boxed{\frac{\binom{2p}{p}+2p-2}{p}}\]
This post has been edited 1 time. Last edited by Spectator, Nov 11, 2023, 3:50 PM
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
#36 • 1 Y
Y by cubres
Let $F(x,y)=\prod_{i=1}^{2p}(1+yx^i)$ be the gen func representing sums of subsets and their number of elements. Note that the answer is equal to \[\frac{1}{p^2}\left(\sum_{k=1}^p \sum_{k=1}^p F\left(e^{2\pi ij/p},e^{2\pi i k/p}\right)\right)-2\]by roots of unity filter, with the $-2$ coming from the empty set and $\{1,2,\dots,2p\}$ being included in this count. We thus compute this!!!
  • First, if $j=1,2,\dots,p-1$, then the sequence $j,2j,\dots, 2pj$ contains each residue modulo $p$ twice. Thus $j+k,2j+k,\dots, 2pj+k$ contains each residue twice. herefore, \[\sum_{k=1}^{p}F\left(e^{2\pi ij/p},e^{2\pi i k/p}\right)=p\prod_{k=1}^p \left(1+e^{2\pi i k/p}\right)^2=4p\]As \[\prod_{k=1}^p \left(1+e^{2\pi i k/p}\right)^2=\prod_{k=1}^p \left(-1-e^{2\pi i k/p}\right)^2=P(-1)^2=4\]in $P(x)=x^p-1$.
  • If $j=p$, then \[\sum_{k=1}^{p}F\left(1,e^{2\pi i k/p}\right)=p\sum_{k=1}^{p}F\left(1+e^{2\pi i k/p}\right)^{2p}\]By roots of unity filter on $(1+x)^{2p}$, we get that the above sum is $p\left(2+\binom{2p}{p}\right).$
Thus the total sum ignoring the division by $p^2$ and subtraction is \[p\left(2+\binom{2p}{p}\right)+4p(p-1)=p\binom{2p}{p}+4p^2-2p\]implying a final answer of \[\frac{p\binom{2p}{p}+4p^2-2p}{p^2}-2=\frac{\binom{2p}{p}-2}{p}+2.\]

Remark: N6 is crazy lol
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
blueprimes
387 posts
#37 • 1 Y
Y by cubres
We will create a generating function $f(x, y)$, where the coefficient $c_{i, j}$ of $x^i y^j$ represents the number of subsets $A \subseteq \{1, 2, \dots, 2p \}$ where the sum of the elements of $A$ is $i$, while $|A| = j$. By considering how many numbers we extract from each individual residue class, it is not hard to find that
$$f(x, y) = \prod_{n = 0}^{p - 1} (1 + 2x^ny + x^{2n}y^2) = \prod_{n = 0}^{p - 1} (1 + x^ny)^2.$$We will use a double roots of unity filter to add all coefficients $c_{i, j}$ where $p \mid i, j$, then subtract $2$ to account for the cases when $j = 0, 2p$. Let $\omega = e^{2 \pi i / p}$. We want to evaluate $\frac{1}{p^2} \sum_{r = 0}^{p - 1} \sum_{s = 0}^{p - 1} f(\omega^r, \omega^s)$. When $r \ne 0$, $f(\omega^r, \omega^s) = \left[\prod_{n = 0}^{p - 1} (1 + \omega^n) \right]^2 = 2^2 = 4$. All cases belonging to the latter yield a total of $4p(p - 1)$. On the other hand, when $r = 0$, we have $\sum_{s = 0}^{p - 1} f(1, \omega^s) = \sum_{s = 0}^{p - 1} (1 + \omega^s)^{2p}$. Using the binomial theorem, only the terms when the exponent of $\omega$ is divisible by $p$ are left behind, and we obtain $p \left[\binom{2p}{p} + 2 \right]$. Our final answer is
$$\frac{4p(p - 1) + p \left[\binom{2p}{p} + 2 \right]}{p^2} - 2 = \frac{\binom{2p}{p} - 2}{p} + 2.$$
This post has been edited 1 time. Last edited by blueprimes, Apr 29, 2024, 1:24 AM
Reason: omega definition
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
KnowingAnt
162 posts
#38 • 1 Y
Y by cubres
I think you only need one filter! We want to find the sum of the coefficients of $x^0y^p,x^py^p,x^{2p}y^p,\dots$ in
\[(1 + xy)(1 + x^2y)\dots(1 + x^{2p}y)\text{.}\]First fix $y$. Now let $\omega$ be a primitive $p$-th root of unity, we want the coefficient of $y^p$ in
\[\frac{P(1) + P(\omega) + \dots + P(\omega^{p - 1})}{p} = \frac{(1 + y)^{2p} + (p - 1)(1 + y^p)^2}{p}\]so the answer is
\[\frac1p\left(\binom{2p}{p} - 2\right) + 2\text{.}\]
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Mathandski
776 posts
#39 • 1 Y
Y by cubres
Subjective Rating (MOHs) $       $
Attachments:
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Maximilian113
591 posts
#40 • 1 Y
Y by cubres
niceee :-D
Let $A(x, y) = (1+xy)(1+x^2y)(\cdots)(1+x^{2p}y).$ Clearly, we want the sum of the coefficients of the terms with $x$ of degree divisible by $p$ and $y$ having degree $p.$ Let $z=e^{2\pi i/p}.$ Then by Roots of Unity Filter we have $$\frac{1}{p} \sum^{p-1}_{k=0}A(z^k, y).$$However, for $k = 1, 2, \cdots, p-1,$ clearly the set $\{1, z, z^2, \cdots z^{p-1}\}$ is a permutation of $\{ z^k, z^{2k}, \cdots z^{pk} \},$ so $$A(z^k, y) = \left( \prod_{k=0}^{p-1} (1+z^ky) \right)^2 = \left( y^{2p} \prod_{k=0}^{p-1} (\frac{1}{y}+z^k) \right)^2 = y^{2p} \cdot \left( -\frac{1}{y^p}-1 \right)^2 = (y^p+1)^2.$$Hence, our sum equals $$\frac{1}{p} \left((p-1)(y^p+1)^2+(y+1)^{2p} \right).$$Now, we simply extract the coefficient of $y^p$ from here, and this is just $$\boxed{\frac{2p-2+\binom{2p}{p}}{p}}.$$
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
golue3120
59 posts
#41 • 1 Y
Y by cubres
Here's the other genfunc solution.

Let $\textstyle\binom{n}{k}_q$ be the $q$-binomial coefficient and $\textstyle [n]_q=1+q+\dots+q^{n-1}=\frac{1-q^n}{1-q}$. Then it is well-known that
\[\sum_{\substack{S\subseteq\{1,2,\dots,2p\}\\|S|=p}}q^{\sum S}=q^{p(2p+1)}\binom{2p}{p}_q.\]
Let $\omega$ be a primitive $p$th root of unity. Then we have
\[\binom{2p}{p}_q=\frac{[2p]_q[2p-1]_q\dots[p+1]_q}{[p]_q[p-1]_q\dots[1]_q}=(1+q^p)\frac{[2p-1]_q\dots[p+1]_q}{[p-1]_q\dots[1]_q}.\]As we let $q\rightarrow\omega$, then the product cancels out, so we have $\textstyle\binom{2p}{p}_\omega=1+\omega^p=2$.

Hence by roots of unity filter, the desired result is $\textstyle\frac{1}{p}\sum_{i=0}^{n-1}\binom{n}{k}_{\omega^i}=\frac{\binom{2p}{p}-2}{p}+2$, since $\omega^0=1$ and all other powers are primitive $p$th roots of unity.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
smileapple
1013 posts
#42 • 1 Y
Y by cubres
Define \[P(x,y)=\prod_{n=1}^{2p}(x+y^n).\]Note that if a subset $S\subseteq\{1,2,\dots,2p\}$ has $m$ elements that sum to $s$, the set $S$ will show up in the expansion of $P$ as $x^{2p-m}y^s$.

Now let $\zeta=e^{2\pi i/n}$. By roots of unity filter it suffices to find the coefficient $c_p$ of $x^p$ in the expansion of $Q(x)=\frac1p\sum_{n=0}^{p-1}P(x,\zeta^n)$. But note that $P(x,\zeta^n)$ is equal to $(x+1)^{2p}$ if $n=0$ and is equal to $(x^p+1)^2$ otherwise. Thus \[Q(x)=\frac{(x+1)^{2p}+(p-1)(x^p+1)^2}p,\]from which extracting $c_p$ yields \[c_p=\boxed{\frac{\binom{2p}p+2(p-1)}p},\]which is our answer. $\blacksquare$

Edit: 999th post?
This post has been edited 1 time. Last edited by smileapple, Feb 21, 2025, 1:35 AM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
eg4334
733 posts
#43 • 1 Y
Y by cubres
Lol what. Just take the generating function $(x+y)(x+y^2) \dots (x+y^{2p})$ where $x$ counts the number of elements we dont use and $y$ counts the exponent. We want $y$ to be a multiple of $p$, and $x$ to be $p$. To extract the first condition, take ROUF with a primitive $p$th root $\omega$. We get $\frac{(x+1)^{2p} + (p-1)((x+\omega)(x+\omega^2)\dots (x+\omega^p))^2}{p} = \frac{(x+1)^{2p} + (p-1)(x^p+1)^2}{p}$. Its obvious by binomial expansion that the answer from here is $\boxed{\frac{\binom{2p}{p} + 2(p-1)}{p}}$
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
cubres
158 posts
#44
Y by
Yapping
Storage - grinding IMO problems
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
lpieleanu
3126 posts
#45 • 1 Y
Y by cubres
Solution
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Ilikeminecraft
734 posts
#46 • 1 Y
Y by cubres
We do ROUF on $(1 + xy)(1 + x^2y)\cdots(1 + x^{2p}y)$ and then subtract 2.

If $x = 1,$ it follows that we are just looking for the exponent of $y^{pk}$ and so it is $\binom{2p}p + 2$.

Now consider when $x = \omega^i$ for some $i > 0$ where $\omega$ is some primitive $p$-th root of unity.
\begin{align*}
    \sum_{i = 1}^{p - 1}\sum_{j = 0}^{p - 1} \prod_{k = 1}^{p} (1 + \omega^{k \cdot i + j})^2 & = \sum_{j = 0}^{p - 1}\sum_{i = 1}^{p - 1} \prod_{k = 0}^{p - 1}(w + \omega^{ki + j})^2 \\
    & = 4 (p-1)\sum_{j = 0}^{p - 1} \prod_{k = 1}^{p - 1}(1 + \omega^j)^2 \\
    & = 4(p - 1)p
\end{align*}Thus, to finish, we divide by $p^2$ and $-2$. This gives $\frac1{p}\left(\binom{2p}p - 2\right) + 2$
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Jupiterballs
119 posts
#47 • 1 Y
Y by cubres
Storage
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Jackson0423
161 posts
#48
Y by
Here is an elegant solution without generating functions.
Let \( U = \{1, 2, \ldots, p\} \), and \( V = \{p+1, p+2, \ldots, 2p\} \).
Let \( X \) be a \( p \)-element subset of \( U \cup V \). Define \( U' = X \cap U \), and \( V' = X \cap V \).
For \( 0 \leq k \leq p - 1 \), define \( U' + k \) as the set obtained by adding \( k \) to each element of \( U' \).

Let \( n(U') \) be the number of elements in \( U' \), and set \( m = n(U') \).
If \( S(N) \) denotes the sum of elements in the set \( N \), then we have
\[
S(U' + k) - S(U') = k \cdot n(U') = k m.
\]
Since \( \gcd(k, p) = \gcd(m, p) = 1 \), the set \( \{0, m, 2m, \ldots, (p - 1)m\} \) contains all residues modulo \( p \).

Now consider the sets \( U', U' + 1, \ldots, U' + (p - 1) \).
For exactly one \( k \in \{0, 1, \ldots, p - 1\} \), the value \( S(U' + k) + S(V') \) is divisible by \( p \).
Therefore, for each \( V' \), there is a unique \( k \) such that this condition is satisfied.

Hence, for all \( X \subseteq U \cup V \) with \( |X| = p \), except when \( X = U \) or \( X = V \), there are \( \binom{2p}{p} - 2 \) such sets.
Among these, for each group of \( p \) shifts, exactly one \( X \) satisfies the condition, giving
\[
\frac{\binom{2p}{p} - 2}{p}
\]sets.
Additionally, both \( X = U \) and \( X = V \) satisfy the condition, so we add 2.

Thus, the final answer is
\[
\boxed{ \frac{\binom{2p}{p} - 2}{p} + 2 }.
\]
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
mudkip42
421 posts
#49
Y by
It suffices to find the sum of the coefficients $x^{0 \pmod{p}}y^p$ of
\[ P(x,y)=(1+y)^2(1+xy)^2\cdots(1+x^{p-1}y)^2. \]Letting $\omega$ be a primitive $p$th root of unity. Then, by roots of unity filter, we want the $y^p$ coefficient of
\[ \frac{(1+y)^{2p}+(p-1)((1+y)(1+\omega y)\cdots(1+\omega^{p-1} y))^2}{p}=\frac{(1+y)^{2p}+(p-1)(1+y^p)^2}{p} \]which is easily found to be $\boxed{\frac{\binom{2p}{p}+2p-2}{p}}. \ \blacksquare$
Z K Y
N Quick Reply
G
H
=
a