6.1 Definition

Thermodynamics represents a branch of physics which deals with the energy and work of the system and the energy transfer from one place to another. Thus, thermodynamics is defined as the study of equilibrium states of a system which has been subjected to some energy transformation. The main task of atmospheric thermodynamics is to interpret the average properties of macroscopic properties of a system in equilibrium, and related to proportionally slow movements, utilizing mathematical-physical concept (Bohren and Albrecht 1998; Tsonis 2002; Zdunkowski and Bott 2004; Curry and Webster 2005; North and Erukhimova 2009; Hantel 2013; Khvorostyanov and Curry 2014). Atmospheric thermodynamics deals with the transformations of the energy in a system and between the system and its environment. The system is a typical example of the matter. The equilibrium state of the system can be fully determined by a small number of properties such as pressure , temperature , and volume. These properties are known as state variables, or thermodynamic variables. It can be applied in many scientific disciplines, including physics, chemistry, and biology. Thermodynamics plays an important role in our quantitative understanding of atmospheric processes in a wide range, from the smallest cloud microphysics process to the global atmospheric circulation (Iribarne and Godson 1973). The purpose of this chapter is to introduce the basic elements and relationships that exist in the thermodynamics. We first discuss about the ideal gas equation and its application in dry air, water vapour, and moist air. Then a brief description of a thermodynamic system is given. The following section concentrates on the relationship between the mechanical work performed by the system and the heat that gets in the system, as expressed in the first law of thermodynamics. Then several sections follow, pertaining to apply previously mentioned in the atmosphere . Finally, in this section, we focused on the second law of thermodynamics and the concept of entropy, laws that constitute the basis for derivation of some important relations in the field of atmospheric science.

6.1.1 Thermodynamic System

In general, a system is a specific sample of matter. In the atmosphere , a parcel of air is a system. A thermodynamic system is a component or element of interest that we separate from the rest of the universe by “boundaries”, called the environment. The sum of the system and environment is the universe. There are three types of system:

  1. 1.

    Isolated: a system that exchanges neither matter nor energy with the environment.

  2. 2.

    Closed: a system that does not exchange matter with the environment but which may exchange energy.

  3. 3.

    Open: a system that exchanges both matter and energy with its environment (see Fig. 6.1).

Fig. 6.1
figure 1

Thermodynamic system

In an open system, mass and energy can be exchanged with its environment. A system is defined as closed when it exchanges energy but not matter with its environment and as isolated if it exchanges neither mass nor energy. In atmospheric thermodynamics, we assume that most systems are closed. It is justified when there is no interaction between the system and its environment.

This is approximately true when:

  • The system is large enough to ignore mixing with its surroundings

  • The system is part of large homogeneous system

A set of physical quantities that are used to describe the conditions of the system is referred to as a “state”. Under the term “thermodynamic condition”, we can specify the following variables, pressure , temperature , density, volume, entropy, etc., which we called the state variables.

6.2 An Ideal Gas Law

Laboratory experiments show that pressure , volume, and temperature of a substance can be connected via the equation of state in a wide range of conditions. We require that all emissions approximately follow the same equation of state, which is called the equation of ideal gas. For many practical purposes, it can be assumed that atmospheric gases, whether they are considered as individual or as a mixture of gases, obey the following equation for ideal gas:

$$ pV=n{R}^{\ast }T $$
(6.1)

where p is the pressure (Pa = kg m−1 s−2), V is the volume (m3), n is the chemical amount (in moles) which is equal to the total mass of the gas (m) (in grams) divided by the molar mass (M) (in grams per mole), R* is the gas constant (8.314 J K−1 mole−1), and T is the temperature in K, respectively. Usually, in the atmosphere , we do not know the exact volume of an air parcel or air mass. To solve this problem, we can rewrite the ideal gas law in a different useful form if we divide n by V and then multiply by the average mass per mole of air to get the mass density:

$$ \rho =\frac{nM}{V} $$
(6.2)

where M is the molar mass (kg mole−1). Density has SI units of kg m−3. The value of R depends on the individual gas that is considered. Thus, from Eq. 6.1, the equation for ideal gas per unit mass (m = 1) is given by:

$$ p=\rho RT=\rho \frac{R^{\ast }}{M}T $$
(6.3)

