The question is in the title
if not, I'd like to know why it doesn't work
Thanks in advance.
The question is in the title
if not, I'd like to know why it doesn't work
Thanks in advance.
On
The ratio does not write as a Taylor series directly. To do so, the product and composition rules are used. Recognizing the Taylor series $\frac{1}{1-u} = 1 + u + \dots$, one writes \begin{equation} \begin{aligned} \frac{\sin x}{\cos x} &= \left(x - \frac{x^3}{6} + \dots\right) \frac{1}{1 - \frac{x^2}{2} + \dots}\\ &= \left(x - \frac{x^3}{6} + \dots\right)\left(1 + \frac{x^2}{2} + \dots\right) \\ &= x + \frac{x^3}{3} + \dots \, , \end{aligned} \end{equation} which is the Taylor series of $\tan$.
An important point is convergence. The Taylor series of $\sin$ and $\cos$ are convergent all over $\mathbb{R}$, whereas the Taylor series of $\tan$ is convergent over $]-\pi/2,\pi/2[$.
Note: another technique to obtain the Taylor series of $\tan$ consists in exploiting the fact that $\tan$ is an odd function, and the relationship with the derivative $\tan' = 1 + \tan^2$.
On
$\newcommand{\bbx}[1]{\,\bbox[8px,border:1px groove navy]{\displaystyle{#1}}\,} \newcommand{\braces}[1]{\left\lbrace\,{#1}\,\right\rbrace} \newcommand{\bracks}[1]{\left\lbrack\,{#1}\,\right\rbrack} \newcommand{\dd}{\mathrm{d}} \newcommand{\ds}[1]{\displaystyle{#1}} \newcommand{\expo}[1]{\,\mathrm{e}^{#1}\,} \newcommand{\ic}{\mathrm{i}} \newcommand{\mc}[1]{\mathcal{#1}} \newcommand{\mrm}[1]{\mathrm{#1}} \newcommand{\pars}[1]{\left(\,{#1}\,\right)} \newcommand{\partiald}[3][]{\frac{\partial^{#1} #2}{\partial #3^{#1}}} \newcommand{\root}[2][]{\,\sqrt[#1]{\,{#2}\,}\,} \newcommand{\totald}[3][]{\frac{\mathrm{d}^{#1} #2}{\mathrm{d} #3^{#1}}} \newcommand{\verts}[1]{\left\vert\,{#1}\,\right\vert}$
A recursive approach.
$$ \sin\pars{x} \equiv \sum_{n = 0}^{\infty}s_{n}x^{2n + 1}\,,\qquad \cos\pars{x} \equiv \sum_{n = 0}^{\infty}c_{n}x^{2n}\,,\qquad \tan\pars{x} \equiv \sum_{n = 0}^{\infty}t_{n}x^{2n + 1} $$ where $\ds{s_{n} = {\pars{-1}^{n} \over \pars{2n + 1}!}}$ and $\ds{c_{n} = {\pars{-1}^{n} \over \pars{2n}!}}$
From the last expression I'll get a recursive relation for $\ds{\braces{t_{j}}}$. Namely,
$$ \left\{\begin{array}{rcl} \ds{t_{0}} & \ds{=} & \ds{1} \\ \ds{t_{n}} & \ds{=} & \ds{s_{n} - \sum_{j = 0}^{n - 1}c_{n - j}t_{j} = \pars{-1}^{n}\bracks{{1 \over \pars{2n + 1}!} - \sum_{j = 0}^{n - 1} {\pars{-1}^{\,j} \over \pars{2n - 2j}!}\,t_{j}}\,,\qquad n \geq 1} \end{array}\right. $$
It works, indeed but it is slightly tedious $$\sin(x)=x-\frac{x^3}{6}+\frac{x^5}{120}-\frac{x^7}{5040}+\frac{x^9}{362880}+O\left(x^{11}\right)$$ $$\cos(x)=1-\frac{x^2}{2}+\frac{x^4}{24}-\frac{x^6}{720}+\frac{x^8}{40320}-\frac{x^{10}}{3628 800}+O\left(x^{11}\right)$$ $$\tan(x)=\frac{\sin(x)}{\cos(x)}=\frac{x-\frac{x^3}{6}+\frac{x^5}{120}-\frac{x^7}{5040}+\frac{x^9}{362880}+O\left(x^{11}\right)}{1-\frac{x^2}{2}+\frac{x^4}{24}-\frac{x^6}{720}+\frac{x^8}{40320}-\frac{x^{10}}{3628 800}+O\left(x^{11}\right)}$$ Now, long division to get $$\tan(x)=x+\frac{x^3}{3}+\frac{2 x^5}{15}+\frac{17 x^7}{315}+\frac{62 x^9}{2835}+O\left(x^{11}\right)$$