Summer is a great time to explore cool problems to keep your skills sharp!  Schedule a class today!

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 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
Elementary Problems Compilation
Saucepan_man02   32
N 23 minutes ago by atdaotlohbh
Could anyone send some elementary problems, which have tricky and short elegant methods to solve?

For example like this one:
Solve over reals: $$a^2 + b^2 + c^2 + d^2  -ab-bc-cd-d +2/5=0$$
32 replies
Saucepan_man02
May 26, 2025
atdaotlohbh
23 minutes ago
Random Points = Problem
kingu   5
N 25 minutes ago by happypi31415
Source: Chinese Geometry Handout
Let $ABC$ be a triangle. Let $\omega$ be a circle passing through $B$ intersecting $AB$ at $D$ and $BC$ at $F$. Let $G$ be the intersection of $AF$ and $\omega$. Further, let $M$ and $N$ be the intersections of $FD$ and $DG$ with the tangent to $(ABC)$ at $A$. Now, let $L$ be the second intersection of $MC$ and $(ABC)$. Then, prove that $M$ , $L$ , $D$ , $E$ and $N$ are concyclic.
5 replies
kingu
Apr 27, 2024
happypi31415
25 minutes ago
Combo resources
Fly_into_the_sky   1
N 37 minutes ago by Fly_into_the_sky
Ok so i never did combinatorics in my life :oops: and i am willing to be able to do P1/P4 combos (or even more)
So yeah how can i start from scratch?
Remark:i don't want compuational combo resources :noo:
1 reply
Fly_into_the_sky
43 minutes ago
Fly_into_the_sky
37 minutes ago
Very odd geo
Royal_mhyasd   2
N an hour ago by Royal_mhyasd
Source: own (i think)
nevermind
2 replies
Royal_mhyasd
Yesterday at 6:10 PM
Royal_mhyasd
an hour ago
Polynomial Application Sequences and GCDs
pieater314159   46
N an hour ago by cursed_tangent1434
Source: ELMO 2019 Problem 1, 2019 ELMO Shortlist N1
Let $P(x)$ be a polynomial with integer coefficients such that $P(0)=1$, and let $c > 1$ be an integer. Define $x_0=0$ and $x_{i+1} = P(x_i)$ for all integers $i \ge 0$. Show that there are infinitely many positive integers $n$ such that $\gcd (x_n, n+c)=1$.

Proposed by Milan Haiman and Carl Schildkraut
46 replies
pieater314159
Jun 19, 2019
cursed_tangent1434
an hour ago
c^a + a = 2^b
Havu   10
N an hour ago by Havu
Find $a, b, c\in\mathbb{Z}^+$ such that $a,b,c$ coprime, $a + b = 2c$ and $c^a + a = 2^b$.
10 replies
Havu
May 10, 2025
Havu
an hour ago
Own made functional equation
JARP091   0
2 hours ago
Source: Own (Maybe?)
\[
\text{Find all functions } f : \mathbb{R} \to \mathbb{R} \text{ such that:} \\
f(a^4 + a^2b^2 + b^4) = f\left((a^2 - f(ab) + b^2)(a^2 + f(ab) + b^2)\right)
\]
0 replies
JARP091
2 hours ago
0 replies
Serbian selection contest for the IMO 2025 - P6
OgnjenTesic   16
N 2 hours ago by JARP091
Source: Serbian selection contest for the IMO 2025
For an $n \times n$ table filled with natural numbers, we say it is a divisor table if:
- the numbers in the $i$-th row are exactly all the divisors of some natural number $r_i$,
- the numbers in the $j$-th column are exactly all the divisors of some natural number $c_j$,
- $r_i \ne r_j$ for every $i \ne j$.

A prime number $p$ is given. Determine the smallest natural number $n$, divisible by $p$, such that there exists an $n \times n$ divisor table, or prove that such $n$ does not exist.

