The simple circuit below, consists of a battery with constant electromotive force (efm), $\epsilon_0$, a capacitor which capacity varies with time $C(t)$ and ,to make it simple, ideal wires (zero resistance).
When the switch is closed, the capacity of the capacitor changes with time in a way to maintain current $I_o\;$ constant.
As shown below, the stored energy power in the capacitor is half of the discharge energy of the battery (which I will prove it below). What happens to the other half?
Battery discharge power at any time: $P_{battery}=\epsilon_oI_o$
Stored energy in the capacitor: $U_{stored}=\frac{1}{2}C(t)\; \epsilon_o^2\;$. So, by diffentiating with regards to $t$, we obtain the stored power in the capacitor: $P_{stored}=\frac{1}{2}\; \frac{dC(t)}{dt}\; \epsilon_o^2\;\;$ (eq.1).
On the other hand, for the capacitor: $q=C(t) \;\epsilon_o$, by differentiating with respect to $t$, it gives $I_o= \frac{dC(t)}{dt}\;\epsilon_o\;\;\;$(eq.2).
By substituting $\frac{dC(t)}{dt}$ from (eq.2) in (eq.1), we have: $P_{stored}=\frac{1}{2} \epsilon_oI_o\;$
So, $P_{stored}=\frac{1}{2}P_{battery}$. Where has the other half of $P_{battery}\;$ gone?
Note: This question is not duplicate of A problem of missing energy when charging a second capacitor because in that question, energy is lost due to radiation damping of oscillating charges or other ways, while in my question here that is not the case, if you add a resistance to this circuit, it still can be shown the energy lost in the resistance plus the energy stored in the capacitor is half of the discharge energy of the battery.