Annotation of OpenXM/src/asir-contrib/packages/doc/tk_ode_by_mpfr/tk_ode_by_mpfr-ja.texi, Revision 1.1
1.1 ! takayama 1: %% $OpenXM$
! 2: %% debug に ln -s ../texinfo-ja.tex . をしておく.
! 3: %% xetex tk_ode_by_mpfr-ja.texi (.texi までつける. )
! 4: %% 以下コメントは @comment で始める. \input texinfo 以降は普通の tex 命令は使えない.
! 5: \input texinfo-ja
! 6: @iftex
! 7: @catcode`@#=6
! 8: @def@fref#1{@xrefX[#1,,@code{#1},,,]}
! 9: @def@b#1{{@bf #1}}
! 10: @catcode`@#=@other
! 11: @end iftex
! 12: @c tex
! 13: @c \overfullrule=0pt
! 14: @c end tex
! 15: @documentlanguage ja
! 16: @c -*-texinfo-*-
! 17: @comment %**start of header
! 18: @comment --- おまじない終り ---
! 19:
! 20: @comment --- GNU info ファイルの名前 ---
! 21: @setfilename ox_pari-ja
! 22:
! 23: @comment --- タイトル ---
! 24: @settitle ox_pari
! 25:
! 26: @comment %**end of header
! 27: @comment %@setchapternewpage odd
! 28:
! 29: @comment --- おまじない ---
! 30: @ifinfo
! 31: @macro fref{name}
! 32: @ref{\name\,,@code{\name\}}
! 33: @end macro
! 34: @end ifinfo
! 35:
! 36: @iftex
! 37: @comment @finalout
! 38: @end iftex
! 39:
! 40: @titlepage
! 41: @comment --- おまじない終り ---
! 42:
! 43: @comment --- タイトル, バージョン, 著者名, 著作権表示 ---
! 44: @title tk_ode_by_mpfr
! 45: @subtitle MPFR で ODE の数値解析をするC言語のコードを生成
! 46: @subtitle 1.0 版
! 47: @subtitle 2020 年 9 月 8 日
! 48:
! 49: @author by Nobuki Takayama
! 50: @page
! 51: @vskip 0pt plus 1filll
! 52: Copyright @copyright{} Risa/Asir committers
! 53: 2020--2020. All rights reserved.
! 54: @end titlepage
! 55:
! 56: @comment --- おまじない ---
! 57: @synindex vr fn
! 58: @comment --- おまじない終り ---
! 59:
! 60: @comment --- @node は GNU info, HTML 用 ---
! 61: @comment --- @node の引数は node-name, next, previous, up ---
! 62: @node Top,, (dir), (dir)
! 63:
! 64: @comment --- @menu は GNU info, HTML 用 ---
! 65: @comment --- chapter 名を正確に並べる ---
! 66: @comment --- この文書では chapter XYZ, Chapter Index がある.
! 67: @comment --- Chapter XYZ には section XYZについて, section XYZに関する函数がある.
! 68: @menu
! 69: * tk_ode_by_mpfrについて
! 70: * tk_ode_by_mpfr函数::
! 71: * Index::
! 72: @end menu
! 73:
! 74: @comment --- chapter の開始 ---
! 75: @comment --- 親 chapter 名を正確に. 親がない場合は Top ---
! 76: @node tk_ode_by_mpfrについて,,, Top
! 77: @chapter tk_ode_by_mpfrについて
! 78:
! 79: ODE(ordinary differential equation)をMPFR(任意精度小数パッケージ)を援用して数値解析するための
! 80: C言語のプログラムを生成する.
! 81: 下記のコマンドでこのパッケージがロードされる.
! 82: @example
! 83: load("tk_ode_by_mpfr.rr")$
! 84: @end example
! 85: @noindent
! 86:
! 87: @sp 3
! 88:
! 89: @noindent
! 90: このパッケージは HGM に出現する ODE の数値解析のために作成された.
! 91: HGM については次の web サイトを参照.
! 92: @itemize @bullet
! 93: @item [hgm]
! 94: @uref{http://www.math.kobe-u.ac.jp/OpenXM/Math/hgm/ref-hgm.html}
! 95: @end itemize
! 96:
! 97: @noindent
! 98: 内部函数の仕様は man-asir2mpfr.tex 参照(まだ未公開).
! 99: @c Ref: num-ht2/man-asir2mpfr.tex
! 100:
! 101: @node tk_ode_by_mpfr函数,,, Top
! 102: @chapter tk_ode_by_mpfr函数
! 103:
! 104: @menu
! 105: * pari::
! 106: @end menu
! 107:
! 108: @comment **********************************************************
! 109: @comment --- ◯◯◯◯ の説明
! 110: @comment --- 個々の函数の説明の開始 ---
! 111: @comment --- section 名を正確に ---
! 112: @node code_solve_ode_by_rk4_with_defuse,,, tk_ode_by_mpfr函数
! 113: @section @code{tk_ode_by_mpfr}
! 114: @comment --- 索引用キーワード
! 115: @findex code_solve_ode_by_rk4_with_defuse
! 116:
! 117: @table @t
! 118: @item code_solve_ode_by_rk4_with_defuse(@var{Pmat},@var{T0},@var{F0},@var{T1})
! 119: :: 係数 @var{Pmat} をもつ ODE の初期値問題を解くC言語のコードを生成する.
! 120: @end table
! 121:
! 122: @comment --- 引数の簡単な説明 --- 以下まだ書いてない.
! 123: @table @var
! 124: @item return
! 125: C言語のコード. main 函数を含む.
! 126: @item Pmat
! 127: ODE dF/dt = P F の係数行列 P(t). t の式を成分とすること.
! 128: @item T0
! 129: 初期時刻.
! 130: @item F0
! 131: 初期条件.
! 132: @item T1
! 133: 終了時刻. T1>T0 を満たすこと.
! 134: @end table
! 135:
! 136: @comment --- ここで函数の詳しい説明 ---
! 137: @comment --- @itemize〜@end itemize は箇条書き ---
! 138: @comment --- @bullet は黒点付き ---
! 139: @itemize @bullet
! 140: @item
! 141: dF/dt = PF を F(T0)=F0 の初期条件の元, 時刻 T1 まで求める.
! 142: @item
! 143: big float による matrix factorial を用いて計算する.
! 144: @item
! 145: defusing heuristics や知られている厳密値を用いて不安定性を
! 146: コードも含む.
! 147: これらは下記の option 引数でコントロールする.
! 148: @end itemize
! 149:
! 150: @comment man-asir2mpfr.tex より
! 151: @c @verbatim
! 152: @c @end verbatim
! 153: @multitable {xxxxxxxxxx} {xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx} {xxxxxxxxxxxxxx}
! 154: @item Option @tab @tab default value
! 155: @item { verbose} @tab @tab 0
! 156: @item { prec} @tab doube size of MPFR @tab 64
! 157: @item { progname} @tab @tab { tmp-test}
! 158: @item { h} @tab step size @tab 0.001
! 159: @item { t_noproj}@tab time to apply defusing @tab 0
! 160: @item { n_prune} @tab number of eigen vectors to prune @tab 1
! 161: @item { strat} @tab projection strategy @tab 1
! 162: @item { n_defuse}@tab number of the matrix factorial @tab 5 [1/h]
! 163: @item { ref_value_file}@tab File name of exact values @tab { tmp_ref_value.txt}
! 164: @end multitable
! 165:
! 166:
! 167: @sp 3
! 168: @noindent
! 169: 例:
! 170: Airy の微分方程式
! 171: dF/dt=[[0,1],[t,0]]F, F(0)=[0.355028053887817,-0.258819403792807]
! 172: の解 F(t) を t=10.1 まで計算.
! 173: @comment tk_mat2mpfr.rr, test0908();
! 174: @smallformat
! 175: @example
! 176: --> load("tk_ode_by_mpfr.rr");
! 177: --> Code=tk_ode_by_mpfr.code_solve_ode_by_rk4_with_defuse([[0,1],[t,0]],
! 178: 0,[0.355028053887817,-0.258819403792807],10.1 | h=0.001)$
! 179: --> util_write_string_to_a_file("tmp-test.c",Code)$
! 180:
! 181: On the unix shell
! 182: ln -s ${OpenXM_HOME}/lib/asir-contrib/tk_ode_by_mpfr/proj.c tmp-proj.c
! 183: cc -I${OpenXM_HOME}/lib/asir-contrib/tk_ode_by_mpfr -DNN=2 -c tmp-proj.c
! 184: cc -o tmp-test tmp-test.c tmp-proj.o -lmpfr -lgmp -lgsl -lgslcblas -lm
! 185:
! 186: ./tmp-test --verbose --t_noproj 8.1 --n_defuse 2000 --n_prune 1
! 187: @end example
! 188: @end smallformat
! 189: @noindent
! 190: 上記の compile 用のコマンドは上記のコマンドが出力する.
! 191: --t_noproj 8.1 は t<8.1 までは4次の Runge-Kutta 法を適用する.
! 192: t=8.1 以降は --n_prune で指定した個数の固有空間(Re(固有値)の順)の成分
! 193: を削除する.
! 194: --n_defuse 2000 は 2000 個の行列の matrix factorial を計算する.
! 195:
! 196: @noindent
! 197:
! 198:
! 199:
! 200: @comment --- 参照(リンク)を書く ---
! 201: @table @t
! 202: @item 参照
! 203: @comment @ref{code_mat_fac_mpfr}
! 204: @end table
! 205:
! 206: @comment --- ChangeLog を書く. ソースコードの位置. 変更日時 など CVSサーバを見るため
! 207: @noindent
! 208: ChangeLog
! 209: @itemize @bullet
! 210: @item
! 211: tk_ode_by_mpfr/tk_man2mpfr.rr
! 212: @end itemize
! 213:
! 214:
! 215: @comment --- おまじない ---
! 216: @node Index,,, Top
! 217: @unnumbered Index
! 218: @printindex fn
! 219: @printindex cp
! 220: @iftex
! 221: @vfill @eject
! 222: @end iftex
! 223: @summarycontents
! 224: @contents
! 225: @bye
! 226: @comment --- おまじない終り ---
! 227:
! 228:
! 229: @comment テンプレート. start_of_template.
! 230: @comment **********************************************************
! 231: @comment --- ◯◯◯◯ の説明
! 232: @comment --- 個々の函数の説明の開始 ---
! 233: @comment --- section 名を正確に ---
! 234: @node gtt_ekn3.hoge,,, 超幾何函数E(k,n)
! 235: @subsection @code{gtt_ekn3.hoge}
! 236: @comment --- 索引用キーワード
! 237: @findex gtt_ekn3.hoge
! 238:
! 239: @table @t
! 240: @item gtt_ekn3.hoge(@var{i})
! 241: ::
! 242: @end table
! 243:
! 244: @comment --- 引数の簡単な説明 --- 以下まだ書いてない.
! 245: @table @var
! 246: @item i hage
! 247: @item return
! 248: @end table
! 249:
! 250: @comment --- ここで函数の詳しい説明 ---
! 251: @comment --- @itemize〜@end itemize は箇条書き ---
! 252: @comment --- @bullet は黒点付き ---
! 253: @itemize @bullet
! 254: @item 説明.
! 255: @end itemize
! 256:
! 257: @comment --- @example〜@end example は実行例の表示 ---
! 258: 例:
! 259: @example
! 260: [2221] gtt_ekn3.hoge([[1,4],[2,3]]);
! 261: @end example
! 262:
! 263:
! 264: @comment --- 参照(リンク)を書く ---
! 265: @table @t
! 266: @item 参照
! 267: @ref{gtt_ekn3.nc}
! 268: @ref{gtt_ekn3.gmvector}
! 269: @end table
! 270:
! 271: @comment --- ChangeLog を書く. ソースコードの位置. 変更日時 など CVSサーバを見るため
! 272: @noindent
! 273: ChangeLog
! 274: @itemize @bullet
! 275: @item
! 276: @end itemize
! 277: @comment end_of_template
! 278:
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>