## 2020年7月24日金曜日

### 数学 - Python - 解析学 - ベクトルの微分 - 微分係数 - 法平面、法線、速度ベクトル、垂直、内積、零、指数関数、累乗

1. $\frac{d}{\mathrm{dt}}\left({e}^{t},t,{t}^{2}\right)=\left({e}^{t},1,2t\right)$
$\left({e}^{0},1,2·0\right)=\left(1,1,0\right)$
$x+y+0z=\left(1,0,0\right)·\left(1,1,0\right)$
$x+y=1$

コード

#!/usr/bin/env python3
from sympy import Matrix, exp
from sympy.plotting import plot3d_parametric_line, plot3d
from sympy.abc import t, x, y

print('10.')

p = plot3d_parametric_line(
(exp(t), t, t ** 2, (t, -10, 10)),
*[(exp(t0) + t * exp(t0), t0 + t * 1, t0 ** 2 + 2 * t, (t, 0, 1))
for t0 in range(10)],
legend=False,
show=False
)
colors = ['red', 'green', 'blue', 'brown', 'orange',
'purple', 'pink', 'gray', 'skyblue', 'yellow']
for o, color in zip(p, colors):
o.line_color = color
print(o, color)
p.save('sample10.png')
p.show()


% ./sample10.py
10.
3D parametric cartesian line: (exp(t), t, t**2) for t over (-10.0, 10.0) red
3D parametric cartesian line: (t + 1, t, 2*t) for t over (0.0, 1.0) green
3D parametric cartesian line: (E*t + E, t + 1, 2*t + 1) for t over (0.0, 1.0) blue
3D parametric cartesian line: (t*exp(2) + exp(2), t + 2, 2*t + 4) for t over (0.0, 1.0) brown
3D parametric cartesian line: (t*exp(3) + exp(3), t + 3, 2*t + 9) for t over (0.0, 1.0) orange
3D parametric cartesian line: (t*exp(4) + exp(4), t + 4, 2*t + 16) for t over (0.0, 1.0) purple
3D parametric cartesian line: (t*exp(5) + exp(5), t + 5, 2*t + 25) for t over (0.0, 1.0) pink
3D parametric cartesian line: (t*exp(6) + exp(6), t + 6, 2*t + 36) for t over (0.0, 1.0) gray
3D parametric cartesian line: (t*exp(7) + exp(7), t + 7, 2*t + 49) for t over (0.0, 1.0) skyblue
3D parametric cartesian line: (t*exp(8) + exp(8), t + 8, 2*t + 64) for t over (0.0, 1.0) yellow
%