「GNU Octave 2.1.x 日本語マニュアル/数値積分」の版間の差分

削除された内容 追加された内容
quad_options (opt, val)
quad_options (opt, val)
63 行
</source>
 
演算子‘dot’フォームの使用に留意してください。quadの呼び出しで必須ではありませんが、プロットのための点の集合を生成するのがはるかに簡単になります(引数がベクトルで、結果がベクトルを持つ関数として呼び出すことを可能にします)。
Note the use of the ‘dot’ forms of the operators. This is not necessary for the call to quad, but it makes it much easier to generate a set of points for plotting (because it makes it possible to call the function with a vector argument to produce a vector result).
単にquadを呼び出します:
 
Then we simply call quad:
 
<source lang=matlab>
75 ⟶ 74行目:
</source>
 
難しい積分にもかかわらず、quadがierにゼロ以外の値を返したら結果は十分に正確です。
Although quad returns a nonzero value for ier, the result is reasonably accurate (to see why, examine what happens to the result if you move the lower bound to 0.1, then 0.01, then 0.001, etc.).
(理由を理解するために、下限を0.1, 次に 0.01, さらに 0.001, etc.と移動したときに何がおこるか試験してください)
 
=== 22.2 Orthogonal Collocation ===