「高さ h からの斜方投射の最大到達距離を求める準備」のページを参照。
最大水平到達距離となる打ち出し角度 $\theta$ を求めるには,平方根を含む非線形方程式を解く必要があるので,SymPy でやってみた。
ライブラリの import
# 1文字変数の Symbol の宣言が省略できる
from sympy.abc import *
from sympy import *
init_printing()
最大水平到達距離となる $\sin\theta_{\rm max}$ を解析的に求める
水平到達距離 $L$ を $s \equiv \sin \theta$ で表す
水平到達距離 $L(\theta)$ を $s \equiv \sin \theta$ を使って表してみます。
\begin{eqnarray}
L(\theta) &=& \left( \sin{\left(\theta \right)} + \sqrt{2 H + \sin^{2}{\left(\theta \right)}}\right) \cos{\left(\theta \right)} \\
&=& \left(s + \sqrt{s^2 + 2H}\right) \, \sqrt{1 -s^2}
\end{eqnarray}
var('H s', positive = True) # H, s > 0
def Ls(s):
return (s + sqrt(2*H + s**2)) * sqrt(1 - s**2)
Ls(s)
$L$ が最大となる $\sin\theta$ を求める
dLs
$\displaystyle \equiv\frac{d L(s)}{d s} = 0$ となる $s \equiv s_{\rm max}$ を solve()
で求めます。
dLs = diff(Ls(s), s)
dLs = dLs.simplify()
dLs
dLs = 0
を s
について解く。
solve(dLs, s)
ということで,最大水平到達距離となる $\sin\theta_{\rm max}$ は
\begin{eqnarray}
\sin\theta_{\rm max} &=& s_{\rm max} = \frac{1}{\sqrt{2 (1 + H)}} \\
\therefore\ \ \theta_{\rm max} &=& \arcsin\left(\frac{1}{\sqrt{2 (1 + H)}}\right)
\end{eqnarray}
最大水平到達距離
そのときの最大水平到達距離 $L_{\rm max} = L(\theta_{\rm max}, H)$ は…
smax = 1/sqrt(2*(1+H))
Ls(smax).simplify()
簡単化してくれないなぁ…
最大水平到達距離となる $\tan\theta_{\rm max}$ を解析的に求める
水平到達距離 $L(\theta)$ を $t \equiv \tan \theta$ を使って表してみます。
水平到達距離 $L$ を $t \equiv \tan\theta$ で表す
$t \equiv \tan\theta$ として規格化された水平到達距離 $L$ を $t$ で表すと
\begin{eqnarray}
L(t)
&=& \frac{1}{1+t^2} \left\{t + \sqrt{(1+2H)\, t^2 + 2H} \right\}
\end{eqnarray}
var('t H', positive = True) # positive = True とすると吉
def Lt(t):
return (t+sqrt((1+2*H)*t**2 + 2*H))/(1 + t**2)
Lt(t)
$L$ が最大となる $\tan\theta$ を求める
$\displaystyle \frac{d L(t)}{dt} = 0$ となる $t \equiv t_{\rm max}$ を solve()
で求めます。
dLt = diff(Lt(t), t)
sols = solve(dLt, t)
sols
念のため,本当に解になっているか,確認します。
dLt.subs(t, sols[0])
として,dLt
の t
に sols[0]
を代入し,simplify()
で簡単化してみます。
simplify(dLt.subs(t, sols[0]))
よって,$L(t)$ が最大となる $t$ の値 $t_{\rm max}$ は…
tmax = 1/sqrt(1 + 2*H)
最大水平到達距離
simplify(Lt(tmax))
つまり,高さ $H$ のときの最大水平到達距離は,
$$L_{\rm max} = \sqrt{1 + 2H}$$
となることがわかります。
このときの滞空時間 $T_1(\theta)$ は…
$$T_1(\theta) = \sin\theta + \sqrt{\sin^2\theta + 2 H}$$
に
\begin{eqnarray}
t_{\rm max} &=& \tan\theta_{\rm max} = \frac{1}{\sqrt{1 + 2 H}} \\
\therefore\ \ \theta_{\rm max} &=& \arctan \left(\frac{1}{\sqrt{1 + 2 H}}\right)
\end{eqnarray}
で決まる $\theta_{\rm max}$ を代入して…
あるいは,
\begin{eqnarray}
s_{\rm max} &=& \sin\theta_{\rm max} = \frac{1}{\sqrt{2(1 + H)}}
\end{eqnarray}
を使って…
T1 = smax + sqrt(factor(smax**2 + 2*H))
T1.factor()