From b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b Mon Sep 17 00:00:00 2001 From: priyanka Date: Wed, 24 Jun 2015 15:03:17 +0530 Subject: initial commit / add all books --- 764/CH7/EX7.2.b/solution7_2.sce | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100755 764/CH7/EX7.2.b/solution7_2.sce (limited to '764/CH7/EX7.2.b/solution7_2.sce') diff --git a/764/CH7/EX7.2.b/solution7_2.sce b/764/CH7/EX7.2.b/solution7_2.sce new file mode 100755 index 000000000..7079dc7c8 --- /dev/null +++ b/764/CH7/EX7.2.b/solution7_2.sce @@ -0,0 +1,30 @@ + +//Function to standardise the given bolt-size +function[v] = standard(w) + v = ceil(w) + rem = pmodulo(v,10) + if (rem ~= 0) then + v = v + (10 - rem) + end +endfunction + +//Obtain path of solution file +path = get_absolute_file_path('solution7_2.sce') +//Obtain path of data file +datapath = path + filesep() + 'data7_2.sci' +//Clear all +clc +//Execute the data file +exec(datapath) +//Calculate the yield shear strength Ssy (N/mm2) +Ssy = (50/100)*Syt +//Calculate the permissible shear stress tau (N/mm2) +tau = Ssy/fs +//Shear load acting on one bolt P (kN) +P = Pt/2 +//Calculate the diameter of the bolt shank d (mm) +d = ((4 * P * 1000)/(%pi * tau))^(1/2) +//Standardise the bolt size from Table 7.1 +d = standard(d) +//Print results +printf('\nThe standard size of the bolt is M%d\n',d) -- cgit