I am required to find the Fourier Series of the following function, on $[-\pi,\pi]$:
$$f(x)=\frac{4-2\cos(x)}{5-4\cos(x)}$$
This question seemed simple, at first. I managed to compute $a_0$ (which wasn't too easy) and noticed that $b_n=0$ for all $n\in\mathbb{N}$ (since the given $f$ is even). However, computing the coefficients $a_n$ seemed like an impossible mission. So I cheated a little, and looked at the final answer, which is:
$$f(x)\simeq1+\sum_{n=1}^{\infty}\frac{1}{2^n}\cos(nx)\triangleq\mathfrak{F}(x)$$
The problem is $a_n$ - I don't know how to compute them, and therefore I couldn't find the Fourier Series by myself. However, after finding out what the final answer is, I thought of a creative way to show the final answer is actually the Fourier Series of $f(x)$. This is kind of cheating, but I'll show my solution anyway:
Let $z=\frac{\cos(x)+i\sin(x)}{2}, z\in\mathbb{C}.$ Using the fact that $z^n=\frac{\cos(nx)+i\sin(nx)}{2^n}$, and that $|z|=\frac 12<1$, we receive:
$$\mathfrak{F}(x)=\sum_{n=0}^{\infty}\Re{(z^n)}=\Re{\left(\sum_{n=0}^{\infty}z^n\right)}=\Re{\left(\frac{1}{1-z}\right)}$$$$=\Re{\left(\frac{1-\bar{z}}{|1-z|^2}\right)}=\Re{\left(\frac{1-0.5\cos(x)+0.5i\sin(x)}{(1-0.5\cos(x))^2+(0.5\sin(x))^2}\right)}$$$$=\frac{1-0.5\cos(x)}{1-\cos(x)+0.25\cos^2(x)+0.25\sin^2(x)}=\frac{4-2\cos(x)}{5-4\cos(x)}\equiv f(x)$$
We know that $f(x)$ is differentiable everywhere. Therefore, it has only one Fourier Series, and it has to be $\mathfrak{F}(x)$, since it is a Fourier Series that converges to $f(x)$. This might not be a true statement (so please correct me if so), but either way, I would like to hear your thoughts about a more legit solution to the problem (without knowing the Fourier Series in advance).
Write $2\cos(x) = z+z^{-1}$ for some $\lvert z \rvert = 1$. Then $$\frac{4-2\cos(x)}{5-4\cos(x)} = \frac{4-z-z^{-1}}{5-2z-2z^{-1}}=\frac12 + \frac1{2-z} + \frac1{4z-2}.$$ Since $\lvert z \rvert = 1$ this expands as $$\frac12 + \frac12 \sum_{n=0}^{\infty}\frac{z^n}{2^n} + \frac12 \sum_{n=1}^{\infty}\frac{z^{-n}}{2^n} = 1 + \frac12 \sum_{n=1}^{\infty} \frac{z^n+z^{-n}}{2^n}.$$ The Fourier series is apparent from this expansion.