TRBMFR Matlab
TRBMFR Matlab
clear; clear;
clc; clc;
% Material properties
E = 200e9; % Young's modulus in Pa
A = 16000e-6; % Cross-sectional area in m^2
I = 1186e-6; % Moment of inertia in m^4
% Geometry
L1 = 16; % Length of member 1 in m
L2 = 7; % Length of member 2 in m
% Load
w = 20e3; % Distributed load in N/m
% Local stiffness matrix for member 2 (horizontal beam with distributed load)
k2 = (E*I / L2^3) * [12 6*L2 -12 6*L2;
6*L2 4*L2^2 -6*L2 2*L2^2;
-12 -6*L2 12 -6*L2;
6*L2 2*L2^2 -6*L2 4*L2^2];
k2_transformed = T' * k2 * T;
% Calculate reactions
R = K * u - F;
% Display results
disp('Nodal displacements (in meters):');
disp(u);