In order to have the consistency in the last equation, the heat q 2 flown from the engine 2 to the intermediate reservoir must be equal to the heat q 2 ∗ ∗ flown out from the reservoir to the engine 3.