Proposed by Pavle Martinović
16 replies
OgnjenTesic
May 22, 2025
JARP091
2 hours ago
equal segments on radiuses
danepale   8
N 2 hours ago by zuat.e
Source: Croatia TST 2016
Let $ABC$ be an acute triangle with circumcenter $O$. Points $E$ and $F$ are chosen on segments $OB$ and $OC$ such that $BE = OF$. If $M$ is the midpoint of the arc $EOA$ and $N$ is the midpoint of the arc $AOF$, prove that $\sphericalangle ENO + \sphericalangle OMF = 2 \sphericalangle BAC$.
8 replies
danepale
Apr 25, 2016
zuat.e
2 hours ago
Inequality
SunnyEvan   8
N 2 hours ago by arqady
Let $a$, $b$, $c$ be non-negative real numbers, no two of which are zero. Prove that :
$$ \sum \frac{3ab-2bc+3ca}{3b^2+bc+3c^2} \geq \frac{12}{7}$$
8 replies
SunnyEvan
Apr 1, 2025
arqady
2 hours ago
Inequality conjecture
RainbowNeos   2
N 2 hours ago by RainbowNeos
Show (or deny) that there exists an absolute constant $C>0$ that, for all $n$ and $n$ positive real numbers $x_i ,1\leq i \leq n$, there is
\[\sum_{i=1}^n \frac{x_i^2}{\sum_{j=1}^i x_j}\geq C \ln n\left(\prod_{i=1}^n x_i\right)^{\frac{1}{n}}\]
2 replies
RainbowNeos
May 29, 2025
RainbowNeos
2 hours ago
2- player game on a strip of n squares with two game pieces
parmenides51   2
N 2 hours ago by Gggvds1
Source: 2023 Austrian Mathematical Olympiad, Junior Regional Competition , Problem 3
Alice and Bob play a game on a strip of $n \ge  3$ squares with two game pieces. At the beginning, Alice’s piece is on the first square while Bob’s piece is on the last square. The figure shows the starting position for a strip of $ n = 7$ squares.
IMAGE
The players alternate. In each move, they advance their own game piece by one or two squares in the direction of the opponent’s piece. The piece has to land on an empty square without jumping over the opponent’s piece. Alice makes the first move with her own piece. If a player cannot move, they lose.

For which $n$ can Bob ensure a win no matter how Alice plays?
For which $n$ can Alice ensure a win no matter how Bob plays?

(Karl Czakler)
2 replies
parmenides51
Mar 26, 2024
Gggvds1
2 hours ago
Incenters and Circles
rkm0959   6
N 3 hours ago by happypi31415
Source: Korean National Junior Olympiad Problem 1
In a triangle $\triangle ABC$ with incenter $I$,
Let $D$ = $AI$ $\cap$ $BC$
$E$ = incenter of $\triangle ABD$
$F$ = incenter of $\triangle ACD$
$P$ = intersection of $\odot BCE$ and $\overline {ED}$
$Q$ = intersection of $\odot BCF$ and $\overline {FD}$
$M$ = midpoint of $\overline {BC}$

Prove that $D, M, P, Q$ concycle
6 replies
rkm0959
Nov 2, 2014
happypi31415
3 hours ago
Reflected point lies on radical axis
Mahdi_Mashayekhi   6
N 3 hours ago by khanhnx
Source: Iran 2025 second round P4
Given is an acute and scalene triangle $ABC$ with circumcenter $O$. $BO$ and $CO$ intersect the altitude from $A$ to $BC$ at points $P$ and $Q$ respectively. $X$ is the circumcenter of triangle $OPQ$ and $O'$ is the reflection of $O$ over $BC$. $Y$ is the second intersection of circumcircles of triangles $BXP$ and $CXQ$. Show that $X,Y,O'$ are collinear.
6 replies
Mahdi_Mashayekhi
Apr 19, 2025
khanhnx
3 hours ago
integer functional equation
ABCDE   156
N May 21, 2025 by MathIQ.
Source: 2015 IMO Shortlist A2
Determine all functions $f:\mathbb{Z}\rightarrow\mathbb{Z}$ with the property that \[f(x-f(y))=f(f(x))-f(y)-1\]holds for all $x,y\in\mathbb{Z}$.
156 replies
ABCDE
Jul 7, 2016
MathIQ.
May 21, 2025
integer functional equation
G H J
G H BBookmark kLocked kLocked NReply
Source: 2015 IMO Shortlist A2
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
ABCDE
1963 posts
#1 • 30 Y
Y by mathmaths, doxuanlong15052000, Davi-8191, tenplusten, mathleticguyyy, Amir Hossein, A-Thought-Of-God, MathLuis, mathematicsy, chessgocube, HWenslawski, centslordm, donotoven, megarnie, jhu08, RedFlame2112, ImSh95, vic_52math, OronSH, Adventure10, Mango247, kimyager, lian_the_noob12, ItsBesi, WiseTigerJ1, Sedro, aidan0626, cubres, ray66, Funcshun840
Determine all functions $f:\mathbb{Z}\rightarrow\mathbb{Z}$ with the property that \[f(x-f(y))=f(f(x))-f(y)-1\]holds for all $x,y\in\mathbb{Z}$.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Kezer
986 posts
#2 • 10 Y
Y by Vietjung, Plops, chessgocube, HWenslawski, centslordm, donotoven, megarnie, lego_man, Adventure10, WiseTigerJ1
That was also Problem 5 in this year's German TSTST (VAIMO).
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Aiscrim
409 posts
#6 • 9 Y
Y by baladin, A-Thought-Of-God, chessgocube, centslordm, donotoven, megarnie, Adventure10, gatnghiep, WiseTigerJ1
The only functions that work are $f\equiv -1$ and $f(x)=x+1,\ \forall x\in \mathbb{Z}$.

