I'm looking for the Laurent series around $x=0$ of a particularly resilient function.
$$f(x) = \frac{e^x+e^{-x}}{e^x-e^{-x}}\tag{1}$$
A.k.a. $f(x) = \text{coth}(x)$. I have found the first two terms—which was all I needed really—but the method I used generalised very poorly if I were to look for more terms. And wouldn't work at all if I was looking for the exact solution.
$$f(x) = \sum_{n=-\infty}^{\infty}a_n (x)^n\tag{2}$$
I have looked at my book on complex analysis. First, it is mostly concerned about weather a solution exist, and not so much, how to find it. Second, in the way it does discuss finding solutions, I am recommended rewriting the expression in terms of known series expansions, and reverse-engineer the solution using relations like the following.
$$\frac{1}{1-Y} = 1 + Y^2 + Y^3 + \cdots \;\;\;\; ; \;\;\;\; |Y|<1 \tag{3}$$
But I haven't found any way to rewrite equation $(1)$, in forms like the one in equation $(3)$. The problem is mainly that I don't know how to deal with the infinite series in the denominator.
$$ f(x) = \frac{e^x+e^{-x}}{e^x-e^{-x}}\tag{4} = \frac{\left(1+x+\frac{x^2}{2!}+\frac{x^3}{3!}\cdots\right) + \left(1-x+\frac{x^2}{2!}-\frac{x^3}{3!}+\cdots\right)} {\left(1+x+\frac{x^2}{2!}+\frac{x^3}{3!}\cdots\right) - \left(1-x+\frac{x^2}{2!}-\frac{x^3}{3!}+\cdots\right)} $$
Any solution that I have found begins by chopping the denominator at some suitable length. But then I will never reach the exact solution like in equation $(2)$. Right?
PS. In my original problem $x$ is a real number, so I used $x$ instead of $z$. But anyway..