In the function fit, what exactly is the difference between the 2 parameters MaxFunEvals & MaxIter?

조회 수: 7 (최근 30일)
In the function fit(Curve Fitting Toolbox), what exactly is the difference between the 2 parameters MaxFunEvals & MaxIter?
  댓글 수: 1
dpb
dpb 2019년 8월 5일
In nonlinear fitting there's more than one function evaluation per solution iteration -- the number of "outer" iterations is MaxIter while the number of total function evaluations is MaxFunEvals There's no specific relationship between the two; if one has a very expensive functional, one can limit total time by not allowing more than some N evaluations. Of course, limiting either risks terminating before convergence even if there may be a final solution.

댓글을 달려면 로그인하십시오.

채택된 답변

Steven Lord
Steven Lord 2019년 8월 5일
If you had to walk through an unfamiliar darkened room and you had a stick, you might tap the ground in front of you, in front and to the left, and in front and to the right to determine where the path is clear. Once you know the direction where it's safe to move, you take a step and repeat the process of tapping and stepping.
Tapping the ground is a function evaluation. Stepping is an iteration. One step (iteration) may require multiple taps (function evaluations) to complete.
  댓글 수: 3
Bruno Luong
Bruno Luong 2019년 8월 13일
편집: Bruno Luong 2019년 8월 13일
If you provide the Jacobian the number of function evaluations will be close to the number iterations.
If not the minimizer needs to evaluation additional N function-evaluations per iteration and estimate the Jacobian by finite difference. So the number of function evaluations is roughly N x m, whener N is the number of unkown parameter and m the number of iterations.
Beside that there is also some extra function evaluation duting a "line search" meaning once the descent direction is known, the optimizer might need more than 1 iteration to goes down before changing the direction.
On top of that the selected algoritm also affect both counters for reach the same performance.
To set correctly the parameters, the most important thing to know is whereas you provide or not the Jacobian to the minimizer.

댓글을 달려면 로그인하십시오.

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Get Started with Curve Fitting Toolbox에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by