How is the residual in lsqnonlin calculated?

Does anyone know how's the residual being calcualted in lsqnonlin function?
I am interested to know the formula.
Is it : res = sum(fun(x).^2) at x?
Where fun is the function you are trying to minimize.

2 件のコメント

Torsten
Torsten 2019 年 4 月 2 日
編集済み: Torsten 2019 年 4 月 2 日
5th line from above under
But as a user of lsqnonlin, you have to supply the residual vector as
res(i) = f_i(x)
where f_i(x) is the i-th function you want to zeroize.
John D'Errico
John D'Errico 2019 年 4 月 2 日
Exactly. lsqnonlin does not calculate any residual. YOU calculate it, and return that to lsqnonlin, via your objective function.

サインインしてコメントする。

回答 (0 件)

カテゴリ

質問済み:

2019 年 4 月 2 日

コメント済み:

2019 年 4 月 2 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by