Effacer les filtres
Effacer les filtres

Calculate normal and shear stress of a beam where values of depth and width are under certain conditions

5 vues (au cours des 30 derniers jours)
close all
clear
clc
b = 1:200;
d = 1:200;
A = 2640;
F = 300e3;
d_max = 125;
b_min = 20;
NL = length(b);
sigma_max = zeros(1,NL);
tau_max = zeros(1,NL);
for i = 1
if (b(i)>=d(i)) && (d(i)<=d_max) && (b(i)>=b_min) && (b(i)*d(i)==A)
My = F*(b(i)/2);
Iyy = (b(i)*d(i)^3)/12;
sigma_max(i) = (My*Iyy)*(d(i)/2);
Qy = (b(i)*d(i)^2)/8;
tau_max(i) = (Vz/(Iyy*b(i)))*Qy;
end
end

Réponse acceptée

VBBV
VBBV le 31 Mar 2023
Modifié(e) : VBBV le 31 Mar 2023
close all
clear
clc
b = 1:200;
d = 1:200;
A = 2640;
F = 300e3;
d_max = 125;
b_min = 20;
NL = length(b);
sigma_max = zeros(1,NL);
tau_max = zeros(1,NL);
for i = 1:NL
if ((b(i)>=d(i)) | (d(i)<=d_max)) & ((b(i)>=b_min) | (b(i)*d(i)==A))
My(i) = F*(b(i)/2);
Iyy(i) = (b(i)*d(i)^3)/12;
sigma_max(i) = (My(i)/Iyy(i))*(d(i)/2);
Qy(i) = (d(i)*b(i)^2)/6;
tau_max(i) = (My(i)/Iyy(i))*(d(i)/2)*Qy(i);
end
end
% normal stress
figure
bar(b,sigma_max)
xlim([min(b) max(b)])
%shear stress
figure
bar(b,tau_max)
xlim([min(b) max(b)])
  1 commentaire
Zara
Zara le 4 Avr 2023
How can I get the values for sigma_max and tau_max to be saved in the arrays I created to allow for further calculations in the future?

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

En savoir plus sur Stress and Strain dans Help Center et File Exchange

Community Treasure Hunt

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

Start Hunting!

Translated by