|| Rankine cycle Simulator ||
- AIM:
The Rankine cycle is the fundamental operating cycle of all power plants where an operating fluid is continuously evaporated and condensed. In this mechanism, fuel is used to produce heat within a boiler, converting water into steam which then expands through a turbine producing useful work. In this project, we are going to create a Rankine Cycle Simulator using MATLAB. This Simulator can be used to calculate the useful data from a set of inputs of the cycle & also plot the thermodynamic properties. This simulator can be used as a Tool that predicts the performance of the cycle under given conditions.
- GOVERNING EQUATIONS:
Rankine Cycle consists of four processes, these are -
1-2 is Isentropic Expansion in the Turbine
2-3 is Constant Pressure Heat Rejection by the Condensor
3-4 is Isentropic Compression in the Pump
4-1 is Constant Pressure Heat Addition by the Boiler
~ Work done by Turbine, `W_T` = `(H_1 - H_2)` KJ/kg. ~ Work input to Pump, `W_P` = `(H_4 - H_3)` = `v_3 *(P_1 - P_2)` KJ/kg.
~ NetWork Output, `W` = `( W_T - W_P)` KJ/kg. ~ Back Work Ratio, BWR = `(W_P/W_T)` KJ/kg.
~ Heat added to Boiler, `Q_1` = `(H_1 - H_4)` KJ/kg. ~ Heat Rejected by Condensor, `Q_2` = `(H_2 - H_3) ` KJ/kg.
~ Specific Steam Consumption, SSC = `(3600/ W_T)` kg/KW-h. ~ Thermal Efficiency, `eta` = `(W/Q_1*100)` %
Where `H_1, H_2, H_3, H_4` are Enthalpy values at State points 1,2,3,4 & `v_3` is Specific volume of water at State Point 3.
- After the 1st Process (1-2), i.e. inlet to Condensor, steam consists of water vapour and liquid water. This state of the Steam mixture can be identified by Dryness Fraction of Steam. This can be defined as - x = `(m_v/(m_v + m_l))`
Where `m_v` is the mass of water vapour in the steam mixture & `m_l` is the mass of liquid water in the steam mixture. Dryness Fraction of steam is needed to calculate Enthalpy for state point 2.
- As the 1-2 process is Isentropic so that Entropy values after and before this process remains the same. We can say that - `S_1 = S_2`.
And, `S_2` = `S_f + x*( S_g - S_f )` KJ/kg-k & `H_2` = `H_f + x*( H_g - H_f)` KJ/kg.
Where `S_f` & `S_g` are Enropy values at Saturate Liquid line and Saturated Vapour line respectively. `H_f` & `H_g` are Enthalpy values at Saturate Liquid line and Saturated Vapour line respectively.
- OBJECTIVES:
Any Thermodynamic Cycle can be studied based on the plots of thermodynamic properties, at last, we have to calculate some parameters that define the limit of the Cycle, i.e. Thermal Efficiency, Back work Ratio, etc. So the main objectives of this project are -
1) To calculate four State Points of the Rankine Cycle,
2) To plot the corresponding T-s and h-s plots for the given set of inputs,
3) To calculate Net Work Output, Back Work Ratio,
4) To write a command that displays all the results in the command window.
- EVALUATION OF PROGRAM:
In this program, we are going to extract useful data from a Function, called XSteam which has a link - https://drive.google.com/open?id=1RK_fvrOj38CIaQvmLT1S3daqHnxKCGU-
XSteam is a Matlab Function, from that we get the steam table data for water. Then we use this data to calculate the necessary state variables for this project.
clc
close all
clear all
printf(' \n \n RANKINE CYCLE SIMULATOR \n');
printf('\n 1-2 is Isentropic Expansion in the Turbine');
printf('\n 2-3 is Constant Pressure Heat Rejection by the Condensor');
printf('\n 3-4 is Isentropic Compression in the Pump');
printf('\n 4-1 is Constant Pressure Heat Addition by the Boiler\n\n');
P1 = input(' Enter the Pressure at the Turbine Inlet (in bar) :');
T1 = input(' Enter the Temperature at the Turbine Inlet (in Degree Celcius) : ');
P2 = input(' Enter the Pressure at the Condensor (in bar) : ');
printf(' _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ \n')
printf(' \n RESULTS\n');
% Data for State 1
T_sat_1 = XSteam('Tsat_p',P1); % To extract Saturation Temp for Turbine Inlet Pressure
if T1 > T_sat_1 % Condition for values of Enthalpy and Entropy for state 1
H1 = XSteam('h_pT',P1,T1); % Enthalpy Value for Super-Heat Region
S1 = XSteam('s_pT',P1,T1); % Entropy Value for Super-Heat Region
else H1 = XSteam('hV_p',P1) ; % Enthalpy at Saturation Condition
S1 = XSteam('sV_p',P1); % Entropyat Saturation Condition
end
% Data for State 2
S2 = S1; % Entropy at State 2 is same as state 1, for Isentropic Process
Sf2 = XSteam('sL_p',P2); % Entropy on Saturated Liquid line for Condensor Pressure
Sg2 = XSteam('sV_p',P2); % Entropy on Saturated Vapour line for Condensor Pressure
x2 = (S2 - Sf2)/(Sg2-Sf2) ; % Dryness Fraction
Hf2 = XSteam('hL_p',P2); % Enthalpy on Saturated Liquid line for Condensor Pressure
Hg2 = XSteam('hV_p',P2); % Entropy on Saturated Liquid line for Condensor Pressure
H2 = Hf2 + (x2 *(Hg2-Hf2)); % Enthalpy at State 2
T2 = XSteam('T_ph',P2,H2); % Temperature at State 2
% Data for State 3
P3 = P2; % Pressure at state 3
H3 = XSteam('hL_p',P3); % Enthalpy at State 3
S3 = XSteam('sL_p',P3); % Entropy at State 3
T3 = T2; % Temperature at State 3
v3 = XSteam('vL_p',P3); % Specific Volume at satate 3
% Data for State 4
P4 = P1; % Pressure at state 4
S4 = S3 ; % Entropy at State 4
Cp_4 = XSteam('Cp_ps',P4,S4); % Specific Heat at Constant Pressure at State 4
Cv_4 = XSteam('Cv_ps',P4,S4); % Specific Heat at Constant Volume at State 4
b = Cp_4 / Cv_4 ; % Specific Heat Ratio
a = (b-1)/b;
T4 = T3 * (P4 /P3)^a; % Temperature at State 3
W_Pump = v3 *(P4-P3)*100 ; % Work input to Pump
H4 = H3 - W_Pump; % Enthalpy at State 3
W_Turbine = H1 - H2 ; % Work done by Turbine
Q1 = H1-H4 ; % Heat Addition to Boiler
Q2 = H2- H3; % Heat Resjection From Condensor
W_Net = W_Turbine - W_Pump ; % Net Work Output
Ntherm = (W_Turbine/ Q1)*100; % Thermal Efficiency of Cycle
SSC = 3600/ W_Turbine ; % Specific Steam Consumption
BWR = W_Pump/ W_Turbine ; % Back Work Ratio
T = linspace(0,600,300); % TO creat a Temperature Range
% Display command for Results
printf(' \n At State Point- 1 At State Point- 2 ');
printf(' \n P1 = %d Bar P2 = %d Bar' ,P1,P2);
printf(' \n T1 = %d Deg Celcius T2 = %d Deg Celcius' ,T1,T2);
printf(' \n H1 = %d KJ/Kg H2 = %d KJ/Kg' ,H1,H2);
printf(' \n S1 = %d KJ/Kg-K S2 = %d KJ/Kg-K\n' ,S1,S2);
printf(' \n At State Point - 3 At State Point - 4 ');
printf(' \n P3 = %d Bar P4 = %d Bar' ,P3,P4);
printf(' \n T3 = %d Deg Celcius T4 = %d Deg Celcius' ,T3,T4);
printf(' \n H3 = %d KJ/Kg H4 = %d KJ/Kg' ,H3,H4);
printf(' \n S3 = %d KJ/Kg-K S4 = %d KJ/Kg-K\n' ,S3,S4);
printf(' -------------------------------------------------------------------------------\n')
printf(' Turbine Work [ W_T ]= %d KJ/Kg \n',W_Turbine)
printf(' Pump Work [ W_P ] = %d KJ/Kg \n',W_Pump)
printf(' Heat Added [ Q_1 ]= %d KJ/Kg\n',Q1)
printf(' Heat Rejected [ Q_2 ]= %d KJ/Kg\n',Q2)
printf(' Net Work Output [ W_Net ] = %d KJ/Kg \n',W_Net)
printf(' Dryness Fraction at State 2 = %d \n',x2)
printf(' Back Work Ratio [ BWR ]= %d \n',BWR)
printf(' Specific Steam Consumption [ SSC ] = %d Kg/KW-h \n',SSC)
printf(' Thermal Efficiency of Cycle = %d Percent \n\n',Ntherm)
% Command To Plot
% Plotting T/S Diagram
figure(1);
plot ([S1 S2 S3 S4],[T1 T2 T3 T4], 'k', 'linewidth',2)
hold on
plot([S4 XSteam('sL_p',P4)],[T4 T_sat_1],'k', 'linewidth',2);
plot([XSteam('sL_p',P4) XSteam('sV_p',P4)],[T_sat_1 T_sat_1],'k', 'linewidth',2);
plot([XSteam('sV_p',P4) S1],[T_sat_1 T1],'k', 'linewidth',2);
for i= 1:length(T)
plot(XSteam('sL_T',T(i)),T(i),'r','linewidth',2)
plot(XSteam('sV_T',T(i)),T(i),'r','linewidth',2)
end
title('T Vs S');
xlabel('ENTROPY [ KJ/Kg-K ]');
ylabel('TEMPERATURE [ Deg Celcius ]');
text(S1,T1,'1','FontSize',15);
text(S2,T2,'2','FontSize',15);
text(S3,T3,'3','FontSize',15);
text(S4,T4,'4','FontSize',15);
% Plotting H/S Diagram
figure(2);
plot([S1 S2 S3 S4 S1],[H1 H2 H3 H4 H1],'k','linewidth',2)
hold on
for j=1:300
plot(XSteam('sL_T',T(j)),XSteam('hL_T',T(j)),'r','linewidth',2);
plot(XSteam('sV_T',T(j)),XSteam('hV_T',T(j)),'r','linewidth',2)
endfor
title('H Vs S');
xlabel('ENTROPY [ KJ/Kg-K ]');
ylabel('ENTHALPY [ KJ/Kg ] ');
text(S1,H1,'1','FontSize',12);
text(S2,H2,'2','FontSize',12);
text(S3,H3,'3','FontSize',12);
text(S4,H4,'4','FontSize',12);
To execute this program, the necessary inputs are -
^ Turbine Inlet Pressure = 30 bars
^ Turbine Inlet temperature = 400° C
^ Turbine Outlet Pressure = 0.05 bars = Condenser Inlet Pressure.
Display of Command Window -
T-s and h-s plots for the given set of inputs -
ERRORS -
A series of Errors have been faced during programming. During plotting, we should concern about the paths of the cycle. In the T-S plot, vertical lines are Isentropic path, horizontal lines are Constant Temperature process. Inside the Vapour dome of the T-S diagram, horizontal lines also represent constant Pressure process & outside of the Vapour dome inclined lines represent Constant pressure process. So, during plotting of a constant pressure process in the T-S plot, we should use a correct command to describe the path, otherwise, it will show the wrong diagram. As -
OTHER CASE -
When the inlet condition of steam lies in Saturated condition (rather than Super-Heat condition), Then the plots will be-
Inlet conditions for these plots are -
^ Turbine Inlet Pressure = 80 bars
^ Turbine Inlet temperature = 250° C
^ Turbine Outlet Pressure = 2 bars = Condenser Inlet Pressure.
- CONCLUSION:
Rankine cycle is widely used in Steam Turbines, also used to study the performance of reciprocating steam engines. From this simulator, we can predict how efficient the Rankine cycle is under the given Inlet condition. Though it gives Ideal result, differ from Actual value. But It can be helpful to get a clear idea about the whole performance. By changing some conditions we can observe the change in Efficiency as well as Net Work output from this Cycle. Generally, the range of Efficiency of Rankine Cycle is found to be between 35% to 45%. From the given Inlet condition we get Efficiency of 36.194% from this Project. That is acceptable.
- REFERENCES: