The First Law of Thermodynamics

          Thermodynamics is a macroscopic science.  Our approach has been to understand the microscopic origin of the variables that thermodynamics relates.  But, in fact, the history of the thermodynamic laws we will derive here precedes the microscopic point of view.  In the early 1800s it was realized the Newton’s equations of motion did not provide a complete description of the state of a system.  From a practical point of view steam engines were designed to pump water out of coal mines.  However, these engines were extremely inefficient.  It was clear that an understanding of the interaction of heat and mechanical devices that perform work was essential to the design of a more efficient engine.  These considerations lead to the laws of thermodynamics.

 

Pressure-Volume Work

          Students often wonder why we begin with pressure-volume work.  After all, there are lots of kinds of work starting with the basic definition that work is a force acting through a distance.  However, the work performed by an engine involves the expansion of a gas to drive a piston and it is this work that is of practical interest in the design of steam and internal combustion engines.  It is also pressure-volume work that leads most directly to an understanding of the relationship between heat and work.  In order to study the transfer of energy in the form of heat and work we define the system (the engine or mechanical device we are interested in) and the surroundings.  We define heat, q, to be energy flow associated with a temperature difference between the system and the surroundings.  Heat input to the system is defined to be a positive quantity and heat extracted from the system is defined to be a negative quantity.  We define work, w, to be the transfer of energy between the system and surroundings as a result of unbalanced forces between the two.  If the energy of the system is increased by the work, we say that the work is done on the system (a positive quantity).  If the energy of the systems is decreased by the work, we that the work is done by the system (a negative quantity).

 

Energy

+ (increased)

- (decreased)

Work

on system

by system

Heat

into system

from system

 

Work done by the system is an expansion and work done on the system is a compression.  To understand pressure-volume work we use the picture of a gas in a cylinder with a mass on top (Figure 1 below).  If the pressure inside the piston is sufficiently great it can expand and lift the mass.  The work required to lift the mass, M against gravity is w = -Mgh where g is gravitational acceleration of 9.8 m/s2 and h is the height.  Notice that the minus sign applies because the system (i.e. the gas inside the piston) is doing the work.  The area of the head of the piston is A (see Figure 1) so that the volume change in the expansion is DV = Ah.  Therefore we can write the work as

w = -Mgh = -Mg(DV/A) = -PDV

where we have used the definition of the pressure as force per unit area.  This definition is clear in the SI units (Newtons/meter2) or even in the English system (pounds/inch2) that is still in use in the United States.


 


The SI unit is also known as Pascal (=N/m2).  One atmosphere of pressure is equal to 1.0325 x 105 N/m2.

The pressure referred to in the work term is the external pressure Pext.  Clearly, the pressure inside the piston must be greater than the external pressure to effect the expansion.  If we imagine that the piston was held in place in the initial state and then released then the pressure inside the piston should be equal to atmospheric pressure in the final state.  Pfinal or Pf = Pext.  If the external pressure is not a constant during the expansion then the work is given by

The expansion shown in Figure 1 is an expansion against a constant pressure Pext. 

 w = -Pext(Vfinal – Vinitial) = -PextDV

as we saw before.  However, if imagine that the pressure inside and outside the piston are equal at all points during the expansion we can define an isothermal expansion.  An isothermal or constant temperature expansion implies that the system is at equilibrium at all times during the expansion.  Since P = Pext we can substitute Pext = nRT/V into the expression for work. To solve for the isothermal work we have used the definition of the logarithm that you learned in calculus. 

Using this integral we can solve for the reversible work by substituting in from the ideal gas law P = nRT/V.

We can use the indices f for final and i for initial or 2 for final and 1 for initial.   Recall the basic properties of a log (base 10) or ln (base e) function that ln(a/b) = ln(a) – ln(b) and therefore ln(a/b) = - ln(b/a).  These facts are used repeatedly in thermodynamic derivations.  The reason for this is apparent in the definition of isothermal work above.  You might think of isothermal work as an artifice since, after all, how is the external pressure going to be equal to the pressure in the piston at all stages of an expansion.  However, if you imagine the piston in an internal combustion engine connected to the crankshaft you will realize that the pressure (i.e. force on the piston) is not at all constant during the expansion of the piston.  This turns out to be very important for the design of an efficient engine (as we shall prove later in the course).  We can think of the pressure-volume work as the area under a P-V plot.  For example, if the initial state of the piston is 10 atm in a volume of 0.5 liters we can plot a constant pressure expansion against 1 atm of pressure and an isothermal expansion at 298 K on a P-V plot.  You can work this example in Maple.  At the prompt type

                evalf(-1.0*(2.0 – 0.5)); Result is –1.50.  This is the pressure-volume work in units of liter-atmospheres.

