Solution of the following error : "Maximum number of function evaluations reached; increase OPTIONS.MaxFunEvals".
2 views (last 30 days)
Show older comments
Hi Dear all, I have the problem in solving the non-linear equations. My code is as follows- The code is : %========================================================================== 27 MAR 2014 % x(1)= x % x(2)= y %++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Eqs = @(x,y) [(((1+2.*x(1).^2)./(1-x(1).^2))+(4.*(1-2.*x(2).^2).*sqrt(1-x(1).^2).*(2+x(1).^2))./((1-x(1).^2).*(1-x(2).^2).^0.5.*(2+x(2).^2)));... (((4.*(x(2).*(2+x(1).^2).*(1-x(1).^2).*sqrt(pi.^2.*(1-x(2).^2)+4.*x(2).^2)))./(x(1).*(2+x(2).^2).*(1-x(2).^2).*sqrt(pi.^2.*(1- x(1).^2)+4.*x(1).^2))-1))]; %========================================================================== xy = []; Eqval = []; for k1 = [0.25 0.25] % Guess Values [p, fval] = fsolve(Eqs,[k1; k1]); xy = [xy p]; Eqval = [Eqval fval]; end xy Eqval %@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ When i ran the above code, i got the following message
Maximum number of function evaluations reached: increase options.MaxFunEvals.
xy = 1.0e-005 * -0.8410 -0.8410 -0.2102 -0.2102 Eqval = 5.0000 5.0000 -0.0000 -0.0000
Kindly suggest me to get the correct roots of the above TWO NON-LINEAR Equations.
0 Comments
Answers (0)
See Also
Categories
Find more on Systems of Nonlinear Equations in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!