Unable to run a simple 'fsolve' example.
이전 댓글 표시
Hi,
While running the root2d example file provided with the 'fsolve' document, MATLAB is throwing the following error:
Unrecognized function or variable 'eml_allow_mx_inputs'.
Error in fsolve
The code for root2d file is below and the m-file is placed in the MATLAB directory:
function F = root2d(x)
F(1) = exp(-exp(-(x(1)+x(2)))) - x(2)*(1+x(1)^2);
F(2) = x(1)*cos(x(2)) + x(2)*sin(x(1)) - 0.5;
end
I am running the following syntax to solve 'root2d':
fun = @root2d;
x0 = [0,0];
x = fsolve(fun,x0)
댓글 수: 2
Walter Roberson
2023년 4월 11일
Experiment with
restoredefaultpath; rehash toolboxcache
If that solves the problem then
savepath
Shiv Tewari
2023년 4월 11일
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Solver Outputs and Iterative Display에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!