summaryrefslogtreecommitdiff
path: root/764/CH4/EX4.8.b/solution4_8.sce
diff options
context:
space:
mode:
Diffstat (limited to '764/CH4/EX4.8.b/solution4_8.sce')
-rwxr-xr-x764/CH4/EX4.8.b/solution4_8.sce36
1 files changed, 36 insertions, 0 deletions
diff --git a/764/CH4/EX4.8.b/solution4_8.sce b/764/CH4/EX4.8.b/solution4_8.sce
new file mode 100755
index 000000000..72db15254
--- /dev/null
+++ b/764/CH4/EX4.8.b/solution4_8.sce
@@ -0,0 +1,36 @@
+
+//Obtain path of solution file
+path = get_absolute_file_path('solution4_8.sce')
+//Obtain path of data file
+datapath = path + filesep() + 'data4_8.sci'
+//Clear all
+clc
+//Execute the data file
+exec(datapath)
+//Calculate the permissible tensile stress for the link sigmat (N/mm2)
+sigmat = Sut/fs
+//Assume the value of t to be 1mm
+t = 1
+//Calculate the direct tensile stress D (N/mm2)
+D = (P * 1000)/(t * (ratio * t))
+//Calculate the value of y (mm)
+y = t
+//Calculate the second moment of area I (mm4)
+I = (t * ((ratio * t)^3))/12
+//Calculate the dimensions of cross-section t
+a = (-1 * D) + ((-1 * P * 1000)/I)
+b = (-1 * P * 1000 * e)/I
+p = [sigmat 0 a b]
+r = roots(p)
+real_part = real(r)
+for i = 1:1:3
+ if(real_part(i)>0)
+ t = real_part(i)
+ break
+ end
+end
+//Print results
+printf('\nValue of t = %f mm\n',t)
+printf('\nArea of cross-section = (%f x %f) mm2\n',t,(ratio * t))
+
+