summaryrefslogtreecommitdiff
path: root/2126/CH3/EX3.1
diff options
context:
space:
mode:
authorpriyanka2015-06-24 15:03:17 +0530
committerpriyanka2015-06-24 15:03:17 +0530
commitb1f5c3f8d6671b4331cef1dcebdf63b7a43a3a2b (patch)
treeab291cffc65280e58ac82470ba63fbcca7805165 /2126/CH3/EX3.1
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 '2126/CH3/EX3.1')
-rwxr-xr-x2126/CH3/EX3.1/1.sce17
1 files changed, 17 insertions, 0 deletions
diff --git a/2126/CH3/EX3.1/1.sce b/2126/CH3/EX3.1/1.sce
new file mode 100755
index 000000000..20f703bec
--- /dev/null
+++ b/2126/CH3/EX3.1/1.sce
@@ -0,0 +1,17 @@
+clc
+clear
+
+//input data
+M1=0.25 //Mach number at entrance
+M2=1 //Mach number at exit
+D=0.04 //inner tude diameter in m
+f=0.002 //frictional factor
+
+//calculation
+X1=8.537 //frictional constant fanno parameter at entry from gas tables @M1=0.25
+X2=0 //frictional constant fanno parameter at exit from gas tables @M2=1
+X=X1-X2 //overall frictional constant fanno parameter i.e. (4*f*L)/D
+L=(X*D)/(4*f) //Length of the pipe in m
+
+//output
+printf('(A)Length of the pipe is %3.3f m',L)