Not enough input arguments in function with fsolve

13 Ansichten (letzte 30 Tage)
Ece Balkan
Ece Balkan am 20 Jul. 2016
Bearbeitet: Matt J am 20 Jul. 2016
I can not figure out what causes this error in this function. Any help will be appreciated. Thanks!
function gx = gx_fermi(y,t1,t2 )
options=optimset('Display','iter');
gx=fsolve(@(t1,t2,y)[0 t1 6*(y^(1/2)) 0]*(t2-t1),[t1,t2,y],options);
% disp(gx);
gx=reshape(gx,[2,2]);
end
  1 Kommentar
Matt J
Matt J am 20 Jul. 2016
Bearbeitet: Matt J am 20 Jul. 2016
The problem you are solving with fsolve looks highly degenerate. There is a continuum of solutions over the sets of points {t1=t2} and over {t1=y=0}.

Melden Sie sich an, um zu kommentieren.

Antworten (1)

Matt J
Matt J am 20 Jul. 2016
Bearbeitet: Matt J am 20 Jul. 2016
fun = @(x) [0 x(1) 6*(x(3)^(1/2)) 0]*(x(2)-x(1));
gx=fsolve(fun ,[t1,t2,y],options);

Kategorien

Mehr zu Deep Learning Toolbox finden Sie in Help Center und File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by