while R = cp − cV is a specific gas constant of the observed ideal gas, which is related with the universal gas constant R through R = R/M, where M is the mass of one kilo mole of substance into SI system or one mole substance (molar mass).

If the density is expressed through the specific volume of gas ρ = 1/α, then the following form of the ideal gas law is obtained:

$$ p\alpha = RT $$
(6.4)

If the temperature is constant, Eq. 6.4 is reduced to Boyle’s law, which says: if the temperature of a mass of gas is constant, the volume of gas is vice versa with pressure . Changes in the physical condition of the body that occur at a constant temperature are called isotherms. Also, implicit in Eq. 6.4, both Charles laws are given. The first of these laws is the constant mass of gas at constant pressure ; the volume of gas is directly proportional to its absolute temperature . The second law is the constant mass of gas contained in constant volume; the pressure of gas is proportional to its absolute temperature (Fig. 6.2).

Fig. 6.2
figure 2

Graphical illustration of the second law of thermodynamics. (Credot: BlyumJ [CC BY-SA 4.0 (https://creativecommons.org/licenses/by-sa/4.0)])

6.2.1 The Equation of State of Dry Air

Often in meteorology we use mass-specific gas laws so that we must specify the gas that we are talking about, usually only dry air (N2 + O2 + Ar + CO2 + …) or water vapour (gaseous H2O). We can divide R* by M to get a mass-specific gas constant, such as Rd = R*/Mdry air. Thus, we will use the following form of the ideal gas law for dry air:

$$ {p}_d={\rho}_d{R}_dT $$
(6.5)

where Rd = R*/Mdry air = 8.314 J K−1 mole−1/0.02897 kg mole−1 = 287 m2 s−2 K−1 = 287 J kg−1 K−1.

6.2.2 The Equation of State of Moist Air

The same procedure can be applied to water vapour:

$$ {p}_v=e={\rho}_v{R}_vT $$
(6.6)

where Rd = R*/Mwater vapour = 8.314 J K−1 mole−1/0.01802 kg mole−1 = 461 m2s−2 K−1 = 461 J kg−1 K−1. Typically, e is used to denote the water vapour pressure , which is also called the partial pressure of water vapour.

6.3 First Principle of Thermodynamics

Atmospheric thermodynamics deals with equilibrium states of the system. It basically states that the total energy of the system will remain constant if no energy is added or subtracted from the system. If we imagine a closed system in which the total amount of mass (either in the form of gas, liquid, or solid state or a mixture of phases) does not change, such thermodynamic system contains an internal energy due to kinetic and potential energy of its molecules or atoms. In this case, the system of unit mass has a certain amount of thermal energy (Q) which the system can obtain through thermal conductivity and/or radiation. Consequently, the system can carry out external work (W). The excess energy which the body obtains as the result of the external work is the difference between the thermal energy and the work that should be done by the system itself (Q − W). Following the principle of conservation of energy, the internal energy of the system must increase (Q − W), i.e.

$$ Q-W={U}_1-{U}_2 $$
(6.7)

where U1 and U2 are internal energies of the system before and after the change. In differential form Eq. 6.7 becomes:

$$ dQ= dW+ dU $$
(6.8)
$$ dQ= dW+\left({E}_2-{E}_1\right)= dW+ dE $$
(6.9)

where dQ is the differential change of heat added to the system, dW is the differential change of the work carried out by the system, and dU represents the differential change in internal energy of the system. Equations 6.7 and 6.8 express the first principle of thermodynamics , whose graphical illustration is shown in Fig. 6.3. Actually, Eq. 6.8 defines the change of internal energy of the system where dU depends only on the initial and final states of the system and does not depend on the way in which the system is transferred between these two states. Such parameters are known as state functions. The first principle of thermodynamics is an expression for maintaining the energy of the system. The first law of thermodynamics provides the basic definition of internal energy, associated with all thermodynamic systems, and states the rule of conservation of energy.

Fig. 6.3
figure 3

Entropy of the system

6.3.1 The First Principle of Thermodynamics for an Ideal Gas

For an ideal gas, internal energy is a function of temperature only, because the energy added by heating at constant volume only increases the accidental molecular movement, which is proportional to the temperature and is expressed as:

$$ dU={C}_V dT $$
(6.10)

After replacing dW = pdV in Eq. 6.8, where α\( =\frac{1}{\rho } \)is the specific volume of gas, we obtain:

$$ {C}_V dT= dQ- pd\alpha $$
(6.11)

Or by some arrangement:

$$ dQ={C}_V dT+ pd\alpha $$
(6.12)

Thereby, we can use the equation of state for an ideal gas, to write the alternative form of the first principle of thermodynamics. The equation of state is the following:

$$ pd\alpha +\alpha dp= RdT $$
(6.13)

Using the above relation, the first principle of thermodynamics (6.8) becomes:

$$ dQ=\left({C}_V+R\right) dT-\alpha dp $$
(6.14)

For isobaric process:

$$ dQ=\left({C}_V+R\right) dT $$
(6.15)

From the definition of heat capacity of air at constant pressure Cp, dQ = CpdT with replacement CV + R = Cp, we get the alternative form of the first principle of thermodynamics:

$$ dQ={C}_p dT-\alpha dp $$
(6.16)

Or if Q = H, where H is a new quantity called enthalpy, then:

$$ dH={c}_p dT-\alpha dp $$
(6.17)

Enthalpy of the ideal gas as internal energy of gas is only a function of temperature . The other form is specific enthalpy:

$$ dH={c}_p dT $$
(6.18)

In meteorology, quantity CVdT is also called latent heat. It is the energy transferred to the heating system during isobaric process.

6.3.2 Enthalpy

The internal energy U and the volume V are not the only state variables that we can use to characterize a thermodynamic system. We can choose other quantities that can be closely related to U and V, such as the temperature T, pressure p, and enthalpy H. One commonly used state variable is called enthalpy and is defined as:

$$ H\equiv U+ pV $$
(6.19)

The differential of H is given as dH = dU + pdV + Vdp. This makes it possible to write the first law of thermodynamics as:

$$ dH= dQ+ Vdp $$
(6.20)

From the first form of the thermodynamics law, dU = dQ − pdV, we see that at constant volume, dU = dQ. Enthalpy of the ideal gas, as an internal energy of gas, is only a function of temperature . It is worth repeating the following:

  1. 1.

    For constant pressure processes, heat and enthalpy change are equivalent.

  2. 2.

    For constant volume processes, heat and internal energy change are equivalent.

6.3.3 Poisson Equations

Even though energy in the atmosphere /ocean system ultimately comes from radiative heating, adiabatic processes in the atmosphere are of interest for several reasons. Often it is because real atmospheric processes occur quickly in comparison with the time scale for heat transfer and so may be approximately adiabatic. Alternatively, we may wish to make the adiabatic assumption simply because we are ignorant of the heat transfer and consequently must ignore it or give up. Poisson’s equations describe relationships between the state variables T, p, and ρ for the adiabatic processes. When dB = 0 (adiabatic process), the first principle of thermodynamics can be written as:

$$ {c}_v dT+ pdV=0 $$
(6.21)

Substituting for p from the ideal gas law, dividing by CVT, and using R = Cp − CV, we have, after some replacements:

$$ d\ln \left(T{V}^{\gamma -1}\right)=0 $$
(6.22)

where γ = Cp/Cv (which is equal to 7/5 for an ideal gas). This implies that, for an ideal gas undergoing an adiabatic process:

$$ T{V}^{\gamma -1}=\mathrm{const}. $$
(6.23)

Equation 6.22 is one of the three Poisson’s equations. Eq. (6.22) can be used to explain several atmospheric phenomena. Starting with the second version of the first law of thermodynamics, dQ = CVdT + pdα, and following a similar replacement, one may arrive at the second Poisson’s equation for an adiabatic process in an ideal gas:

$$ T{p}^{-k}=\mathrm{const}. $$
(6.24)

where k = R/Cp (which for an ideal gas is equal to 2/7). Finally, by combining Eqs. 6.22 and 6.23, we arrive at the third Poisson’s equation

$$ p{V}^{\gamma }=\mathrm{const}. $$
(6.25)

where \( \gamma =\frac{C_p}{C_V}=7/5 \). Equation 6.24 is the most familiar of Poisson’s equations, although they are all equivalent.

6.3.4 Potential Temperature

Meteorologists use Eq. 6.24 to define a quantity known as potential temperature (a thermodynamic concept that seems to be unique to meteorology). Suppose we start with a parcel of air in some arbitrary initial state specified by T, p. Let us move the air parcel adiabatically to a pressure of 100 kPa and call the temperature which it achieves the potential temperature, θ. By using Eq. 6.24 in the initial and final states, it can be easily shown that:

$$ \theta \equiv T{\left(\frac{100}{p}\right)}^k $$
(6.26)

where p must be expressed in kPa (since we have used 100 kPa in the numerator). Because the potential temperature of an air parcel is conserved under dry adiabatic processes, it may be used as a tracer for air parcels.

6.3.5 Implementation of the First Principle of Thermodynamics

We will calculate the specific energy added by heating (q), the specific work carried out (W), changes in internal energy (dU), and changes in enthalpy (dH), for isotherm , isobaric, and esoteric processes (constant volume) of an ideal gas.

Isotherm process: For dT = 0 at isothermal process, expressions of changes in specific internal energy of ideal gas (dU = CVdT) and enthalpy (dH = CpdT) are equal to zero. Since (dU = 0) for this process, the first principle of thermodynamics (6.8) simply becomes:

$$ Q=W=\underset{\alpha_1}{\overset{\alpha_2}{\int }} pd\alpha = RT\ln \frac{\alpha_2}{\alpha_1} $$
(6.27)

The total energy is transformed in the system by heating during isothermal expansion of ideal gas, and it is used by the system to perform work in the area.

Isobaric process: In isobaric expansion of the gas, because the change in temperature dT > 0, changes in specific internal energy (dU = CVdT) and enthalpy (dH = CpdT) are also positive. The specific work carried out by the system is:

$$ W=p\left({\alpha}_2-{\alpha}_1\right) $$
(6.28)

To calculate the energy delivered to the heating system, an alternative form of the first principle of thermodynamics is used:

$$ dQ={c}_p dT-\alpha dp $$
(6.29)

Since dp = 0 during isobaric process, the first principle of thermodynamics simply becomes Q = dH. The whole energy passing through the heating system during the isobaric process is used to increase the specific enthalpy of the system:

$$ dQ={c}_p dT-\alpha dp=>{c}_p dT= dH $$
(6.30)

Isosteric process

Since dT > 0 for isosteric process (constant volume), in which the pressure increases, changes in specific internal energy dU = CVdT and enthalpy dH = cpdT are also positive. The specific work carried out by the system is equal to zero, because ( = 0) during the isosteric process. The first principle of thermodynamics (6.8) simply becomes:

$$ dQ= dU+ pdV=> dU $$
(6.31)

The overall amount of energy transferred through the heating system at isosteric process is used to increase the specific internal energy of the system.

6.4 The Second Principle of Thermodynamics

While the first principle of thermodynamics says that energy is conserved in all thermodynamic processes, the second principle of thermodynamics is concerned with the direction of natural processes and definition of a new variable to the state called “entropy”. The second law claims that a natural process runs only in one sense and is not reversible. For example, heat always flows spontaneously from hotter to colder bodies, and never the reverse, unless external work is performed on the system (see Fig. 6.2). The explanation of the phenomena was given in terms of entropy. Total entropy (S) can never decrease over time for an isolated system because the entropy of an isolated system spontaneously evolves towards thermodynamic equilibrium: the entropy should stay the same or increase.

6.4.1 Definition of Entropy

Entropy has different physical interpretations, including statistical disorder (chaos) of the system (see Fig. 6.3) but for our purposes to consider the entropy as another feature of the system, as enthalpy or temperature . The second law says that there is a useful variable in the state called entropy (S). The change of entropy dS is equal to the transfer of heat dQ divided by temperature (T) which follows that the change of entropy is then the inverse of temperature :

$$ dS= dQ/T $$
(6.32)

For a given physical process, the entropy of the system and the environment remains unchanged if the process is the return (reversible). If you mark the initial and final states of the system (i) and (f), then there is a balance between these situations:

$$ {S}_{\mathrm{f}}={S}_{\mathrm{i}}\left(\mathrm{reversible}\kern0.17em \mathrm{process}\right) $$
(6.33)

Example of feedback process is ideally forcing the air flow through the narrowed tube. Ideally, that means no loss in the border layer. As the fluid flows and moves through the narrowing, the pressure , temperature , and speed are changing, but these variables returned to their original values downstream of the narrowing. The state of the gas returns to its original conditions and the change of entropy of the system is zero. This process is called isentropic process, i.e. the entropy of the system is constant. In order to calculate the change in entropy, we use the first principle of thermodynamics:

$$ dU= dQ- dW\kern1em \mathrm{or}\kern1em dQ= dU+ pdV $$
(6.34)

Changing the definition of term which expresses the work of gas:

$$ dQ= dU+ dV{c}_p dT-\alpha dp $$
(6.35)

where

$$ {c}_p dT= dH. $$
(6.36)

In the above expression, (p) is the pressure and (V) is the volume of gas. If we use the definition of the enthalpy of the gas (H):

$$ dH= dU+ pdV+ Vdp $$
(6.37)

Enthalpy change for the next expression is obtained. By replacing in Eq. 6.8, an alternative way of presenting the first principle of thermodynamics is obtained:

$$ dQ= dH- Vdp- pdV+ pdV= dH- Vdp $$
(6.38)

For the ideal gas, the equation of state is written as pV = RT, where (R) is the gas constant. The transfer of heat of gas is equal to the heat capacity multiplied by the change of temperature , which in differential form is expressed as

$$ dQ={C}_V dT $$
(6.39)

If we consider the process of constant volume, the first principle of thermodynamics, the following expression is obtained:

$$ dE= dQ={C}_V dT $$
(6.40)

Similarly, for the process of constant pressure , the formulation of the first principle of thermodynamics gives:

$$ dH= dQ={C}_V dT $$
(6.41)

If we assume that the heat capacity is constant with temperature , we can use these two equations to define the change of enthalpy and internal energy. If we replace the value of pressure (p) in the equation of state of ideal gas and the definition of dE in the first equation of energy, we get:

$$ dQ={c}_V dT+R\;T\; dV/V $$
(6.42)

With the replacement value (V), the equation of state, and the definition of change of enthalpy (dH), the first principle of thermodynamics is recorded by the expression:

$$ dQ={c}_p dT-R\;T\; dp/p $$
(6.43)

By replacing dQ in the form of differential equation for entropy, we obtain:

$$ dQ=\frac{C_V dT}{T}+R\kern1em dV/V $$
(6.44)

and

$$ dS={C}_p dT/T-R\;T\; dp/p $$
(6.45)

These equations can be integrated by the condition “1” to that “2” as follows:

$$ {S}_2-{S}_1={C}_V\ln \left(\frac{T_2}{T_1}\right)+R\ln \left(\frac{V_2}{V_1}\right) $$
(6.46)

and

$$ {S}_2-{S}_1={c}_p\ln \left(\frac{T_2}{T_1}\right)+R\ln \left(\frac{p_2}{p_1}\right) $$
(6.47)

where CV and Cp are the heat capacity at constant volume and pressure , and (ln) is a symbol for a logarithmic function. Depending on the type of process, the change of entropy of the gas may be determined. From Eq. 6.46, the process at constant volume, the second term in the equation is zero, because v2/v1 = 1. Then you can determine the value of specific heat at constant volume process. The first term of the equation can be considered as a contribution to the constant volume process and the second term as an additional shift caused by the change of volume.

6.4.2 Summary on Reversible and Irreversible Processes

As a summary, “reversible process” is the one performed in such way that the system and the local environment may be restored to their initial states, without producing any changes in the rest of the “universe”. A little thought should convince you that no real process is reversible. The abstraction of reversible processes provides a clean theoretical foundation for the description of real-world, irreversible processes. The logical question arises “What real-world processes” make things irreversible? Dissipative effects (e.g. viscosity, friction, inelasticity), i.e. processes for which the thermodynamic equilibrium for mechanical, thermal, or chemical equilibrium, are not satisfied. In atmospheric and ocean sciences, it is common to assume no dissipative effects (particularly for large-scale flows) and that motion of the atmosphere and oceans is isentropic. Viscous and frictional dissipation of course occur, but a good understanding of the dynamics can be obtained from inviscid theory.