当前位置: > 用matlab解一个二元方程组,会的进,得到解再回答...
题目
用matlab解一个二元方程组,会的进,得到解再回答
tan(4*3.14*20000*0.03)+2*3.14*20000/k1*tan(k1*x)=0
k1=sqrt(4*3.14^2*20000^2*7840/2.1e11-log(2)*log(2)/x^2)

提问时间:2021-03-21

答案
clear,clc
format long
f=@(x)[tan(4*3.14*20000*0.03)+2*3.14*20000/x(1)*tan(x(1)*x(2));
sqrt(4*3.14^2*20000^2*7840/2.1e11-log(2)*log(2)/x(2)^2)-x(1)];
[s,v]=fsolve(f,[24;0.1])
Equation solved.
fsolve completed because the vector of function values is near zero
as measured by the default value of the function tolerance,and
the problem appears regular as measured by the gradient.
s =
23.698316600893644
0.132572516762675
v =
1.0e-011 *
0.327282645429250
0
所以就是k1=23.698316600893644,x=0.132572516762675
换用不同的初值会有不同的结果
或者直接用solve
clear,clc
s = solve('tan(4*3.14*20000*0.03)+2*3.14*20000/k1*tan(k1*x)=0',...'k1=sqrt(4*3.14^2*20000^2*7840/2.1e11-log(2)*log(2)/x^2)');
disp('k1='); disp(s.k1); disp('x='); disp(s.x);
举一反三
已知函数f(x)=x,g(x)=alnx,a∈R.若曲线y=f(x)与曲线y=g(x)相交,且在交点处有相同的切线,求a的值和该切线方程.
我想写一篇关于奥巴马的演讲的文章,写哪一篇好呢?为什么好
奥巴马演讲不用看稿子.为什么中国领导演讲要看?
想找英语初三上学期的首字母填空练习……
英语翻译
版权所有 CopyRight © 2012-2019 超级试练试题库 All Rights Reserved.