summaryrefslogtreecommitdiff
path: root/1457/CH4/EX4.7/4_7.sce
diff options
context:
space:
mode:
authorpriyanka2015-06-24 15:03:17 +0530
committerpriyanka2015-06-24 15:03:17 +0530
commitb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch)
treeab291cffc65280e58ac82470ba63fbcca7805165 /1457/CH4/EX4.7/4_7.sce
downloadScilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.gz
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.tar.bz2
Scilab-TBC-Uploads-b1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b.zip
initial commit / add all books
Diffstat (limited to '1457/CH4/EX4.7/4_7.sce')
-rwxr-xr-x1457/CH4/EX4.7/4_7.sce17
1 files changed, 17 insertions, 0 deletions
diff --git a/1457/CH4/EX4.7/4_7.sce b/1457/CH4/EX4.7/4_7.sce
new file mode 100755
index 000000000..ef3302f22
--- /dev/null
+++ b/1457/CH4/EX4.7/4_7.sce
@@ -0,0 +1,17 @@
+clc
+//Initialization of variables
+d=3 //in
+x1=0.5^2
+x2=0.75^2
+z=80 //ft
+z3=10 //ft
+//calculations
+disp("Using bernoullis theorem")
+v3=29.7 //fps
+Q=%pi /4 *(d/12)^2 *v3
+hls=5*(x1*v3)^2 /(2*32.2)
+hld=12*(x2*v3)^2 /(2*32.2)
+//results
+printf("Head loss in suction pipe = %.1f ft",hls)
+printf("\n Head loss in discharge pipe = %.1f ft",hld)
+printf("\n Flow rate = %.2f cfs",Q)