In [2]:

```
#Input data
p1=40#Initial pressure of steam in bar
T1=500#Initial temperature of steam in degree C
m1=5500#Rate of steam in kg/h
p2=2#Pressure of steam after expansion in bar
n1=0.83#Isentropic efficiency
q=0.87#Quality
m2=2700#Mass flow rate in kg/h
p3=0.1#Pressure of steam after expansion in l.p turbine in bar
n2=0.78#Isentropic efficiency
#Calculations
h1=3445.3#Enthalpy in kJ/kg
s1=7.0901#Entropy in kJ/kg.K which is 1.5301+x2s*5.5970
x2s=(5.5600/5.5970)#dryness fraction
h2s=(504.7+(x2s*2201.9))#Enthalpy in kJ/kg
h2=h1-(n1*(h1-h2s))#Enthalpy in kJ/kg
h3=(504.7+(q*2201.9))#Enthalpy in kJ/kg
h4=((m2*h3+m1*h2)/(m1+m2))#Enthalpy in kJ/kg
x4=(2183.78/2201.9)#dryness fraction
s4=(1.5301+x4*5.5970)#Entropy in kJ/kg.K
x5s=0.8574#dryness fraction
h5s=(191.84+x5s*2392.5)#Enthalpy in kJ/kg
dh4h5=(n2*(h4-h5s))#Difference in enthalpy (h4-h5) in kJ/kg
h6=191.83#Enthalpy in kJ/kg
W1=((m1*(h1-h2))+((m1+m2)*dh4h5))/3600#Power output of the plant in kW
Q1=(m1*(h1-h6))/3600#Heat input in kW
n1=(W1/Q1)*100#Efficiency in percent
WT=(m1*(h1-h2))/3600#Power output without the geothermal heat supply in kW
Q2=(m1*(h1-h6))/3600#Heat input without the geothermal heat supply in kW
n2=(WT/Q2)*100#Efficiency of the cycle without the geothermal heat supply in percent
#Output
print "(a)Power output of the cycle is %3.1f kW \n Efficiency of the cycle is %3.1f percent \n\n (b)Without geothermal heat supply \n Power output of the cycle is %3.2f kW \n Efficiency of the cycle is %3.2f percent"%(W1,n1,WT,n2)
```

In [3]:

```
#Input data
p1=90#Initial pressure of steam in bar
T1=500#Initial temperature of steam in degree C
O=(500*1000)#Output in kW
T2=40#Condensation temperature in degree C
nhp=0.92#Efficiency of h.p turbine
nlp=0.9#Efficiency of l.p turbine
np=0.75#Isentropic efficiency of the pump
TTD=-1.6#Temperature in degree C
#Calculations
p2=(0.2*p1)#Optimum reheat pressure in bar
h1=3386.1#Enthalpy in kJ/kg
s1=6.6576#Entropy in kJ/kg.K
s2s=s1#Entropy in kJ/kg.K
h2s=2915#Enthalpy in kJ/kg
h3=3469.8#Enthalpy in kJ/kg
s3=7.4825#Entropy in kJ/kg.K
x4s=(s3-0.5725)/7.6845#Dryness fraction
h4s=(167.57+x4s*2406.7)#Enthalpy in kJ/kg
h5=167.57#Enthalpy in kJ/kg
h7=883.42#Enthalpy in kJ/kg
Wps=(0.001008*p1*10)#Workdone by the pump in kJ/kg
h6s=176.64#Enthalpy in kJ/kg
dh1h2=(nhp*(h1-h2s))#Difference in enthalpy (h1-h2) in kJ/kg
h2=h1-dh1h2#Enthalpy in kJ/kg
dh3h4=(nlp*(h3-h4s))#Difference in enthalpy (h3-h4) in kJ/kg
h4=h3-dh3h4#Enthalpy in kJ/kg
Wp=(Wps/np)#Workdone by the pump in kJ/kg
h6=(Wp+h5)#Enthalpy in kJ/kg
tsat=207.15#Saturation temperature at 18 bar in degree C
t9=(tsat-TTD)#Temperature in degree C
h9=875#Enthalpy in kJ/kg
m=((h9-h6)/(h2-h7))#Mass of steam in kg
WT=(dh1h2+(1-m)*dh3h4)#Workdone by the turbine in kJ/kg
Wnet=(WT-Wp)#Net workdone in kJ/kg
ws=(O/Wnet)#Mass flow rate of steam at turbine inlet in kg/s
Q1=((h1-h9)+(1-m)*(h3-h2))#Heat input in kJ/kg
n=(Wnet/Q1)*100#Efficiency of the cycle in percent
Wr=(Wnet/WT)#Work ratio
#Output
print "(a)Mass flow rate of steam at turbine inlet is %3.0f kg/s \n (b)The cycle efficiency is %3.2f percent \n (c)Work ratio is %3.3f"%(ws,n,Wr)
```