Let $P(x,y)$ be the assertion that $f(x-f(y))=f(f(x))-f(y)-1$. From $P(x,f(x))$, we get that there is an $a\in \mathbb{Z}$ s.t. $f(a)=-1$. From $P(x,a)$ we get $f(x+1)=f(f(x))$, so $f(f(f(x)))=f(f(x+1))=f(x+2)$.

$P(f(x),x)$ yields $f(0)=f(f(f(x)))-f(x)-1\Leftrightarrow f(x+2)=f(x)+f(0)+1$. It's easy to show by induction that $f(2k)=f(0)+k(f(0)+1)\ (*)$

Looking at $P(f(8),f(4))$ and using $(*)$, we get $f(2f(0)+2)=3f(0)+2$. As $2f(0)+2$ is even we can use again $(*)$ to get $f(0)\in \{-1,1\}$.

If $f(0)=-1$, by $(*)$ and induction we get $f(2k)=-1,\ \forall k\in \mathbb{Z}$. Also note $f(2k+1)=f(f(2k))=f(-1)$. From $P(1,0)$ we get $f(-1)=-1$, so $f(2k+1)=-1,\ \forall k\in \mathbb{Z}$, whence $f\equiv -1$.

If $f(0)=1$, by $(*)$ and induction we get $f(2k)=2k+1,\ \forall k\in \mathbb{Z}$. Also note $f(2k+1)=f(2k-1)+f(0)+1=f(2k-1)+2$, so by induction $f(2k+1)=f(1)+2k\ (**)$
If $f(1)$ is odd, by $(**)$, $f(f(1))=f(1)+2\cdot \dfrac{f(1)-1}{2}=2f(1)-1$; $f(f(1))=f(2)=3$, so $f(1)=2$, contradiction. If $f(1)$ is even, by $(*)$, $f(f(1))=\dfrac{f(1)}{2}(f(0)+1)+f(0)=f(1)+1$; but $f(f(1))=f(2)=3$, so $f(1)=2$, whence $f(2k+1)=2k+2,\ \forall k\in \mathbb{Z}$, so $f(x)=x+1,\ \forall x\in \mathbb{Z}$.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
ABCDE
1963 posts
#8 • 4 Y
Y by chessgocube, centslordm, Adventure10, WiseTigerJ1
Let $A$ be the range of $f$, and let $A+1=\{a+1\mid a\in A\}$. The condition implies that for all $a,b\in A$, $a-b-1,a+b+1\in A$, so for all $m,n\in A+1$, $m+n,m-n\in A+1$. Hence, $A+1$ is the set of all integer multiples of some nonnegative integer $k$.

If $k=0$, then $A=\{-1\}$, so $f(x)=-1$. We can check that this works.

If $k>0$, let $g(x)=\frac{f(x)+1}{k}$. Since $A$ is the set of integers that are $-1\pmod{k}$, $g$ is a surjective map from integers to integers. Substituting, we have that $g(x-kg(y)+1)=g(kg(x)-1)-g(y)$. Since $g$ is surjective, we in fact have $g(x-kz+1)=g(kg(x)-1)-z$, where $z=f(y)$ can be any integer. Setting $z=0$, we have that $g(x+1)=g(kg(x)-1)$.

