blob: e6ccfe2b552fc130f7d84120b0b36f4937ebbea4 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
clear all; clc;
disp("Scilab Code Ex 5.15 : ")
//Given:
l_cd = 0.5; //m
l_de = 1.5; //m
h =60/1000; //m
w = 40/1000; //m
t_h = 3/1000; //m
t_w = 5/1000; //m
T_c = 60; //Nm
T_d = 25; //Nm
G = 38*10^9; //N/m^2
T1 = T_c - T_d;
//Average Shear Stress:
area = (w-t_w)*(h-t_h);
shear_a = T1/(2*t_w*area*10^6);
shear_b = T1/(2*t_h*area*10^6);
//Angle of Twist:
ds_t = 2*(((w-t_w)/t_h)+((h-t_h)/t_w));
T = [T_c T1];
l = [l_cd l_de];
phi = 0;
for i = 1:2
phi = phi+ (T(i)*l(i)*ds_t)/(4*area^2*G);
end
//Display:
printf('\n\nThe average shear stress of the tube at A = %1.2f MPa',shear_a);
printf('\nThe average shear stress of the tube at B = %1.2f MPa',shear_b);
printf('\nThe angle of twist of end C = %1.6f rad',phi);
//----------------------------------------------------------------------------END-------------------------------------------------------------------------------
|