Loading [MathJax]/jax/output/HTML-CSS/jax.js

2019年9月19日木曜日

学習環境

解析入門(上) (松坂和夫 数学入門シリーズ 4) (松坂 和夫(著)、岩波書店)の第5章(各種の初等関数)、5.4(三角関数(続き)、逆三角関数)、問題8の解答を求めてみる。



    1. limh0f(0+h)=limh0f(h)=limh0hmsin1hn=0

      よって、 関数 f は 0において連続である。

      (証明終)


    2. limh0f(0+h)-f(0)h=limh0f(h)h=limh0hmsin1hnh=limh0hm-1sin1hn

      この極極が存在するのは、

      limh0hm-1=0

      のとき、 すなわち

      m-1>0m>1

      のときである。

      (証明終)


    3. x0f'(x)=mxm-1sin1xn+xm(cos1xn)(-nxn-1x2n)=mxm-1sin1xn-x(m-n-1)cos1xn

      よって、 0において連続、 すなわち

      limx0f'(x)=0

      を満たすのは、

      m-n-1>0m>n+1

      のときである。

      (証明終)


    4. limh0f'(0+h)-f'(0)h=limh0f'(h)h=limh01h(mhm-1sin1hn-h(m-n-1)cos1hn)=limh0(mhm-2sin1hn-h(m-n-2)cos1hn)

      この極限が存在するのは、

      m-2>0m-n-2>0m>n+2

      のとき o

      (証明終)


    5. x0f''(x)=m(m-1)xm-2sin1xn+mxm-1(cos1xn)-nxn-1x2n-(m-n-1)x(m-n-2)cos1xn-x(m-n-1)(-sin1xn)·-nxn-1x2n

      よって、

      limx0f''(x)=0

      となるのは、

      m-2>0m-n-2>0m-2n-2>0m>2n+2

      のとき。

      (証明終)

コード

Python 3

#!/usr/bin/env python3
from sympy import pprint, symbols, sin, Derivative, plot

print('8.')

x = symbols('x')
n = 2
ms = [n + m for m in range(1, 5)]