To continue and evaluate the isothermal work, w =     -nRTln(Vf/Vi) we need to know the number of moles, n.  This is obtained from the ideal gas law n = PV/RT.

                evalf(10.0*0.5/(0.082*298)); Result is 0.204.  Here we use universal gas constant R in units of liter-atm.

R = 0.082 L-atm.

                evalf(-0.2*0.082*298*ln(2.0/0.5)); Result is –6.775 which is the isothermal work in units of liter-atm.

To examine the result graphically, use the plot command.

                with(plots):plot(-1.0,v=0.5..2.0);

                plot(-0.2*0.082*298/v,v=0.5..2.0);

To examine both plots at the same time

as shown above, type

                plot({-1.0,-0.2*0.082*298/v}, v=0.5..2.0);

The area underneath each of the curves corresponds to the P-V work.  The work of expansion is negative (w < 0).  If we consider a compression as is seen in Figure 19.2 of McQuarrie and Simon the P-V isotherms are in the first quadrant. As a second example we consider compression of the same piston discussed above.  In order to compress the volume back to 0.5 liters we require an external pressure of 10 atm.  Therefore, the work of compression is (again using Maple as our calculator)

                evalf(-10.0(0.5 – 2.0)); Result is 15.0 L-atm.

For the isothermal compression the external pressure is equal to the internal pressure at all times.  Once again since w = -nRTln(V2/V1) we use the value of n = 0.2 that we calculated above.

                evalf(-0.2*0.082*298*ln(0.5/2.0)); Result is 6.775 L-atm.  Notice that the work required to compress at constant pressure is much greater than the work obtained from the constant pressure expansion.  However, the work of isothermal compression is exactly equal (and opposite in sign) to the work of isothermal expansion.   We calculate the total work as

wtotal = wexpansion + wcompression

Case I. constant pressure

wtotal = -1.5 + 15.0 = 13.5 L-atm.

Case II. Isothermal

wtotal = -6.775 + 6.775 = 0 !!

          We call an isothermal expansion a reversible expansion for this reason.  No net energy was expended in the process.   Microscopically, the reason for this is that the system is in equilibrium with the surroundings at each stage during the expansion.  

          Some practical tips for calculating P-V work.

1.                Keep the units consistent.  The universal gas constant is defined in several different units.  When comparing constant pressure and isothermal work you will need to remember that the P-V product in a constant pressure calculation gives units of L-atm. (L = liter).  Therefore, use R = 0.082 L-atm./mol-K when calculating work along a reversible isothermal path.  If you need to convert from one set of units to another use the definition of R.  For example, R = 8.314 J/mol-K.  Therefore, 8.314 J/0.082 L-atm gives the conversion factor 101.39 J/L-atm.

2.                Pressure is not defined for a system during the expansion.  The pressure is always the external pressure.  Only in an isothermal (reversible) expansion is the external pressure equal to the internal pressure.  This is because the system is in equilibrium in such an expansion.

3.                If there is any missing quantity in the given data for a problem you must use PV=nRT to find the unknown.

 

Energy is a State Function


          A state function is a property of a system that depends only on the state of the system and not the path taken to get to that state.  A state function usually depends on only a few variables P, V, T etc. in the same way that an equation of state for a gas relates one property to the others.  Energy is a state function.  The energy change can be calculated according to

The notation indicates that the value of DU is independent of the path taken between initial state 1 and final state 2.  Work and heat are not state functions.  To
see this, consider the definition of work.


The work done to compress a gas will depend on the external pressure used (see the examples of constant pressure and isothermal paths given above).  We call work a path function


