by Wolstenholme, Nov 4, 2014, 4:03 AM
Find all functions

such that
is perfect square for all
Solution:
Lemma 1: 
and
Proof: This follows immediately from the fact that the product of two positive integers with difference less than

cannot be a perfect square.
Lemma 2: For any odd prime
, we have that

for all
Proof: Assume

for some

It is clear that there exists a

such that

Since

is a square we must have

and similarly we find that

which implies the desired result.
Lemma 3: 
for all
Proof: This is essentially equivalent to the proof of Lemma 2.
The combination of Lemmas

and

yields that

for all

After some casework using Lemma 1, we find that the only solution is

where

This post has been edited 1 time. Last edited by Wolstenholme, Nov 4, 2014, 3:44 PM