Now, if $g(a)=g(b)$ for some $a\neq b$, then $g(a+1)=g(b+1)=g(kg(a)-1)$, so if $g$ is not injective then it is periodic for large inputs. But fixing $x$, for some constants $c$ and $d$ we have that $g(c-kz)=d-z$, so for sufficiently negative values of $z$, and thus sufficiently large values of $c-kz$, $g$ is unbounded, a contradiction. Hence, $g$ is injective, so we can conclude that $g(x+1)=g(kg(x)-1)\implies g(x)=\frac{x+2}{k}$. Since $g$ maps integers to integers, $k=1$, and we obtain a solution of $g(x)=x+2$ or $f(x)=x+1$, which works.

Thus, our solutions are $f(x)=-1$ and $f(x)=x+1$.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
Darn
996 posts
#9 • 43 Y
Y by SCP, doxuanlong15052000, PRO2000, Tommy2000, Kayak, Dukejukem, Fermat_Theorem, Myriam2003, ayan_mathematics_king, Bassiskicking, Lifefunction, Siddharth03, Imayormaynotknowcalculus, mathleticguyyy, Luchitha2, A-Thought-Of-God, mijail, microsoft_office_word, lneis1, Smkh, chessgocube, centslordm, Timmy456, Elnuramrv, myh2910, Bapun, Mathlover_1, megarnie, Chokechoke, hqxaev, Ibrahim_K, Adventure10, sabkx, D_S, jimmy_li, bin_sherlo, DrYouKnowWho, wizixez, EpicBird08, aidan0626, DroneChaudhary, Ismayil_Orucov, ZZzzyy
Here's an alternate solution.
The only solutions are $f(x)=\boxed{x+1}$ and $f(x)=\boxed{-1}$.

Let $P(x,y)$ be the assertion that \[f(x-f(y))=f(f(x))-f(y)-1.\]$P(x,f(x))$ implies that \[ f(x-f(f(x)))=-1, \]so $-1$ must be in the range of $f$.

Let $f(a)=-1$ for some integral $a$. Then from $P(x,a)$ we get \[ f(x+1)=f(f(x)). \quad (\star).  \]Now from $P(f(x)-1,x)$ we find that \begin{align*} f(-1)+1 &= f(f(f(x)-1)))-f(x) \\ &= f(f(x))-f(x) \\ &= f(x+1)-f(x), \end{align*}implying that $f(x+1)-f(x)$ is constant for all $x\in\mathbb{Z}$. Since the domain of $f$ is $\mathbb{Z}$, this means that $f(x)$ must be of the form $kx+c$ for some constants $k,c$.
It remains to solve for $f$. From $(\star)$, we obtain \[ k(x+1)+c = k(kx+c)+c, \]so \[ k(x+1)=k(kx+c). \]If $k\not=0$, then \[ kx+c=x+1, \]meaning that $f(x)=x+1$. Otherwise, $f$ is constant, so from the hypothesis we get \[ c=c-c-1=-1,\]so $f(x)=-1$.
Both of these functions satisfy the original condition, and so we have shown that $\boxed{-1\text{\;and\;}x+1}$ are indeed the only solutions to $f$.
$\square$
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
navi_09220114
487 posts
#10 • 4 Y
Y by JoelBinu, centslordm, Adventure10, Mango247
The only solutions are $f(n)=-1$ for all $n\in \mathbb{Z}$, and $f(n)=n+1$ for all $n\in \mathbb{Z}$.

To verify that these are solutions, the first solution gives $-1=-1-(-1)-1$, which is true. The second solution gives $x-(y+1)+1=(x+1)+1-(y+1)-1$, which is also true. Now we will prove that these are the only soluitons.

