Matlab求方程的未知数?h=29.8149; b= 68.4982*0.5; x=123.5; hr=h/b; xr=x/b; A=1/((hr^2+xr^2)^0.5); B=hr/sqrt(1+xr^2); S1=(1/pi)*(atan(1/xr)-A*xr*atan(A)); S2=(1/pi)*(xr*A*atan(A)+(B/hr)*atan(B)); S=((S1)^2+(S2)^2)^0.5 输出是S=0.1010.现在我
来源:学生作业帮助网 编辑:六六作业网 时间:2024/12/23 04:22:56
Matlab求方程的未知数?h=29.8149; b= 68.4982*0.5; x=123.5; hr=h/b; xr=x/b; A=1/((hr^2+xr^2)^0.5); B=hr/sqrt(1+xr^2); S1=(1/pi)*(atan(1/xr)-A*xr*atan(A)); S2=(1/pi)*(xr*A*atan(A)+(B/hr)*atan(B)); S=((S1)^2+(S2)^2)^0.5 输出是S=0.1010.现在我
Matlab求方程的未知数?
h=29.8149; b= 68.4982*0.5; x=123.5; hr=h/b; xr=x/b; A=1/((hr^2+xr^2)^0.5); B=hr/sqrt(1+xr^2); S1=(1/pi)*(atan(1/xr)-A*xr*atan(A)); S2=(1/pi)*(xr*A*atan(A)+(B/hr)*atan(B)); S=((S1)^2+(S2)^2)^0.5 输出是S=0.1010.现在我想输入S=0.1010来求x的值,想得到123.5,该怎么求啊?抱歉我没财富值了
Matlab求方程的未知数?h=29.8149; b= 68.4982*0.5; x=123.5; hr=h/b; xr=x/b; A=1/((hr^2+xr^2)^0.5); B=hr/sqrt(1+xr^2); S1=(1/pi)*(atan(1/xr)-A*xr*atan(A)); S2=(1/pi)*(xr*A*atan(A)+(B/hr)*atan(B)); S=((S1)^2+(S2)^2)^0.5 输出是S=0.1010.现在我
输入下面4行命令即可.
>> h=29.8149; b=68.4982*0.5;
>> syms x
>> 123.5; hr=h/b; xr=x/b; A=1/((hr^2+xr^2)^0.5); B=hr/sqrt(1+xr^2); S1=(1/pi)*(atan(1/xr)-A*xr*atan(A)); S2=(1/pi)*(xr*A*atan(A)+(B/hr)*atan(B)); S=((S1)^2+(S2)^2)^0.5
>> fsolve(@(t) (subs(S,x,t)-.1010251),0)
利用的是matlab的非线性方程求解函数.