If $f(x+1) +f(x-1) =\sqrt{3}\,f(x)$ and $f(2) =2$, what is the value of $f(4)$? My Attempt
$f(2)=2$. So,  $f(1) + f(3)=2\sqrt{3}$ and  $f(2) + f(4)=\sqrt{3}\,f(3)$.  After solving these equations I got the value of $f(3)=2\sqrt{3}$ and $f(4)=4$.  But are there any other methods than this? Any suggestions are welcome.  
Update:- @ProfessorVector pointed out that the above solutions are only true if $f(1)=0$. After checking I find that it is true. So, my above attempt is a failure. Is there a way to solve this question?  
Update 2:- Is there a way to find the period of this function?
 A: I'll be more general.
$f(n+1)+f(n-1)
= cf(n)
$.
Suppose
$f(n)
= b^n
$.
Then
$b^{n+1}+b^{n-1}
= cb^n
$
or
$b^2-cb+1
= 0
$.
Then
$b
=\dfrac{c\pm\sqrt{c^2-4}}{2}
$.
If $c^2=4$,
$b = c/2 = \pm 1$,
so
$f(n)=1$
or
$(-1)^n$.
If
$c^2 > 4$,
then
$b$ has two possible values,
one with
$|b|>1$
and one with
$|b|<1$.
If
$c^2 < 4$,
then
$b$ has two possible
complex values
$b_1
=\dfrac{c+\sqrt{c^2-4}}{2}
=\dfrac{c+i\sqrt{4-c^2}}{2}
$
and
$b_2
=\dfrac{c-i\sqrt{4-c^2}}{2}
$.
Note that
$b_1b_2
=\dfrac{c+\sqrt{c^2-4}}{2}\dfrac{c-\sqrt{c^2-4}}{2}
=\dfrac{4}{4}
=1
$
(as can also be deduced
from the quadratic
specifying $b$)
and that
$|b_k|^2
=\dfrac{c^2+4-c^2}{4}
=1
$.
Since
$|b| = 1$,
$b 
=e^{it}
=\cos(t)+i\sin(t)
$
where
$\cos(t)
=c/2
$.
In your case,
$c = \sqrt{3}$
so
$t
=\arccos(\sqrt{3}/2)
=\pi/6
$.
Therefore
the two possible solutions are
$f(n)
=e^{\pm ni\pi/6}
$
and any linear combination of these.
So any solution
is of the form
$ue^{in\pi/6}+ve^{-in\pi/6}
=(u+v)\cos(n\pi/6)+(u-v)\sin(n\pi/6)
$.
If the solution is real
for an $n$
such that
$\sin(n\pi/6) \ne 0$,
then
$u=v$,
so it is
$f(n)=2u\cos(n\pi/6)
$.
If
$f(2) = 2$,
then
$2=f(2)
=2u\cos(\pi/3)
=u
$
so
$u = 2$
and the solution is
$f(n)
=4\cos(n\pi/6)
$.
Putting $n=4$,
$f(4)
=4\cos(4\pi/6)
=-2
$.