To start, take $y=f(x)$ in $(1)$, then we get $$f(x-f(f(x)))=f(f(x))-f(f(x))-1=-1 \enspace{........ (2)}$$So by (2), choose $y=x-f(f(x))$ gives $f(y)=-1$, so we have $$f(x+1)=f(x-f(y))=f(f(x))-f(y)-1=f(f(x))$$Applying this successively we obtain $$f(x+k)=f(f(x+k-1))=f(f(f(x+k-2)))=\cdots =f^{(k+1)}(x)\enspace\text{for all $x\in \mathbb{Z}, k\in\mathbb{N}$}\enspace{........ (3)}$$With this $(1)$ rewrites to $$f(x-f(y))=f(x+1)-f(y)-1$$
Now we claim that $f(-2)=-1$. Take $x=f(y)$, then using $(3)$ we get $$f(0)=f(f(y)-f(y))=f(f(y)+1)-f(y)-1=f(f(f(y)))-f(y)-1=f(y+2)-f(y)-1$$so take $y=-2$, $f(0)=f(0)-f(2)-1\Rightarrow f(-2)=-1$.

So if we set $f(0)=a$, then $$f(y+2)-f(y)=a+1\enspace{........ (4)}$$Since $f(-2)=-1$, by induction, $f(2m)=a+m(a+1)$ for all $m\in \mathbb{Z}$. Likewise, if we set $f(1)=b$, then $f(2m+1)=b+m(a+1)$ for all $m\in \mathbb{Z}$. In particular, $f(2m+1)-f(2m)=b-a$ for all $m$. Now we give a method to determine $b$ in terms of $f(4)$.

Set $x=b+1, y=1$, then $b=f(1)=f((b+1)-f(1))=f(b+2)-f(1)-1$, but $f(b+2)=f(f(f(b)))=f(f(f(f(1))))=f(4)$, so $b=f(4)-f(1)-1$. So we have $$b=\frac{f(4)-1}{2}\enspace{........ (5)}$$We split into $2$ cases.

Case 1: $a\neq-1$.

In view of $(3)$, if $a\neq -1$, and if $f(p)=f(p+k)$ for some $p\in \mathbb{Z}, k\in \mathbb{N}$, then for all $\ell\in \mathbb{N}$, we obtain $$f(p+\ell)=f^{(\ell+1)}(p)=f^{(\ell+1)}(p+k)=f(p+k+\ell)$$In particular, $f(p)=f(p+k)=f(p+2k)\Rightarrow k(a+1)=f(p+2k)-f(p)=0$, clearly a contradiction. So $f$ is injective.

Take $x=y=2m$, we get $f(2m-a-m(a+1))=f(2m-f(2m))=f(2m+1)-f(2m)-1=b-a-1$, but if $a\neq 1$, then $2m-a-m(a+1)$ takes more than $1$ value, which is impossible since $f$ is injective. So $a=1$, and we get $f(2m)=2m+1$ for all $m\in \mathbb{Z}$. Now, in view of $(5)$, since $f(4)=5$, $b=\frac{f(4)-1}{2}=2\Rightarrow f(2m+1)=2+m(a+1)=2m+2$. So $f(n)=n+1$ for all $n\in \mathbb{Z}$, which had been verified to be a solution.

Case 2: $a=-1$

Then $f(2m)=f(0)=-1$, and $f(2m+1)=f(1)=b$ for all $m\in \mathbb{Z}$. Then again in view of $(5)$, we get $b=\frac{f(4)-1}{2}=-1$, so $f(2m+1)=b=-1$, so $f(n)=-1$ for all $n\in \mathbb{Z}$, which is also verified to be a solution.

So the only solutions are $f(n)=-1$ for all $n\in \mathbb{Z}$, and $f(n)=n+1$ for all $n\in \mathbb{Z}$. Q.E.D
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
adamov1
355 posts
#11 • 6 Y
Y by Mobashereh, wheisenberg, centslordm, Adventure10, Mango247, H_Taken
Let $P(x,y)$ be the assertion. $P(x,f(x))$ gives that there exists $a$ such that $f(a)=-1$. $P(x,a)$ gives
\[f(x+1)=f(f(x))\]$P(f(x)-1,x)$ gives
\[f(-1)=f(f(f(x)-1))-f(x)-1=f(f(x))-f(x)-1=f(x+1)-f(x)-1\longrightarrow f(x+1)-f(x)=f(-1)+1\]Thus $f$ is linear, so either $f$ is constant or injective. If $f$ is constant, it must clearly be identically $-1$, which works, and if it is injective we have that $x+1=f(x)$ which also works.
This post has been edited 2 times. Last edited by adamov1, Jul 8, 2016, 4:22 AM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
gavrilos
233 posts
#12 • 2 Y
Y by Adventure10, Mango247
Hello.

