How can I calculate base shear of a linear MDOF building ?
1 visualizzazione (ultimi 30 giorni)
Mostra commenti meno recenti
Hi,
I have running code for 3-degre of fredoom builidng model. I was just wondeering how to clacute the base shear of the model. A simple code is given below. Can you please help me with that ? Thanks for your consideration.
x0=[zeros(6,1)];
[y,t,x]=lsim(sys_s,u,t,x0);
0 Commenti
Risposta accettata
Manikanta Aditya
il 15 Mar 2025
To calculate the base shear of a linear Multi-Degree-of-Freedom (MDOF) building, you can check the following code:
clear all
clc
% Define mass, stiffness, and damping matrices
m1 = 3; m2 = 2; m3 = 1;
k1 = 2; k2 = 2; k3 = 2;
c1 = 1; c2 = 1; c3 = 1;
M = [m1 0 0; 0 m2 0; 0 0 m3];
K = [k1+k2 -k2 0; -k2 k2+k3 -k3; 0 -k3 k3];
C = [c1+c2 -c2 0; -c2 c2+c3 -c3; 0 -c3 c3];
% State space model matrices
F = [-m1 -m2 -m3]';
inv_M = inv(M);
A = [zeros(3,3) eye(3); -inv_M*K -inv_M*C];
B = [zeros(3,1); inv_M*F];
Cc = eye(6);
D = zeros(6,1);
sys_s = ss(A,B,Cc,D);
% Define input motion
acc = [1; 2; 3; 4; 5];
u = acc;
dt = 0.01;
t = (0:length(acc)-1)*dt;
x0 = zeros(6,1);
[y,t,x] = lsim(sys_s,u,t,x0);
% Calculate base shear
base_shear = sum(M * x(:, 1:3)', 2);
% Display base shear
disp('Base Shear:');
disp(base_shear);
This code calculates the base shear by summing the contributions of the mass matrix and the displacements at each degree of freedom. You can adjust the input motion and other parameters as needed for your specific analysis.
Hope this helps.
Più risposte (0)
Vedere anche
Categorie
Scopri di più su Stress and Strain in Help Center e File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!