关于自由板频散曲线的matlab实现出错请教
我现在在做自由板频散曲线的matlab实现,我的程序如下:mui = 0.32;
c1 = 3130;
c2 = 6350;
h = 1.55;
syms w phase
k = w/phase
alpha = abs(sqrt( w^2/(c1^2) - k^2 ))
belta = abs(sqrt( w^2/(c2^2) - k^2 ))
a11 = mui * (k^2 - belta^2) * exp(i * alpha * h)
a12 = mui * (k^2 - belta^2) * exp(-i * alpha * h)
a13 = 2 * mui * k * belta * exp(i * belta * h)
a14 = (-2) * mui * k * belta * exp(-i * belta * h)
a21 = (-2) * mui * k * s * exp(i * alpha * h)
a22 = 2 * mui * k * alpha * exp(-i * alpha * h)
a23 = mui * (k^2 - belta^2) * exp(i * belta * h)
a24 = mui * (k^2 - belta^2) * exp(-i * belta * h)
a31 = mui * (k^2 - belta^2) * exp(-i * alpha * h)
a32 = mui * (k^2 - belta^2) * exp(i * alpha * h)
a33 = 2 * mui * k * belta * exp(-i * belta * h)
a34 = (-2) * mui * k * belta * exp(i * belta * h)
a41 = (-2) * mui * k * alpha * exp(-i * alpha * h)
a42 = 2 * mui * k * alpha * exp(i * alpha * h)
a43 = mui * (k^2 - belta^2) * exp(-i * belta * h)
a44 = mui * (k^2 - belta^2) * exp(i * belta * h)
A = [ a11,a12,a13,a14;a21,a22,a23,a24;a31,a32,a33,a34;a41,a42,a43,a44 ];
disperse = det(A)
a = 50000;
b = 10;
w = 0:1000:a
phase = 0:0.1:b
for j = 1:length(w)
for kk = 2;length(phase)
m = w(j) + eps
n = phase(o - 1) + eps
p = phase(o) + eps
q = phase(o+1) + eps
disperse(m,n)
disperse(m,p)
disperse(m,q)
if ( disperse(m,n) > disperse(m,p) & disperse(m,q) > disperse(m,p) )
min = fimibnd( dieperse,n,q );
elseif( disperse(w(j-1),phase(kk)) > disperse(w(j),phase(k)) & disperse(w(j+1),phase(kk)) > disperse(w(j),phase(kk)) )
min = fimibnd(dieperse,w(j-1),w(j+1));
end
end
axis();
plot(w,phase);
可是程序每次运行到disperse(m,n) 语句就出错,哪位能不能帮忙看看问题出在哪里?谢谢!
我的QQ是:645744547,欢迎各位不吝赐教!
[ 本帖最后由 eight 于 2007-11-25 16:51 编辑 ]
回复 #1 xiao肖 的帖子
a21 = (-2) * mui * k * s * exp(i * alpha * h)中的s没有定义 为什么 屏蔽,我还想看看你做的是 多模式的?
页:
[1]