Capacitor charging and discharging experiment design