www.pudn.com > pinsanquxian.rar > za0.m, change:2004-09-04,size:960b


%求解Lame波反对称部分的基本模态Ao 
format long 
syms c;   %定义速度c为符号函数 
kh=0.4   %k为波数,h为总的板厚 
cd=5790;cs=3200; %cd为纵波波速,cs为横波波速 
y1=4*tanh(kh/2*(1-(c/cs)^2)^(1/2))*(1-(c/cd)^2)^(1/2)*(1-(c/cs)^2)^(1/2); 
y2=(2-(c/cs)^2)^2*tanh(kh/2*(1-(c/cd)^2)^(1/2)); 
c=[400;700]; 
eps=1e-12; 
xx=[]; 
for i=2:2 
    a=c(i-1);b=c(i); 
    c=(a+b)/2; 
    while (subs(y1-y2)~= 0) & ((b-a)>eps) 
        c=(a+b)/2; 
        fa=4*tanh(kh/2*(1-(a/cs)^2)^(1/2))*(1-(a/cd)^2)^(1/2)*(1-(a/cs)^2)^(1/2)-(2-(a/cs)^2)^2*tanh(kh/2*(1-(a/cd)^2)^(1/2)); 
        fb=4*tanh(kh/2*(1-(b/cs)^2)^(1/2))*(1-(b/cd)^2)^(1/2)*(1-(b/cs)^2)^(1/2)-(2-(b/cs)^2)^2*tanh(kh/2*(1-(b/cd)^2)^(1/2)); 
        fy=4*tanh(kh/2*(1-(c/cs)^2)^(1/2))*(1-(c/cd)^2)^(1/2)*(1-(c/cs)^2)^(1/2)-(2-(c/cs)^2)^2*tanh(kh/2*(1-(c/cd)^2)^(1/2)); 
        if fa*fy < 0 
            b=c; 
        else 
            a=c; 
        end 
    end 
    xx=[xx;c]; 
    xx=[xx;c] 
    m=subs(y1-y2) 
end