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
Hard Inequality
danilorj   5
N 29 minutes ago by danilorj
Let $a, b, c > 0$ with $a + b + c = 1$. Prove that:
\[
\sqrt{a + (b - c)^2} + \sqrt{b + (c - a)^2} + \sqrt{c + (a - b)^2} \geq \sqrt{3},
\]with equality if and only if $a = b = c = \frac{1}{3}$.
5 replies
danilorj
Today at 5:17 AM
danilorj
29 minutes ago
easy geo
ErTeeEs06   5
N 32 minutes ago by Adywastaken
Source: BxMO 2025 P3
Let $ABC$ be a triangle with incentre $I$ and circumcircle $\Omega$. Let $D, E, F$ be the midpoints of the arcs $\stackrel{\frown}{BC}, \stackrel{\frown}{CA}, \stackrel{\frown}{AB}$ of $\Omega$ not containing $A, B, C$ respectively. Let $D'$ be the point of $\Omega$ diametrically opposite to $D$. Show that $I, D'$ and the midpoint $M$ of $EF$ lie on a line.
5 replies
ErTeeEs06
Apr 26, 2025
Adywastaken
32 minutes ago
Inspired by SXJX (12)2022 Q1167
sqing   4
N 34 minutes ago by sqing
Source: Own
Let $ a,b,c>0 $. Prove that$$\frac{kabc-1} {abc(a+b+c+8(2k-1))}\leq \frac{1}{16 }$$Where $ k>\frac{1}{2}.$
4 replies
1 viewing
sqing
Yesterday at 4:01 AM
sqing
34 minutes ago
Geometry hard problem.
noneofyou34   3
N 39 minutes ago by noneofyou34
In a circle of radius R, three chords of length R are given. Their ends are joined with segments to
obtain a hexagon inscribed in the circle. Show that the midpoints of the new chords are the vertices of
an equilateral triang
3 replies
noneofyou34
Today at 9:50 AM
noneofyou34
39 minutes ago
Weird integral
Martin.s   0
Today at 9:33 AM
\[
\int_{-\frac{\pi}{2}}^{\frac{\pi}{2}} 
\frac{1 - e^{-2} \cos\left(2\left(u + \tan u\right)\right)}
{1 - 2e^{-2} \cos\left(2\left(u + \tan u\right)\right) + e^{-4}} 
\, \mathrm{d}u
\]
0 replies
Martin.s
Today at 9:33 AM
0 replies
hard number theory problem
danilorj   4
N Today at 9:01 AM by c00lb0y
Let \( a \) and \( b \) be positive integers. Prove that
\[
a^2 + \left\lceil \frac{4a^2}{b} \right\rceil
\]is not a perfect square.
4 replies
danilorj
May 18, 2025
c00lb0y
Today at 9:01 AM
Unsolving differential equation
Madunglecha   2
N Today at 8:44 AM by vanstraelen
For parameter t
I made a differential equation :
y"=y*(x')^2
for here, '&" is derivate and second order derivate for t
could anyone tell me what is equation between y&x?
2 replies
Madunglecha
May 18, 2025
vanstraelen
Today at 8:44 AM
maximum dimention of non-singular subspace
FFA21   1
N Today at 8:27 AM by alexheinis
Source: MSU algebra olympiad 2025 P1
We call a linear subspace in the space of square matrices non-singular if all matrices contained in it, except for the zero one, are non-singular. Find the maximum dimension of a non-singular subspace in the space of
a) complex $n\times n$ matrices
b) real $4\times 4$ matrices
c) rational $n\times n$ matrices
1 reply
FFA21
Today at 12:02 AM
alexheinis
Today at 8:27 AM
functional equation
pratyush   4
N Today at 8:00 AM by Mathzeus1024
For the functional equation $f(x-y)=\frac{f(x)}{f(y)}$, if f ' (0)=p and f ' (5)=q, then prove f ' (-5) = q
4 replies
pratyush
Apr 4, 2014
Mathzeus1024
Today at 8:00 AM
a product that is never a square
FFA21   1
N Today at 7:21 AM by ohiorizzler1434
Source: MSU algebra olympiad 2025 P3
Show that the product $7*77*777*7777*77777...$ is never a square of an integer.
1 reply
FFA21
Today at 12:18 AM
ohiorizzler1434
Today at 7:21 AM
Convergence of complex sequence
Rohit-2006   8
N Today at 7:12 AM by ohiorizzler1434
Suppose $z_1, z_2,\cdots,z_k$ are complex numbers with absolute value $1$. For $n=1,2,\cdots$ define $w_n=z_1^n+z_2^n+\cdots+z_k^n$. Given that the sequence $(w_n)_{n\geq1}$ converges. Show that,
$$z_1=z_2=\cdots=z_k=1$$.
8 replies
Rohit-2006
May 17, 2025
ohiorizzler1434
Today at 7:12 AM
ignore this
Martin.s   7
N Today at 6:22 AM by Cats_on_a_computer
Source: ignore this
ignore this
7 replies
Martin.s
Jul 16, 2024
Cats_on_a_computer
Today at 6:22 AM
non-identity invariant subgroup of automorphism
FFA21   1
N Today at 2:18 AM by ysharifi
Source: MSU algebra olympiad 2025 P6
Show that an order two automorphism of a non-identity Abelian group always has a non-identity invariant cyclic subgroup
1 reply
FFA21
Today at 12:27 AM
ysharifi
Today at 2:18 AM
proper subfield of squares
FFA21   1
N Today at 2:01 AM by ysharifi
Source: MSU algebra olympiad 2025 P5
Show that if the set of all squares of elements of a field is a proper subfield, then the characteristic of the field is two.
1 reply
FFA21
Today at 12:25 AM
ysharifi
Today at 2:01 AM
Good Permutations in Modulo n
swynca   10
N May 16, 2025 by MR.1
Source: BMO 2025 P1
An integer $n > 1$ is called $\emph{good}$ if there exists a permutation $a_1, a_2, a_3, \dots, a_n$ of the numbers $1, 2, 3, \dots, n$, such that:
$(i)$ $a_i$ and $a_{i+1}$ have different parities for every $1 \leq i \leq n-1$;
$(ii)$ the sum $a_1 + a_2 + \cdots + a_k$ is a quadratic residue modulo $n$ for every $1 \leq k \leq n$.
Prove that there exist infinitely many good numbers, as well as infinitely many positive integers which are not good.
10 replies
swynca
Apr 27, 2025
MR.1
May 16, 2025
Good Permutations in Modulo n
G H J
G H BBookmark kLocked kLocked NReply
Source: BMO 2025 P1
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
swynca
16 posts
#1 • 2 Y
Y by dangerousliri, megarnie
An integer $n > 1$ is called $\emph{good}$ if there exists a permutation $a_1, a_2, a_3, \dots, a_n$ of the numbers $1, 2, 3, \dots, n$, such that:
$(i)$ $a_i$ and $a_{i+1}$ have different parities for every $1 \leq i \leq n-1$;
$(ii)$ the sum $a_1 + a_2 + \cdots + a_k$ is a quadratic residue modulo $n$ for every $1 \leq k \leq n$.
Prove that there exist infinitely many good numbers, as well as infinitely many positive integers which are not good.
This post has been edited 2 times. Last edited by swynca, Apr 27, 2025, 4:15 PM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Double07
92 posts
#2 • 2 Y
Y by lksb, Assassino9931
We prove that any prime $p\equiv 3\mod 4$ works.
We have $\left(\frac{-1}{p}\right)=-1$, so we can split $1, 2, ..., p-1$ into $\frac{p-1}{2}$ pairs $(r_i, s_i)$ such that $r_i+s_i=p$, $\left(\frac{r_i}{p}\right)=1$ and $\left(\frac{s_i}{p}\right)=-1$.
Order the pairs such that, for all $1\leq i\leq k$, $r_i$ is odd and, for all $k+1\leq i\leq \frac{p-1}{2}$, $r_i$ is even.
Now just consider the permutation $r_1, s_1, r_2, s_2, ..., r_k, s_k, p, r_{k+1}, s_{k+1}, ..., r_{\frac{p-1}{2}}, s_{\frac{p-1}{2}}$.
Modulo $2$ this will be $1, 0, 1, 0, ..., 1, 0, 1, 0, 1, ..., 0, 1$, so $(i)$ is achieved.
At any point the sum $a_1+...+a_m\mod p$ will be either $0$ or $r_i$, for a $1\leq i\leq \frac{p-1}{2}$, so a quadratic residue.

