Qurak

Find a local minimum

4 ステップを1つのセッション内で順に実行します。各ステップはエンジンで実行済みで、以下の出力は実際に生成されたものです。

ステップ 1
Plot[x Cos[x], {x, 0, 20}]
出力
-Graphics-
ステップ 2
min = FindMinimum[x Cos[x], {x, 2}]
出力
{-3.2883713955908966, {x -> 3.4256184594817283}}
ステップ 3
pt = Reverse[Cases[min, _ ? NumberQ, Infinity]]
出力
{3.4256184594817283, -3.2883713955908966}
ステップ 4
Plot[x Cos[x], {x, 0, 20}, Epilog -> {PointSize[Medium], Point[pt]}]
出力
-Graphics-

使用する関数

関連レシピ

すべてのレシピ · 関数リファレンス · MCPクライアントから使う