Open Source Exergy Calculation Tool
Open Source Exergy Calculation Tool
Open Source Exergy Calculation Tool
The constant tightening of environmental regulations using Sim42 [2] as the chosen process simulator. Then
and the ongoing need to reduce operating costs have the exergy calculator tool is applied to the simulation
posed a challenge for the design of any chemical to perform an energy analysis and “discover” the most
process. Exergy is a potential indicator that can aid in inefficient parts of the simulated process. Numerical
the design of energy efficient chemical processes and results for the case study are presented in section 5.
plants. An open source exergy calculator has been
created by embedding the calculation procedure in an 2. The exergy concept
open source chemical process simulator. This serves as
a potential tool for design teams to quickly evaluate The most common analysis for energy efficiency of a
several process options in detail in order to understand plant or process is based on the First Law of
their energy utilization. A simulation case study is Thermodynamics (i.e. Energy conservation balance).
presented to show the application of the tool. However, this analysis does not provide enough
information regarding the potential work that a form of
1. Introduction energy can produce or the potential work lost in energy
transformation processes [3].
Process design has been always an extremely important Exergy, however, is based on the First and Second
step in the creation of a new chemical process or plant. Laws of Thermodynamics which allows accounting for
The constant tightening of environmental regulations irreversibilities in a process providing a more detailed
and the ongoing need to reduce operating costs have tracking mechanism for the energy usage.
posed a challenge for the design of any chemical The Exergy of a stream of matter is defined by Kotas
process; this is also the case for existing processes that as the maximum amount of work obtainable when the
have to be retrofitted to comply with the changing stream is brought from its initial state to the dead state
environmental regulations. by (reversible) processes during which the stream may
In process design the capabilities provided by interact only with the environment [3]. Where the dead
computers (e.g. fast calculation, large data storage, state is that of unrestricted equilibrium conditions of
logical decisions) allow engineers to solve larger mechanical, thermal and chemical equilibrium between
problems and to do it much more rapidly; furthermore, the system and the environment.
with the aid of computer software the engineers’ role There are two main ways to calculate exergy. One
can be shifted from problem solving to planning, divides exergy into physical and chemical components
conceiving, interpreting and implementing [1]. [4] and the other considers exergy as being composed
The intention of this article is to show the potential of three components, namely physical exergy,
help obtained in process design by using the chemical exergy and exergy change of mixing [5]. For
computational tools available to chemical engineers the present work the latter approach was used to
today and applying the concept of exergy as a means of develop the software because it presents more
finding the most inefficient parts of a given process or advantages for composition-changing processes.
plant. The advantages of considering exergy as being
The concept of exergy is reviewed in the next section composed of three components is that the exergy
and from there the equations and procedure to calculate components are calculated independently from each
the exergy of a steady-state material stream within a other and the calculation appeals to be clear with no
chemical process simulator are presented. In section 3 “hidden” components in each step. So the exergy, B, is
the design of the exergy calculator is presented. In calculated via equation (1).
section 4 a typical gas dehydration plant is simulated
B = B chem + B phys + ∆ mix B (1) The necessary calculations can be easily done in a
chemical process simulator which inherently performs
Exergy components thermodynamic calculations in a very efficient manner.
The design of the exergy calculator and the
Exergy will be calculated as the sum of three implementation of these equations are presented in the
components; chemical and physical exergy and the next section.
exergy change of mixing [5].
The chemical exergy is calculated based on the so- 3. Exergy calculator tool
called standard chemical exergy for the chemical
elements which can be calculated from standard As mentioned in the previous section, Exergy can be
formation enthalpy and Gibbs energy or obtained from easily calculated with the help of a process simulator.
standard tables [6]. Section 5 shows some numerical For the present work Sim42 [2] was used as the
values for the standard chemical exergy of the chemical process simulator. Since Sim42 is an Open
elements used in the case study. Calculation of Source program, this permitted the seamless inclusion
chemical exergy also requires a flash calculation at of the exergy calculations into the code of the
reference conditions. The chemical exergy is then simulator without having the inconvenience of linking
given by equation (2). any external computer routines to the simulator or
n n writing a macro-like routine inside the simulator’s own
B chem = L 0 ∑ x 0 , i B chem
0l
, i + V 0 ∑ y 0 , i B chem , i
0v
(2) programming or scripting language. It is also freely
i =1 i =1
available to any interested user or developer.
The Physical Exergy term requires a flash calculation As mentioned before, the approach by Hinderink et al.
at both the reference and the actual conditions. A [5] where the calculation of the exergy is divided into
mixing term is avoided by considering only the three components was implemented in the open source
contribution of the pure components to the enthalpy chemical process simulator Sim42 to create the exergy
and entropy of the mixture at reference and actual calculator.
conditions. The physical exergy component is then The exergy calculator performs the following steps in
given by equation (3). order to get the exergy of a material stream:
1. Identify the thermodynamic property package
T ,P
⎡ ⎛ n n
l ⎞ ⎤
and the chemical species used in the
⎢ L⎜ ∑ xi H i − T0 ∑ xi S i ⎟ + ⎥
l
⎝ i =1 ⎠ ⎥
simulation.
B phys =⎢
i =1 (3)
⎢ ⎛ n 2. Identify which elements within the simulation
n
⎞ ⎥
⎢V ⎜ ∑ yi H iv − T0 ∑ yi S iv ⎟ ⎥ represent material streams.
⎣⎢ ⎝ i =1 i =1 ⎠ ⎦⎥ T 0 , P0 3. Calculate thermodynamic properties for each
of the chemical species at standard conditions.
For the determination of the Exergy Change of Mixing, 4. Get thermodynamic properties for each of the
the concept of “property change of mixing” is used; chemical species at actual conditions.
this is shown for an arbitrary thermodynamic property, 5. Calculate thermodynamic properties for the
M, in equation (4). material streams at reference conditions.
6. Get thermodynamic properties for the material
⎛ n
⎞
∆ mix M = L ⎜ M l − ∑ x i M il ⎟ + streams at actual conditions.
⎝ i =1 ⎠ 7. Calculate the chemical exergy component.
(4) 8. Calculate the physical exergy and the exergy
⎛ n
⎞
V ⎜ M v − ∑ y i M iv ⎟ change of mixing components.
⎝ i =1 ⎠ 9. Calculate the exergy for the material stream.
10. Display the results for the total exergy for
Thus, enthalpy and entropy changes can be calculated each stream.
to obtain the exergy change of mixing, which is the In Sim42 it is not necessary to have “Material
contribution due to the pure components being in a Streams”, instead, the information is propagated
mixture, at actual conditions is calculated by applying through “Ports”. The “Material Port” represents
equation (5). streams of matter and it carries all the information
∆ mix B = ∆ mix H − T0 ∆ mix S (5) regarding physical, chemical and thermodynamic
properties [7].
The implementation for the exergy calculation was set From [8] a simplified typical configuration and
up in the call to the thermodynamic property package. operating conditions for a TEG Dehydration plant were
The “Exergy Property” was added to the Sim42 list of selected. Table 1 shows the composition of the
variables and then calculated in the thermodynamic saturated lean natural gas coming in to the plant.
provider interface. This allowed inserting the exergy
into the material ports and propagating the values Table 1. Inlet gas composition
throughout the simulation. Component Mole fraction
It is worth noting that at actual conditions the exergy N2 0.00100
calculator just needs to take values for the H2S 0.01544
thermodynamic properties already calculated by the CO2 0.02835
“natural flow” of the process simulator. However, the CH4 0.89820
values for the standard conditions need to be calculated C2H6 0.03098
because they are not included in the regular process C3H8 0.01479
simulator calculation steps. Notice also that the exergy i-C4H10 0.00590
calculator does not take into account energy streams n-C4H10 0.00300
modeled as pure or direct energy. In order to take the i-C5H12 0.00100
exergy of the utilities into account it is necessary to n-C5H12 0.00050
model them as the actual material streams they H2O 0.00086
represent (e.g. high pressure steam, hot oil, etc.).
The main specifications for the computer simulation of
4. Natural gas dehydration plant the dehydration plant were as follows:
simulation • Inlet gas pressure, 6200 kPa
• Inlet gas temperature, 303.15 K
A typical natural gas Tri Ethylene Glycol (TEG) • Inlet gas flow, 500 kmole/h
Dehydration process has been selected as a case study • TEG contactor pressure drop, 10 kPa
for the purposes of demonstrating the exergy
• TEG contactor theoretical stages, 8
calculation tool.
• TEG contactor feed pressure, 6205 kPa
Glycol dehydration is used to lower the water content
of natural gas to prevent hydrate formation in the • TEG contactor feed temperature, 318.15 K
pipelines and downstream processes; TEG Dehydration • TEG contactor feed flow, 4.02 kmole/h
is not the only process available but it is very common • Dry gas temperature, 304 K
when the specifications to meet are not too stringent. • Sales gas temperature, 309.8 K
The process consists of an absorber operated at high • Low pressure rich TEG, 180 kPa
pressure in which the water-saturated natural gas is • TEG regen. feed temperature, 378.15 K
contacted with recycled lean TEG, from this absorber • TEG regen. feed pressure, 110 kPa
the dry gas stream is sent to a heat exchanger where it • TEG regen. theoretical stages, 2
takes some energy from the recycled TEG stream • TEG regen. reboiler temperature, 477.15 K
before this one enters the absorber. The rich TEG • TEG regen. overhead temperature, 375.15 K
stream is passed through a J-T valve and then in a flash • Pump feed pressure, 102.3 kPa
drum some of the water vapour and acid gas contents • Pump outlet pressure, 6275 kPa
are taken out of the system to a separate processing
unit. The liquid stream coming out of the flash drum is The Peng-Robinson equation of state was used in the
preheated in a heat exchanger and fed to the TEG simulation as the thermodynamic property package.
regenerator where the water and the rest of the acid gas Notice also that the simulation case study was set up
are taken away and the regenerated lean TEG sent back with no heat losses from any equipment to the
to the process. The regenerated TEG from the environment and it was a rather idealized simulation.
regenerator is passed through a heat exchanger where it However, as it will be shown in the following sections
preheats the regenerator feed. Make up TEG is added even an idealized process has exergy losses and it is
to the lean recycled TEG to counteract any TEG losses possible to identify the equipments in which these
and then the recycled TEG stream is boosted to high losses are larger.
pressure again before passing it through the heat Figure 1 shows a simplified diagram of the case study
exchanger before entering the absorber again. process. The results for the exergy calculation for
every material stream in the simulated plant are presented in the next section.
MakeUp TEG
Sales Gas
To Gas/Gas To Pump
Pump FromL/R
Gas
TEG Feed Dry Gas
Regenerator Feed
Lean/Rich HEX
Lean TEG
Superscripts
0 Standard conditions
l Liquid phase
v Vapour phase