And we use the squiggly delta to represent the fact that work is an inexact differential.  Likewise, heat is a path function.

For a process in which energy is transferred as both heat and work, the law of conservation of energy states that

dU = dw + dq

in differential form, or

DU = w + q

in integrated form.  The first law of thermodynamics states that even though w and q are not state functions, their sum is a state function.  All state functions are exact differentials.  For the definition of exact differential see Mathchapter H in McQuarrie and Simon.

          In Chapter 17 it was shown that U = 3/2nRT for an ideal monatomic gas.  The internal energy depends only on the temperature.  This implies that DU = 0 for all isothermal processes.  This means further that dq = -dw for an isothermal process.  

Heat and work are path functions

An isotherm is one possible path that we can follow to change state variables P, V, and T.  The Table below shows the commonly used paths in thermodynamics.

 

Path

Condition

Result

Isothermal

DT = 0

dw = -dq

Constant V

DV = 0

dw = 0, dU = CvdT

Constant P

DP = 0

w = -PDV, q = CpdT

Adiabatic

dq = 0

dU = dw

 

The adiabatic path refers to process which is thermally insulated from the surroundings.  The meaning of dq = 0 is that there is no heat transfer from the system to the surroundings (or vice versa).  The possible paths are all exhibited in Figure 19.5 in McQuarrie and Simon.  This path diagram is used to show that DU is a state function but dq and dw are not, even when a reversible path is followed.  

                        The change in internal energy DU = 0 along an isotherm.  Any other path will result in a temperature change and therefore a change in internal energy.  For example a constant pressure path will result in a volume change and a temperature change.  We need to be able to determine DV and DT for a constant pressure path in order to determine the work w and the heat q as shown in the path table above.  In practice, either DV or DT must be a given in a constant pressure problem.  Note that if you known P (a constant), (the number of moles) and V2 (the new final volume) you can calculate T2 from the ideal gas law.  The same logic applies to a constant volume path.

The adiabatic path

                        The adiabatic path (dq = 0) requires some math to determine the temperature change.   Along an adiabatic path there is no heat exchange between the system and surroundings.  Therefore, the internal energy change is equal to the work

                           dU = dw = dw

If the system is doing the work (i.e. in an adiabatic expansion) the sign of w is negative.  Therefore, the sign of dU is negative.  The decrease in internal energy is due to the decrease in temperature in the system.  The work performed along an adiabatic path represents the maximum work that can be extracted from the system without adding heat to the system.
     To find quantitative relationships between the volume change and the temperature change (as we discussed above for the constant pressure and constant volume paths) we use the relations dU = CvdT and dw = – PdV = – nRTdV/V.

                                                CvdT = – nRTdV/V.


Divide both sides by T and integrate.


We have shown that Cv = 3/2nR.  Substituting this into the above integral we obtain


Note that nR cancels and the integrals evaluate to logarithms.  Thus, we have


By the properties of logarithms


Exponentiate both sides to find

Which gives the relationship between the temperature and volume along an adiabatic path.  McQuarrie and Simon cast this in terms of an adiabatic expansion where the gas cools.  For an adiabatic compression the gas heats up.  You can imagine that a column of air rising when it reaches a mountain range is an adiabatic expansion.  Thus, it cools.  Likewise, you can think of the piston in an internal combustion engine.  When the fuel is ignited the hot gas in the piston causes it to expand and the gas cools.  Obviously, neither process is perfectly adiabatic.  The adiabatic path serves as an ideal limiting model for real processes.  Finally we can relate pressure to volume

along an adiabatic path.  We use the relationship


And subsitute in for T2/T1.


This can be rearranged to yield

Keep in mind that these formulae are valid for an ideal monatomic gas.  If we were to describe a polyatomic gas then Cv would change and the exponent would change.  The derivation is the same, however.  McQuarrie and Simon derive the result for an ideal diatomic gas in Example 19-6.

 

Look at the P-V plot below.  This is the same as the plot shown in McQuarrie and Simon Figure 19.5.  This plot was made with Igor.  A similar plot can be made using Maple.  At the Maple prompt type in the commands

>with(plots):plot({0.082*300/v,0.082*300*1^(2/3)/v^(5/3),0.082*300/1},v=1..10);


You should get the following plot

The colors may differ in your version of Maple.  Here green is an isotherm, red is a constant pressure path, and yellow is an adiabatic path.  Calculation of the isothermal path is just RT/V (assuming one mole of gas and T = 300 K).  R = 0.082 L-atm/mole-K.  The second function is derived from the above calculation for an adiabatic path.  To plot an adiabatic path we use


T1 and V1 are simply initial constants (here V1 = 1).  I have defined V2 as v in the above function.  Once you have worked through this and read section 19-5 you should return to section 19-4 to try to understand the paths with insight into the adiabatic path.

The microscopic interpretation of work and heat

          The internal energy can be expressed as a sum over microscopic states, Ej multiplied by the probability the any given state will be occupied, pj.

The probability is given by the Boltzmann distribution is pj = e-bEj/Q.  According the definitions given above the average internal energy has N, V, and T fixed.  We differentiate U to obtain:

 

We can express the first term as the work and the second term as the heat.

We use the trick that we can rewrite dE as (E/V)dV to show that the work term involves a volume change.  In order for dw = - PdV to be the definition of work we require


 


Where the angle brackets represent averaging over populations as indicated by the sum Spj.  Reversible work results from a change in the allowed energies of the system, without changing the probability distribution of its states.  Reversible heat results from a change in the probability distribution of the states in the system without changing the allowed energies.

Enthalpy is the constant pressure heat

          If the volume change is zero (DV = 0), then the work is zero and the internal energy change is equal to the heat exchanged between the system and surroundings

DU = qv

where the subscript v indicates a constant pressure process. DU is measured experimentally at constant volume (e.g. in a bomb calorimeter).

          Many chemical processes are carried out at constant pressure.  We define the heat exchanged at constant pressure as the enthalpy, DH.

  DH = qp

The enthalpy is a new state function that plays the same role for a constant pressure process that DU plays for a constant volume process.  The relationship between the enthalpy and the pressure is H = U + PV.  This expression (also known as a LeGendre transform) allows for a change of variables from U(V,T) to H(P,T).  In general, we can write

DH = DU + VDP + PDV

But since DP = 0 for a constant pressure process we have

DH = DU + PDV

There is latent heat associated with phase transitions.  This is known as the enthalpy of phase transition.  For example, for the melting of ice qp = 6.01 kJ/mol and for the boiling of water qp = 40.7 kJ/mol.  The volume change upon melting of ice is small.  Therefore, DH = DU for this process.  The volume change upon boiling is large therefore DU < DH by an amount PDV.  This accounts for the fact that work must be done against the atmosphere in order for water vapor to form.

For a process that involves and ideal gas PDV = DnRT + nRDT.  A phase transition occurs at constant temperature and we have

DH = DU + DnRT

In this expression Dn represents the change in the number of moles in the gaseous state.

Dn = (moles of gas products) – (moles of gas reactants)

 


Heat capacity is a path function

          The value of the heat capacity depends on whether we heat a substance at constant pressure or constant volume.  Therefore, it is a path function.  If a substance is heated at constant volume, the energy added as heat is qv and the heat capacity is called Cv.  Because DU = qv, Cv is given
by


If a substance is heated at constant pressure, the energy added as heat is qp and the heat capacity is called Cp.  Because DH = qp, Cp is given by

Cp should be larger than Cv since in addition to the heat added in both, work must done to expand against atmospheric pressure in a constant pressure process.

For an ideal gas we have relationship H = U + PV or as we saw above (since PV = nRT) we can write

 

                                                          H = U + nRT

 

Take the derivative of both sides with respect to temperature.


 


According to the definition we can write this as

 

                                      Cp = Cv + nR

Temperature dependence of enthalpy


          In general the heat capacity at constant pressure is also a function of temperature, Cp(T).  We can use this function to determine the temperature dependence of the enthalpy


If we set T1 = 0 K then we can calculate the enthalpy at any temperature T relative to 0 K provided that we also include the latent heat of phase transitions.

Where DfusH is the enthalpy change of fusion (melting).  The enthalpy change is smooth and continuous until a phase transition is reached where there is an abrupt jump.

This implies that Cp is also discontinuous at a phase transition.