import math
# Variables
N = 900./60
x1 = 90.
D1 = 0.2
D2 = 0.4
n = 0.7
g = 9.81
u1 = math.pi*D1*N
u2 = 2*u1 # as D2 = 2D1
y1 = 20.
# Calculations
Vf1 = u1*math.tan(math.radians(y1))
Vr1 = Vf1/math.sin(math.radians(y1))
Vf2 = Vf1
Vr2 = Vr1
x = (Vr2*Vr2-Vf1*Vf1)**0.5
Vw2 = u2-x
B1 = 0.02
Q = math.pi*D1*B1*Vf1
H = Vw2*u2/g
w = 9810
P = (w*Q*Vw2*u2)/(g*1000)
inputpower = (w*Q*H)/(1000*n)
print "discharge through the pump %.4f litre/s \
\nheat developed %f m \
\npower in Kw at outlet %.3f \
\ninput power if overall efficiency is 70%% : %.4f kW" \
%(Q*1000,H,P,inputpower)
# note : rounding off error
# Variables
Hs = 2.
Hd = 20.
Hfs = 1.
Hfd = 5.
Q = 1./60
N = 1450./60
ds = 0.1
dd = ds
n = 0.75
g = 9.81
w = 9810.
# Calculations
a = 3.142*ds*ds/4
Vs = Q/a
Vd = Vs
Ht = Hs+Hd+Hfs+Hfd+(Vs*Vs/(2*g))+(Vd*Vd/(2*g))
Pi = (w*Q*Ht)/(n*1000)
Ns = ((N*(Q**0.5))/(Ht**0.75))*60
# Results
print "total head developed by the pump,power input to the pump,specific speed of pump in r.p.m",round(Ht,4),round(Pi,5),round(Ns,3)
import math
# Variables
d2 = 0.6
Q = 20./60
N = 1400./60
V1 = 2.8
g = 9.81
y2 = 30.
w = 9810.
Vf1 = V1
Vf2 = V1
# Calculations
u2 = 3.142*d2*N
x = Vf2/math.radians(math.tan(y2))
Vw2 = u2-x
Hm = Vw2*u2/g
P = (w*Q*Hm)/1000
# Results
print "head developed, pump power",round(Hm,4),round(P,4)
# Variables
N = 1450./60
N1 = 1650./60
H = 12.
P = 6.
# Calculations
H1 = H*((N1/N)**2)
P1 = P*((N1/N)**3)
# Results
print "head developed and power required if pump runs at 1650 r.p.m",round(H1,4),round(P1,4)
# Variables
Q = 0.03
Hs = 18.
d = 0.1
l = 90.
n = 0.8
w = 9810.
a = 3.142*d*d/4
f = 0.04
g = 9.81
# Calculations
Vd = Q/a
H1 = (4*f*l*Vd*Vd)/(d*2*g)+(Vd*Vd/(2*g))
Hm = Hs+H1
P = (w*Q*Hm)/(n*1000)
# Results
print "power required to drive the pump",round(P,3),"kW"
# Variables
Q = 0.04
Hm = 30.
n = 0.75
w = 9810.
# Calculations
p = w*Q*Hm/1000
P = p/n
# Results
print "output power of the pump,power required to drive the motor",p,P
# Variables
Q = 1.8/60
d = 0.1
n = 0.72
Hs = 20.
w = 9810.
Hl = 8.
# Calculations
Hm = Hs+Hl
p = (w*Hm*Q)/1000
P = p/n
print "water power required to the pump,power required to run the pump",p,P
import math
# Variables
d2 = 0.6
Q = 15./60
N = 1450./60
V1 = 2.6
g = 9.81
y2 = 30.
w = 9810.
Vf1 = V1
Vf2 = V1
# Calculations
u2 = math.pi*d2*N
x = Vf2/math.tan(math.radians(y2))
Vw2 = u2-x
Hm = Vw2*u2/g
P = (w*Q*Hm)/1000
# Results
print "head developed, pump power",round(Hm,4),round(P,4)
# Variables
Q = 0.05
p = 392.4*1000
n = 0.65
s = 0.8
w1 = 9810.
# Calculations
Hw = p/w1
Hoil = p/(w1*s)
Pw = (w1*Q*Hw)/(n*1000)
Poil = (w1*s*Q*Hoil)/(n*1000)
# Results
print "power in Kw to drive the pump with water and oil of s,p = 0.8",round(Poil,6),round(Pw,6)
import math
# Variables
Q = 0.118
N = 1450./60
Hm = 25.
d2 = 0.25
B2 = 0.05
n = 0.75
g = 9.81
# Calculations
u2 = math.pi*d2*N
Vf2 = Q/(math.pi*d2*B2)
Vw2 = g*Hm/(n*u2)
y2 = math.degrees(math.atan(Vf2/(u2-Vw2)))
# Results
print "vane angle in degree at the outer nperiphery of the impeller",round(y2,2)
# note : rounding off error
import math
# Variables
Hm = 14.5
N = 1000./60
y2 = 30.
d2 = 0.3
B2 = 0.05
g = 9.81
n = 0.95
# Calculations
u2 = math.pi*d2*N
Vw2 = g*Hm/(n*u2)
Vf2 = (u2-Vw2)*math.tan(math.radians(y2))
Q = math.pi*d2*B2*Vf2
# Results
print "discharge of pump in m3/sec if manometric efficiency if 95%% : %.3f litre/s"%(Q*1000)
import math
# Variables
d2 = 1.2
N = 200./60
Q = 1.88
Hm = 6.
y2 = 26.
g = 9.81
Vf2 = 2.5
d1 = 0.6
u2 = math.pi*d2*N
# Calculations
Vw2 = u2-(Vf2/math.tan(math.radians(y2)))
n = g*Hm/(Vw2*u2)
z1 = (math.pi*d2/60)**2
z2 = (math.pi*d1/60)**2
N1 = (Hm*2*g/(z1-z2))**0.5
# Results
print "least speed to start pump : %.3f r.p.m \
\nmanometric efficiency : %.2f %%"%(N1,(n*100))
import math
# Variables
Q = 0.125
Hm = 25.
N = 660./60
d2 = 0.6
d1 = d2*0.5
a = 0.06
y2 = 45.
g = 9.81
# Calculations
u2 = math.pi*d2*N
u1 = u2*0.5
Vf2 = Q/a
Vw2 = u2-(Vf2/math.tan(math.radians(y2)))
n = g*Hm/(Vw2*u2)
Vf1 = Q/(a)
y1 = math.degrees(math.atan(Vf1/u1))
# Results
print "manometric efficiency %.2f %% \
\nvane angle at inlet : %.2f degrees"%((n*100),y1)
# note : rounding off error.
import math
# Variables
n = 3.
d2 = 0.4
B2 = 0.02
y2 = 45.
da = 0.1
nm = 0.9
w = 9810.
no = 0.8
g = 9.81
N = 1000./60
Q = 0.05
# Calculations
Vf2 = Q/(math.pi*d2*nm*B2)
u2 = math.pi*d2*N
Vw2 = u2-(Vf2/math.tan(math.radians(y2)))
Hm = nm*Vw2*u2/g
Ht = n*Hm
P = w*Q*Ht/1000
Ps = P/no
# Results
print "shaft power in Kw %.2f"%Ps
# Variables
n = 6.
Q = 0.12
p = 5003.1*1000
N = 1450./60
w = 9810.
# Calculations
Ht = p/w
h = Ht/n
Ns = (N*(Q**0.5)/(h**0.75))*60
# Results
print "radial impeller would be selected",round(Ns,2)
import math
# Variables
sg = 1.08
w = 9810.*sg
Q = 0.3
H = 12.
no = 0.75
# Calculations
P = w*Q*H/(no*1000)
p = w*H
# Results
print "power in Kw required by the pump,pressure developed by the pump in N/m2",round(P,3),p
# Variables
d1 = 0.3
N1 = 2000./60
Q1 = 3.
Hm1 = 30.
Q2 = 5.
N2 = 1500./60
Ht = 200.
# Calculations
Hm2 = ((N2/N1)*((Q2/Q1)**0.5)*(Hm1**0.75))**1.3333
n = Ht/Hm2
d2 = ((Hm2/Hm1)**0.5)*(N1/N2)*d1
# Results
print "number of stages and diameter of each impeller in cm",round(n,3),round((d2*100),2)