14
$\begingroup$

The functions $\tanh x$ and $\arctan x$ have a similar graph. Is there a formula to transform $\tanh x$ to $\arctan x$?

  • 0
    Is an identity like $\mathrm{tanh}(ix)=i\mathrm{tan}(x)$ what you're looking for?2011-12-18

6 Answers 6

23

The two functions resemble each other on the real line, but they're not the only sigmoidal functions around. There are functions as simple as $\dfrac{x}{\sqrt{1+x^2}}$ and as complicated as $\dfrac2{\sqrt \pi}\int_0^x e^{-t^2}\mathrm dt$ that also have the s-shape.

Also, the resemblance ends when we look at their behavior for complex arguments:

arctangent plots

hyperbolic tangent plots

The former possesses branch cuts, while the latter exhibits periodicity on the imaginary axis.

On the other hand, a look at the Maclaurin series for $\tan\tanh\,z$ and $\mathrm{artanh}\arctan\,z$ gives a clue as to why there is some resemblance between $\arctan$ and $\tanh$:

$\begin{align*} \tan\tanh\,z&=z-\frac{z^5}{15}+\frac{z^7}{45}-\frac{z^9}{2835}-\frac{13 z^{11}}{4725}+\cdots\\ \mathrm{artanh}\arctan\,z&=z+\frac{z^5}{15}-\frac{z^7}{45}+\frac{64 z^9}{2835}-\frac{71 z^{11}}{4725}+\cdots \end{align*}$

10

There is the identity $\arcsin(\tanh x) = \arctan(\sinh x)$, if that's what you're looking for. See Gudermannian function on Wikipedia.

  • 0
    ...and the Gudermannian is yet another fine example of a sigmoidal function...2011-12-19
10

There is no formula that "transforms $\tanh x$ to $\arctan x$" even though the graphs of the two functions look apparently similar: Both functions are odd, are defined on all of ${\mathbb R}$, and for $x>0$ are monotonically increasing to some finite limit. But that's where the similarities end: In particular

${\pi\over2}-\arctan(x)\sim{1\over x}\ ,\qquad 1-\tanh(x)\sim 2e^{-2x}$

when $x\to\infty$. This shows that the asymptotic behavior of the two functions is completely different.

As indicated in other answers, $\tan$ and $\tanh$ are related to the function $\exp$ whereas $\arctan$ and ${\rm artanh}$ are related to the function $\log$, whereby the transition from trigonometric functions to hyperbolic ones lives in the complex domain.

3

They are only similar around the origin because their Taylor series agree up to fourth order, that is,

$\begin{align*} \tanh(x) &= x -x^3/3 + 2x^5/15 + O(x^7)\\ \arctan(x) &= x - x^3/3 + x^5/5 + O(x^7) \end{align*}$

I don't believe there is any deeper reason why these look alike, since one is an inverse trigonometric function, while the other is a hyperbolic function (not an inverse).

2

If you define $f(t) = \arctan(\text{arctanh}(t))$, you'll have $f(\tanh(x)) = \arctan(x)$. $f$ is analytic in $|t|<1$, with Maclaurin series $f(t) = t + \frac{t^5}{15} + \frac{t^7}{45} + \frac{64}{2835} t^9 + \frac{71}{4725} x^{11}+ \ldots$

0

If we let $f$ and $g$ be defined by

$\begin{align} f&:\mathbb{C}\to\mathbb{C}\\ &z\mapsto -i\tanh(z)\\ g&:\mathbb{R}\to\mathbb{C}\\ &:x\mapsto i\arctan(x) \end{align}$

Then $f$ and $g$ are semi-inverses, in the sense that $f\circ g=$ is the identity map.

Another way to say the same thing: If we consider multiplication by $i$ as a function represented by $\mu_i$, then $\mu_i^{-1}\circ\tanh\circ \mu_i\circ\arctan=\mathrm{id}_{\mathbb{R}}$

So there is this relationship between the functions, along with all the others mentioned in other answers.