fs = [x ** m * sin(1 / x ** n) for m in ms]
for i, g in enumerate(fs):
    gs = []
    for l in range(3):
        d = Derivative(g, x, l)
        d1 = d.doit()
        gs.append(d1)
        for o in [d, d1]:
            pprint(o)
            print()
    p = plot(*[(g, (x, -1, -0.00001)) for g in gs],
             *[(g, (x, 0.00001, 1)) for g in gs],
             ylim=(-1, 1),
             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('sample8_{i}.png')

入出力結果(Bash、cmd.exe(コマンドプロンプト)、Terminal、Jupyter(IPython))

C:\Users\...>py sample8.py
8.
 3    ⎛1 ⎞
x ⋅sin⎜──⎟
      ⎜ 2⎟
      ⎝x ⎠

 3    ⎛1 ⎞
x ⋅sin⎜──⎟
      ⎜ 2⎟
      ⎝x ⎠

d ⎛ 3    ⎛1 ⎞⎞
──⎜x ⋅sin⎜──⎟⎟
dx⎜      ⎜ 2⎟⎟
  ⎝      ⎝x ⎠⎠

   2    ⎛1 ⎞        ⎛1 ⎞
3⋅x ⋅sin⎜──⎟ - 2⋅cos⎜──⎟
        ⎜ 2⎟        ⎜ 2⎟
        ⎝x ⎠        ⎝x ⎠

  2            
 d ⎛ 3    ⎛1 ⎞⎞
───⎜x ⋅sin⎜──⎟⎟
  2⎜      ⎜ 2⎟⎟
dx ⎝      ⎝x ⎠⎠

  ⎛                               ⎛1 ⎞            ⎞
  ⎜                          2⋅sin⎜──⎟            ⎟
  ⎜                               ⎜ 2⎟            ⎟
  ⎜                   ⎛1 ⎞        ⎝x ⎠        ⎛1 ⎞⎟
  ⎜              3⋅cos⎜──⎟ - ─────────   6⋅cos⎜──⎟⎟
  ⎜                   ⎜ 2⎟        2           ⎜ 2⎟⎟
  ⎜       ⎛1 ⎞        ⎝x ⎠       x            ⎝x ⎠⎟
2⋅⎜3⋅x⋅sin⎜──⎟ + ───────────────────── - ─────────⎟
  ⎜       ⎜ 2⎟             x                 x    ⎟
  ⎝       ⎝x ⎠                                    ⎠

 4    ⎛1 ⎞
x ⋅sin⎜──⎟
      ⎜ 2⎟
      ⎝x ⎠

 4    ⎛1 ⎞
x ⋅sin⎜──⎟
      ⎜ 2⎟
      ⎝x ⎠

d ⎛ 4    ⎛1 ⎞⎞
──⎜x ⋅sin⎜──⎟⎟
dx⎜      ⎜ 2⎟⎟
  ⎝      ⎝x ⎠⎠

   3    ⎛1 ⎞          ⎛1 ⎞
4⋅x ⋅sin⎜──⎟ - 2⋅x⋅cos⎜──⎟
        ⎜ 2⎟          ⎜ 2⎟
        ⎝x ⎠          ⎝x ⎠

  2            
 d ⎛ 4    ⎛1 ⎞⎞
───⎜x ⋅sin⎜──⎟⎟
  2⎜      ⎜ 2⎟⎟
dx ⎝      ⎝x ⎠⎠

  ⎛                                ⎛1 ⎞⎞
  ⎜                           2⋅sin⎜──⎟⎟
  ⎜                                ⎜ 2⎟⎟
  ⎜   2    ⎛1 ⎞        ⎛1 ⎞        ⎝x ⎠⎟
2⋅⎜6⋅x ⋅sin⎜──⎟ - 5⋅cos⎜──⎟ - ─────────⎟
  ⎜        ⎜ 2⎟        ⎜ 2⎟        2   ⎟
  ⎝        ⎝x ⎠        ⎝x ⎠       x    ⎠

 5    ⎛1 ⎞
x ⋅sin⎜──⎟
      ⎜ 2⎟
      ⎝x ⎠

 5    ⎛1 ⎞
x ⋅sin⎜──⎟
      ⎜ 2⎟
      ⎝x ⎠

d ⎛ 5    ⎛1 ⎞⎞
──⎜x ⋅sin⎜──⎟⎟
dx⎜      ⎜ 2⎟⎟
  ⎝      ⎝x ⎠⎠

   4    ⎛1 ⎞      2    ⎛1 ⎞
5⋅x ⋅sin⎜──⎟ - 2⋅x ⋅cos⎜──⎟
        ⎜ 2⎟           ⎜ 2⎟
        ⎝x ⎠           ⎝x ⎠

  2            
 d ⎛ 5    ⎛1 ⎞⎞
───⎜x ⋅sin⎜──⎟⎟
  2⎜      ⎜ 2⎟⎟
dx ⎝      ⎝x ⎠⎠

    ⎛                                 ⎛1 ⎞⎞
    ⎜                            2⋅sin⎜──⎟⎟
    ⎜                                 ⎜ 2⎟⎟
    ⎜    2    ⎛1 ⎞        ⎛1 ⎞        ⎝x ⎠⎟
2⋅x⋅⎜10⋅x ⋅sin⎜──⎟ - 7⋅cos⎜──⎟ - ─────────⎟
    ⎜         ⎜ 2⎟        ⎜ 2⎟        2   ⎟
    ⎝         ⎝x ⎠        ⎝x ⎠       x    ⎠

 6    ⎛1 ⎞
x ⋅sin⎜──⎟
      ⎜ 2⎟
      ⎝x ⎠

 6    ⎛1 ⎞
x ⋅sin⎜──⎟
      ⎜ 2⎟
      ⎝x ⎠

d ⎛ 6    ⎛1 ⎞⎞
──⎜x ⋅sin⎜──⎟⎟
dx⎜      ⎜ 2⎟⎟
  ⎝      ⎝x ⎠⎠

   5    ⎛1 ⎞      3    ⎛1 ⎞
6⋅x ⋅sin⎜──⎟ - 2⋅x ⋅cos⎜──⎟
        ⎜ 2⎟           ⎜ 2⎟
        ⎝x ⎠           ⎝x ⎠

  2            
 d ⎛ 6    ⎛1 ⎞⎞
───⎜x ⋅sin⎜──⎟⎟
  2⎜      ⎜ 2⎟⎟
dx ⎝      ⎝x ⎠⎠

     ⎛                                 ⎛1 ⎞⎞
     ⎜                            2⋅sin⎜──⎟⎟
     ⎜                                 ⎜ 2⎟⎟
   2 ⎜    2    ⎛1 ⎞        ⎛1 ⎞        ⎝x ⎠⎟
2⋅x ⋅⎜15⋅x ⋅sin⎜──⎟ - 9⋅cos⎜──⎟ - ─────────⎟
     ⎜         ⎜ 2⎟        ⎜ 2⎟        2   ⎟
     ⎝         ⎝x ⎠        ⎝x ⎠       x    ⎠


C:\Users\...>

0 コメント:

コメントを投稿