Solution (source code)

= Solution

The total <work> by the gas is the enclosed triangular area, $W=\tfrac12p_0V_0$. The positive <heat> on the sloping leg is
$$
 Q_{BC,+}=p_0V_0\int_1^{15/8}(15/2-4v)dv=\frac{49}{32}p_0V_0.
$$
Add $Q_{AB}=48p_0V_0/32$, excluding the emitting part of $BC$ and all of $CA$. Hence
$$
\boxed{Q_{\rm in}=\frac{97}{32}p_0V_0,\qquad\eta=\frac{W}{Q_{\rm in}}=\frac{16}{97}.}
$$
As an independent <conservation of energy> check, the <heat> emitted on late $BC$ is $p_0V_0/32$ and on $CA$ is $80p_0V_0/32$; thus $Q_{\rm in}-Q_{\rm out}=16p_0V_0/32=W$. Using only the net <heat> on $BC$ would give an incorrect <thermal efficiency>.