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
Greece JBMO TST
ultralako   26
N 28 minutes ago by Adywastaken
Source: Greece JBMO TST Problem 4
Find all positive integers $x,y,z$ with $z$ odd, which satisfy the equation:

$$2018^x=100^y + 1918^z$$
26 replies
ultralako
Apr 22, 2018
Adywastaken
28 minutes ago
An innocent-looking inequality
Bryan0224   1
N 30 minutes ago by Quantum-Phantom
Source: Idk
If $\{a_i\}_{1\le i\le n }$ and $\{b_i\}_{1\le i\le n}$ are two sequences between $1$ and $2$ and they satisfy $\sum_{i=1}^n a_i^2=\sum_{i=1}^n b_i^2$, prove that $\sum_{i=1}^n\frac{a_i^3}{b_i}\leq 1.7\sum_{i=1}^{n} a_i^2$, and determine when does equality hold
Please answer this @sqing :trampoline:
1 reply
Bryan0224
5 hours ago
Quantum-Phantom
30 minutes ago
Inspired by Turkey 2025
sqing   0
31 minutes ago
Source: Own
Let $ a, b, c >0, a^2 + \frac{b}{a}  = 8 $ and $ ab + c^2 \leq 18 .$ Prove that $$ 3a + b + c\leq  9\sqrt{3}$$

0 replies
sqing
31 minutes ago
0 replies
ISI UGB 2025 P7
SomeonecoolLovesMaths   8
N 44 minutes ago by Mathworld314
Source: ISI UGB 2025 P7
Consider a ball that moves inside an acute-angled triangle along a straight line, unit it hits the boundary, which is when it changes direction according to the mirror law, just like a ray of light (angle of incidence = angle of reflection). Prove that there exists a triangular periodic path for the ball, as pictured below.

IMAGE
8 replies
1 viewing
SomeonecoolLovesMaths
Yesterday at 11:28 AM
Mathworld314
44 minutes ago
No more topics!
integer functional equation
ABCDE   149
N Yesterday at 1:49 AM by ezpotd
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}$.
149 replies
ABCDE
Jul 7, 2016
ezpotd
Yesterday at 1:49 AM
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
479 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