<s>[INST] To get addition formula of $\tan (x)$ via analytic methods Assume that we only know  $\tan (0)=0$  and also given  the relation $\tan'(x)=1+\tan^2(x)$ about $\tan (x)$ and we do not know other $\tan (x)$ relations of trigonometry.
How can I get the additon formula $$ \tan (x+h)=\frac{\tan(x)+\tan(h)}{1-\tan(x)\tan(h)}$$  via  using the differential equation ($\tan'(x)=1+\tan^2(x)$) and analytic methods ? (without using geometry)
Could you please provide me with an easy way to get addition formula of $\tan (x+h)$ ?
My attempt:
$$\tan'(x)=1+\tan^2(x)$$
$$\int \frac{d\tan(x)}{1+\tan^2(x)}=\int dx$$
$$\tan(x)- \frac{\tan^3(x)}{3}+ \frac{\tan^5(x)}{5}+....=x$$
$$\tan(h)- \frac{\tan^3(h)}{3}+ \frac{\tan^5(h)}{5}+....=h$$
$$+$$
$$\tan(x)+\tan(h)- (\frac{\tan^3(x)}{3}+\frac{\tan^3(h)}{3})+ (\frac{\tan^5(x)}{5}+\frac{\tan^5(h)}{5})+....=x+h$$
$$\tan(x+h)- \frac{\tan^3(x+h)}{3}+ \frac{\tan^5(x+h)}{5}+....=x+h$$
$$\tan(x+h)- \frac{\tan^3(x+h)}{3}+ \frac{\tan^5(x+h)}{5}+....=\tan(x)+\tan(h)- (\frac{\tan^3(x)}{3}+\frac{\tan^3(h)}{3})+ (\frac{\tan^5(x)}{5}+\frac{\tan^5(h)}{5})+....=x+h$$
Let's define that $\tan(x+h)=\tan(x)+\tan(h)+P(x,h)$
$$(\tan(x)+\tan(h)+P(x,h))- \frac{(\tan(x)+\tan(h)+P(x,h))^3}{3}+ \frac{(\tan(x)+\tan(h)+P(x,h))^5}{5}+....=\tan(x)+\tan(h)- (\frac{\tan^3(x)}{3}+\frac{\tan^3(h)}{3})+ (\frac{\tan^5(x)}{5}+\frac{\tan^5(h)}{5})+....$$
$$P(x,h)- \frac{(\tan(x)+\tan(h))^3+ 3 (\tan(x)+\tan(h))^2 P(x,h)+3 (\tan(x)+\tan(h)) P(x,h)^2+P(x,h)^3}{3}+ \frac{(\tan(x)+\tan(h)+P(x,h))^5}{5}+....=- (\frac{\tan^3(x)}{3}+\frac{\tan^3(h)}{3})+ (\frac{\tan^5(x)}{5}+\frac{\tan^5(h)}{5})+....$$
Let's define that
$$P(x,h)= \tan(x)\tan(h)(\tan(x)+\tan(h))+G(x,h) $$
thus we get 
$\tan(x+h)=\tan(x)+\tan(h)+\tan(x)\tan(h)(\tan(x)+\tan(h))+G(x,h)$
I know  we can find the solution in my method but so many calculations are needed in that method. It is very very long way. 
And Finally I  need to get that $$ \tan (x+h)=\frac{\tan(x)+\tan(h)}{1-\tan(x)\tan(h)}=(\tan(x)+\tan(h))(1-\tan(x)\tan(h))^{-1}=(\tan(x)+\tan(h))(1+\tan(x)\tan(h)+\tan^2(x)\tan^2(h)+......)$$
Note:I try to get addition formulas from a given differential equations and initial conditions.
I  wish to find a method to get a closed form addition formulas for the problem as shown below.
$U(0)=0$  and also given the relation $U'(x)=1+U^n(x)$  where $n>2$
Thanks a lot for answers
 [/INST] Here is my approach:
Let
$$
\arctan(x) := \int_0^x \frac{dt}{1+t^2}
$$
and $\tan(x)$ is defined as the inverse of $\arctan(x)$, so that $\tan(0) = 0$.
Consider the differential equation
$$
\frac{d x}{1+x^2} + \frac{dy}{1+y^2} = 0 \tag{DE},
$$
one solution is
$$
\arctan x + \arctan y = c,
$$
but the equation has also the solution
$$
\frac{x + y}{1 - x y} = C.
$$
Since the differential equation has but one distinct solution, the two solutions must be related to one another in a definite way. This relation is expressed by the equation
$$
C = f(c)
$$
Now, let
$$
x = \tan u, \quad y = \tan v,
$$
then
\begin{align}
u + v &= c \\ \\
\frac{\tan u + \tan v}{1 - \tan u \tan v} &= f(c) = f(u +v)
\end{align}
Let $v = 0$, then
$$
\tan u = f(u)
$$
and therefore
$$
\color{blue}{\frac{\tan u + \tan v}{1 - \tan u \tan v} = \tan(u + v).}
$$

Construction of the second solution
Let $x = \tan u$ and $y = \tan v$. By definition
$$
\frac{d x}{d u} = 1 + x^2 \quad \Longrightarrow \quad \frac{d^2 x}{d u^2} = 2x(1+x^2).
$$
Similarly
$$
\frac{d y}{d u} = -\frac{d y}{d v} = -(1+y^2), \mbox{ and } \frac{d^2 y}{d u^2} = \frac{d^2 y}{d v^2} = 2y(1+y^2)
$$
from which follows that
$$
x \frac{d^2 y}{d u^2} - y \frac{d^2 x}{d u^2} = 2xy(y^2 - x^2)
$$
and
$$
x^2\left(\frac{d y}{d u}\right)^2 - y^2 \left(\frac{d x}{d u}\right)^2 = (x^2 - y^2)(1 - x^2 y^2)
$$
Hence
$$
\frac{x \frac{d^2 y}{d u^2} - y \frac{d^2 x}{d u^2}}{x \frac{d y}{d u} - y \frac{d x}{d u}} = - \left(x \frac{d y}{d u} + y \frac{d x}{d u}\right) \frac{2 x y}{1-x^2y^2}
$$
This equation is immediately integrable; the solution is
$$
\log\left(x \frac{d y}{d u} - y \frac{d x}{d u}\right) = \mbox{const.} + \log(1 - x^2 y^2)
$$
or
$$
x \frac{d y}{d v} + y \frac{d x}{d u} = C(1- x^2 y^2).
$$
Using this information, we can see that
$$
\Phi(x,y) = \frac{x(1+y^2) + y(1+x^2)}{1 - x^2 y^2} = \frac{x + y}{1 - x y} = C
$$
is also a solution of (DE).

Other Examples


*

*$\color{green}{\sin(x)}$


Let $y' = \sqrt{1-y^2}$. If we consider the (DE)
$$
\frac{d x}{\sqrt{1-x^2}} + \frac{d y}{\sqrt{1-y^2}} = 0
$$
and define
$$
\arcsin(x) = \int_0^x \frac{d t}{\sqrt{1-t^2}}dt
$$
where $\sin(x)$ is defined as the inverse of $\arcsin(x)$, so that $\sin(0) = 0$, and $\cos(x)$ is defined as $\sqrt{1-\sin^2 (x)}$, with the condition that $\cos(0) = 1$.
One solution for the (DE) is
$$
\arcsin x + \arcsin y = c.
$$
Using the same method as with $\tan(x)$, we can build a second solution:
Let $x = \sin u$, $y = \sin v$, by definition
$$
\frac{d x}{d u} = \sqrt{1-x^2}, \qquad \frac{d^2 x}{d u^2} = -x
$$
Similarly
$$
\frac{d y}{d u} = -\frac{d y}{d u} = -\sqrt{1-y^2}, \qquad \frac{d^2 y}{d u^2} = -y
$$
from which follows
$$
x \frac{d^2 y}{d u^2} - y \frac{d^2 x}{d u^2} = 0
$$
Hence
$$
\frac{x \frac{d^2 y}{d u^2} - y \frac{d^2 x}{d u^2}}{x \frac{d y}{d u} - y \frac{d x}{d u}} = 0
$$
Integrating
$$
x \frac{d y}{d v} + y \frac{d x}{d u} = C
$$
and another solution of the (DE) is
$$
x\sqrt{1-y^2} + y \sqrt{1-x^2} = C
$$
Recapitulating:
The (DE) has two solutions
$$
\arcsin x + \arcsin y = c,
$$
$$
x\sqrt{1-y^2} + y \sqrt{1-x^2} = C
$$
As with $\tan(x)$, the (DE) has but one solution, and the two solutions must be related to one another in a definite way $f(c) =C$.
Let $x = \sin u$ and $y = \sin v$, then
$$
u + v = c
$$
$$
\sin u \cos v + \sin v \cos u = f(c) = f(u+v)
$$
Setting $v = 0$ implies $f(u) = \sin u$ so
$$
\color{blue}{\sin u \cos v + \sin v \cos u = \sin(u +v)}
$$


*

*$\color{green}{\mbox{sn}(x)}$


Let $y' = (1-y^2)^{\frac{1}{2}}(1-k^2y^2)^{\frac{1}{2}}$. The (DE)
$$
\frac{dx}{(1-x^2)^{\frac{1}{2}}(1-k^2x^2)^{\frac{1}{2}}} +\frac{dy}{(1-y^2)^{\frac{1}{2}}(1-k^2y^2)^{\frac{1}{2}}} = 0
$$
has the solutions (using the same technique)
$$
\mbox{argsn } x + \mbox{argsn } y = c
$$
$$
x \frac{d y}{d v} + y \frac{d x}{d u} = C(1-k^2 x^2 y^2)
$$
Let $x = \mbox{sn }u$, $y = \mbox{sn }v$, then
$$
\color{blue}{\mbox{sn}(u+v) = \frac{\mbox{sn }u \,\mbox{sn}'v + \mbox{sn }v \,\mbox{sn}'u}{1-k^2 \mbox{sn}^2u \,\mbox{sn}^2v}}
$$


*

*$\color{green}{\wp(x)}$


Let $y' = \sqrt{4x^3-g_2x-g_3}$. In this case, the (DE) is of the form
$$
\frac{dx}{\sqrt{4x^3-g_2x-g_3}} + \frac{dy}{\sqrt{4y^3-g_2y-g_3}}
$$
and we can derive the addition formula
$$
\color{blue}{\wp(u + v) = - \wp(u) - \wp(v) + \frac{1}{4} \left\{\frac{\wp'(u)-\wp'(v)}{\wp(u)-\wp(v)} \right\}^2}
$$
</s>