Error in optimoptions for Fmincon

10 ビュー (過去 30 日間)
Moe Almakhaita
Moe Almakhaita 2017 年 1 月 31 日
回答済み: Marcelo Fernandes 2019 年 11 月 25 日
Hello,
For this line of code:
options=optimoptions(@fmincon,'MaxFunctionEvaluations',Inf,'MaxIterations',3000*t,'Algorithm','interior-point','ConstraintTolerance',1e-7);
I keep getting the following error:
Error using optimoptions (line 105) 'MaxFunctionEvaluations' is not an option for FMINCON. A list of options can be found on the FMINCON documentation page.
I have R2015a on a 32 bit machine. Global Optimization toolbox purchased. It is an option for FMINCON and the same program has a history of running just fine on another computer. Could it be that the issue is in the transferring of the license or that I run it now on a 32 bit rather than 64?

回答 (3 件)

Steven Lord
Steven Lord 2017 年 1 月 31 日
The online documentation is for the most recent release (currently release R2016b) and uses the renamed options introduced in release R2016a. Refer to the documentation installed with your release of Optimization Toolbox and/or the "Current and Legacy Option Name Tables" linked in that Release Notes entry for the names of the options in your release.

jinhyuk kim
jinhyuk kim 2017 年 2 月 1 日
I am using 2016b academic version
I got error message ( the function is working other version)
'getIpOptions'은(는) 정의되지 않은 함수 또는 변수입니다.
error: fmincon (line 796) options = getIpOptions(options,sizes.nVar,mEq,flags.constr,defaultopt,10,0.01);
error: try1 (line 13) [x,fval,exitflag,output,lambda,grad,hessian] = fmincon(@try_obj,x0,[],[],[],[],[],[],@try_con,options);
  1 件のコメント
Walter Roberson
Walter Roberson 2017 年 2 月 1 日
Please show
which -all fmincon
I suspect that your path is to a different MATLAB release than you are using.

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


Marcelo Fernandes
Marcelo Fernandes 2019 年 11 月 25 日
Check out this answer from another topic.
I also had this problem when updating my MATLAB to a newer version without deleting/uninstalling the older version. I ended up having to reinstall the new version after deleting all of the other files related to older versions.

カテゴリ

Help Center および File ExchangeSurrogate Optimization についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by