The energy stored in the capacitors is U when S is open. Now S is closed