Now, for the second part, just choose $n=2^k, k\geq 2$.
We will prove that there don't exist two quadratic residues with difference equal to $2$, hence such a permutation wouldn't exist, since there must exist $a_i=2$ in the permutation.
Suppose there existed $a, b$ such that $\left(\frac{a}{p}\right)=\left(\frac{b}{p}\right)=1$ and $b-a\equiv 2\mod 2^k$.
Since $b-a\equiv 2\mod 2^k$, we have two cases:
1. $\{a,b\}\equiv \{0,2\}\mod4$, in which case there should exist a perfect square $m^2\equiv 2\mod 4$, impossible.
2. $\{a,b\}\equiv \{1,3\}\mod4$, in which case there should exist a perfect square $m^2\equiv 3\mod 4$, impossible.
So such permutation doesn't exist for all $n=2^k$.
This post has been edited 2 times. Last edited by Double07, Apr 27, 2025, 6:56 PM
Reason: Deleted a mistake
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
DensSv
62 posts
#3
Y by
Does anyone know the proposer?
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Ivan_Borsenco
28 posts
#5
Y by
The (i) condition adds a small twist to the problem.
I believe the problem looks also complete and interesting to solve without the (i) condition.

-- To construct such a permutation, it is natural to look for a sequence with pairs that add up to 0 mod $p$.
The next desire is to pair a residue with a non-residue and also for them to alternate.
Choosing $p \equiv 3 \pmod 4$ solves this, as Double07 showed in his/her post.

