|
马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。
您需要 登录 才可以下载或查看,没有账号?我要加入
x
A=[-17.7166,5.1179;50.3437,-20.9333;-99.3832,66.756;236.1567,-192.9286;-169.4007,141.9878];
b=[73.8263;75.5454;13.6275;21.772;15.2625];
x0=[3;3];
x=fmincon('((405.5574*x(3)-334.9164*x(4)+35.0546)^2+(-17.7166*x(3)+5.1179*x(4)+36.0007)^2)^(1/2)',x0,A,b)
Warning: Large-scale (trust region) method does not currently solve this type of problem,
switching to medium-scale (line search).
> In fmincon at 260
??? Error using ==> fmincon
FMINCON cannot continue because user supplied objective function failed with the following error:
Error using ==> inlineeval
Error in inline expression ==> ((405.5574*x(3)-334.9164*x(4)+35.0546)^2+(-17.7166*x(3)+5.1179*x(4)+36.0007)^2)^(1/2)
??? Error using ==> eval
Index exceeds matrix dimensions.
谢谢,很不好意思 |
|