What’s wrong with the even Fibonacci generating function

fibonacci-numbersgenerating-functions

I'm trying to find the closed form for the generating function of an even Fibonacci series $F_{2n}$, but I'm not getting the right answer. My idea was to use the even Fibonacci series to find the odd Fibonacci series, then combine them. i.e. if

\begin{align}
f(x) = f_0 + f_2x^2 + f_4x^4 + \dots
\end{align}

then
\begin{align}
x^2f(x) = f_0x^2 + f_2x^4 + \dots
\end{align}

so subtracting one from the other,
\begin{align}
(1 – x^2)f(x) &= f_0 + (f_2 – f_0)x^2 + (f_4 – f_2)x^4 + \dots \\
&= f_0 + f_1x^2 + f_3x^4 + \dots \\
\implies \frac{(1-x^2)f(x) – f_0}{x} &= f_1x + f_3x^3 + \dots
\end{align}

Then I add odd and even parts together (and putting $f_0 = 1$),
\begin{align}
\frac{(1-x^2)f(x) – 1}{x} + f(x) = f_0 + f_1x + f_2x^2 + f_3x^3 + \dots = \frac{x}{1-x-x^2}
\end{align}

Then when I solve for $f(x)$ I get
\begin{align}
f(x) = \frac{1-x}{(1-x-x^2)(1+x-x^2)}
\end{align}

But when I chuck this in Mathematica it gives me $1-x+3x^2-3x^3+8x^4-8x^5+21x^6-21x^7 + …$. What went wrong?

Best Answer

What Mathematica gives you indicates that you're close. The desired terms are repeated, and those repeats are because of the $1-x$ in the numerator, so the correct answer is $$\frac{x^2}{(1-x-x^2)(1+x-x^2)}=\frac{x^2}{1-3x^2+x^4}$$ where the $x^2$ shifts the series so $F_0=0$ is the $x^0$ coefficient.

Related Question