Actually cos[(2a^1/2)x] will work for any a in R+
If you need to verify:
f(0) =1 is obvious
using the double angle formula cos(2t) = 2cos^2(t)-1 for t = (2a)^1/2 x
which is precisely 2f(x)^2 -1
double application of L'Hopital's Rule verifies the limit
Now if you need to come up with cos((2a)^1/2 x) from first principles then that's another story. Do we have any other conditions such as differentiability ?
My thought process was simply
1. The condition f:R - [-1,1] led me to cosines and sines
2. f(0) =1 narrowed this to cos(bx)
3. the limit led to b^2 = 2a
Let me know if this not sufficient and I'll consider it further