-- When we need to prove that no such sequence exists. We can choose $n=2k$, then
the last sum is a number that we can compute: $k(2k+1)\equiv k \pmod{2k}$. If there exists $x^2 \equiv k \pmod{2k}$,
then $x^2 = 2k\cdot s + k = k (2s +1)$. Choosing $k = 2m^2$ assures that no such $x$ exists.
This post has been edited 2 times. Last edited by Ivan_Borsenco, Apr 27, 2025, 3:25 PM
Reason: -
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
megarnie
5610 posts
#7
Y by
Part 1) Prove that there are infinitely many good numbers.
Fix any prime $p \equiv 3 \pmod 4$. Let $n = p$. Choose values for these odd indices of the sequence $a_1, a_3, a_5,\ldots, a_{2k - 1} $ so that they consist of all the even quadratic residues modulo $p$ exactly once and $a_{2k - 1} = 0$. Now, choose the values of these even indices of the sequence $a_{2k}, a_{2k + 2}, a_{2k + 4} , \ldots, a_{p - 1}$ so that they consist of all the odd quadratic residues modulo $p$ exactly once. Now, for any index $i$, if $a_i$ is a nonzero QR mod $p$, then choose $a_{i + 1} = p - a_i$. One can check that this sequence works.
Part 2) Prove that there are infinitely many numbers that are not good.
Let $n = 8k + 4$. We compute $a_1 + a_2 + \cdots + a_n = 1 + 2 + \cdots + n = \frac{n(n+1)}{2} = (4k + 2)(8k +5) \equiv 4k + 2 \pmod{8k + 4}$. Anything that is $4k + 2\pmod{8k + 4}$ must also be $2 \pmod 4$, so it cannot be a perfect square, as desired.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
EVKV
71 posts
#8
Y by
Claim 1 : All primes $p \equiv 3 $ mod $4$ are good

Proof 1 :

Claim 1.1 : If a is a QR mod p then p-a is not where a $\neq$ pk for some integer k

Proof 1.1 : FTSOC assume for some integer x,y $x^{2} +y^{2} \equiv a +p-a \equiv 0 $ mod $p$
Which is nonsense by Fermat's christmas theorem

Defination 1.1 : We define $a_{i}$ as the odd numbers which are QR mod p and lesser than p. . Here
$1 \leq i \leq r$ where r is the amount of odd numbers which are QR mod p and lesser than p.

Defination 1.2 : We define $b_{i}$ as the even numbers which are QR mod p and lesser than p. . Here
$1 \leq i \leq k$ where k is the amount of even numbers which are QR mod p and lesser than p.

Also clearly $a_{i}$ and $p-a_{i}$ have different parity so do $b_{i}$ and $p-b_{i}$

Now we already know there are $\frac{p-1}{2}$ non-zero quadratic residues mod p. So, $a_{i}$ and $p-a_{i}$ and $b_{i}$ and $p-b_{i}$ form $\frac{p-1}{2}$ pairs and as none of them include p ( all are non zero quadratic residues)
we will get all numbers $ \leq p $ in the following sequence which will also satisfy the other conditions clearly as at any point it will be either 0,$a_{i}$,$b_{i}$ which are all QRs

$a_{1}$,$p-a_{1}$, $ \cdots $,$a_{r}$,$p-a_{r}$,$p$,$b_{1}$,$p-b_{1}$, $ \cdots $,$b_{k}$,$p-b_{k}$,

Claim 2 : All numbers of the form $4K$ where K is odd are not good (They are bad)

Proof 2 : Obviously If x is a QR mod $4K$ it is a QR mod 4
So, All $\sum_1 ^{k} a_{i}$ $ \equiv $ $0,1$ mod 4
Now as $0+2$ and $1+2$ are not QRs mod 4
Thus we can never have $a_{i+1} \equiv 2$ mod 4 for all $i \leq 4K-1$ but that is nonsense as for all $r \leq 4K$ there is an $a_{g} = r$

