Computation of the thermal efficiency of a Rankine Cycle