声振论坛

 找回密码
 我要加入

QQ登录

只需一步,快速开始

查看: 1229|回复: 3

[转子动力学] 程序上的问题(求助)

[复制链接]
发表于 2009-3-15 21:17 | 显示全部楼层 |阅读模式

马上注册,结交更多好友,享用更多功能,让你轻松玩转社区。

您需要 登录 才可以下载或查看,没有账号?我要加入

x
syms s
mb=[3577,0;0,3577];
cb=[140 1.24;1.24,140]*(10e4);
kb=[270.48 -1.28;1.28 270.48]*(10e8);
k=[196 1.12;1.12 196]*(10e7);
c=[14.5 2.31;2.31 14.5]*(10e5);
a=k+s*c;
b=a+kb+s*cb+s^2*mb;
c=kb+s*cb+s^2*mb;
d=a/b*c;
K=vpa(d,10);
m1=2.94e3;
m27=2.94e3;
mi=5.88e3;
li=0.4;
EJ=1.3514e11;
L=[li,li,li,li,li,li,li,li,li,li,li,li,li,li,li,li,li,li,li,li,li,li,li,li,li,li,0];
M=[m1,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,mi,m27];
KXX=[K(1,1),0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,K(1,1)];
KXY=[K(1,2),0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,K(1,2)];
KYX=[K(2,1),0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,K(2,1)];
KYY=[K(2,2),0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,K(2,2)];
for i=1:27
    u11=[1,L(i),0,0;
        0,1,0,0;
        0,0,1,L(i);
        0,0,0,1];
    u21=[L(i)^2/(2*EJ),L(i)^3/(6*EJ),0,0;
        L(i)/(2*EJ),L(i)^2/(2*EJ),0,0;
        0,0,L(i)^2/(2*EJ),L(i)^3/(6*EJ);
        0,0,L(i)/(2*EJ),L(i)^2/(2*EJ)];
    u12=[-L(i)*(M(i)*s^2+KXX(i)),0,-L(i)*KXY(i),0;
        -(M(i)*s^2+KXX(i)),0,-KXY(i),0;
        -L(i)*KYX(i),0,-L(i)*(M(i)*s^2+KYY(i)),0;
        -KYX(i),0,-(M(i)*s^2+KYY(i)),0];
    u22=[1-(M(i)*s^2+KXX(i))*L(i)^3/(6*EJ),L(i),-KXY(i)*L(i)^3/(6*EJ),0;
        -(M(i)*s^2+KXX(i))*L(i)^2/(2*EJ),1,-KXY(i)*L(i)^2/(2*EJ),0;
        -KYX(i)*L(i)^3/(6*EJ),0,1-(M(i)*s^2+KYY(i))*L(i)^3/(6*EJ),L(i);
        -KYX(i)*L(i)^2/(2*EJ),0,-(M(i)*s^2+KYY(i))*L(i)^2/(2*EJ),1];
    T(:,:,i)=[u11 u12;u21 u22];
end
H=T(:,:,1);
for n=2:27;
    H=T(:,:,n)*H;
end
H
请问下这个程序为什么错误?
回复
分享到:

使用道具 举报

发表于 2009-3-16 09:33 | 显示全部楼层
建议给出出错提示
 楼主| 发表于 2009-3-16 12:07 | 显示全部楼层
H=T(:,:,n)*H;
出错就在这个语句
发表于 2009-3-19 11:50 | 显示全部楼层
H=T(:,:,n).*H;
您需要登录后才可以回帖 登录 | 我要加入

本版积分规则

QQ|小黑屋|Archiver|手机版|联系我们|声振论坛

GMT+8, 2024-11-30 02:40 , Processed in 0.090144 second(s), 18 queries , Gzip On.

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表