Originally Posted by de.das.dude
also once again his graph is only possible as the cap already has some charge in it when the switch is connected. start the circuit on an empty cap and it WILL show a zero voltage spike.
The cap is at 0v when powered on. The 100ohm resistor keeps it discharged and the emulator also assumes caps are at 0v when the emulator is started. I started it with the switch open then closed and reopened the switch to produce the wave form shown.
If I place the scope across the resistor/cap you will see the exact opposite waveform as the cap charges from 0v to 6v.
EDIT - Here is the charge curve on the cap as the switch is closed then opened. It starts at 0, charges to 6, then discharges back to 0 by the 100ohm resistor in parallel with it.