This was also problem 3 in 2016 Greece Team Selection Test.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
rkm0959
1721 posts
#13 • 5 Y
Y by B.J.W.T, E.A.K, Pluto1708, Adventure10, Mango247
We show $f$ is linear.
$P(x,f(x))$ shows that there exists an $u$ such that $f(u)=-1$.
$P(x,u)$ shows that $f(x+1)=f(f(x))$. This gives us $f(x-f(y))=f(x+1)-f(y)-1$.
Now $x=f(y)-1$ gives $f(-1)=f(f(y))-f(y)-1=f(y+1)-f(y)-1$, so $f$ is linear as required.
Now set $f(x)=ax+b$ and solve. $a(x+1)+b=a(ax+b)+b$, so $a=a^2$ and $a+b=ab+b$.
This gives $a=1, b=1$ or $a=0$. If $a=0$, we easily see that $f(x) \equiv -1$.
Therefore, the solution set is $f(x)=x+1$ and $f(x)=-1$. $\blacksquare$
This post has been edited 1 time. Last edited by rkm0959, Jul 9, 2016, 4:42 AM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
DrMath
2130 posts
#14 • 1 Y
Y by Adventure10
Let $P(x,y)$ denote the given assertion.

By $P(x, f(x))$ we have $f(x-f(f(x)))=-1$. Thus there is a value $y$ such that $f(y)=-1$. Taking $P(x,y)$ with $f(y)=-1$ gives $f(x+1)=f(f(x))$.

Suppose $f$ is one to one. Then we instantly get that $f(x)=x+1$.

Else, suppose $f(a)=f(b)$ for $a, b$ distinct. We claim this gives $f(x)=-1$ for all $x$. Note $P(a,y)$ and $P(b,y)$ gives $f$ is periodic. Let the period be $p$, and suppose for the sake of contradiction we can take $y$ to be a value such that $f(y)\neq -1$. Then $P(x-1, y)$ gives $f(x-1-f(y))=f(x)-f(y)-1$. Thus, if $r$ is in the range of $f$, so is $r-f(y)-1$. Thus, for some integer $k$, $r$ and $r-kp$ are both in the range of $f$. But take $f(y)=r$ and $f(y')=r -kp$. $P(x,y)$ and $P(x, y')$ gives our contradiction, as $f$ has period $p$. Thus if $f$ is periodic then $f(x)=-1$ for all $x$.
This post has been edited 1 time. Last edited by DrMath, Jul 9, 2016, 6:38 AM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
mathmoGJ
47 posts
#15 • 2 Y
Y by Adventure10, Mango247
Was also Problem 2 on the UK Team selection test 2.
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
hnkevin42
226 posts
#16 • 1 Y
Y by Adventure10
This will be long.

We have the following basic pieces of information.

Setting $(x, y) \rightarrow (f(0), 0)$ yields $f(f(f(0))) = 2f(0) + 1. \quad (\textbf{I})$
Setting $(x, y) \rightarrow (0, f(0))$ yields $f(-f(f(0))) = -1. \quad (\textbf{II})$
Via $\textbf{(II)}$, setting $(x, y) \rightarrow (x, -f(f(0)))$ yields $f(x + 1) = f(f(x)). \quad (\textbf{III})$

We then attack with the following lemmas.

Lemma 1: For every integer $n$, we have $f(n(f(0) + 1)) = (n + 1)f(0) + n$.
Proof: We induct both ways, starting with the obviously true base case of $n = 0$ and going in the negative and positive direction.
We go in the positive direction. If $n$ is not negative, setting $(x, y) \rightarrow ((n + 1)f(0) + n, n(f(0) + 1))$ yields, using $\textbf{(III)}$,
$$f(0) = f(f((n + 1)f(0) + n)) - (n + 1)f(0) - n - 1$$$$\implies f((n + 1)f(0) + (n + 1)) = f((n + 1)(f(0) + 1)) = (n + 2)f(0) + (n + 1)$$which completes the inductive step. In the negative direction, setting $(x, y) \rightarrow (n(f(0) + 1) - 1, 0)$ yields, again using $\textbf{(III)}$,
$$f((n - 1)f(0) + (n - 1)) = f(f(n(f(0) + 1) - 1)) - f(0) - 1$$$$\implies f((n - 1)(f(0) + 1)) = (n + 1)f(0) + n - f(0) - 1 = nf(0) + (n - 1)$$which completes the inductive step, proving Lemma 1.

