Change of frequency in a capacitor when switch closes
This looks a little bit like a Tesla coil circuit. Initially the switch charges a capacitor from a low frequency voltage source, then at some time the switch changes over and discharges the capacitor through a resonant transformer.

In the first position the frequency is entirely dictated by the voltage source Vg and may be low, e.g. 60Hz. When the switch changes over then Vg is completely removed from the circuit. The energy that has been stored in the capacitor C1 is released into the coupled transformer circuit. This part of the circuit has a self-resonant frequency which is nothing to do with the source frequency. 

The things that set the output frequency are the values of C1, C2, L1, L2 and the coupling constant k. Normally as you show in the bottom trace, in such circuits, a high frequency oscillation occurs and the energy transfers back and forth at a lower rate from the primary to the secondary of the transformer resulting in a modulated sinusoid. If k is low then the rate of modulation is slower. The oscillation frequency has no relation to the original input frequency of Vg. In a Tesla coil arrangement the primary capacitor and primary inductor values form one resonant circuit, while the output coil and the capacitance of that coil plus any top loading form the other resonant circuit. For best operation they are chosen to be quite similar frequencies. The input frequency Vg can be 60Hz, e.g. from a neon sign transformer, while the output frequency might be 300kHz for example. The approximate output frequency is $$1/(2\pi \sqrt{LC})$$ where L and C are L1,C1, or L2, C2. This is assuming the product L1 C1 is similar to L2 C2. It's a little bit like periodically hitting a bell; you might strike it once per second but the pitch of its ringing is intrinsic to the bell itself.