71a75b13b98416f54fe4fa81463dece4e926670f
[scilab.git] / scilab / modules / differential_equations / help / ja_JP / daskr.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2
3 <!--\r
4  * Scilab ( http://www.scilab.org/ ) - This file is part of Scilab\r
5  * Copyright (C) 2013 - Scilab Enterprises\r
6  *\r
7  * This file must be used under the terms of the CeCILL.\r
8  * This source file is licensed as described in the file COPYING, which\r
9  * you should have received as part of this distribution.\r
10  * The terms are also available at\r
11  * http://www.cecill.info/licences/Licence_CeCILL_V2.1-en.txt\r
12  *\r
13  -->
14
15 <refentry xmlns="http://docbook.org/ns/docbook" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:svg="http://www.w3.org/2000/svg" xmlns:ns5="http://www.w3.org/1999/xhtml" xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:db="http://docbook.org/ns/docbook" xmlns:scilab="http://www.scilab.org" xml:id="daskr" xml:lang="ja">
16     
17     <refnamediv>
18         
19         <refname>daskr</refname>
20         
21         <refpurpose>ゼロ交差を有するDAEソルバー</refpurpose>
22         
23     </refnamediv>
24     
25     <refsynopsisdiv>
26         
27         <title>呼び出し手順</title>
28         
29         <synopsis>[r, nn [, hd]] = daskr(x0, t0, t [, atol [, rtol]], res [, jac], ng, surf [, info [, psol] [, pjac]] [, hd])</synopsis>
30         
31     </refsynopsisdiv>
32     
33     <refsection>
34         
35         <title>引数</title>
36         
37         <variablelist>
38             
39             <varlistentry>
40                 
41                 <term>x0</term>
42                 
43                 <listitem>
44                     
45                     <para>
46                         
47                         は <literal>y0</literal> (<literal>ydot0</literal> は
48                         
49                         ゼロを初期推定値として <literal>dassl</literal> により推定)
50                         
51                         または行列 <literal>[y0 ydot0]</literal>のどちらかです.
52                         
53                         <literal>g(t,y0,ydot0)</literal> はゼロに等しい必要があります.
54                         
55                         <literal>ydot0</literal> の推定値のみ既知の場合, 
56                         
57                         <literal>info(7)=1</literal> を指定してください.
58                         
59                     </para>
60                     
61                     <variablelist>
62                         
63                         <varlistentry>
64                             
65                             <term>y0</term>
66                             
67                             <listitem>
68                                 
69                                 <para>初期条件の実数列ベクトル.</para>
70                                 
71                             </listitem>
72                             
73                         </varlistentry>
74                         
75                         <varlistentry>
76                             
77                             <term>ydot0</term>
78                             
79                             <listitem>
80                                 
81                                 <para>
82                                     
83                                     <literal>y</literal> at <literal>t0</literal> (推定値でも可)における<literal>y</literal>の時間微分の実数列ベクトル.
84                                     
85                                 </para>
86                                 
87                             </listitem>
88                             
89                         </varlistentry>
90                         
91                     </variablelist>
92                     
93                 </listitem>
94                 
95             </varlistentry>
96             
97             <varlistentry>
98                 
99                 <term>t0</term>
100                 
101                 <listitem>
102                     
103                     <para>実数, 初期時間.</para>
104                     
105                 </listitem>
106                 
107             </varlistentry>
108             
109             <varlistentry>
110                 
111                 <term>t</term>
112                 
113                 <listitem>
114                     
115                     <para>実数スカラーまたはベクトル. 
116                         
117                         解を得る時刻を指定します. 
118                         
119                         <literal>info(2)=1</literal>と指定することにより,
120                         
121                         dasslの各ステップ点で解を得ることができます.
122                         
123                     </para>
124                     
125                 </listitem>
126                 
127             </varlistentry>
128             
129             <varlistentry>
130                 
131                 <term>nn</term>
132                 
133                 <listitem>
134                     
135                     <para>
136                         
137                         2個のエントリ <literal>[times num]</literal>を有するベクトル.
138                         
139                         <literal>times</literal> は面が交差する点における時間の値,
140                         
141                         <literal>num</literal> は交差する面の数です.
142                         
143                     </para>
144                     
145                 </listitem>
146                 
147             </varlistentry>
148             
149             <varlistentry>
150                 
151                 <term>atol, rtol</term>
152                 
153                 <listitem>
154                     
155                     <para>
156                         
157                         <literal>y</literal>と同じ大きさの実数スカラーまたは列ベクトル. 
158                         
159                         <literal>atol, rtol</literal> はそれぞれ解の絶対及び相対許容誤差を
160                         
161                         表します. この許容誤差は
162                         
163                         <literal>y</literal>の各要素について指定されます.
164                         
165                     </para>
166                     
167                 </listitem>
168                 
169             </varlistentry>
170             
171             <varlistentry>
172                 
173                 <term>res</term>
174                 
175                 <listitem>
176                     
177                     <para>
178                         
179                         <link linkend="external">external</link> (関数またはリストまたは文字列). 
180                         
181                         <literal>g(t,y,ydot)</literal>の値を計算します. 以下のようになります :
182                         
183                     </para>
184                     
185                     <itemizedlist>
186                         
187                         <listitem>
188                             
189                             <para>Scilab関数.</para>
190                             
191                             <para>呼び出し手順は以下とします
192                                 
193                                 <literal>[r,ires]=res(t,y,ydot)</literal> かつ
194                                 
195                                 <literal>res</literal> は残差
196                                 
197                                 <literal>r=g(t,y,ydot)</literal> かつ エラーフラグ
198                                 
199                                 <literal>ires</literal>を返すこと.
200                                 
201                                 <literal>res</literal> は, <literal>r</literal>の計算に成功した場合は<literal>ires = 0</literal>,
202                                 
203                                 残差が<literal>(t,y,ydot)</literal> において局所的に定義されないには
204                                 
205                                 <literal>=-1</literal>, パラメータが許容範囲を逸脱している場合には <literal>=-2</literal>
206                                 
207                                 となります.
208                                 
209                             </para>
210                             
211                         </listitem>
212                         
213                         <listitem>
214                             
215                             <para>リスト.</para>
216                             
217                             <para>この形式により, t, y, ydot 以外のパラメータを関数に指定出来ます.
218                                 
219                                 以下のような形式とする必要があります:
220                                 
221                             </para>
222                             
223                             <programlisting role="no-scilab-exec"><![CDATA[\r
224 list(res,x1,x2,...)\r
225  ]]></programlisting>
226                             
227                             <para>ただし関数
228                                 
229                                 <literal>res</literal> の呼び出し形式は以下とします
230                                 
231                             </para>
232                             
233                             <programlisting role="no-scilab-exec"><![CDATA[\r
234 r=res(t,y,ydot,x1,x2,...)\r
235  ]]></programlisting>
236                             
237                             <para>
238                                 
239                                 <literal>res</literal> は
240                                 
241                                 <literal>(t,y,ydot,x1,x2,...)</literal>の関数として<literal>r=g(t,y,ydot)</literal>を返します.
242                                 
243                             </para>
244                             
245                             <para>
246                                 警告: この形式は<literal>関数</literal>に渡す別の引数が存在しない場合には
247                                 
248                                 使用するべきではありません.
249                                 
250                             </para>
251                             
252                         </listitem>
253                         
254                         <listitem>
255                             
256                             <para>文字列.</para>
257                             
258                             <para>ScilabにリンクされたCまたはFortranサブルーチンの名前を指定します.
259                                 
260                             </para>
261                             
262                             <para>Cの場合, 呼び出し手順は次のようにします:</para>
263                             
264                             <programlisting role="no-scilab-exec"><![CDATA[\r
265 void res(double *t, double y[], double yd[], double r[],\r
266          int *ires, double rpar[], int ipar[])\r
267  ]]></programlisting>
268                             
269                             <para>Fortranの場合, 以下としま:</para>
270                             
271                             <programlisting role="no-scilab-exec"><![CDATA[\r
272 subroutine res(t,y,yd,r,ires,rpar,ipar)\r
273 double precision t, y(*),yd(*),r(*),rpar(*)\r
274 integer ires,ipar(*)\r
275  ]]></programlisting>
276                             
277                             <para>
278                                 
279                                 <literal>rpar</literal> および <literal>ipar</literal> 配列は存在する必要がありますが使用できません.
280                                 
281                             </para>
282                             
283                         </listitem>
284                         
285                     </itemizedlist>
286                     
287                 </listitem>
288                 
289             </varlistentry>
290             
291             <varlistentry>
292                 
293                 <term>jac</term>
294                 
295                 <listitem>
296                     
297                     <para>
298                         
299                         <link linkend="external">external</link> (関数またはリストまたは文字列). 指定した<literal>cj</literal>
300                         
301                         の値について, <literal>dg/dy + cj*dg/dydot</literal> の値を計算します.
302                         
303                     </para>
304                     
305                     <itemizedlist>
306                         
307                         <listitem>
308                             
309                             <para>Scilab関数.</para>
310                             
311                             <para>
312                                 呼び出し手順は <literal>r=jac(t,y,ydot,cj)</literal> で,
313                                 
314                                 <literal>jac</literal> 関数は
315                                 
316                                 <literal>r=dg(t,y,ydot)/dy+cj*dg(t,y,ydot)/dydot</literal>を返す必要があります.
317                                 
318                                 ただし,  
319                                 
320                                 <literal>cj</literal> は実数スカラーです.
321                                 
322                             </para>
323                             
324                         </listitem>
325                         
326                         <listitem>
327                             
328                             <para>リスト.</para>
329                             
330                             <para>以下のように指定します</para>
331                             
332                             <programlisting role="no-scilab-exec"><![CDATA[\r
333 list(jac,x1,x2,...)\r
334  ]]></programlisting>
335                             
336                             <para>ただし関数
337                                 
338                                 <literal>jac</literal> の呼び出し手順は以下のようになります
339                                 
340                             </para>
341                             
342                             <programlisting role="no-scilab-exec"><![CDATA[\r
343 r=jac(t,y,ydot,cj,x1,x2,...)\r
344  ]]></programlisting>
345                             
346                             <para>
347                                 
348                                 さらに<literal>jac</literal> は
349                                 
350                                 <literal>(t,y,ydot,cj,x1,x2,...)</literal>の関数として<literal>dg/dy + cj*dg/dydot</literal> を返します.
351                                 
352                             </para>
353                             
354                         </listitem>
355                         
356                         <listitem>
357                             
358                             <para>文字列.</para>
359                             
360                             <para>scilabにリンクされたCまたはFortran サブルーチンの名前を指定します
361                                 
362                             </para>
363                             
364                             <para>Cの場合, 呼び出し手順は以下となります:</para>
365                             
366                             <programlisting role="no-scilab-exec"><![CDATA[\r
367 void jac(double *t, double y[], double yd[], double pd[],\r
368          double *cj, double rpar[], int ipar[])\r
369  ]]></programlisting>
370                             
371                             <para>Fortranの場合は以下となります:</para>
372                             
373                             <programlisting role="no-scilab-exec"><![CDATA[\r
374 subroutine jac(t,y,yd,pd,cj,rpar,ipar)\r
375 double precision t, y(*),yd(*),pd(*),cj,rpar(*)\r
376 integer ipar(*)\r
377  ]]></programlisting>
378                             
379                         </listitem>
380                         
381                     </itemizedlist>
382                     
383                 </listitem>
384                 
385             </varlistentry>
386             
387             <varlistentry>
388                 
389                 <term>surf</term>
390                 
391                 <listitem>
392                     
393                     <para>
394                         
395                         <link linkend="external">external</link> (関数またはリストまたは文字列). 
396                         
397                         <literal>ng</literal>個の要素を有する列ベクトル <literal>surf(t,y)</literal> の値を計算します.
398                         
399                         各要素は局面を定義します.
400                         
401                         これは以下のように定義できます:
402                         
403                     </para>
404                     
405                     <itemizedlist>
406                         
407                         <listitem>
408                             
409                             <para>Scilab関数.</para>
410                             
411                             <para>呼び出し手順は
412                                 
413                                 <literal>surf(t,y)</literal>とします
414                                 
415                             </para>
416                             
417                         </listitem>
418                         
419                         <listitem>
420                             
421                             <para>リスト.</para>
422                             
423                             <para>以下のように定義します</para>
424                             
425                             <programlisting role="no-scilab-exec"><![CDATA[\r
426 list(surf,x1,x2,...)\r
427  ]]></programlisting>
428                             
429                             <para>ただし関数
430                                 
431                                 <literal>surf</literal>の呼び出し手順は以下とします
432                                 
433                             </para>
434                             
435                             <programlisting role="no-scilab-exec"><![CDATA[\r
436 r=surf(t,y,x1,x2,...)\r
437  ]]></programlisting>
438                             
439                         </listitem>
440                         
441                         <listitem>
442                             
443                             <para>文字列.</para>
444                             
445                             <para>ScilabにリンクされたC または Fortran サブルーチンの名前を指定します.
446                                 
447                             </para>
448                             
449                             <para>Cの場合, 呼び出し手順は以下とします:</para>
450                             
451                             <programlisting role="no-scilab-exec"><![CDATA[\r
452 void surf(int *ny, double *t, double y[], int *ng, double gout[])\r
453  ]]></programlisting>
454                             
455                             <para>Fortranの場合,  以下とします:</para>
456                             
457                             <programlisting role="no-scilab-exec"><![CDATA[\r
458 subroutine surf(ny,t,y,ng,gout)\r
459 double precision t, y(*),gout(*)\r
460 integer ny,ng\r
461  ]]></programlisting>
462                             
463                         </listitem>
464                         
465                     </itemizedlist>
466                     
467                 </listitem>
468                 
469             </varlistentry>
470             
471             <varlistentry>
472                 
473                 <term>info</term>
474                 
475                 <listitem>
476                     
477                     <para>
478                         
479                         <literal>14</literal> 個の要素を有するリスト. デフォルト値は
480                         
481                         <literal>list([],0,[],[],[],0,[],0,[],0,[],[],[],1)</literal>です.
482                         
483                     </para>
484                     
485                     <variablelist>
486                         
487                         <varlistentry>
488                             
489                             <term>info(1)</term>
490                             
491                             <listitem>
492                                 
493                                 <para>
494                                     
495                                     <literal>g</literal> を評価できる時刻の最大値を実数スカラーで指定します.
496                                     
497                                     時間を制限しない場合は空の行列<literal>[]</literal>を指定します.
498                                     
499                                 </para>
500                                 
501                             </listitem>
502                             
503                         </varlistentry>
504                         
505                         <varlistentry>
506                             
507                             <term>info(2)</term>
508                             
509                             <listitem>
510                                 
511                                 <para>
512                                     
513                                     <literal>dassl</literal> が中間計算値を返すか(<literal>flag=1</literal>)
514                                     
515                                     またはユーザが指定した時刻のみを返すか
516                                     
517                                     (<literal>flag=0</literal>)を指定するフラグ.
518                                     
519                                 </para>
520                                 
521                             </listitem>
522                             
523                         </varlistentry>
524                         
525                         <varlistentry>
526                             
527                             <term>info(3)</term>
528                             
529                             <listitem>
530                                 
531                                 <para>
532                                     
533                                     <literal>2</literal> 要素のベクトルで,
534                                     
535                                     <literal>jac</literal>; <literal>r(i - j + ml + mu + 1,j) =
536                                         
537                                         "dg(i)/dy(j)+cj*dg(i)/dydot(j)"
538                                         
539                                     </literal>
540                                     で計算するバンド行列の定義域<literal>[ml,mu]</literal>を指定します.
541                                     
542                                     <literal>info(3)=[]</literal>の場合, <literal>jac</literal> は通常の行列
543                                     
544                                     を返します.
545                                     
546                                     <literal>info(8)=1</literal>の場合, ダミーとして扱われます.
547                                     
548                                 </para>
549                                 
550                             </listitem>
551                             
552                         </varlistentry>
553                         
554                         <varlistentry>
555                             
556                             <term>info(4)</term>
557                             
558                             <listitem>
559                                 
560                                 <para>最大ステップサイズを指定する実数スカラー値.
561                                     
562                                     制限しない場合は <literal>info(4)=[]</literal>を指定します.
563                                     
564                                 </para>
565                                 
566                             </listitem>
567                             
568                         </varlistentry>
569                         
570                         <varlistentry>
571                             
572                             <term>info(5)</term>
573                             
574                             <listitem>
575                                 
576                                 <para>初期ステップサイズを指定する実数スカラー値.
577                                     
578                                     指定しない場合は <literal>info(5)=[]</literal>を指定します.
579                                     
580                                 </para>
581                                 
582                             </listitem>
583                             
584                         </varlistentry>
585                         
586                         <varlistentry>
587                             
588                             <term>info(6)</term>
589                             
590                             <listitem>
591                                 
592                                 <para>
593                                     
594                                     解が非負であることが既知な場合は <literal>info(6)=1</literal>,
595                                     
596                                     それ以外は <literal>info(6)=0</literal> を指定します.
597                                     
598                                 </para>
599                                 
600                             </listitem>
601                             
602                         </varlistentry>
603                         
604                         <varlistentry>
605                             
606                             <term>info(7)</term>
607                             
608                             <listitem>
609                                 
610                                 <para>
611                                     
612                                     ydot0 が<literal>g(t0,y0,ydot0)=0</literal>のように指定された場合,
613                                     
614                                     <literal>info(7)=[]</literal> と指定します.
615                                     
616                                     それ以外の場合は <literal>info(7)=[+-1, ..., +-1]</literal>とします.
617                                     
618                                     ここで,y(i)が微分変数の場合は<literal>info(7)(i)=1</literal>,
619                                     
620                                     y(i)が代数変数(関数g(t,y,ydot)に微分値が陽に現れない)の場合は
621                                     
622                                     <literal>info(7)(i)=-1</literal>とします.
623                                     
624                                 </para>
625                                 
626                             </listitem>
627                             
628                         </varlistentry>
629                         
630                         <varlistentry>
631                             
632                             <term>info(8)</term>
633                             
634                             <listitem>
635                                 
636                                 <para>
637                                     
638                                     直接法 / Krylov. 
639                                     
640                                     ソルバーでKrylov反復法を使用したい場合,<literal>info(8)=1</literal>と指定し,
641                                     
642                                     <literal>psol</literal>にルーチンを指定します.
643                                     
644                                     それ以外の場合(dasslの直接法)は<literal>info(8)=0</literal>を指定します.
645                                     
646                                 </para>
647                                 
648                             </listitem>
649                             
650                         </varlistentry>
651                         
652                         <varlistentry>
653                             
654                             <term>info(9)</term>
655                             
656                             <listitem>
657                                 
658                                 <para>
659                                     
660                                     Krylovパラメータ. 
661                                     
662                                     <literal>info(8)=0</literal>とした場合はダミー引数として処理されます. 
663                                     
664                                     それ以外の場合は
665                                     
666                                     <literal>info(9)=[maxl kmp nrmax epli]</literal>を指定します, ただし:
667                                     
668                                 </para>
669                                 
670                                 <para>
671                                     
672                                     - maxl = mSPIGMRアルゴリズムの最大反復回数 (デフォルト
673                                     
674                                     <literal>min(5,neq)</literal>),
675                                     
676                                 </para>
677                                 
678                                 <para>
679                                     
680                                     - kmp = SPIGMRアルゴリズムで直交化を行うベクトルの数
681                                     
682                                     (デフォルト maxl),
683                                     
684                                 </para>
685                                 
686                                 <para>
687                                     
688                                     - nrmax = 各非線形反復におけるSPIGMRアルゴリズムのリスタート最大数
689                                     
690                                     (デフォルト <literal>5</literal>),
691                                     
692                                 </para>
693                                 
694                                 <para>
695                                     
696                                     - epli = SPIGMRアルゴリズムの収束安定定数 (デフォルト <literal>0.05</literal>).
697                                     
698                                 </para>
699                                 
700                             </listitem>
701                             
702                         </varlistentry>
703                         
704                         <varlistentry>
705                             
706                             <term>info(10)</term>
707                             
708                             <listitem>
709                                 
710                                 <para>
711                                     
712                                     初期条件.
713                                     
714                                     <literal>info(7)=[]</literal>の場合はダミーとして処理されます. 
715                                     
716                                     初期条件の計算直後にソルバーを停止させる場合は
717                                     
718                                     <literal>info(10)=1</literal>と指定し,それ以外は
719                                     
720                                     <literal>info(10)=0</literal>と指定します.
721                                     
722                                 </para>
723                                 
724                             </listitem>
725                             
726                         </varlistentry>
727                         
728                         <varlistentry>
729                             
730                             <term>info(11)</term>
731                             
732                             <listitem>
733                                 
734                                 <para>
735                                     
736                                     <literal>psol</literal>用のプリコンディショナ計算およびLU分解ルーチン.
737                                     
738                                     <literal>info(8)=0</literal>の場合はダミーとして扱われます. 
739                                     
740                                     <link linkend="external">external</link> <literal>psol</literal>が特定の
741                                     
742                                     ルーチンを使用する必要がある場合は,<literal>info(11)=1</literal>を指定し,
743                                     
744                                     <literal>pjac</literal>ルーチンを指定します.
745                                     
746                                     それ以外は<literal>info(11)=0</literal>とします.
747                                     
748                                 </para>
749                                 
750                             </listitem>
751                             
752                         </varlistentry>
753                         
754                         <varlistentry>
755                             
756                             <term>info(12)</term>
757                             
758                             <listitem>
759                                 
760                                 <para>
761                                     
762                                     全変数についてエラー制御をローカルに行いたい場合,
763                                     
764                                     <literal>info(12)=[]</literal>を指定します. それ以外は,
765                                     
766                                     <literal>info(12)=[+-1, ..., +-1]</literal>を指定します.
767                                     
768                                     ただし, y(i)が微分変数の場合は  <literal>info(12)(i)=1</literal>,
769                                     
770                                     y(i)が代数変数(微係数が関数g(t,y,ydot)に陽に現れない) の場合は
771                                     
772                                     <literal>info(12)(i)=-1</literal>とします.
773                                     
774                                 </para>
775                                 
776                             </listitem>
777                             
778                         </varlistentry>
779                         
780                         <varlistentry>
781                             
782                             <term>info(13)</term>
783                             
784                             <listitem>
785                                 
786                                 <para>
787                                     
788                                     経験的なパラメータ.
789                                     
790                                     <literal>info(7)=[]</literal>の場合はダミーとして扱われます. 
791                                     
792                                     それ以外の場合,
793                                     
794                                     <literal>info(13)=[mxnit mxnj mxnh lsoff stptol epinit]</literal>を指定します, 
795                                     
796                                     ただし:
797                                     
798                                 </para>
799                                 
800                                 <para>
801                                     
802                                     - mxnit = ヤコビアンまたはプリコンディショナ評価毎のニュートン反復の最大回数
803                                     
804                                     (デフォルト:<literal>info(8)=0</literal>の場合は <literal>5</literal>,
805                                     
806                                     それ以外は <literal>15</literal>),
807                                     
808                                 </para>
809                                 
810                                 <para>
811                                     
812                                     - mxnj = ヤコビアンまたはプリコンディショナ評価の最大回数
813                                     
814                                     (デフォルト:<literal>info(8)=0</literal>の場合は <literal>6</literal>,
815                                     
816                                     それ以外は <literal>2</literal>),
817                                     
818                                 </para>
819                                 
820                                 <para>
821                                     
822                                     - mxnh = info(7) &#8800; [] の場合に試行する人工的なステップサイズ
823                                     
824                                     パラメータHの最大値
825                                     
826                                     (デフォルト <literal>5</literal>),
827                                     
828                                 </para>
829                                 
830                                 <para>
831                                     
832                                     - lsoff = ライン探索アルゴリズムをオフにするフラグ 
833                                     
834                                     (lsoff = 0 はライン探索有効を意味します, lsoff = 1 はオフを意味します)
835                                     
836                                     (デフォルト: <literal>0</literal>),
837                                     
838                                 </para>
839                                 
840                                 <para>
841                                     
842                                     - stptol = ライン探索アルゴリズムの最小スケール刻み (デフォルト: <literal>(丸め誤差単位)^(2/3)</literal>),
843                                     
844                                 </para>
845                                 
846                                 <para>
847                                     
848                                     - epinit = ニュートン反復収束判定の振幅係数 (デフォルト <literal>0.01</literal>).
849                                     
850                                 </para>
851                                 
852                             </listitem>
853                             
854                         </varlistentry>
855                         
856                         <varlistentry>
857                             
858                             <term>info(14)</term>
859                             
860                             <listitem>
861                                 
862                                 <para>
863                                     
864                                     冗長性.
865                                     
866                                     出力を最小化する場合は <literal>info(14)=1</literal>,
867                                     
868                                     最大化する場合は <literal>info(14)=2</literal>, それ以外は
869                                     
870                                     <literal>info(14)=0</literal>を指定します.
871                                     
872                                 </para>
873                                 
874                             </listitem>
875                             
876                         </varlistentry>
877                         
878                     </variablelist>
879                     
880                 </listitem>
881                 
882             </varlistentry>
883             
884             <varlistentry>
885                 
886                 <term>psol</term>
887                 
888                 <listitem>
889                     
890                     <para>
891                         
892                         <link linkend="external">external</link> (関数またはリストまたは文字列). 
893                         
894                         線形システム<literal>P*x = b</literal>を解きます.
895                         
896                         ただし, P はプリコンディショナで, ルーチン <literal>pjac</literal> 
897                         
898                         が事前に計算して, wp 及び iwpに保存します.
899                         
900                     </para>
901                     
902                     <itemizedlist>
903                         
904                         <listitem>
905                             
906                             <para>Scilab関数.</para>
907                             
908                             <para>呼び出し手順は
909                                 
910                                 <literal>[r, ier] = psol(wp, iwp, b)</literal> とします.
911                                 
912                                 <literal>psol</literal> 関数はシステムの解<literal>r</literal>と
913                                 
914                                 エラーフラグ<literal>ier</literal>を返す必要があります.
915                                 
916                             </para>
917                             
918                         </listitem>
919                         
920                         <listitem>
921                             
922                             <para>リスト.</para>
923                             
924                             <para>以下のような形式とします</para>
925                             
926                             <programlisting role="no-scilab-exec"><![CDATA[\r
927 list(psol,x1,x2,...)\r
928  ]]></programlisting>
929                             
930                             <para>ただし, 関数
931                                 
932                                 <literal>psol</literal>の呼び出し手順は以下とします
933                                 
934                             </para>
935                             
936                             <programlisting role="no-scilab-exec"><![CDATA[\r
937 psol(wp,iwp,b,x1,x2,...)\r
938  ]]></programlisting>
939                             
940                             <para>
941                                 
942                                 <literal>psol</literal> は <literal>r</literal>の解を返します.
943                                 
944                             </para>
945                             
946                         </listitem>
947                         
948                         <listitem>
949                             
950                             <para>文字列.</para>
951                             
952                             <para>ScilabにリンクされたCまたはFortranサブルーチンの名前を指定します
953                                 
954                             </para>
955                             
956                             <para>Cの場合,呼び出し手順は以下とします:</para>
957                             
958                             <programlisting role="no-scilab-exec"><![CDATA[\r
959 void psol (int*neq, double*t, double*y, double*ydot, double*savr,\r
960   double*wk, double*cj, double*wght, double*wp, int*iwp, double*b, double*eplin, int*ier, double*rpar, int*ipar)\r
961  ]]></programlisting>
962                             
963                             ただし,配列 <literal>wp</literal> および <literal>iwp</literal> はプリコンディショナ
964                             
965                             <literal>P</literal>の行列要素を行圧縮形式で有します.
966                             
967                             <para>Fortranの場合は以下とします:</para>
968                             
969                             <programlisting role="no-scilab-exec"><![CDATA[\r
970 subroutine psol (neq, t, y, ydot, savr, wk, cj, wght,\r
971   wp, iwp, b, eplin, ier, rpar, ipar)\r
972 double precision t,y(*),ydot(*),savr(*),wk(*),cj,wght(*),wp(*),\r
973   b(*),eplin,rpar(*)\r
974 integer neq,iwp(*),ier,ipar(*)\r
975  ]]></programlisting>
976                             
977                         </listitem>
978                         
979                     </itemizedlist>
980                     
981                 </listitem>
982                 
983             </varlistentry>
984             
985             <varlistentry>
986                 
987                 <term>pjac</term>
988                 
989                 <listitem>
990                     
991                     <para>
992                         
993                         <link linkend="external">external</link> (関数またはリストまたは文字列). 
994                         
995                         指定したパラメータ<literal>cj</literal>について
996                         
997                         <literal>dg/dy + cj*dg/dydot</literal>を計算し,
998                         
999                         doubleおよびint配列にLU分解を行います.
1000                         
1001                     </para>
1002                     
1003                     <itemizedlist>
1004                         
1005                         <listitem>
1006                             
1007                             <para>Scilab関数.</para>
1008                             
1009                             <para>呼び出し手順は
1010                                 
1011                                 <literal>[wp, iwp, ires] = pjac(neq, t, y, ydot, h, cj, rewt, savr)</literal>
1012                                 
1013                                 となり, 結果として,
1014                                 
1015                                 配列 wp および iwp には全てのプリコンディショナ情報が
1016                                 
1017                                 圧縮スパース行形式で返されます.
1018                                 
1019                             </para>
1020                             
1021                         </listitem>
1022                         
1023                         <listitem>
1024                             
1025                             <para>リスト.</para>
1026                             
1027                             <para>以下の形式とします</para>
1028                             
1029                             <programlisting role="no-scilab-exec"><![CDATA[\r
1030 list(pjac,x1,x2,...)\r
1031  ]]></programlisting>
1032                             
1033                             <para>ただし,関数
1034                                 
1035                                 <literal>pjac</literal>の呼び出し手順は以下とします
1036                                 
1037                             </para>
1038                             
1039                             <programlisting role="no-scilab-exec"><![CDATA[\r
1040 pjac(neq,t,y,ydot,h,cj,rewt,savr,x1,x2,...)\r
1041  ]]></programlisting>
1042                             
1043                             <para>
1044                                 
1045                                 <literal>pjac</literal> は,
1046                                 
1047                                 <literal>(neq,t,y,ydot,h,cj,rewt,savr,x1,x2,...)</literal>の関数として
1048                                 
1049                                 分解した <literal>dg/dy + cj*dg/dydot</literal> を返します.
1050                                 
1051                             </para>
1052                             
1053                         </listitem>
1054                         
1055                         <listitem>
1056                             
1057                             <para>文字列.</para>
1058                             
1059                             <para>ScilabにリンクされたCまたはFortran形式のサブルーチン名を指定します
1060                                 
1061                             </para>
1062                             
1063                             <para>Cの場合,呼び出し手順は以下とします:</para>
1064                             
1065                             <programlisting role="no-scilab-exec"><![CDATA[\r
1066 void pjac (double*res, int*ires, int*neq, double*t, double*y, double*ydot, double*rewt, double*savr,\r
1067 double*wk, double*h, double*cj, double*wp, int*iwp, int*ier, double*rpar, int*ipar)\r
1068  ]]></programlisting>
1069                             
1070                             <para>Fortranの場合, 以下のとします:</para>
1071                             
1072                             <programlisting role="no-scilab-exec"><![CDATA[\r
1073 subroutine pjac (res, ires, neq, t, y, ydot, rewt, savr,\r
1074   wk, h, cj, wp, iwp, ier, rpar, ipar)\r
1075 double precision res(*), t, y(*), ydot(*), rewt(*), savr(*),\r
1076   wk(*), h, cj, wp(*), rpar(*)\r
1077 integer ires, neq, iwp(*), ier, ipar(*)\r
1078  ]]></programlisting>
1079                             
1080                         </listitem>
1081                         
1082                     </itemizedlist>
1083                     
1084                 </listitem>
1085                 
1086             </varlistentry>
1087             
1088             <varlistentry>
1089                 
1090                 <term>hd</term>
1091                 
1092                 <listitem>
1093                     
1094                     <para>
1095                         
1096                         <literal>dassl</literal>コンテキストを保存し,積分を再開できるようにする実数ベクトル.
1097                         
1098                     </para>
1099                     
1100                 </listitem>
1101                 
1102             </varlistentry>
1103             
1104             <varlistentry>
1105                 
1106                 <term>r</term>
1107                 
1108                 <listitem>
1109                     
1110                     <para>
1111                         
1112                         実数行列 .
1113                         
1114                         各列はベクトル<literal>[t;x(t);xdot(t)]</literal>で,
1115                         
1116                         <literal>t</literal> は解が計算される添字の時刻です.
1117                         
1118                     </para>
1119                     
1120                 </listitem>
1121                 
1122             </varlistentry>
1123             
1124         </variablelist>
1125         
1126     </refsection>
1127     
1128     <refsection>
1129         
1130         <title>説明</title>
1131         
1132         <para>陰的微分方程式の解.</para>
1133         
1134         <programlisting role="no-scilab-exec"><![CDATA[\r
1135 g(t,y,ydot) = 0\r
1136 y(t0) = y0  and   ydot(t0) = ydot0\r
1137  ]]></programlisting>
1138         
1139         <para>
1140             
1141             局面交差した時刻と面交差した数を<literal>nn</literal>に返します.
1142             
1143         </para>
1144         
1145         <para>詳細な例は SCI/modules/differential_equations/tests/unit_tests/daskr.tst にあります.</para>
1146         
1147     </refsection>
1148     
1149     <refsection>
1150         
1151         <title>例</title>
1152         
1153         <programlisting role="example"><![CDATA[\r
1154 // dy/dt = ((2*log(y)+8)/t -5)*y,  y(1) = 1,  1 <= t <=6\r
1155 // g1 = ((2*log(y)+8)/t - 5)*y\r
1156 // g2 = log(y) - 2.2491\r
1157 y0 = 1; t = 2:6; t0 = 1; y0d = 3;\r
1158 atol = 1.d-6; rtol = 0; ng = 2;\r
1159 \r
1160 deff('[delta,ires] = res1(t,y,ydot)','ires = 0; delta = ydot-((2*log(y)+8)/t-5)*y')\r
1161 deff('[rts] = gr1(t,y)','rts = [((2*log(y)+8)/t-5)*y; log(y)-2.2491]')\r
1162 \r
1163 [yy,nn] = daskr([y0,y0d],t0,t,atol,rtol,res1,ng,gr1);\r
1164 nn\r
1165 \r
1166 // nn = [2.4698972 2] を返します\r
1167  ]]></programlisting>
1168         
1169     </refsection>
1170     
1171     <refsection role="see also">
1172         
1173         <title>参照</title>
1174         
1175         <simplelist type="inline">
1176             
1177             <member>
1178                 
1179                 <link linkend="ode">ode</link>
1180                 
1181             </member>
1182             
1183             <member>
1184                 
1185                 <link linkend="dasrt">dasrt</link>
1186                 
1187             </member>
1188             
1189             <member>
1190                 
1191                 <link linkend="dassl">dassl</link>
1192                 
1193             </member>
1194             
1195             <member>
1196                 
1197                 <link linkend="impl">impl</link>
1198                 
1199             </member>
1200             
1201             <member>
1202                 
1203                 <link linkend="fort">fort</link>
1204                 
1205             </member>
1206             
1207             <member>
1208                 
1209                 <link linkend="link">link</link>
1210                 
1211             </member>
1212             
1213             <member>
1214                 
1215                 <link linkend="external">external</link>
1216                 
1217             </member>
1218             
1219         </simplelist>
1220         
1221     </refsection>
1222     
1223     <refsection>
1224         
1225         <title>履歴</title>
1226         
1227         <revhistory>
1228             
1229             <revision>
1230                 
1231                 <revnumber>5.5.0</revnumber>
1232                 
1233                 <revdescription>daskr ソルバーが追加されました</revdescription>
1234                 
1235             </revision>
1236             
1237         </revhistory>
1238         
1239     </refsection>
1240     
1241 </refentry>
1242