Lemma 2: We either have $f(0) = 1$ or $f(0) = -1$.
Proof: Note that by $(\textbf{III})$, we have $f(f(0)) = f(1)$. Since $f(f(x)) = f(x + 1)$ for all integers $x$, we have that $f$ is periodic, for all $x \ge \min(f(0), 1)$ if $f(0) \ne 1$. For these $x$, $f$ is bounded. But from Lemma 1, $f$ must be unbounded for positive $x$ and for $f(0) \ne -1$. This is because, if $f(0)$ is nonnegative, both $n(f(0) + 1)$ and $f(n(f(0) + 1))$ are positive and strictly increasing as $n$ grows in the positive integers. Likewise, if $f(0) < -1$, both $n(f(0) + 1)$ and $f(n(f(0) + 1))$ are positive and strictly increasing as $n$ gets more negative, so either way, $f$ is unbounded in the positive integers if $f(0) \ne -1$. Since $f$ is periodic and unbounded in the positive integers for all $f(0)$ not equal to $1$ or $-1$, we cannot have $f(0)$ be any other value than $1$ or $-1$.

END LEMMA: The solutions, and the only solutions, are $f(x) = x + 1$ and $f(x) = -1$.
Proof: Setting $(x, y) \rightarrow (0, 0)$ yields $(\star) f(-f(0)) = f(f(0)) - f(0) - 1 = f(1) - f(0) - 1$ via $\textbf{(III)}$. Then setting $(x, y) \rightarrow (f(1) - 1, -f(0))$ yields via $\textbf{(III)}$, $$f(f(0)) = f(f(f(1) - 1)) - f(1) + f(0) \implies f(f(1)) = 2f(1) - f(0).$$We know $f(f(1)) = f(f(f(0))) = 2f(0) + 1$ from $\textbf{(I)}$ and $\textbf{(III)}$, so then $2f(1) = 3f(0) + 1$.

If $f(0) = 1$, then $f(1) = 2$ and, with $(\star)$, $f(-1) = 0$. Then, plugging in $(x, y) \rightarrow (x, -1)$ yields that for all integers $x$, we need $f(x) = f(f(x)) - 1 \implies f(x + 1) = f(x) + 1$. From here we get that $f(0) = 1$ leads to the one solution $f(x) = x + 1$.

If $f(0) = -1$, then $f(1) = -1$ and, with $(\star)$, $f(2) = -1$. Then, plugging in $(x, y) \rightarrow (x, -1)$ yields that for all integers $x$, we need $f(x + 1) = f(f(x))$. A quick induction starting with $x = 1$ yields that for all positive integers $x$, $f(x) = -1$. Now suppose $f(k) = a \ne -1$ for any $k < -1$. Setting $(x, y) \rightarrow (x, -1)$ yields that for all integers $x$, we need $f(x - a) = f(x + 1) - a - 1$. If we choose a positive integer $x = k > |a|$, then we have $k - a, k + 1$ are positive integers and $f(k - a) = f(k + 1) - a + 1 \implies -1 = -1 - a + 1$, which is a contradiction since we said $a \ne 1$. Thus, we have the one solution $f(x) = -1$ for all $x$.

Since both solutions easily work when plugged back into the original equation, The answer is $$\boxed{f(x) = x + 1, f(x) = -1.}$$
This post has been edited 2 times. Last edited by hnkevin42, Jul 12, 2016, 12:49 PM
Reason: Copy error
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
tenplusten
1000 posts
#17 • 2 Y
Y by Adventure10, Mango247
Good problem.

Claim 1: There exist $a\in R$ such that $f(a)=-1$.
Proof:Just see $P(x,f(x))$

Claim 2: $f(f(x))=f(x+1)$
Proof: $P(x,a)$ $\implies$ $f(x+1)=f(f(x))$

Claim 3: $f(f(f(x)))-f(x)=f(0)+1$
Proof: Just see $P(f(x),x)$

Claim 4: $f(x+2)=f(x)+f(0)+1$
Proof: Using "Claim 2" we get $f(f(f(x)))=f(f(x+1))=f(x+2)$
So $f(f(f(x)))-f(x)=f(0)+1=f(x+2)-f(x)$.

