Work done by reversible and irreversible process Reversible work is greater than irreversible work and the examples given in the book are isothermal reversible work and isochoric irreversible work. The explanation is as following.

"More work is obtained when the expansion is reversible because matching the external pressure to the internal pressure at each stage of the process ensures that none of the system’s pushing power is wasted. We cannot obtain more work than for the reversible process because increasing the external pressure even infinitesimally at any stage results in compression. We may infer from this discussion that, because some pushing power is wasted when $\mathbf{p > p_{\textbf{external}}},$ the maximum work available from a system operating between specified initial and final states and passing along a specified path is obtained when the change takes place reversibly."

I understand the mathematical interpretation of work done by reversible and irreversible process. But I don't understand the above physical interpretation. The highlighted parts are unclear to me.

 A: Think of an ideal gas as behaving like an elastic spring and a viscous damper joined in parallel, with the spring representing the (non-dissipative) PVT behavior of the gas and the damper representing its viscous behavior.  Initially, the system is in equilibrium, with the spring preloaded in compression (by an external force).  If you ease up very gradually on the external force, you get maximum work from the spring-damper combination, because the viscous damper contribution to the overall force (which increases directly with how rapidly the combination is extending) is negligible.  However, if the external force is dropped suddenly to a lower value, part of the work that the spring could have done is used up in extending the (dissipative) damper.  The presence of the viscous damper reduces the force that the combination can exert on their surroundings.  This is very much analogous mechanistically to what happens in reversible and irreversible gas expansions and compressions.
A: Definition [Heat engine]
A heat engine is a cyclic device that converts heat into work by exploiting a difference in temperature between two reservoirs.
Here, "cyclic" means that the device periodically returns to its initial state.
Let us model such a device as a system $\mathcal{S}$ coupled to three auxiliary systems


*

*A reservoir $\mathcal{R_h}$ at high temperature $\tau_h$,

*A reservoir $\mathcal{R_l}$ at low temperature $\tau_l$

*An auxiliary system $\mathcal{S}'$ on which $\mathcal{S}$ can do work.


Over the course of a cycle, the device takes in heat $Q_h$ at high temperature $\tau_h$, does some work $W$ on $\mathcal{S}'$, and ejects heat $Q_l$ at low temperature $\tau_l$. By conservation of energy, we have
\begin{equation}
Q_h = W + Q_l.
\end{equation}
Let us assume the device operates reversibly. This means that the change in entropy of the system must be zero over the course of a cycle. 
The entropy increase accompanying the intake of $Q_h$ is $\sigma_h = Q_h/\tau_h$, and the entropy decrease accompanying the output of $Q_l$ is $\sigma_l=Q_l/\tau_l$. Overall, we must have
\begin{equation}
\sigma_h = \sigma_l \\
Q_h/\tau_h = Q_l/\tau_l.
\end{equation}
From here, we can solve for $W$ in terms of $Q_h$:
\begin{equation}
W = Q_h (1-\tau_l/\tau_h) = \frac{\tau_h-\tau_l}{\tau_h} Q_h = \eta_C Q_h.
\end{equation}
The quantity $\eta_C$ is called the Carnot efficiency. It gives the fraction of heat that can be converted into work by a heat engine operating reversibly.
Suppose now that the heat engine operates irreversibly, so that there is some entropy production inside the engine. For example, at some point the engine could allow gas to expand suddenly into a larger chamber, or friction inside the engine could directly turn work into heat. Because entropy must increase, in this case we have
\begin{equation}
\sigma_h \leq \sigma_l \\\
Q_h/\tau_h \leq Q_l/\tau_l\qquad\textrm{(irreversible engine)}
\end{equation}
Solving for $W$ in this case, we have
\begin{equation}
W = Q_h - Q_l \leq Q_h (1-\tau_l/\tau_h) = \eta_C Q_h\qquad\textrm{(irreversible engine)}.
\end{equation}
Thus, heat engines operating irreversibly have a lower energy conversion efficiency $W/Q_h\leq \eta_C$.
I take no credit for this writing The source for this is the 2019 lecture notes for Caltech's Ph12c Stat Mech class taught by David Simmons-Duffin.
