how to find numerical soloution
2 次查看(过去 30 天)
显示 更早的评论
Hi everyone; How can I find the numerical solution of the equation: dldk3=0 in order to get k2? dldk3 is obtained from following codes:
clear all
clc
syms k1 k2 k3 u1 u2
m1=100*10^-9;
m2=100*10^-9;
a=200;
b=1;
s1=0;
s2=0;
x=(k1+k2)/m1+(k2+k3)/m2;
y=(((k1+k2)/m1)^2+((k2+k3)/m2)^2+(2*k2^2-(k1+k3)*k2-2*k1*k3)/(m1*m2))^0.5;
omega1=(2^0.5/2)*(x+y)^0.5;
omega2=(2^0.5/2)*(x-y)^0.5;
delta=omega2-omega1;
eps=(k2)/(y*(m1*m2)^0.5);
L=eps+delta+u1*(a-(2^0.5/2)*(((x+y)^0.5)-((x-y)^0.5))+s1^2)+u2*(b-(k2/(y*(m1*m2)^0.5))+s2^2);
dldk1=jacobian(L,k1);
dldk2=jacobian(L,k2);
dldk3=jacobian(L,k3);
dldu1=jacobian(L,u1);
dldu2=jacobian(L,u2);
B=solve(dldk1,'u1');
u1=B;
dldk2=subs(dldk2);
dldk3=subs(dldk3);
C=solve(dldk2,'u2');
u2=C;
dldu1=subs(dldu1);
dldk3=subs(dldk3);
D=solve(dldu1,'k1');
k1=D(1,1);
dldu2=subs(dldu2);
dldk3=subs(dldk3);
E=solve(dldu2,'k3');
k3=E(1,1);
dldk3=subs(dldk3);
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Calculus 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!