MATLAB爱好者论坛-LabFans.com

MATLAB爱好者论坛-LabFans.com (https://www.labfans.com/bbs/index.php)
-   MATLAB论坛 (https://www.labfans.com/bbs/forumdisplay.php?f=6)
-   -   【求助】为什么这样简单的方程也会出错? (https://www.labfans.com/bbs/showthread.php?t=573)

隐身猪 2007-07-15 13:27

【求助】为什么这样简单的方程也会出错?
 
方程1:
function Ayy
x0=1;
x=fzero(@Ff,x0);
%%%%%%%%%%%%%%%%%%
function f=Ff(x)
A=zeros(6,1);
A(3)=log(x)+x^2;
A(2)=x^3;
f=A(3)-A(2);

??? Error using ==> fzero
Too many input arguments.

Error in ==> yy at 3
x=fzero(@Ff,x0);

不明白为什么。

方程2:
function Fshiyan
clc;
x0=[3,3];
f=fsolve(@ffG,x0);
%%%%%%%%%%%%%%%
function f=ffG(x)
f1=x(1)-x(2);
f2=x(1)^2-10;
f=[f1;f2];

Optimization terminated: first-order optimality is less than options.TolFun.

以上两个方程,请高人指点一二,万分感谢


所有时间均为北京时间。现在的时间是 11:12

Powered by vBulletin
版权所有 ©2000 - 2025,Jelsoft Enterprises Ltd.