Non linear least square function lsqnonlin
1 次查看(过去 30 天)
显示 更早的评论
I was wondering if there is a way to stop the lsqnonlin function before converge to the optimal solution.
0 个评论
回答(1 个)
Matt J
2018-4-23
编辑:Matt J
2018-4-23
You can apply your own stopping criterion in any of the Optimization Toolbox solvers using the OutputFcn option, e.g.,
options = optimoptions(@lsqnonlin,'OutputFcn',@myFunction)
Similarly, you could limit the number of iterations to some desired maximum if that's what you're trying to do.
options = optimoptions(@lsqnonlin,'MaxIter',Nmax)
0 个评论
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Nonlinear Optimization 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!