Discharge of a capacitor : energy viewpoint
Using applets