## 2017年5月22日月曜日

### 数学 - Python - 解析学 - 微分と基本的な関数 - 微分係数、導関数 - 合成微分律(三角関数、指数関数、対数関数)

1. $3{x}^{2}\mathrm{cos}\left({x}^{3}+1\right)$

2. $-3{x}^{2}\mathrm{sin}\left({x}^{3}+1\right)$

3. $3{x}^{2}{e}^{{x}^{3}+1}$

4. $\frac{3{x}^{2}}{{x}^{3}+1}$

5. $-\mathrm{sin}x\mathrm{cos}\left(\mathrm{cos}x\right)$

6. $-\mathrm{cos}x\mathrm{sin}\left(\mathrm{sin}x\right)$

7. $3{x}^{2}{e}^{\mathrm{sin}\left({x}^{3}+1\right)}\mathrm{cos}\left({x}^{3}+1\right)$

8. $\frac{3{x}^{2}\mathrm{cos}\left({x}^{3}+1\right)}{\mathrm{sin}\left({x}^{3}+1\right)}$

9. $\left({x}^{2}+2+\left(x+1\right)2x\right)\mathrm{cos}\left(\left(x+1\right)\left({x}^{2}+2\right)\right)$

10. $\frac{4x+3}{2{x}^{2}+3x+5}$

11. $\left(x-3+x+1\right){e}^{\left(x+1\right)\left(x-3\right)}$

12. $2{e}^{2x+1}$

13. $2\mathrm{cos}\left(2x+5\right)$

14. $-7\mathrm{sin}\left(7x+1\right)$

15. $\frac{2}{2x+1}$

16. $\frac{x+3}{2x+1}·\frac{2\left(x+3\right)-\left(2x+1\right)}{{\left(x+3\right)}^{2}}$

17. $\frac{2x+4-\left(x-4\right)2}{{\left(2x+4\right)}^{2}}\mathrm{cos}\frac{x-5}{2x+4}$

18. $-\frac{2\left(x+3\right)-\left(2x-1\right)}{{\left(x+3\right)}^{2}}\mathrm{sin}\frac{2x-1}{x+3}$

19. $\left(4x+3\right){e}^{2{x}^{2}+3x+1}$

20. $\frac{12{x}^{2}-2}{4{x}^{3}-2x}$

21. $\frac{1}{2x+1}\mathrm{cos}\left(\mathrm{log}\left(2x+1\right)\right)$

22. $-2{e}^{2x}\mathrm{sin}\left({e}^{2x}\right)$

23. $-\left(6x-2\right)\mathrm{sin}\left(3{x}^{2}-2x+1\right)$

24. $\frac{2x\left(2{x}^{3}+1\right)-\left({x}^{2}-1\right)6x}{\left(2{x}^{3}+1\right)}\mathrm{cos}\frac{{x}^{2}-1}{2{x}^{3}+1}$

25. $80{\left(2x+1\right)}^{79}2$

26. $50{\left(\mathrm{sin}x\right)}^{49}\mathrm{cos}x$

27. $49{\left(\mathrm{log}x\right)}^{48}\frac{1}{x}$

28. $4{\left(\mathrm{sin}2x\right)}^{3}2\mathrm{cos}2x$

29. $5{\left({e}^{2x+1}-x\right)}^{4}\left(2{e}^{2x+1}-1\right)$

30. $20{\left(\mathrm{log}x\right)}^{19}\frac{1}{x}$

31. $\frac{1}{2}{\left(3\mathrm{log}\left({x}^{2}+1\right)-{x}^{3}\right)}^{-\frac{1}{2}}\left(\frac{3·2x}{{x}^{2}+1}-3{x}^{2}\right)$

32. $\frac{4}{3}{\left(\mathrm{log}\left(2x+3\right)\right)}^{\frac{1}{3}}\frac{2}{2x+3}$

33. $\frac{2\mathrm{cos}2x+\mathrm{sin}2x3\mathrm{cos}3x}{{\mathrm{cos}}^{2}3x}$

