1.用solve命令求解
clc;clear;syms x2j=1;su=0;x1=2;jie=solve((x1-x1^(-1)*x2^2)/(1-(x1^2+x2^2+x1^(-2)*x2^(-2)-3)/69)==su,x2);
2.用fsolve
◆写好function函数
function F = myfun(x)F = [2*x(1) - x(2) - exp(-x(1));-x(1) + 2*x(2) - exp(-x(2))];
◆ 写好实现函数
x0 = [-5; -5]; % Make a starting guess at the solutionoptions = optimoptions('fsolve','Display','iter'); % Option to display output[x,fval] = fsolve(@myfun,x0,options) % Call solver