Heat Engine and Carnot Cycle Simulator
Run an ideal gas round a Carnot, Otto or Stirling heat engine cycle on a PV diagram, with the net work, heat flows and efficiency against the Carnot limit.
Simulator
- Efficiency Net work out divided by heat in.
- 50 %
- Carnot limit 1 - Tc/Th. No cycle between these two temperatures can beat it.
- 50 %
- Fraction of the limit How close this cycle gets to the ceiling the second law sets.
- 100 %
- Net work per cycle The area enclosed by the loop, which is why the shading is the answer.
- 2740 J
- Heat in
- 5481 J
- Heat rejected Never zero. Dumping heat to the cold side is what makes the cycle repeatable.
- 2740 J
- This cycle
- Carnot limit
Citing this tool
Last updated . Add the date you accessed it as well, which a citation of a page that can change asks for. If a specific result matters, cite the permalink from the tool’s share row instead of this page: it reproduces the exact parameters.
The equation
Carnot, Réflexions sur la puissance motrice du feu (1824)
The area is the answer
Work done by an expanding gas is ∫P dV, the sum of P times each small change in volume, so along any leg of the
cycle it is the area under that leg. Travelling to the right the gas
expands and does positive work. Coming back to the left it is compressed
and the work is negative. What survives the subtraction is precisely the
area between the outward and return paths, which is the area enclosed by
the loop.
That is why the shaded region is the result rather than a picture of it, and it is also why the direction matters. Traversed clockwise the loop produces net work and the device is an engine. Anticlockwise it consumes work to move heat from cold to hot, and the same diagram describes a refrigerator. No single state variable tells you which you are looking at.
Why there is a ceiling at all
The Carnot efficiency
η = 1 - Tc/Th
depends only on the two temperatures. Not on the gas, not on the machine, not on how cleverly it is built. The argument is short: if some engine beat it, you could use its surplus work to drive a reversed Carnot cycle and end up moving heat from cold to hot with nothing left over, which the second law forbids. The bound is therefore about what is thermodynamically possible rather than about engineering quality.
This has an uncomfortable consequence. To improve efficiency you must widen the temperature gap, and the cold side is usually the surroundings, so in practice you raise the hot side until the materials complain. That, and not inefficiency in the ordinary sense, is why power stations run their steam as hot as they can survive.
Rejected heat is not waste in the ordinary sense
The ledger beside the diagram splits the heat taken in into the part that became work and the part that was dumped. The dumped part shrinks as the cycle gets more efficient, but no arrangement of the cycle removes it.
The reason is that a cycle must return to its starting state to run again. Getting the pressure back down without undoing the work you just extracted means removing energy, and the only place to put it is the cold side. Rejecting heat is the price of repeatability, not a flaw in the design.
Three cycles, and what each one is limited by
Carnot is two isotherms joined by two adiabats, and it sits
exactly on the limit. Its problem is practical rather than theoretical: both
adiabatic legs span the same temperature range, so both change the volume by
the same factor, (Th/Tc)^(1/(γ-1)). At 800 K against 300 K with
a diatomic gas that is already 11.6 before the isothermal legs are added.
An enormous swept volume for a modest output is most of the reason nobody
builds one.
Otto is the petrol engine: two adiabats joined by two
constant-volume legs, with combustion supplying the heat at the top of the
compression stroke. Its efficiency is
1 - r^(1-γ), which contains no temperature whatsoever. Set the
cycle to Otto and sweep the hot side: the efficiency line is flat while the
ceiling above it rises. Raising the peak temperature buys nothing; raising
the compression ratio buys everything, and knock is what stops you around 11.
Stirling is the interesting one. Two isotherms joined by constant-volume legs, and provided the heat moved on those legs is recovered by a regenerator, it reaches the Carnot efficiency by a completely different route. It is the counterexample to the widespread belief that only a Carnot cycle can. Real regenerators are imperfect, which is where the shortfall in an actual Stirling engine comes from.
Common mistakes
- Thinking efficiency can be improved by using more gas. Every energy scales in proportion, so the ratio does not move. The amount slider demonstrates it.
- Believing only a Carnot cycle can hit the limit. An idealised Stirling cycle does too.
- Reading rejected heat as a defect. It is structural. A cycle that rejected nothing could not return to its starting state.
- Expecting a hotter petrol engine to be more efficient. Otto efficiency has no temperature in it at all.
- Confusing the enclosed area with the area under the curve. Under one leg is that leg’s work. Enclosed by the loop is the net work of the whole cycle.
- Assuming any closed loop is a valid cycle. A loop can close, conserve energy and obey the gas law at every point and still not be the cycle you named. Carnot in particular requires the two isothermal volume ratios to be equal.
Model and assumptions
- Method
- Exact expression, no time stepping
- Repeatability
- Deterministic. The same link gives the same numbers on any machine.
What it assumes
- An ideal gas taken around a closed quasi-static cycle, so every point on the path is an equilibrium state.
- Net work per cycle is the area the loop encloses, computed from the path rather than measured from an animation.
- No friction and no heat leakage, so the only irreversibility is the one the chosen cycle implies.
Where it stops holding. Any real engine, where finite-time processes are not quasi-static and the efficiency falls below the cycle’s ideal value.
Numerical accuracy
No method error to report: the result is a closed-form expression evaluated directly, with no time stepping to accumulate error. What remains is double-precision rounding, of order one part in 10^16 per operation.
Common questions
Why is the area inside the loop the work done?
Work is the sum of pressure times each small change in volume, the integral of P dV, so along any leg it is the area under that leg. Going right the gas expands and does positive work; coming back left it is compressed and the work is negative. Subtracting one from the other leaves exactly the area between the outward and return paths, which is the area enclosed. That is why the shading is the answer rather than an illustration of it.
Why can no engine beat the Carnot efficiency?
Because a more efficient engine could be run alongside a reversed Carnot cycle to move heat from cold to hot with no net work, which the second law forbids. The limit is 1 minus Tc over Th and it depends only on the two temperatures, not on the gas or the machine. Every cycle here is checked against it.
Why does a real engine reject so much heat?
Because it has to return to its starting state to run again, and getting the pressure back down without undoing all the work means dumping heat. The ledger beside the diagram shows this: the rejected slice gets smaller as the cycle gets more efficient, but it never reaches zero. It is the price of a repeatable cycle rather than a manufacturing defect.
Why does raising the peak temperature not help a petrol engine?
Otto cycle efficiency is 1 minus r to the power of 1 minus gamma, which contains no temperature at all. Only the compression ratio and the gas matter. Set the cycle to Otto and sweep the hot side: the efficiency line stays flat while the Carnot ceiling above it climbs. Real engines are limited by knock and by materials, which is why compression ratios stop around 11.
Can any real cycle actually reach the Carnot efficiency?
An idealised Stirling cycle does, which surprises people who assume only a Carnot cycle can. It uses two isotherms joined by constant volume legs, and provided the heat moved on those legs is recovered by a regenerator, only the isothermal heat counts. Select Stirling and compare the efficiency with the limit. A real regenerator is imperfect, which is where the gap comes from.
Why does the Carnot volume ratio get so large?
Both adiabatic legs span the same temperature range, so both change volume by the same factor, and that factor is the temperature ratio raised to 1 over gamma minus 1. At 800 K against 300 K with a diatomic gas that alone is 11.6, before the isothermal legs are added. Needing an enormous swept volume for a modest power output is a large part of why nobody builds one.