# Why I cannot simplify these two summations?

I was thinking about Maclaurin Series to compute sin, cos and tan. It was in a Python programming group and we started to think about simplification of tan, based on sin/cos formula. As both have summations, but their interval are the same ($n=1$ to $\infty$), I thought that I could write them in single summation of the quotient of both.

$$\sin x= \sum_{n=0}^{\infty} \frac{(-1)^n}{(2n+1)!} x^{2n+1} = \sum_{n=0}^{\infty} \frac{(-1)^n}{(2n)!(2n+1)} x^{2n}x$$

$$\cos x= \sum_{n=0}^{\infty} \frac{(-1)^n}{(2n)!} x^{2n}$$

$$\frac{\sin x}{\cos x} = \frac{\sum_{n=0}^{\infty} \frac{(-1)^n}{(2n)!(2n+1)} x^{2n}x}{\sum_{n=0}^{\infty} \frac{(-1)^n}{(2n)!} x^{2n}} = \sum_{n=0}^{\infty} \frac{(-1)^n x^{2n}x}{(2n)!(2n+1)} \times \frac{(2n)!}{(-1)^n x^{2n}} = \sum_{n=0}^{\infty} \frac{x}{2n+1}$$

But the result is far from correct. Can anyone help me understand why I cannot join these two summations in a single one (as they have the same period/interval)?

I understand the result is incorrect, but I could not figure out why.

• $(a+b)/(c+d) \neq a/c + b/d$. You are confusing sums with products. Apr 12 '17 at 13:42
• I once did this exact same thing. Easy mistake to make. Good for you for catching it and asking about it. Apr 12 '17 at 13:47

$$\dfrac{a+b}{c+d} = \dfrac{a}{b} + \dfrac{c}{d}$$