[Physics] Energy stored in a capacitor in an RC circuit

capacitanceelectric-circuitselectrical-resistance

Suppose we have a capacitor of capacitance $C$ and a cell of emf $E$, why is the maximum energy stored in a capacitor equal to $\tfrac{1}{2}CE^2$? I feel confused because, the potential difference against the capacitor will be less than the emf of the cell because of the potential drop across the resistor. What is the flaw in my thinking?

Best Answer

Once the capacitor has fully charged the current in the circuit will be zero, so the voltage drop across the resistor is zero and hence the voltage across the capacitor is equal to the cell voltage.

Having said this, the current falls exponentially with time so in principle the current takes an infinite time to fall to zero, and the voltage across the capacitor takes an infinite time to rise to $E$. However this is a somewhat pedantic position as in most cases the voltage across the capacitor will rapidly be indistinguishable from $E$.