Hello, i'm trying to solve a nonlinear system of equations and I saw on the web that the function I should be looking for was "fsolve" (I am a beginner MATLAB user). I created my personal function as the following:
function y = eita(x, alpha)y(1) = 1.543*10^-5 * x + 0.57y(2) =(44.092 / 0.89605 - x) - alphaend
Then I opened another path to call fsolve:
fun = @eitax0= [0,0]sol = fsolve(fun,x0)
But something is wrong with my code and I get this command box report:
Subscripted assignment dimension mismatch. Error in eita (line 2)y(1) = 1.543*10^-5 * x + 0.57 Error in fsolve (line 230) fuser = feval(funfcn{3},x,varargin{:}); Error in ha (line 3)sol = fsolve(fun,x0) Caused by: Failure in initial objective function evaluation. FSOLVE cannot continue.
Best Answer