From 7f60ea012dd2524dae921a2a35adbf7ef21f2bb6 Mon Sep 17 00:00:00 2001 From: prashantsinalkar Date: Tue, 10 Oct 2017 12:27:19 +0530 Subject: initial commit / add all books --- 3785/CH9/EX9.7/Ex9_7.sce | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 3785/CH9/EX9.7/Ex9_7.sce (limited to '3785/CH9/EX9.7/Ex9_7.sce') diff --git a/3785/CH9/EX9.7/Ex9_7.sce b/3785/CH9/EX9.7/Ex9_7.sce new file mode 100644 index 000000000..b9a0cb27b --- /dev/null +++ b/3785/CH9/EX9.7/Ex9_7.sce @@ -0,0 +1,29 @@ +// Example 9_7 +clc;funcprot(0); +// Given data +h=100; +Q=10; +n_t=.85; +D=1.5; +L=300; +delta_t=93.99; +epsilon=1*10^-4; +nu=1.0*10^-6;// The kinematic viscosity in m/s^2 +rho=1*10^3;// The density of water in kg/m^3 +g=9.81;// The acceleration due to gravity in m/s^2 + +// Calculation +V=(4*Q)/(%pi*D^2);// m/s +Re_D=(V*D)/nu;// Reynolds number +function[X]=frictionfactor(y) + X(1)=-(2.0*log10(((epsilon/D)/3.7)+(2.51/(Re_D*sqrt(y(1))))))-(1/sqrt(y(1))); +endfunction +// Guessing a value of f=1*10^-2; +y=[1*10^-2]; +f=fsolve(y,frictionfactor); +K_f=f*((L)/D);// The head loss coefficient +SigmaK=3.681; +deltah_1=SigmaK*((V^2)/(2*g));// The head loss in m +P=n_t*(rho*Q)*g*deltah_1; +P=P/10^3; +printf("\nThe head loss in the piping,deltah_1=%1.3f m \nThe power produced by the turbine,P=%3.0f kW",deltah_1,P); -- cgit