I'm trying to use fsolve to numerically solve a system of non-linear equations but it isn't working. Also all the variables in the function (except x(1) and x(2) are constants that I define before the function. This is my code:
myfun = @(x) [(2*theta*(x(1).^4))+(theta*(x(2)).^4)*(tad+aad-1)+((S/4)*(aa+ta-1-(as*ta)))-(c*(x(2)-x(1)));... ((S/4)*(as*ta-ta))+(c*(x(2)-x(1)))+(theta*(x(2)).^4)*(1-aad)-(theta*(x(1)).^(4))];x0 = [273,273];[x,fval] = fsolve(myfun,x0)
This is the error code I get
No solution found.fsolve stopped because the problem appears regular as measured by the gradient,but the vector of function values is not near zero as measured by thedefault value of the function tolerance.<stopping criteria details>x = 265.2980 280.7020fval = -119.6125 -119.6125
Best Answer