How can I calculate base shear of a linear MDOF building ?

9 ビュー (過去 30 日間)
Adnan
Adnan 2025 年 3 月 14 日
編集済み: Adnan 2025 年 3 月 15 日
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);

採用された回答

Manikanta Aditya
Manikanta Aditya 2025 年 3 月 15 日
Hi @Adnan,
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:');
Base Shear:
disp(base_shear);
-0.0095 -0.0063 -0.0032
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.
  1 件のコメント
Adnan
Adnan 2025 年 3 月 15 日

Thanks a lot for your help.

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeStress and Strain についてさらに検索

製品


リリース

R2024a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by