## 2019年9月29日日曜日

### 数学 - Python - 解析学 - 各種の初等関数 - 三角関数(続き)、逆三角関数 - 双曲線関数、加法定理、指数関数、ネイピア数(オイラー数)、導関数

1. $\begin{array}{l}{\mathrm{cosh}}^{2}x-{\mathrm{sinh}}^{2}x\\ ={\left(\frac{{e}^{x}+{e}^{-x}}{2}\right)}^{2}-{\left(\frac{{e}^{x}-{e}^{-x}}{2}\right)}^{2}\\ =\frac{4{e}^{x}{e}^{-x}}{{2}^{2}}\\ =1\end{array}$

2. $\begin{array}{l}1-{\mathrm{tanh}}^{2}x\\ =1-{\left(\frac{{e}^{x}-{e}^{-x}}{{e}^{x}+{e}^{-x}}\right)}^{2}\\ =\frac{{\left({e}^{x}+{e}^{-x}\right)}^{2}-{\left({e}^{x}-{e}^{-x}\right)}^{2}}{{\left({e}^{x}+{e}^{-x}\right)}^{2}}\\ =\frac{{2}^{2}}{{\left({e}^{x}+{e}^{-x}\right)}^{2}}\\ =\frac{1}{{\mathrm{cosh}}^{2}x}\end{array}$

3. $\begin{array}{l}\mathrm{sinh}x\mathrm{cosh}y+\mathrm{cosh}x\mathrm{sinh}y\\ =\frac{{e}^{x}-{e}^{-x}}{2}·\frac{{e}^{y}+{e}^{-y}}{2}+\frac{{e}^{x}+{e}^{-x}}{2}·\frac{{e}^{y}-{e}^{-y}}{2}\\ =\frac{2{e}^{x+y}-2{e}^{-\left(x+y\right)}}{{2}^{2}}\\ =\frac{{e}^{x+y}-{e}^{-\left(x+y\right)}}{2}\\ =\mathrm{sinh}\left(x+y\right)\end{array}$

4. $\begin{array}{l}\mathrm{cosh}x\mathrm{cosh}y+\mathrm{sinh}x\mathrm{sinh}y\\ =\frac{{e}^{x}+{e}^{-x}}{2}·\frac{{e}^{y}+{e}^{-y}}{2}+\frac{{e}^{x}-{e}^{-x}}{2}·\frac{{e}^{y}-{e}^{-y}}{2}\\ =\frac{2{e}^{x+y}+2{e}^{-\left(x+y\right)}}{{2}^{2}}\\ =\frac{{e}^{x+y}+{e}^{-\left(x+y\right)}}{2}\\ =\mathrm{cosh}\left(x+y\right)\end{array}$

5. $\begin{array}{l}\frac{d}{\mathrm{dx}}\mathrm{sinh}x\\ =\frac{{e}^{x}+{e}^{-x}}{2}\\ =\mathrm{cosh}x\\ \frac{d}{\mathrm{dx}}\mathrm{cosh}x\\ =\frac{{e}^{x}-{e}^{-x}}{2}\\ =\mathrm{sinh}x\\ \frac{d}{\mathrm{dx}}\mathrm{tanh}x\\ =\frac{\left({e}^{x}+{e}^{-x}\right)\left({e}^{x}+{e}^{-x}\right)-\left({e}^{x}-{e}^{-x}\right)\left({e}^{x}-{e}^{-x}\right)}{{\left({e}^{x}+{e}^{-x}\right)}^{2}}\\ =\frac{4}{{\left({e}^{x}+{e}^{-x}\right)}^{2}}\\ ={\left(\frac{2}{{e}^{x}+{e}^{-x}}\right)}^{2}\\ =\frac{1}{{\mathrm{cosh}}^{2}x}\end{array}$

コード

Python 3

#!/usr/bin/env python3
from sympy import pprint, symbols, sinh, cosh, tanh, plot

print('14.')

x = symbols('x')

p = plot(sinh(x), cosh(x), tanh(x),
ylim=(-10, 10),
show=False,
legend=True)

colors = ['red', 'green', 'blue', 'brown', 'orange',
'purple', 'pink', 'gray', 'skyblue', 'yellow']

for o, color in zip(p, colors):
o.line_color = color

p.show()
p.save(f'sample14.png')


$./sample14.py 14.$