QED

Remark : A very very tasty problem which i never expected to be able to solve. Had so much fun tho had fake solved once lol.

I rate it d6

Solved : 27/4/25
This post has been edited 4 times. Last edited by EVKV, Apr 28, 2025, 7:38 PM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
dangerousliri
932 posts
#9 • 3 Y
Y by bsf714, NO_SQUARES, Achilleas
One of the best Number Theory problems on Olympiads. I will show my solution in some details another way how it could be done since I think most likely it would be hard someone to thought of this.

As before to show that there are infinitely non good numbers we take $n=4^m$.

We are going to prove that $n=2p$ is a good number where $p$ is a prime number such that $p\equiv 5\pmod6$. To do that with some manipulation we can prove $x^3$ is a complete residue for $x=1,2,...,2p$ modulo $2p$. After that we have for every $i=1,2,...,2p$ there exist a unique $x_i\in\{1,2,...,2p\}$ such that $i\equiv x_i^3\pmod{2p}$ and we have that $i$ and $x_i$ have same parities. Now to finish the problem we use the identity,
$$1^3+2^3+...+k^3=\left(\frac{k(k+1)}{2}\right)^2.$$
This post has been edited 3 times. Last edited by dangerousliri, Apr 27, 2025, 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.
MathLuis
1545 posts
#10
Y by
For the first part just notice that taking $n$ as a prime $p \equiv 3 \pmod 4$ just works as $-1$ is NQR mod $p$ and as a result we have that $k(p-k) \equiv -k^2 \pmod p$ which is an NQR by multiplicativiness of the Legendre Symbol and therefore we can split in $\frac{p-1}{2}$ pairs $(q_i,n_i)$ for which $q_i+n_i=p$ and one is a QR and the other is NQR, and the idea for the parity part is just to put $1$ first then $p-1$ and then another odd one and so on until you run out of odd ones then add zero and add even ones and then their pair to finish.
Now to see infinitely many $n$ that fail we pick $n=2^k$ for $k$ large and the reason for this pick is that clearly we can't have two QRs that are consecutive by $2$ as it leads to a contradiction $\pmod 4$ but at some point we have to add $2$ to the sum so that gives a contradiction for it working, thus done.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Thapakazi
67 posts
#11 • 2 Y
Y by missionjoshi.65, Bergo1305
For the first part, we take $n$ as a prime $p \equiv 3 \pmod 4$. Note that if $i$ is a QR, then $p-i$ is NQR, and vice versa. Then we start pairing the terms as follows:

Let $s_2, s_3, \cdots, s_{\frac{p-1}2}$ be all quadratic residues mod $p$ not including $1$.

- First pair $(1, p-1)$.
- Then for $i > 1$, keep on pairing $(a_i, a_{i+1}) = (s_i, p-s_i)$ where $s_i$ is odd, till we run out of odd QR's.
- Then we let the next term be $p$.
- Finally pair $(a_i, a_{i+1}) = (s_i, p-s_i)$ where $s_i$ is even, till we run out of them.

It is clear that this pairing works.

For the second part, we let $n = 4p$ for an odd prime $p$. Then, note that $t^2 \equiv \sum a_i = 2p(4p+1) \equiv 2p \pmod {4p}.$

Then, we get a contradiction as

$$4p \mid t^2 - 2p \implies 2p \mid t^2 \implies 4p^2 \mid t^2 \implies 4p \mid t^2 \implies 4p \mid 2p.$$
This post has been edited 5 times. Last edited by Thapakazi, May 2, 2025, 4:07 PM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
optimusprime154
23 posts
#12
Y by
first we prove that every prime of the form $4k+3$ is good. we know that if $a$ is a quadratic residue $mod$ $p$ then $p - a$ wont be a quadratic residue $mod$ $p$ this means that we can divide the residues into two groups, $ b_1, b_2, \ldots , b_t$ and $ c_1, c_2 \ldots, c_m$ where the first are odd residues and the second are even residues. we begin by creating a construction: $b_1, p - b_1, b_2, p - b_2, \ldots b_t, p-b_t, p, c_1, p - c_1, \ldots c_m, p - c_m$ which clearly satisfies both conditions.
now for the second part, i claim all numbers of the form $4^k$ are not good, by taking the sum $a_1+a_2 \cdots +a_n$ is the same as $\frac{n(n+1)}{2} = (2^{2k-1})(4^k + 1) \equiv (2^{2k-1}) mod 4^k$, but $2k-1$ is odd therefore $2^{2k-1}$ can not be a quadratic residue.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
MR.1
129 posts
#13
Y by
trash sol :wallbash_red:
Z K Y
N Quick Reply
G
H
=
a