In [4]:

```
#Input data
p1=70#Pressure at which an ideal seam power plant operates in bar
T1=550#Temperature at which an ideal seam power plant operates in degrees C
p2=0.075#Pressure at which an ideal seam power plant operates in bar
#Calculations
TB=285.9#Saturation temperature at 70 bar in degree C
TC=40.3#Saturation temperature at 0.075 bar in degree C
Tr=(TB-TC)/(7+1)#Temperature rise per heater for maximum cycle efficiency in degree C
t1=(TB-Tr)#Temperature at heater 1 in degree C
P1=4.33#Pressure at heater 1 in MPa
t2=(t1-Tr)#Temperature at heater 2 in degree C
P2=2.5318#Pressure at heater 2 in MPa
t3=(t2-Tr)#Temperature at heater 3 in degree C
P3=1.367#Pressure at heater 3 in MPa
t4=(t3-Tr)#Temperature at heater 4 in degree C
P4=0.6714#Pressure at heater 4 in MPa
t5=(t4-Tr)#Temperature at heater 5 in degree C
P5=0.2906#Pressure at heater 5 in MPa
t6=(t5-Tr)#Temperature at heater 6 in degree C
P6=0.108#Pressure at heater 6 in MPa
t7=(t6-Tr)#Temperature at heater 7 in degree C
P7=32.65#Pressure at heater 7 in kPa
#Output
print "The optimum pressure and temperature at different heaters are: \n Heater 1: t1 = %3.1f degree C and p1 = %3.2f MPa\n Heater 2: t2 = %3.1f degree C and p2 = %3.4f MPa\n Heater 3: t3 = %3.1f degree C and p3 = %3.3f MPa\n Heater 4: t4 = %3.1f degree C and p4 = %3.4f MPa\n Heater 5: t5 = %3.1f degree C and p5 = %3.4f MPa\n Heater 6: t6 = %3.1f degree C and p6 = %3.3f MPa\n Heater 7: t7 = %3.1f degree C and p7 = %3.2f kPa"%(t1,P1,t2,P2,t3,P3,t4,P4,t5,P5,t6,P6,t7,P7)
```

In [5]:

```
#Input data
ng=0.97#Efficiency of electric generator
nt=0.95#Efficiency of turbine
nb=0.92#Efficiency of boiler
nc=0.42#Efficiency of cycle
no=0.33#Efficiency of overall plant
#Calculations
na=(no/(ng*nt*nb*nc))#Efficiency of auxiliaries
n=(1-na)*100#Percentage of total electricity generated which is consumed in running the auxiliaries
#Output
print "Percentage of total electricity generated which is consumed in running the auxiliaries is %3.2f percent"%(n)
```

In [6]:

```
#Input data
T1=140#Temperature with which feed water enters into economiser in degree C
T2=[25,250]#Temperature from air is preheated to in degree C
P1=60#Pressure with which steam leaves the drum in bar
x1=0.98#Dryness fraction
T3=450#Temperature with which steam leaves the superheater in degree C
cc=25.2#Calorific value of coal in MJ/kg
r=8.5#Rate of evaporation of steam per kg coal
wf=1#Mass of coal in kg
R=15#Air fuel ratio by mass
Cpa=1.005#Specific heat of air at constant pressure in kJ/kg.K
Cpw=4.2#Specific heat of water at constant pressure in kJ/kg.K
#Calculations
h1=(T1*Cpw)#Enthalpy in kJ/kg
hf=1213.35#Enthalpy in kJ/kg
h2=hf#Enthalpy in kJ/kg
hfg=1571#Enthalpy in kJ/kg
h4=3301.8#Enthalpy in kJ/kg
h3=(hf+x1*hfg)#Enthalpy in kJ/kg
n=((r*(h4-h1))/(wf*cc*1000))*100#Efficiency
he=(r*(h2-h1))/wf*10**-3#Heat transfer in the economiser in MJ/kg
hb=(r*(h3-h2))/wf*10**-3#Heat transfer in the boiler in MJ/kg
hs=(r*(h4-h3))/wf*10**-3#Heat transfer in the superheater in MJ/kg
ha=(R*Cpa*(T2[1]-T2[0]))/wf*10**-3#Heat transfer in the air preheater in MJ/kg
pe=((h2-h1)/(h4-h1))*100#Percentage of total heat absorbed in the economiser in percent
pb=((h3-h2)/(h4-h1))*100#Percentage of total heat absorbed in the boiler in percent
ps=((h4-h3)/(h4-h1))*100#Percentage of total heat absorbed in the superheater in percent
#Output
print "Efficiency of steam generator is %3.2f percent \n\n Heat transfer per kg fuel in \n (i)economiser is %3.4f MJ/kg \n (ii)boiler is %3.3f MJ/kg \n (iii)superheater is %3.3f MJ/kg \n (iv)air pre-heater is %3.3f MJ/kg \n\n Percentage of total heat absorption taking place in \n (i)economiser is %3.2f percent \n (ii)boiler is %3.2f percent \n (iii)superheater is %3.2f percent"%(n,he,hb,hs,ha,pe,pb,ps)
```

In [7]:

```
#Input data
p1=150#Pressure of inlet steam in bar
T1=550#Temperature of steam in degree C
p2=20#Pressure after expansion in bar
T2=500#Reheat temperature in degree C
pc=0.075#Condenser pressure in bar
php=50#Pressure of steam in h.p turbine in bar
pip=[10,5,3]#Pressure of steam in i.p turbines in bar
plp=1.5#Pressure of steam in l.p turbine in bar
m=300*1000#Steam flow rate in kg/h
#Calculations
h1=3448.6#Enthalpy in kJ/kg
h4=3467.6#Enthalpy in kJ/kg
s1=6.5119#Entropy in kJ/kg.K
s2=s1#Entropy in kJ/kg.K
s3=s1#Entropy in kJ/kg.K
s4=7.4317#Entropy in kJ/kg.K
s5=s4#Entropy in kJ/kg.K
s6=s5#Entropy in kJ/kg.K
s7=s6#Entropy in kJ/kg.K
s8=s7#Entropy in kJ/kg.K
s9=s8#Entropy in kJ/kg.K
t2=370#Temperature in degree C
t3=245#Temperature in degree C
t5=400#Temperature in degree C
t6=300#Temperature in degree C
t7=225#Temperature in degree C
t8=160#Temperature in degree C
h2=3112#Enthalpy in kJ/kg
h3=2890#Enthalpy in kJ/kg
h5=3250#Enthalpy in kJ/kg
h6=3050#Enthalpy in kJ/kg
h7=2930#Enthalpy in kJ/kg
h8=2790#Enthalpy in kJ/kg
x9=(s9-0.5764)/7.6751#Dryness fraction
h9=168.79+x9*2406##Enthalpy in kJ/kg
h10=168.79#Enthalpy in kJ/kg
h11=h10+0.001*pip[1]*100#Enthalpy in kJ/kg
h12=467.11#Enthalpy in kJ/kg
t14=111.37#Temperature in degree C
h14=467#Enthalpy in kJ/kg
h13=h12#Enthalpy in kJ/kg
h14=h13#Enthalpy in kJ/kg
h15=h14#Enthalpy in kJ/kg
h16=561.47#Enthalpy in kJ/kg
h17=h16#Enthalpy in kJ/kg
h18=640.23#Enthalpy in kJ/kg
h19=h18+0.001*(p1-pip[1])*100#Enthalpy in kJ/kg
h20=762.8#Enthalpy in kJ/kg
h21=h20#Enthalpy in kJ/kg
h22=1154.23#Enthalpy in kJ/kg
h23=h22#Enthalpy in kJ/kg
m1=((h23-h21)/(h2-h22))#Mass in kg
m2=((h21-h19)-(m1*(h22-h20)))/(h5-h20)#Mass in kg
m3=(((1-m1-m2)*(h18-h17))-((m1+m2)*(h20-h18)))/(h6-h18+h18-h17)#Mass in kg
m4=((1-m1-m2-m3)*(h17-h15))/(h7-h16)#Mass in kg
m5=(((1-m1-m2-m3-m4)*(h14-h11))-(m4*(h16-h12)))/(h8-h12+h14-h11)#Mass in kg
WT=(h1-h2)+(1-m1)*(h2-h3)+(1-m1)*(h4-h5)+(1-m1-m2)*(h5-h6)+(1-m1-m2-m3)*(h6-h7)+(1-m1-m2-m3-m4)*(h7-h8)+(1-m1-m2-m3-m4-m5)*(h8-h9)#Workdone by turbine in kJ/kg
Wp=(0.5+14.5+0.15)#Workdone in kJ/kg
Wnet=(WT-Wp)#Net workdone in kJ/kg
Q1=(h1-h23)+(1-m1)*(h4-h3)#Heat supplied in kJ/kg
ncy=(Wnet/Q1)*100#Cycle efficiency in percent
t23=264#Temperature in degree C
sr=(3600/Wnet)#Steam rate in kJ/kWh
hr=((Q1/Wnet)*3600)#Heat rate in kJ/kWh
P=((Wnet*m)/3600)/10**3#Power output in MW
#Output
print "(a) The cycle efficiency is %3.2f percent \n (b) The feedwater temperature is %d degree C \n (c) The steam rate is %3.2f kJ/kWh \n (d) The heat rate is %3.0f kJ/kWh \n (e) The quality of steam at turbine exhaust is %3.4f \n (f) The power output is %3.2f MW"%(ncy,t23,sr,hr,x9,P)
```

In [8]:

```
#Input data
m=10000#Mass flow rate of steam in kg/h
p=3#Pressure of steam in bar
P=1000#Power in kW
n=0.7#Internal efficiency of turbine
#Calculations
dh=(P*3600)/m#Change in enthalpy in kJ/kg
h2=2725.3#Enthalpy in kJ/kg from Fig. E2.7
h1=dh+h2#Enthalpy in kJ/kg
dh1h2s=dh/n#Change in enthalpy in kJ/kg
h2s=h1-dh1h2s#Enthalpy in kJ/kg
x2s=(h2s-561.47)/2163.8#Dryness fraction
s2s=1.6718+x2s*(6.999-1.6718)#Entropy in kJ/kg.K
s1=s2s#Entropy in kJ/kg.K
p1=37.3#Pressure in bar from Mollier diagram
t1=344#Temperature in degree C
#Output
print "The steam condition required at inlet of the turbine: \n Enthalpy is %3.1f kJ/kg \n Entropy is %3.4f kJ/kg.K \n Pressure is %3.1f bar \n Temperature is %d degree C"%(h1,s1,p1,t1)
```

In [9]:

```
from __future__ import division
#Input data
Pl=5.6#Power load in MW
Hl=1.163#Heat load in MW
p1=40#Pressure in bar
T1=500+273#Temperature in K
p2=0.06#Pressure in bar
p3=2#Pressure in bar
CV=25#Calorific value in MJ/kg
n=88#Boiler efficiency in percent
T=6#Temperature rise in degree C
#Calculations
h1=3445.3#Enthalpy in kJ/kg
s1=7.0901#Entropy in kJ/kg.K
s2=s1#Entropy in kJ/kg.K
s3=s1#Entropy in kJ/kg.K
x2=(s2-1.5301)/5.5970#Dryness fraction
h2=2706.7#Enthalpy in kJ/kg
h26=2201.9#Difference in enthalpy in kJ/kg
w=(Hl*10**3)/h26#Rate of steam extraction in kg/h
x3=(s1-0.52)/7.815#Dryness fraction
h3=(149.79+x3*2416)#Enthalpy in kJ/kg
h4=149.79#Enthalpy in kJ/kg
ws=((Pl*10**3+(w*(h2-h3)))/((h1-h2)+(h2-h3)))#Steam generation capacity in kg/s
ws1=(ws*3600)/1000#Steam generation capacity in t/h
h7=(504.7+(1.061*10**-3*(p1-p3)*100))#Enthalpy in kJ/kg
h5=(149.79+(1.006*100*p1*10**-3))#Enthalpy in kJ/kg
Q1=(((ws-w)*(h1-h5))+(w*(h1-h7)))#Heat input in kW
wf=((Q1/1000)/((n/100)*CV))*(3600/1000)#Fuel burning rate in t/h
Q2=((ws-w)*(h3-h4))#Heat rejected to the condensor in kW
wc=(Q2/(4.187*T))/1000#Rate of flow of cooling water in m**3/s
#Output
print "(a) the steam generation capacity of the bolier is %3.2f t/h \n (b) the heat input to the boiler is %3.1f kW \n (c) the fuel burning rate of the bolier is %3.3f t/h \n (d) the heat rejected to the condensor is %3.0f kW \n (e) the rate of flow of cooling water in the condensor is %3.3f m**3/s"%(ws1,Q1,wf,Q2,wc)
```

In [10]:

```
#Input data
m=21000#Steam rate in kg/h
p1=17#Pressure in bar
T1=230+273#Temperature in K
P=132.56#Power in kW
x2=0.957#Dryness fraction
p2=3.5#Pressure in bar
Pl=1337.5#Power in l.p turbine in kW
p3=0.3#Pressure in bar
x3=0.912#Dryness fraction
#Calculations
h1=2869.7#Enthalpy in kJ/kg
s1=6.5408#Entropy in kJ/kg.K
h2=(870.44+x2*1924.7)#Enthalpy in kJ/kg
h3=h2#Enthalpy in kJ/kg
h56=(Pl*3600)/m#Difference in Enthalpy in kJ/kg
h6=(289.23+x3*2336.1)#Enthalpy in kJ/kg
h5=2649.04#Enthalpy in kJ/kg
s4s=s1#Entropy in kJ/kg.K
x4s=(s4s-1.7275)/5.2130#Dryness fraction
h4s=584.33+x4s*2148.1#Enthalpy in kJ/kg
w=(P/(h1-h2))#Flow rate in kg/s
ws=(m/3600)#Steam flow rate in kg/s
h4=((ws*h5)-(w*h3))/(ws-w)#Enthalpy in kJ/kg
x4=(h4-584.33)/2148.1#Dryness fraction
W=(ws-w)*(h1-h4)#Power developed by h.p turbine in kW
n=((h1-h4)/(h1-h4s))*100#Isentropic efficiency in percent
#Output
print "(a) the steam quality at the exhaust of the h.p turbine is %3.3f \n (b) the power developed by the h.p turbine is %3.2f kW \n (c) the isentropic efficiency of the h.p turbine is %3.2f percent"%(x4,W,n)
```