## The Thermodynamic Analysis of a System in the Steady State

The computation of a design point of a system in the steady state, as shown in Figure 2.2, is a key procedure in the further analysis of a system of a given configuration. Enhanced analysis calls for fast computation of this key procedure. The procedure boils down to a number of equality constraining equations and a larger number of variables. The difference is a set of decision variables to be assigned with a purpose in mind such as a targeted level of a system's overall efficiency. The selection of these decision variables from all the participating variables has significant effect on the speed of computation. The selection that leads to sequential solution of the set of equations (as contrasted to simultaneous) gives the fastest computation. A sequential solution has dependent variables within the diagonal of the matrix of the equations and the dependent variables. The decision variables given in the column of Figure 2.2 allows the sequential solution of the considered simple combined cycle. The following sections to the computational algorithm of a design point deal with the number of variables, constraints and decisions as well as with the approach to sequential equation solver.

2.2.1 Variables, constraints and decisions

A system defined via a flow diagram will have Ns states, Np processes, Nv variables and Nq equality constraints. The decision variables Nd= Nv- Nq — (Nv — Nk) — (Nq — Nk) where Nk represents a subset of Nv and a subset of Nq of equal number. Nk may be excluded from Nv and from Nq without affecting the number of decision variables. Thermodynamic and transport properties of the working fluids and their corresponding equations are examples of the subsets that can be excluded when deciding the number of decision variables. They may, however, appear in the matrix of the constraining equations and their dependent variables.

In the absence of chemical separations or combinations, each state has a minimum number of variables per state to compute (e.g. P, T, {A^} and Mass, though P and T may be exchanged by two other properties such as P and H or T and S). The equal subsets take care of the desired property vector. Each process has one mass balance equation and one energy balance equation per process. Discounting property subsets of equal variables and their corresponding equations, the number of decision variables Nd becomes:

In the presence of chemical separation or/and combination, the variables are increased by the composition of the participating species {X,} in the participating chemical processes and the equations are increased by the species mass balance equations. Thus:

where r is the number of processes involving chemical change. Nc^r is the species of the stream of largest number of species. (Nc<r —1) takes into consideration the total mass of the stream accounted for in the first term 3 * Ns. r is the number of states of each reaction r. Neqn^r is the number of mass balance equations in each reaction r. For a combustion process having Ns = 3 and Nc = l and Neqn = 6, the decision variables increase by 12, which is the composition of air and fuel. The six mass balance equations determine the composition of the products of combustion.

### 2.2.2 The approach to sequential equation solver

It is often possible to find more than one sequential equation solver for a system configuration. When this is not possible, minimizing the number of dependent variables to be solved simultaneously is still desired for fast computation.

A sequential equation solver is sought by following the variables of the system and not the sequence of the connectivity of its devices. A solution path is best visualized by mentally solving the system without computation whereby the decision variables and the sequence of computing the dependent variables are identified. Computation often starts with pressures, temperatures, compositions and masses related directly by plus or minus to the selected decisions. The computation of states of known pressure, temperature and composition follows. Mass and energy balance equations are applied to the processes having sufficient known states to determine more masses and states until all states are computed. A state is a vector of thermodynamic properties that should consist at least of pressure, temperature composition, specific volume, enthalpy, entropy, exergy and relative mass. The vector is useful to the consistency of the detailed analysis of the system.

A computerized general sequential equation solver for any system configuration must have built-in guards against premature computations. The states and the processes of a system configuration go through repeated runs. In each run only mature computations are performed. The runs stops when all state vectors are computed, i.e. a system design point is obtained for further system analysis.

An incidence matrix can express the flow diagram of a system. The columns represent the system streams and the rows represent the system processes. A cell (/,/) represents a stream j connected to process i. Input and output streams are differentiated by positive and negative signs. Pressure, temperature, composition and a mass relative to a reference mass are sufficient to indicate that the state of a cell is determined. A solution is reached when all states are known. The incidence matrix of Figure 2.2 is given in Figure 2.3. Processes of splitters and mergers of matter, heat or work may be excluded for simplicity since the quantities are related directly by plus or minus signs similar to the initial computations related to the decision variables.

The incidence matrix may be expanded to identify a sequential computational algorithm free from system iterative loops for fast computation. For modular description of systems, this is analogous to diagonalizing the solution of a set of simultaneous equations.

For a set of thermodynamic decision variables, sequential solution of mass and energy balance equations requires handling the models of the system processes in a particular order. Figure 2.4 shows an expanded incidence matrix that handles the process models in a sequence that is free from system iterative loops. The thermodynamic decisions considered are process efficiency parameters and essential stream parameters. The efficiency parameters are indicated in column 18. They are the adiabatic efficiencies of turbines and pumps {??}, pressure loss ratios of the streams {dPjPin} and the temperature differences that control the heat exchange processes (dThl = T4 — T6, dTc7=Tu-Tl0, and dTh\0=T7—T\7). The essential stream parameters are indicated under the streams. They are boundary parameters and upper and lower values of pressures or temperatures. Target computations for each process model are indicated in column 19. A figure such as Figure 2.4 visualizes the mental solution of a system.

If both the processes and the streams were numbered to follow the sequence of computation, the incidence matrix would appear diagonalized even though the matrix is not square. The stream sequence [1,2,5,3,4,6,10,13,8,9,7,15,16,17,11,12,14] diagonalizes

5. cooling pump

9. economizer +

Figure 2.3 The incidence matrix of the flow diagram 2.2.

Streams and Stream Decisions

Efficiency Target

9 10 11 12 13 14 15 16 17 Decisions Computations

Processes

6. combustor +

2. gas turbine

4. feed pump

3. steam turbine

5. cooling pump 10. condenser 5. cooling pump

7. superheater

8. boiler

9. economizer

satl satl satv

T8,T9,W4

Check balance

## Combining the superheater and the boiler maintains sequential solution by avoiding tear. The energy balance here determines nv (mass of steam relative to air)

### Figure 2.4 Decisions and sequence of computation.

the matrix. Transforming the flow diagram of a system and its decision variables to an expanded incidence matrix helps to identify the sought sequential solution. 