The first law of thermodynamics

Engineering · Second-year university engineering · about 10 min

Heat and work are two ways energy crosses the boundary of a system. The first law makes sure energy is accounted for rather than created or lost. In a closed-system problem, it connects the energy transferred during a process to the change in energy stored within the system.

The key idea

For a stationary closed system with negligible kinetic and potential energy changes,

ΔU=Q−W\Delta U=Q-W

Here ΔU\Delta U is the change in internal energy, QQ is heat transferred into the system, and WW is work done by the system.

A vertical piston-cylinder assembly with fixed side walls and a movable horizontal piston enclosing gas beneath it. Draw a dashed closed boundary just inside the gas space, including only the gas as the system. Draw a wavy heat arrow through the left cylinder wall pointing into the gas, annotated Q > 0. Draw an upward displacement arrow above the piston and a separate outward work arrow from the gas through the piston boundary, annotated W > 0. Show an external load pushing downward on the piston in the opposite direction. Indicate internal-energy change as a text label inside the gas without assigning any value.
Heat enters the gas system while expansion work leaves it.

Choose the system boundary

A closed system contains a fixed amount of matter: energy can cross its boundary, but mass does not. A gas confined under a moving piston is a useful example. Select the gas as the system and draw a boundary around it. Heat supplied by a heater is positive QQ; heat rejected by the gas is negative. Expansion work done on the surroundings is positive WW; compression work done on the gas is negative. The sign convention must be stated before using the energy equation, because some courses use the opposite sign for work.

Boundary work for a piston

When a piston moves quasistatically against pressure pp, the boundary work is W=∫V1V2p dVW=\int_{V_1}^{V_2}p\,\mathrm{d}V. For a constant opposing pressure, the corresponding work is W=pext(V2−V1)W=p_{\mathrm{ext}}(V_2-V_1), provided the boundary movement is mechanically balanced as assumed. Expansion has V2>V1V_2>V_1, so this work is positive. Compression has V2<V1V_2<V_1, so it is negative. A convenient conversion is 1 kPa m3=1 kJ1\,\mathrm{kPa}\,\mathrm{m^3}=1\,\mathrm{kJ}. If the pressure varies, do not multiply a single pressure by the volume change unless that pressure is an appropriate average.

More general energy accounting

If speed or elevation changes significantly, use ΔU+ΔKE+ΔPE=Q−W\Delta U+\Delta KE+\Delta PE=Q-W rather than the simplified result. Internal energy is a property of state, while heat and work describe transfers along a particular process. As a result, for a complete cycle the system returns to its starting internal energy, and ΔU=0\Delta U=0, even though net heat and work transfers may both be nonzero. Before substituting numbers, list the transfers with their signs and check that all terms use the same units.

Worked example: Heating gas beneath a moving piston

A gas in a closed piston-cylinder device expands against a constant external pressure of 150 kPa150\,\mathrm{kPa}. Its volume rises from 0.10 m30.10\,\mathrm{m^3} to 0.30 m30.30\,\mathrm{m^3} while 80 kJ80\,\mathrm{kJ} of heat enters. Ignore changes in kinetic and potential energy. Find the boundary work done by the gas and its change in internal energy.

Two adjacent cutaway views of the same upright piston and cylinder, left labelled initial and right labelled final. Give the same cylinder cross-sectional area in both. Put the left piston low and the right piston three times as high above the bottom so the depicted gas volumes have ratio 1 to 3. Draw an upward expansion arrow from the initial piston elevation to the final one. Draw one rightward wavy heat arrow entering the gas in the final view and mark it as the total heat added during the process. On each piston draw an external downward pressure arrow, equal length in both views. Label the given initial and final volumes, constant external pressure and total heat input, but no calculated work or energy change.
The gas volume increases as heat enters against constant external pressure.
Show the solution

1. Mark heat and work signs. Heat enters, so Q=+80 kJQ=+80\,\mathrm{kJ}. The gas expands, so work done by the gas is positive.

2. Find the change in volume.

ΔV=V2−V1=0.30−0.10=0.20 m3\Delta V=V_2-V_1=0.30-0.10=0.20\,\mathrm{m^3}

3. Calculate boundary work.

W=pextΔV=(150 kPa)(0.20 m3)=+30 kJW=p_{\mathrm{ext}}\Delta V=(150\,\mathrm{kPa})(0.20\,\mathrm{m^3})=+30\,\mathrm{kJ}

4. Apply the first law.

ΔU=Q−W=80−30=+50 kJ\Delta U=Q-W=80-30=+50\,\mathrm{kJ}

Answer: W=+30 kJ\boxed{W=+30\,\mathrm{kJ}} and ΔU=+50 kJ\boxed{\Delta U=+50\,\mathrm{kJ}}. The gas stores more internal energy even after doing expansion work.

Common mistakes

Counting heat leaving as positive in the chosen convention.

Mark heat entering the system positive and heat leaving negative.

Giving expansion work a negative sign when using ΔU=Q−W\Delta U=Q-W.

With work by the system positive, expansion work is positive and is subtracted in the balance.

Assuming heat transfer equals internal-energy change.

Include work and any important kinetic or potential energy changes.

Using constant-pressure work when pressure varies significantly.

Use W=∫p dVW=\int p\,\mathrm{d}V or the correct process relationship.

Check your understanding

1. A stationary closed system receives Q=+25 kJQ=+25\,\mathrm{kJ} and has W=−10 kJW=-10\,\mathrm{kJ}. What is ΔU\Delta U?

2. An insulated, stationary closed system does 12 kJ12\,\mathrm{kJ} of work on its surroundings. What is its internal-energy change?

3. What is the internal-energy change of a closed system after it completes a full thermodynamic cycle?

Still not sure? Talk it through.

Waypoint Mentor's tutor explains this out loud, works through your own problems on a whiteboard, and checks you've got it. Free to start.

Explain this to me

Related topics