A capacitor of capacitance C is charged by a battery of emf E and internal resistance r. A resistance 2r is also connected in series with the capacitor. The amount of heat liberated inside the battery by the time capacitor is charged to 50% of its steady state value is given as