www.pudn.com > pinsanquxian.rar > lame.m, change:2004-07-14,size:967b


format long 
syms p; 
kh=3.0; 
cd=6100;cs=3300;m=cs/cd; 
y1=-4*tan(kh/2*((p^2+1)*m^2-1)^(1/2))*p*((p^2+1)*m^2-1)^(1/2); 
y2=(p^2-1)^2*tan(kh/2*p); 
y=y1-y2; 
ezplot(y1,[0,6]); 
grid on 
hold on 
ezplot(y2,[0.,6]); 
zoom on 
pause; 
[xx,yy]=ginput(3);  %从图上获取曲线零点所对应的p值点 
c1=sqrt(xx(1)^2+1)  %求出所对应的c/cs值 
c2=sqrt(xx(2)^2+1) 
c3=sqrt(xx(3)^2+1) 
[x(1),fval,exitflag]=fzero(inline(y1-y2),xx(1),[]); 
[x(2),fval,exitflag]=fzero(inline(y1-y2),xx(2),[]); 
[x(3),fval,exitflag]=fzero(inline(y1-y2),xx(3),[]); 
c11=sqrt(x(1)^2+1) 
c22=sqrt(x(2)^2+1) 
c33=sqrt(x(3)^2+1) 
%检验结果 
%p=sqrt(结果^2-1) 
%kh=3.0; 
%cd=6100;cs=3300;m=cs/cd; 
%y1=-4*tan(kh/2*((p^2+1)*m^2-1)^(1/2))*p*((p^2+1)*m^2-1)^(1/2); 
%y2=(p^2-1)^2*tan(kh/2*p); 
%y=y1-y2 
%做频散曲线图 
%x=input('jieguo0=') 
%x=a(:,1);y0=a(:,2);y1=a(:,3);y2=a(:,4);y3=a(:,5);y4=a(:,6);y5=a(:,7);plot(x,y0); hold on 
%plot(x,y1,'r');plot(x,y2,'r');plot(x,y3,'r');plot(x,y4,'r');plot(x,y5,'r');grid on