Beruflich Dokumente
Kultur Dokumente
26
The displacements amplitude of each two system above has been plotted using MATLAB scrtipt bellow
and as its obvious in figure the amplitude of displacement for dystem with low frequency is higher than
high frequency system.
MATLAB Script for SDOF problem
clc
clear all
% sysyem 1 & system 2 are investigated
fn1 = 4.5 ;
fn2 = 0.2 ;
m =6500 ;
wn1 = 2*pi*fn1;
wn2 = 2*pi*fn2;
t= 0:0.1:30;
wn = wn2;
x0 = 0.05;
v0 = -1;
A1 = v0/wn1;
A2 = v0/wn2;
B = x0;
k1 = m*(wn1)^2 ;
k2 = m*(wn2)^2 ;
x1 = A1*sin(wn1*t) + B*cos(wn1*t) ;
x2 = A2*sin(wn2*t) + B*cos(wn2*t) ;
subplot(2,1,1);
ylim([-1 , 1]);
plot(t,x1,'r')
grid on
title('high frequency system')
xlabel('time')
ylabel('displacement')
subplot(2,1,2);
ylim([-1 , 1]);
plot(t,x2,'k')
grid on
title('low frequency system')
xlabel('time')
ylabel('displacement')
Since each storey has to column the equivalent stiffness has to be calculated as bellow
12𝐸𝐼
𝐾 = 2( 3 )
ℎ
And it has to be considered that the first storey has the EI value equal to 2EI so we would have :
12 ∗ 4.5 ∗ 10^6
𝐾1 = 2( )
33
12 ∗ 4.5 ∗ 10^6
𝐾2 = 2( )
33
24 ∗ 4.5 ∗ 10^6
𝐾3 = 2( )
63
The above stiffness values and masses for each storey and modal damping ratio’s are all know so we can
set our equation to solve it :
Using the general equation
In order to clarify the formulation set up I have also added the MATRIX from which is actually what we
are dealing with in MATLAB:
In order to have everything available when ever we want on MATLAB program its better to initialy write
a script for input all initial values and term so the file input.m will do this step for us:
as the zeta values are modal damping ratios they woul represent the damping condition of the system
as critical , underdamed and overdamped .
eps= zeta;
eps=str2double(eps);
eps=eps/100;
a=eps*((2*omega(1)*omega(2)*omega(3))/(omega(1)+omega(2)+om
ega(3)));
b=eps*(2/(omega(1)+omega(2)+omega(3)));
Modamp=Vnorm'*(a*M+b*K)*Vnorm;
zeta=diag((1/2)*Modamp*inv(diag(omega)));
ko = K;
[b1,b2]=size(t);
x=zeros(n,b2);
r=zeros(n,b2);
a=m^(-1/2);
kt=a*ko*a;
[p,l]=eig(kt);
s=a*p;
si=inv(s);
r0=zeros(n,1);
rp0=zeros(n,1);
x0 = [0,0,0];
xp0 = [0,0,0];
r0=si*x0';
rp0=si*xp0';
w=sqrt(l);
wd=zeros(size(w));
for k=1:n
wd(k,k)=w(k,k)*sqrt(1-zeta(k)^2);
end
%Note that the same loop control variable can be used for
%every loop, so long as the loops are not nested within
%each other.
for k=1:n
ac(k)=sqrt(wd(k,k)^2*r0(k)^2+(rp0(k)+zeta(k)*w(k,k)*r0(k))^
2)/wd(k,k);
phi(k)=atan2(wd(k,k)*r0(k),(rp0(k)+zeta(k)*w(k,k)*r0(k)));
r(k,:)=ac(k)*exp(-zeta(k)*w(k,k)*t).*sin(wd(k,k)*t+phi(k));
end
x=s*r;
for k=1:n
plot(t,x(k,:))
o=num2str(k);
title(['Response x',o])
xlabel('Time, seconds')
ylabel('Displacement')
grid
figure(gcf)
pause
end
for k=1:n
fprintf('Natural frequency w%g=%g nn',k,w(k,k))
end
by running the code you may simply obtain all required parameters like natural modes and mode
shapes: