Project 2 - Rankine cycle Simulator
AIM:- Rankine Cycle Simulator
Introduction:- A Rankine cycle is an idealized Thermodynamic cycle that governs the working of a Heat Engine. In the Rankine cycle, the friction losses of a heat engine are neglected. It is a cycle that converts heat into mechanical energy which usually is converted into electrical energy. There are four components in this cycle that work on four different processes. The four components are the turbine, Condensor, Pump, and Boiler. The Rankine cycle is nothing but a modification of the Carnot cycle. The ideal Rankine cycle is very useful in steam power plants and gas power plants. To improve the efficiency of the Rankine cycle in the steam power plant, there are some changes in the Rankine cycle that differs from the Carnot cycle. Firstly, a pump is used in place of a condenser to handle only liquid, not a mixture of liquid and vapor. Secondly, exhaust steam from the turbine is completely condensed in the condenser.
The process in the Rankine cycle is given as:
- Isentropic Compression in Pump.
- Constant pressure heat addition in the boiler.
- Isentropic expansion in a turbine.
- Constant pressure heat rejection in the condenser.

Rankine cycle efficiency ηR is -

Back Work Ratio:
The fraction of the work produced by the turbine that is consumed by the compressor.
BW ratio=Wp/Wt
Explanation:
- The creation of the Rankine cycle simulator starts with some input values which is required to calculate the other state point in the cycle eventually.
- The Rankine cycle process is displayed in the command window and then inputs are entered which are inlet pressure for the turbine, temperature at the turbine inlet, and pressure at the condenser.
- Then we are using the XStream function file for reading the state point. First, we get the value of enthalpy and entropy at state point 1 from the XStream function file.
- As process from 1-2 is isentropic compression the entropy at point 1 is equal to point 2. The term ‘(s_pT, p1, T1)’ refers to entropy at pressure and temperature point 1.
- The term ‘sg’ and ‘sf’ are referred to saturated liquid and saturated vapor entropy respectively. This value is used to calculate other functions according to mathematical relations.
- Similarly, other points are taken from the XStream function file which is necessary to calculate other parameters. After that work done in the turbine and pump is calculated for further getting the net work done Rankine cycle.
- After calculating the net work done the efficiency of the Rankine cycle is calculated along with specific steam consumption which is steam consumed by a locomotive cylinder per unit of output of work done.
- The temperature at each point of the cycle is calculated using input taken from the start of the program and data taken from the XStream file. For a given temperature range from lower to higher entropy points are calculated to create the T-S plot. Similarly, another for loop is used to create the saturation curve in each plot.
- Then plotting is done respectively for T-s and H-s graphs in the Rankine cycle and each state point value has been put in the command window.
The code for Rankine Cycle Simulator is given as:
MATLAB Code:-


