fmincon instead of lsqcurvefit

3 次查看(过去 30 天)
options = optimoptions(@lsqcurvefit,'Algorithm','levenberg-marquardt','MaxIter',10000,'TolX',1e-12);
[p,resnorm,res,EXITFLAG,OUTPUT,LAMBDA,jocob]=lsqcurvefit(@fun725,p0,time,x,pL,pU);
While using this we are not getting proper value. How can we implement 'fmincon' or someother optimisation tools.
  1 个评论
Star Strider
Star Strider 2021-2-27
Note that ‘proper value’ is a matter of interpretation. It depends on what ‘fun725’ is, how you wrote it, and what initial parameter estimates you provided.
Some of the Global Optimization Toolbox functions can search the entire parameter space for the best parameter set, so using it would likely be appropriate.

请先登录,再进行评论。

采纳的回答

Shadaab Siddiqie
Shadaab Siddiqie 2021-3-2
If the problem is data fitting, then you should use 'lsqcurvefit' if possible. If the problem has nonlinear constraints, then see the random discussion.
if the problem is to find minimum, then you should use 'fmincon' if possible. It workes for nonlinear multivariable function.

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Nonlinear Optimization 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by