Princeton Satellite Systems has added Rankine cycle functions to release 2023.1 of its MATLAB toolboxes, which is coming soon. The following figures show the output from the function RankineCycle.m. The first diagram is the temperature entropy (T-s) diagram. Entropy can be viewed as the state of disorder in the system.

The red lines indicate the simple Rankine cycle while the bell-shaped curve is the T-s curve for water and steam. The second output is the cycle diagram, shown below.

Entropies are displayed on this diagram. You only need two pressures to define the cycle: the base and the peak. The pump compresses water which is fed to the boiler. The boiler produces steam that is converted to mechanical energy in the steam turbine. This drives a generator to produce electric power. The fluid output of the turbine passes through the condenser to become water.

This is the simplest Rankine cycle. The numbers on the diagram correspond to the numbers on the T-s diagram. The cycle is defined per unit mass of water flowing in the cycle so it can be scaled to any size. The MATLAB code has functions for handling steam tables, which are essential to studying or designing steam engines.