{ "cells": [ { "cell_type": "markdown", "metadata": {}, "source": [ "第1種完全楕円積分はモジュラスkについてのガウス超幾何関数として表すことができます。\n", "$$\\int_{0}^{\\frac{\\pi}{2}}{\\frac{1}{\\sqrt{1-k^2\\,\\sin ^2\\vartheta}}\\;d\\vartheta}=\\frac{\\pi\\,F\\left( \\left. \\begin{array}{c}\\frac{1}{2},\\;\\frac{1}{2}\\\\1\\end{array} \\right |,k^2\\right)}{2}$$\n", "この証明をMaximaで追ってみましょう。" ] }, { "cell_type": "code", "execution_count": 1, "metadata": {}, "outputs": [ { "data": { "text/latex": [ "\\[\\tag{${\\it \\%o}_{1}$}\\int_{0}^{\\frac{\\pi}{2}}{\\frac{1}{\\sqrt{1-k^2\\,\\sin ^2\\vartheta}}\\;d\\vartheta}\\]" ], "text/plain": [ " %pi\n", " ---\n", " 2\n", " /\n", " [ 1\n", "(%o1) I ------------------------ dtheta\n", " ] 2 2\n", " / sqrt(1 - k sin (theta))\n", " 0" ], "text/x-maxima": [ "'integrate(1/sqrt(1-k^2*sin(theta)^2),theta,0,%pi/2)" ] }, "execution_count": 1, "metadata": {}, "output_type": "execute_result" } ], "source": [ "EI1K:integrate(1/sqrt(1-k^2*sin(theta)^2),theta,0,%pi/2);" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "Maximaの関数powerseries()を使って被積分函数を$k^2\\,\\sin ^2\\vartheta$について0の周りで級数展開します。Maximaにpowerseries((1-x^2)^(1/2),x^2,0);と打ち込んでみると分かりやすいかもしれません。" ] }, { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [ { "data": { "text/latex": [ "\\[\\tag{${\\it \\%o}_{4}$}\\int_{0}^{\\frac{\\pi}{2}}{\\sum_{n=1}^{\\infty }{\\frac{2\\,k^{2\\,n}\\,\\left(-1\\right)^{n}\\,\\left(\\sin \\vartheta\\right)^{2\\,n}}{\\beta\\left(\\frac{1}{2}-n , n+1\\right)}}+1\\;d\\vartheta}\\]" ], "text/plain": [ " %pi\n", " ---\n", " 2 inf\n", " / ==== 2 n n 2 n\n", " [ \\ 2 k (- 1) sin(theta)\n", "(%o4) I ( > --------------------------- + 1) dtheta\n", " ] / 1\n", " / ==== beta(- - n, n + 1)\n", " 0 n = 1 2" ], "text/x-maxima": [ "'integrate('sum((2*k^(2*n)*(-1)^n*sin(theta)^(2*n))/beta(1/2-n,n+1),n,1,inf)\n", " +1,theta,0,%pi/2)" ] }, "execution_count": 2, "metadata": {}, "output_type": "execute_result" } ], "source": [ "substpart(powerseries(part(EI1K,1),k^2*sin(theta)^2,0),EI1K,1)$\n", "F1:niceindices(%),niceindicespref:[n]$\n", "F1:intosum(F1);" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "総和の内側の式に$n=0$を代入すると1になることから、%o4の総和を$n=0$から始まるように書き直せます。" ] }, { "cell_type": "code", "execution_count": 3, "metadata": {}, "outputs": [ { "data": { "text/latex": [ "\\[\\tag{${\\it \\%o}_{5}$}2\\,\\int_{0}^{\\frac{\\pi}{2}}{\\sum_{n=0}^{\\infty }{\\frac{k^{2\\,n}\\,\\left(-1\\right)^{n}\\,\\left(\\sin \\vartheta\\right)^{2\\,n}}{\\beta\\left(\\frac{1}{2}-n , n+1\\right)}}\\;d\\vartheta}\\]" ], "text/plain": [ " %pi\n", " ---\n", " 2 inf\n", " / ==== 2 n n 2 n\n", " [ \\ k (- 1) sin(theta)\n", "(%o5) 2 I > ------------------------- dtheta\n", " ] / 1\n", " / ==== beta(- - n, n + 1)\n", " 0 n = 0 2" ], "text/x-maxima": [ "2*'integrate('sum((k^(2*n)*(-1)^n*sin(theta)^(2*n))/beta(1/2-n,n+1),n,0,inf),\n", " theta,0,%pi/2)" ] }, "execution_count": 3, "metadata": {}, "output_type": "execute_result" } ], "source": [ "F2:substpart(sum(part(F1,1,1,1),n,0,inf),F1,1);" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "総和と積分の順番を入れ替えてみます。これが可能なことは別に議論が必要ですが、ここでは省略します。" ] }, { "cell_type": "code", "execution_count": 4, "metadata": {}, "outputs": [ { "data": { "text/latex": [ "\\[\\tag{${\\it \\%o}_{6}$}2\\,\\sum_{n=0}^{\\infty }{\\frac{k^{2\\,n}\\,\\left(-1\\right)^{n}\\,\\int_{0}^{\\frac{\\pi}{2}}{\\left(\\sin \\vartheta\\right)^{2\\,n}\\;d\\vartheta}}{\\beta\\left(\\frac{1}{2}-n , n+1\\right)}}\\]" ], "text/plain": [ " %pi\n", " ---\n", " 2\n", " /\n", " 2 n n [ 2 n\n", " k (- 1) I sin(theta) dtheta\n", " inf ]\n", " ==== /\n", " \\ 0\n", "(%o6) 2 > -------------------------------------\n", " / 1\n", " ==== beta(- - n, n + 1)\n", " n = 0 2" ], "text/x-maxima": [ "2*'sum((k^(2*n)*(-1)^n*'integrate(sin(theta)^(2*n),theta,0,%pi/2))\n", " /beta(1/2-n,n+1),n,0,inf)" ] }, "execution_count": 4, "metadata": {}, "output_type": "execute_result" } ], "source": [ "F3:sum(2*'integrate(part(F2,2,1,1),theta,0,%pi/2),n,0,inf);" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "積分変数に関係のない部分が積分の外側に出されることで、%o6が得られました。そしてこの定積分はMaximaも計算してくれます。" ] }, { "cell_type": "code", "execution_count": 14, "metadata": {}, "outputs": [ { "name": "stdin", "output_type": "stream", "text": [ "Is g7698 positive or zero?\n", " pos;\n" ] }, { "name": "stdout", "output_type": "stream", "text": [ "\n" ] }, { "data": { "text/latex": [ "\\[\\tag{${\\it \\%o}_{17}$}\\sum_{n=0}^{\\infty }{\\frac{\\beta\\left(\\frac{1}{2} , \\frac{2\\,n+1}{2}\\right)\\,k^{2\\,n}\\,\\left(-1\\right)^{n}}{\\beta\\left(\\frac{1}{2}-n , n+1\\right)}}\\]" ], "text/plain": [ " inf 1 2 n + 1 2 n n\n", " ==== beta(-, -------) k (- 1)\n", " \\ 2 2\n", "(%o17) > ----------------------------\n", " / 1\n", " ==== beta(- - n, n + 1)\n", " n = 0 2" ], "text/x-maxima": [ "'sum((beta(1/2,(2*n+1)/2)*k^(2*n)*(-1)^n)/beta(1/2-n,n+1),n,0,inf)" ] }, "execution_count": 14, "metadata": {}, "output_type": "execute_result" } ], "source": [ "F5:F3,nouns;" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "この総和の内側の式が以下の式%o9に等しいことを示します。" ] }, { "cell_type": "code", "execution_count": 7, "metadata": {}, "outputs": [ { "data": { "text/latex": [ "\\[\\tag{${\\it \\%o}_{9}$}\\frac{\\pi\\,\\left(\\left(\\frac{1}{2}\\right)\\right)_{n}^2\\,k^{2\\,n}}{2\\,n!^2}\\]" ], "text/plain": [ " 2\n", " 1 2 n\n", " %pi (-) k\n", " 2 n\n", "(%o9) --------------\n", " 2\n", " 2 n!" ], "text/x-maxima": [ "(%pi*pochhammer(1/2,n)^2*k^(2*n))/(2*n!^2)" ] }, "execution_count": 7, "metadata": {}, "output_type": "execute_result" }, { "name": "stdout", "output_type": "stream", "text": [ "SB-KERNEL:REDEFINITION-WITH-DEFUN: redefining MAXIMA::SIMP-UNIT-STEP in DEFUN\n", "SB-KERNEL:REDEFINITION-WITH-DEFUN: redefining MAXIMA::SIMP-POCHHAMMER in DEFUN\n" ] } ], "source": [ "F6:%pi/2*(pochhammer(1/2,n)/n!)^2*k^(2*n);" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "まず総和の内側の式を取り出します。" ] }, { "cell_type": "code", "execution_count": 8, "metadata": {}, "outputs": [ { "data": { "text/latex": [ "\\[\\tag{${\\it \\%o}_{10}$}\\frac{\\beta\\left(\\frac{1}{2} , \\frac{2\\,n+1}{2}\\right)\\,k^{2\\,n}\\,\\left(-1\\right)^{n}}{\\beta\\left(\\frac{1}{2}-n , n+1\\right)}\\]" ], "text/plain": [ " 1 2 n + 1 2 n n\n", " beta(-, -------) k (- 1)\n", " 2 2\n", "(%o10) ----------------------------\n", " 1\n", " beta(- - n, n + 1)\n", " 2" ], "text/x-maxima": [ "(beta(1/2,(2*n+1)/2)*k^(2*n)*(-1)^n)/beta(1/2-n,n+1)" ] }, "execution_count": 8, "metadata": {}, "output_type": "execute_result" } ], "source": [ "F7:part(F5,1);" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "そしてその式を%o9の式で割ってみます。これが1になることを示せば良いわけです。" ] }, { "cell_type": "code", "execution_count": 9, "metadata": {}, "outputs": [ { "data": { "text/latex": [ "\\[\\tag{${\\it \\%o}_{11}$}\\frac{\\pi\\,\\left(\\left(\\frac{1}{2}\\right)\\right)_{n}^2\\,\\beta\\left(n+1 , -\\frac{2\\,n-1}{2}\\right)}{2\\,\\beta\\left(\\frac{1}{2} , \\frac{2\\,n+1}{2}\\right)\\,\\left(-1\\right)^{n}\\,n!^2}\\]" ], "text/plain": [ " 2\n", " 1 2 n - 1\n", " %pi (-) beta(n + 1, - -------)\n", " 2 n 2\n", "(%o11) --------------------------------\n", " 1 2 n + 1 n 2\n", " 2 beta(-, -------) (- 1) n!\n", " 2 2" ], "text/x-maxima": [ "(%pi*pochhammer(1/2,n)^2*beta(n+1,-(2*n-1)/2))\n", " /(2*beta(1/2,(2*n+1)/2)*(-1)^n*n!^2)" ] }, "execution_count": 9, "metadata": {}, "output_type": "execute_result" } ], "source": [ "F8:F6/F7,ratsimp;" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "ベータ関数とポッホハマー記号が含まれた複雑な式です。それらをガンマ関数で表示させると以下の式まで漢訳できます。" ] }, { "cell_type": "code", "execution_count": 10, "metadata": {}, "outputs": [ { "data": { "text/latex": [ "\\[\\tag{${\\it \\%o}_{12}$}\\frac{\\Gamma\\left(\\frac{1}{2}-n\\right)\\,\\Gamma\\left(n+\\frac{1}{2}\\right)}{\\pi\\,\\left(-1\\right)^{n}}\\]" ], "text/plain": [ " 1 1\n", " gamma(- - n) gamma(n + -)\n", " 2 2\n", "(%o12) -------------------------\n", " n\n", " %pi (- 1)" ], "text/x-maxima": [ "(gamma(1/2-n)*gamma(n+1/2))/(%pi*(-1)^n)" ] }, "execution_count": 10, "metadata": {}, "output_type": "execute_result" } ], "source": [ "F9:expand(ev(makegamma(F8),gamma_expand:true,ratsimp));" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "%o12には半整数に関する2つのガンマ関数が現れています。これらはそれぞれ二重階乗を使った式に直すことができます(例えばWikipediaのガンマ関数の項を参照して下さい)。これらをそれぞれMaximaのルールとして定義します。" ] }, { "cell_type": "code", "execution_count": 11, "metadata": {}, "outputs": [ { "data": { "text/latex": [ "\\[\\tag{${\\it \\%o}_{13}$}{\\it gamma\\_half\\_int}_{1}:\\Gamma\\left(\\frac{1}{2}-n\\right)\\rightarrow \\frac{\\sqrt{\\pi}\\,\\left(-2\\right)^{n}}{{\\it genfact}\\left(2\\,n-1 , \\frac{2\\,n-1}{2} , 2\\right)}\\]" ], "text/plain": [ " n\n", " 1 sqrt(%pi) (- 2)\n", "(%o13) gamma_half_int1 : gamma(- - n) -> ----------------------------\n", " 2 2 n - 1\n", " genfact(2 n - 1, -------, 2)\n", " 2" ], "text/x-maxima": [ "gamma_half_int1:marrow(gamma(1/2-n),\n", " (sqrt(%pi)*(-2)^n)/''genfact(2*n-1,(2*n-1)/2,2))" ] }, "execution_count": 11, "metadata": {}, "output_type": "execute_result" }, { "data": { "text/latex": [ "\\[\\tag{${\\it \\%o}_{14}$}{\\it gamma\\_half\\_int}_{2}:\\Gamma\\left(n+\\frac{1}{2}\\right)\\rightarrow \\frac{\\sqrt{\\pi}\\,{\\it genfact}\\left(2\\,n-1 , \\frac{2\\,n-1}{2} , 2\\right)}{2^{n}}\\]" ], "text/plain": [ " 2 n - 1\n", " sqrt(%pi) genfact(2 n - 1, -------, 2)\n", " 1 2\n", "(%o14) gamma_half_int2 : gamma(n + -) -> --------------------------------------\n", " 2 n\n", " 2" ], "text/x-maxima": [ "gamma_half_int2:marrow(gamma(n+1/2),\n", " (sqrt(%pi)*''genfact(2*n-1,(2*n-1)/2,2))/2^n)" ] }, "execution_count": 11, "metadata": {}, "output_type": "execute_result" } ], "source": [ "defrule(gamma_half_int1,gamma(1/2-n),sqrt(%pi)*(-2)^n/((2*n-1)!!));\n", "defrule(gamma_half_int2,gamma(1/2+n),sqrt(%pi)*((2*n-1)!!)/2^n);" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "それらを%o12に適用し、簡約すると所望の1が得られました。" ] }, { "cell_type": "code", "execution_count": 12, "metadata": {}, "outputs": [ { "data": { "text/latex": [ "\\[\\tag{${\\it \\%o}_{15}$}1\\]" ], "text/plain": [ "(%o15) 1" ], "text/x-maxima": [ "1" ] }, "execution_count": 12, "metadata": {}, "output_type": "execute_result" } ], "source": [ "apply1(F9,gamma_half_int1,gamma_half_int2),radcan;" ] }, { "cell_type": "markdown", "metadata": {}, "source": [ "%o9の式のnに関する総和の式$\\sum_{n=0}^{\\infty}\\frac{\\pi\\,\\left(\\left(\\frac{1}{2}\\right)\\right)_{n}^2\\,k^{2\\,n}}{2\\,n!^2}$はよく見るとガウスの超幾何関数$F\\left( \\left. \\begin{array}{c}\\frac{1}{2},\\;\\frac{1}{2}\\\\1\\end{array} \\right |,k^2\\right)$に$\\frac{\\pi}{2}$を掛けた式です。このことから以下の式が証明されました。" ] }, { "cell_type": "code", "execution_count": 13, "metadata": {}, "outputs": [ { "data": { "text/latex": [ "\\[\\tag{${\\it \\%o}_{16}$}\\int_{0}^{\\frac{\\pi}{2}}{\\frac{1}{\\sqrt{1-k^2\\,\\sin ^2\\vartheta}}\\;d\\vartheta}=\\frac{\\pi\\,F\\left( \\left. \\begin{array}{c}\\frac{1}{2},\\;\\frac{1}{2}\\\\1\\end{array} \\right |,k^2\\right)}{2}\\]" ], "text/plain": [ " %pi\n", " ---\n", " 2\n", " /\n", " [ 1\n", "(%o16) I ------------------------ dtheta = \n", " ] 2 2\n", " / sqrt(1 - k sin (theta))\n", " 0\n", " 1 1 2\n", " %pi hypergeometric([-, -], [1], k )\n", " 2 2\n", " -----------------------------------\n", " 2" ], "text/x-maxima": [ "'integrate(1/sqrt(1-k^2*sin(theta)^2),theta,0,%pi/2)\n", " = (%pi*hypergeometric([1/2,1/2],[1],k^2))/2" ] }, "execution_count": 13, "metadata": {}, "output_type": "execute_result" }, { "name": "stdout", "output_type": "stream", "text": [ "SB-KERNEL:REDEFINITION-WITH-DEFUN: redefining MAXIMA::SIMP-HYPERGEOMETRIC in DEFUN\n" ] } ], "source": [ "EI1K=%pi/2*hypergeometric([1/2,1/2],[1],k^2);" ] }, { "cell_type": "code", "execution_count": null, "metadata": {}, "outputs": [], "source": [] } ], "metadata": { "kernelspec": { "display_name": "Maxima", "language": "maxima", "name": "maxima" }, "language_info": { "codemirror_mode": "maxima", "file_extension": ".mac", "mimetype": "text/x-maxima", "name": "maxima", "pygments_lexer": "maxima", "version": "5.45.1" } }, "nbformat": 4, "nbformat_minor": 4 }