Placement of decoupling capacitors when driving a load through a long cable?

Common knowledge is that decoupling capacitors have to be close to the device that's being decoupled and connected with as short as possible connections, to provide a low inductance path.

Does this still hold true if the device that's being decoupled is driving a load through a long cable (= inductance)? One would think, if the current has to travel all the way through the long cable to the load and back again, a few extra centimeters between the decoupling cap and the device driving the load won't make much difference anymore?

Take, for example, Rod Elliott's Project 113 Headphone amplifier:

The op amp (U1A/B) had its own decoupling cap, C1. Then we have C4 and C5 to decouple the output transistors Q1L and Q2L. Since these transistors are typically driving the headphone's speaker through a long lead, is the placement of these decoupling caps on the PCB still critical?

• What does a decoupling cap do? – user253751 Sep 29 at 17:34

In this circuit the role of decoupling caps is to reduce power supply impedance.

A transistor wired as an emitter follower, as is the case here, can turn into an involuntary Clapp/Colpitts oscillator when collector impedance is inductive enough (due to long traces to the nearest decoupling cap) and layout parasitics (inductance/capacitance/coupling) adds enough of the wrong kind of feedback.

Having a capacitive load (in this case, a cable) makes things worse, although the 10R emitter resistors should be high enough to mitigate this.

Basically, suppose an emitter follower driving a load of impedance $$\ Z_L \$$ with a signal of amplitude $$\ A \$$ applied to the base. Suppose the emitter follower is ideal, thus the signal of amplitude $$\ A \$$ is present at the emitter. Thus emitter current into the load is $$\ A /Z_L \$$ , collector current is the same (neglecting base current). If its power supply at the collector has an impedance $$\ Z_S \$$ then AC voltage at the collector will be $$\ -A Z_S/Z_L \$$ ...

If $$\ Z_L = 1/jCw \$$ (capacitive) and $$\ Z_S = jLw \$$ (inductive) then AC voltage at the collector will be $$\ A L C w^2 \$$

Notice that since $$\ j^2 = -1 \$$ the sign flipped, basically the capacitive load and the inductive supply both add $$\ \pi/2 \$$ phase shift.

This means the signal on the collector due to the inductive power supply impedance has the same polarity as the input signal.

With the "right" conditions this can create positive feedback to the base, and your transistor will oscillate. An inductive power supply can also create LC resonances with the transistor's internal capacitance.

An illustration of this problem is attempting to repair an old amplifier where the output transistors are screwed on a heat sink and connected to the PCB via rather long wires, as was often done back in the day. This worked well with old, slow power transistors because their high frequency gain was low. But if you replace them with modern faster transistors, or even worse MOSFETs, which have gain up to much higher frequency, the wire inductance will may make them oscillate and they will blow.

So the decoupling caps are not really related to load inductance, but to supply impedance.

Note that modern 100µF caps with decent low ESR (a few ohms) and 2.5mm-5mm pin spacing have only a few nH stray inductance. If you don't have a ground plane, this is the same inductance as a bit of trace of the same length as the current path through the cap. And a 100nF thru hole cap having the same pin spacing as the electrolytic has the same inductance (but lower ESR). Thus, for this circuit, the 100nF ceramic caps would only lower power supply inductive impedance if they are much closer to the transistors than the electrolytics.

The longer the cable to load is, the more it will have capacitive load, so the placement of decoupling cap is even more important, to allow driving the capacitive load better.

• Side note, many op-amps oscillate with too much load capacitance. – rdtsc Sep 29 at 18:08

This is an audio output with estimated 1A hard limit (BD139 max current). The decoupling caps aren't avoiding oscillation with long cables. Instead they provide surge currents for transients. Electrolyte caps 100µ aren't fast enough for 10kHz and beyond if they're not low ESR types (equivalent series resistance). For audio projects it is sufficient to add a 100nF ceramic for this. This also provides a low resistance path for high frequency noise.

I assume the traces between the caps and output transistors are quite short (<10cm) so this won't be an issue unless they're very thin. And cable capacitance for 10m of audio cable into a 600Ω inductive load (speaker coil) is truely neglectible.