Since we got $f(x+2)=f(x)+f(0)+1$
Easy to show that $f(x)=x+1$ and $f\equiv-1$
So solutions are $f(x)=x+1$ for all $x\in Z$ and $f\equiv -1$
This post has been edited 6 times. Last edited by tenplusten, Feb 6, 2017, 3:42 PM
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
MSTang
6012 posts
#18 • 3 Y
Y by adityaguharoy, Adventure10, Mango247
Claim 1: $-1$ is in the range of $f$.

Proof: Taking $y=f(x)$ gives $f(x-f(f(x)) = -1$ for all $x$. $\spadesuit$

Claim 2: Over all $x$, the quantity $f(f(x)) - f(x)$ is constant.

Proof. Let $a, b$ be integers. Taking $x=f(a)+f(b)$ and $y=a$ gives \[f(f(b)) = f(f(f(a)+f(b))) - f(a) - 1.\]Taking $x=f(a)+f(b)$ and $y=b$ gives \[f(f(a)) = f(f(f(a)+f(b))) - f(b) - 1.\]Comparing the two equations gives $f(f(a)) - f(a) = f(f(b)) - f(b)$, as claimed. $\spadesuit$

Finisher. Let $f(f(x)) - f(x) = k$ for some constant $k$. Then the given equation becomes \[f(x-f(y)) = f(x) - f(y) + (k-1)\]for all $x, y$. Using Claim 1, choose $y$ in the above equation such that $f(y) = -1$, giving \[f(x+1) = f(x) + k\]for all $x$. Since $f$ has domain $\mathbb{Z}$, we conclude that $f$ is of the form $f(x) = kx + c$ for some constants $k$ and $c$. In the original equation, we need \[k(x-ky-c)+c = k(kx+c) + c - ky - c - 1\]or \[kx - k^2y - ck + c = k^2x + ck - ky - 1.\]Comparing $x$ coefficients gives $k = k^2$, so $k \in \{0, 1\}$. If $k=0$, then $c = -1$, giving the solution $f(x) = -1$ for all $x$. If $k=1$, then $c = 1$, giving the solution $f(x) = x + 1$ for all $x$. It is easy to check that both these functions work. $\square$
Z K Y
The post below has been deleted. Click to close.
This post has been deleted. Click here to see post.
adityaguharoy
4657 posts
#19 • 2 Y
Y by Adventure10, Mango247
MSTang wrote:
Claim 1: $-1$ is in the range of $f$.

Proof: Taking $y=f(x)$ gives $f(x-f(f(x)) = -1$ for all $x$. $\spadesuit$

Claim 2: Over all $x$, the quantity $f(f(x)) - f(x)$ is constant.

Proof. Let $a, b$ be integers. Taking $x=f(a)+f(b)$ and $y=a$ gives \[f(f(b)) = f(f(f(a)+f(b))) - f(a) - 1.\]Taking $x=f(a)+f(b)$ and $y=b$ gives \[f(f(a)) = f(f(f(a)+f(b))) - f(b) - 1.\]Comparing the two equations gives $f(f(a)) - f(a) = f(f(b)) - f(b)$, as claimed. $\spadesuit$

Finisher. Let $f(f(x)) - f(x) = k$ for some constant $k$. Then the given equation becomes \[f(x-f(y)) = f(x) - f(y) + (k-1)\]for all $x, y$. Using Claim 1, choose $y$ in the above equation such that $f(y) = -1$, giving \[f(x+1) = f(x) + k\]for all $x$. Since $f$ has domain $\mathbb{Z}$, we conclude that $f$ is of the form $f(x) = kx + c$ for some constants $k$ and $c$. In the original equation, we need \[k(x-ky-c)+c = k(kx+c) + c - ky - c - 1\]or \[kx - k^2y - ck + c = k^2x + ck - ky - 1.\]Comparing $x$ coefficients gives $k = k^2$, so $k \in \{0, 1\}$. If $k=0$, then $c = -1$, giving the solution $f(x) = -1$ for all $x$. If $k=1$, then $c = 1$, giving the solution $f(x) = x + 1$ for all $x$. It is easy to check that both these functions work. $\square$

It is somewhat similar to the solution I had for this problem.
Z K Y
G
H
=
a