fsolveの目的関数を配列で出力する場合の,要素ごとの計算方法を教えてください.
Show older comments
関数fsolveを使用して,以下の非線形連立方程式を解きたいです.
G = [10 11 ; 12 13];
H = [-2 -1 ; -2 -3];
f = @(x)[x(1).*x(2)-5*x(2)+G(:,:), x(1).^3-x(2).^2+H(:,:)];
% 初期値
x0 = [I J];
I = [1 1 ; 1 1];
J = [1 1 ; 1 1];
x = fsolve(f,x0,options)
で,関数fの要素ごと(この例では2×2)で出力(x1,x2)を各要素で求めたいのですが,方法がわかりません.
分かる方いらっしゃいましたらご回答お願いいたします.
Accepted Answer
More Answers (0)
Categories
Find more on Matrix Indexing in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!