📄 test.m
字号:
% 输入转动惯量(x向、y向、二向混合、翘曲、x向翘曲、y向翘曲)
Ix=input('Please input the x-direction of inertia-moment of the section: ');
Iy=input('Please input the y-direction of inertia-moment of the section: ');
Ixy=input('Please input the xy-direction of inertia-moment of the section: ');
If=input('Please input the warp of inertia-moment of the section: ');
Ixf=input('Please input the x-direction warp of inertia-moment of the section: ');
Iyf=input('Please input the y-direction warp of inertia-moment of the section: ');
% 输入面积(截面、x向剪切、y向剪切、混合剪切、x向翘曲剪切、y向翘曲剪切、翘曲剪切)
A=input('Please input the area of the section: ');
Ax=input('Please input the x-direction of shear-area of the section: ');
Ay=input('Please input the y-direction of shear-area of the section: ');
Axy=input('Please input the mixed shear-area of the section: ');
Axr=input('Please input the x-direction warp of shear-moment of the section: ');
Ayr=input('Please input the y-direction warp of shear-moment of the section: ');
Ar=input('Please input the warp of shear-moment of the section: ');
% 输入x向静矩、y向静矩、弹性模量、剪切模量、扭转常数、密度、固有频率
Sx=input('Please input the x-direction of shear-moment of the section: ');
Sy=input('Please input the y-direction of shear-moment of the section: ');
E=input('Please input the elastic modulus of the material: ');
G=input('Please input the shear modulus of the material: ');
J=input('Please input the torsion-constant of the section: ');
rho=input('Please input the density of the material: ');
omega=input('Please input the inherence frequency of the construction: ');
% 计算各参数与AA矩阵
b2=rho*omega*omega*A;
b3=rho*omega*omega*Sy;
b4=rho*omega*omega*Sx;
b5=G*Ax;
b6=G*Axy;
b7=G*Axr;
b8=-G*Ax+rho*omega*omega*Iy;
b9=G*Axy-rho*omega*omega*Ixy;
b10=G*Axr-rho*omega*omega*Iyf;
b11=G*Ay;
b12=G*Ayr;
b13=-G*Ay+rho*omega*omega*Ixy;
b14=-G*Ayr+rho*omega*omega*Ixf;
b15=rho*omega*omega*If;
b16=G*Ar;
b17=-G*Ar+rho*omega*omega*If;
AA=[0 1 0 0 0 0 0 0 0 0 0 0 0 0;
b2/E/A 0 0 0 -b3/E/A 0 0 0 b4/E/A 0 0 0 0 0;
0 0 0 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;
0 0 0 0 0 0 1 0 0 0 0 0 0 0;
0 0 0 k6/G/Ay 0 0 0 k11/G/Ay 0 0 0 k12/G/Ay 0 0;
0 0 0 0 0 0 0 0 1 0 0 0 0 0;
0 k4/E/Ix 0 0 0 k9/E/Ix 0 0 0 k13/E/Ix 0 0 0 k14/E/Ix;
0 0 0 0 0 0 0 0 0 0 1 0 0 0;
0 0 0 k7/G/(J+Ar) 0 0 0 k12/G/(J+Ar) 0 0 0 k15/G/(J+Ar) 0 0;
0 0 0 0 0 0 0 0 0 0 0 0 1 0;
0 0 0 0 0 k10/E/If 0 0 0 k14/E/If 0 0 0 k16/E/If];
% 计算特征值与特征向量
[Z,lambda]=eig(AA,BB,'qz');
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -