summaryrefslogtreecommitdiff
path: root/587/CH8/EX8.4/example8_4.sce
diff options
context:
space:
mode:
authorprashantsinalkar2017-10-10 12:38:01 +0530
committerprashantsinalkar2017-10-10 12:38:01 +0530
commitf35ea80659b6a49d1bb2ce1d7d002583f3f40947 (patch)
treeeb72842d800ac1233e9d890e020eac5fd41b0b1b /587/CH8/EX8.4/example8_4.sce
parent7f60ea012dd2524dae921a2a35adbf7ef21f2bb6 (diff)
downloadScilab-TBC-Uploads-f35ea80659b6a49d1bb2ce1d7d002583f3f40947.tar.gz
Scilab-TBC-Uploads-f35ea80659b6a49d1bb2ce1d7d002583f3f40947.tar.bz2
Scilab-TBC-Uploads-f35ea80659b6a49d1bb2ce1d7d002583f3f40947.zip
updated the code
Diffstat (limited to '587/CH8/EX8.4/example8_4.sce')
-rwxr-xr-x587/CH8/EX8.4/example8_4.sce56
1 files changed, 30 insertions, 26 deletions
diff --git a/587/CH8/EX8.4/example8_4.sce b/587/CH8/EX8.4/example8_4.sce
index 9c91fedd1..aef022e04 100755
--- a/587/CH8/EX8.4/example8_4.sce
+++ b/587/CH8/EX8.4/example8_4.sce
@@ -1,26 +1,30 @@
-clear;
-clc;
-
-//Example8.4[Pressure Drop in a Water tube]
-Tw=15;//temp of water while entering[degree Celcius]
-rho=999.1;//[kg/m^3]
-mu=1.138*10^(-3);//Viscosity[kg/m.s]
-id=0.05;//Internal diameter[m]
-V=5.5*10^(-3);//Flow rate[m^3/s]
-l=60;//length of tube[m]
-e=0.002*10^(-3);//[m]
-//Solution:-
-v=V/(%pi*(id^2)*(1/4));//Mean Velocity[m/s]
-Re=rho*v*id/mu;
-disp(Re,"Reynolds Number is")
-//Flow is turbulent
-r=e/id;//Relative roughness of the tube
-function[Func]=fric(fac)
- Func(1)=(1/(fac(1)^(1/2)))+(2*log((0.00004/3.7)+(2.51/(122900*fac(1)^(1/2)))));
- deff('[Func]=fric(fac)',['fric_1=(1/(fac(1)^(1/2)))+(2*log((0.00004/3.7)+(2.51/(122900*fac(1)^(1/2)))))'])
-endfunction
-disp(xs,"Friction Factor is")
-del_P=xs*l*rho*(v^2)/(2*id);//[kPa]
-disp("Pa",del_P,"The pressure drop is")
-W_pump=V*del_P;//[W]
-disp("W",W_pump,"The required poer input tp overcome the frictional losses in the tube is") \ No newline at end of file
+clear;
+ clc;
+
+ //Example8.4[Pressure Drop in a Water tube]
+ Tw=15;//temp of water while entering[degree Celcius]
+ rho=999.1;//[kg/m^3]
+ mu=1.138*10^(-3);//Viscosity[kg/m.s]
+ id=0.05;//Internal diameter[m]
+ V=5.5*10^(-3);//Flow rate[m^3/s]
+ l=60;//length of tube[m]
+ e=0.002*10^(-3);//[m]
+ //Solution:-
+ v=V/(%pi*(id^2)*(1/4));//Mean Velocity[m/s]
+ Re=rho*v*id/mu;
+ disp(Re,"Reynolds Number is")
+ //Flow is turbulent
+ r=e/id;//Relative roughness of the tube
+ function[Func]=fric(fac)
+ Func(1)=(1/(fac(1)^(1/2)))+(2*log((0.00004/3.7)+(2.51/(122900*fac(1)^(1/2)))));
+ deff('[Func]=fric(fac)',['fric_1=(1/(fac(1)^(1/2)))+(2*log((0.00004/3.7)+(2.51/(122900*fac(1)^(1/2)))))'])
+ endfunction
+
+ xa = 3.99*10^-3;
+ xs = fric(xa);)
+
+ disp(xs,"Friction Factor is")
+ del_P=xs*l*rho*(v^2)/(2*id);//[kPa]
+ disp("Pa",del_P,"The pressure drop is")
+ W_pump=V*del_P;//[W]
+ disp("W",W_pump,"The required poer input tp overcome the frictional losses in the tube is") \ No newline at end of file