34. $\frac{2\mathrm{cos}\left(2x+5\right)\mathrm{cos}\left({x}^{2}-1\right)+2x\mathrm{sin}\left(2x+5\right)\mathrm{sin}\left({x}^{2}-1\right)}{{\mathrm{cos}}^{2}\left({x}^{2}-1\right)}$

35. $\frac{\frac{4x}{2{x}^{2}}\mathrm{sin}{x}^{3}-\mathrm{log}2{x}^{2}3{x}^{2}\mathrm{cos}{x}^{3}}{{\mathrm{sin}}^{2}{x}^{3}}$

36. $\frac{3{x}^{2}{e}^{{x}^{3}}\left({x}^{2}-1\right)-{e}^{{x}^{3}}2x}{{\left({x}^{2}-1\right)}^{2}}$

37. $\frac{4{x}^{3}\mathrm{cos}2x+\left({x}^{4}+4\right)2\mathrm{sin}2x}{{\mathrm{cos}}^{2}2x}$

38. $\frac{3{x}^{2}\mathrm{cos}\left({x}^{3}-2\right)\mathrm{sin}2x-2\mathrm{sin}\left({x}^{3}-2\right)\mathrm{cos}2x}{{\mathrm{sin}}^{2}2x}$

39. $\frac{4{\left(2{x}^{2}+1\right)}^{3}4x+3{x}^{2}{\left(2{x}^{2}+1\right)}^{4}\mathrm{sin}{x}^{3}}{{\mathrm{cos}}^{2}{x}^{3}}$

40. $\frac{-{e}^{-x}\mathrm{cos}2x+2{e}^{-x}\mathrm{sin}2x}{{\mathrm{cos}}^{2}2x}$

41. $-3{e}^{-3x}$

42. $-2x{e}^{-{x}^{2}}$

43. $\left(-8x+1\right){e}^{-4{x}^{2}+x}$

44. $\frac{1}{2}{\left({e}^{x}+1\right)}^{-\frac{1}{2}}{e}^{x}$

45. $\frac{\frac{2x}{{x}^{2}+2}{e}^{-x}+\mathrm{log}\left({x}^{2}+2\right){e}^{-x}}{{e}^{-2x}}$

46. $\frac{\frac{2}{2x+1}\mathrm{sin}\left(4x+5\right)-4\mathrm{log}\left(2x+1\right)\mathrm{cos}\left(4x+5\right)}{{\mathrm{sin}}^{2}\left(4x+5\right)}$

コード(Emacs)

#!/usr/bin/env python3
# -*- coding: utf-8 -*-

from sympy import Symbol, pprint, Derivative, sqrt, log, exp, sin, cos

x = Symbol('x')
exprs = [
exp(-x) / cos(2 * x),
exp(-3 * x),
exp(-x**2),
exp(-4 * x ** 2 + x),
sqrt(exp(x) + 1),
log(x ** 2 + 2) / exp(-x),
log(2 * x + 1) / sin(4 * x + 5)
]

for i, expr in enumerate(exprs, 64):
print('{0}.'.format(i))
pprint(expr)
pprint(Derivative(expr).doit())


$./sample25.py 64. -x ℯ ──────── cos(2⋅x) -x -x 2⋅ℯ ⋅sin(2⋅x) ℯ ────────────── - ──────── 2 cos(2⋅x) cos (2⋅x) 65. -3⋅x ℯ -3⋅x -3⋅ℯ 66. 2 -x ℯ 2 -x -2⋅x⋅ℯ 67. 2 - 4⋅x + x ℯ 2 - 4⋅x + x (-8⋅x + 1)⋅ℯ 68. ________ ╱ x ╲╱ ℯ + 1 x ℯ ───────────── ________ ╱ x 2⋅╲╱ ℯ + 1 69. x ⎛ 2 ⎞ ℯ ⋅log⎝x + 2⎠ x 2⋅x⋅ℯ x ⎛ 2 ⎞ ────── + ℯ ⋅log⎝x + 2⎠ 2 x + 2 70. log(2⋅x + 1) ──────────── sin(4⋅x + 5) 4⋅log(2⋅x + 1)⋅cos(4⋅x + 5) 2 - ─────────────────────────── + ────────────────────── 2 (2⋅x + 1)⋅sin(4⋅x + 5) sin (4⋅x + 5)$