= Solution
Use positive current in the charging direction and passive voltage drops across $R,L,C$. The five ideal elements obey
$$
\boxed{v_{\rm battery}=V_0,\quad v_R=RI,\quad v_L=L\frac{dI}{dt},\quad I=C\frac{dv_C}{dt}.}
$$
The battery maintains its emf independently of current. An ideal open switch has $I=0$ with its voltage unconstrained; an ideal closed switch has $v_{\rm switch}=0$ with its current unconstrained. These statements are the switch's piecewise current-voltage relation. <Inductor current continuity> and capacitor-voltage continuity hold when no impulse voltage or current is imposed.
Back to article page