Why does parasitic capacitance influence high frequency Dc-Dc switching?

From my understanding, Dc-Dc switching means turning something between 0 and some Dc voltage value. In doing that fast enough we obtain an equivalent Dc voltage value (pwm principle).

When talking about capacitor impedance, the relations is:

In example in the image below, if we imagine that the voltage source is switching DC power source, instead of a sinus, that gives a signal as one on the image below:

In that scenario, a current would never flow.

Doesn't that imply that the impedance of the capacitor is always infinite regardless of the frequency of switching?

If that is true, what does the suggestions not to do Buck-Boost circuits on breadboards?

• You use the words switching frequency doesn't that give you a hint? A simple analysis or basic research would show that any switched pulse is made up from a dc component plus ac component with lots of harmonics. – JIm Dearden Sep 23 '16 at 16:43

In that scenario, a current would never flow.

Of course current flows through a capacitor each time the pulse rises and falls. For a capacitor Q=CV and differentiating on both sides to obtain current we find that: -

I = C dv/dt because dq/dt = current.

In other words when the voltage edge is sharp (high dV/dt) the current can be very large if not limited by some series resistance or an inductor.

It is for this reason that the current into a capacitor from a sine wave voltage source is shifted by 90 degrees into a cosine wave - it's all down to the maths behind differentiation of voltage (dv/dt).

• Fair, I oversimplified that for current flow there has to be a energy loss in the source over time. – TheMeaningfulEngineer Sep 23 '16 at 16:57

It is important to realize that the square wave pulse you put a figure on actually has a number of different frequencies in it.

This shows the first few terms of the Fourier series of a square wave. As you keep adding terms (which are each higher and higher in frequency), you get a better and better approximation to a square wave.

The series can be written down as:

$$f(x) = \frac{4}{\pi} \sum_{n=1} \frac{1}{2n-1} \sin\left(\frac{(2n-1) \pi x}{L}\right)$$

(from here)

So, when a capacitor is being driven by a square wave, the impedance acts (mostly) independently on each of these different sine waves.

At high frequency, any stray capacitance or inductance (which is also pretty big in breadboards) acts on the waveforms. For some of these frequencies, the combination can cause ringing (when you create resonant circuits with the capacitances and inductances). A capacitor followed by a resistor to ground also looks like a differentiator, creating current spikes where the voltage changes suddenly. All these things can cause problems, making breadboard SMPSs hard to get right (though I have gotten a very noisy one working with some lower frequency controllers).

• The square I gave as an example never changes direction (goes to negative). That is the point of the confusion – TheMeaningfulEngineer Sep 24 '16 at 2:18
• @Alan: Voltage is a relative thing. You can set the voltage to be zero wherever you want. – Andrew Spott Sep 24 '16 at 4:59

Current does flow due to parasitic C as Andy and Andrew have covered.This effect is generally bad because on an orthodox hard switched PWM convertor it means power loss because the capacative energy is not recovered .This equates to extra losses that are proportional to frequency that are often lumped in to Total Switching Losses.The peaky wave shapes of these capacitive currents leads to EMC issues . The parasitic inductance of the PCB traces and the leads can and does lead to ringing which if not damped can give peaks in your radiated EMC plot .Generally speaking the capacitance of mosfets , diodes and coils totals to more than the PCB capacitance .Schemes that utilise this capacitance are more efficient and are quieter .