Basic Frequency Control Circuit

How does R4 prevent the output voltage drifting towards one of the supply rails to the op amp? I understand that R4 has to have a high resistance but I do not know why?

Here is the schematic which is puzzling me:

The link to the CircuitLab schematic:

https://www.circuitlab.com/circuit/x66cq6/basic-frequency-control-circuit/

-
That looks like a Circuit Lab schematic! It would be great if you could post a link to the schematic so that answerers could edit, highlight, and reconfigure it if necessary. –  Kevin Vermeer May 14 '12 at 18:13
I love Circuit Lab, but for some reason I cannot save anything I have drawn on it. Otherwise I would, any suggestions on how to save and I would gladly post a link –  user1083734 May 15 '12 at 8:30
I've since found out that the save functions aren't supported by the Chrome I'm using, I will post a link once I have redrawn using Firfox –  user1083734 May 15 '12 at 8:59
circuitlab.com/circuit/x66cq6/basic-frequency-control-circuit I have changed the capacitors to 2nF –  user1083734 May 15 '12 at 9:14
@user1083734 shame on CircuitLab not supporting Chrome! –  abdullah kahraman May 15 '12 at 11:00

With R4 removed, there is no DC feedback path from the op-amp output to the input. So if the b node drifts away from ground, there's nothing the op-amp can do to drive it back towards ground (which it will try to do to keep the two inputs equal). If b drifts high, the output will tend to rail negative, and if b drifts low the output will tend to rail positive, according to the open-loop gain of the op-amp.

With R4 in place, you have a DC feedback path. If b drifts high, the op-amp output can go a little bit low and pull it back to ground. If b drifts low, the op-amp output can go a little bit high and pull it back to ground.

Put in more jargonistic terms, with R4 removed the DC circuit is an open-loop amplifier. With R4 in place, the DC circuit is a voltage follower.

-
I understand that this circuit could be used as a treble control circuit with treble gain occuring when R3 is set so a=b, and treble attenuation occuring when R3 is 22kOhms across a and b. When comparing this circuit to high and low pass filters, I do not understand what is happening: C2 will always have a lower impedance for high frequencies and so surely adjusting R3 will only alter positive gain for high frequencies. Can you help me understand this, or should I post a new question? –  user1083734 May 16 '12 at 8:52
It would make more sense to make it a new question --- partly because there's other people here who know much more about audio than I do. –  The Photon May 16 '12 at 16:19

Without R4, you do not have any DC feedback because the only negative feedback path is through a capacitor. Without DC feedback, you don't have a stable DC operating point.

If R4 has a low resistance (let's say, for the sake of argument, zero). In this case, all the negative feedback goes through R4 (path of least resistance) and the R2/C2 branch of the circuit does nothing.

Intuitively, though, the 4.7 Megohm choice for this resistor seems quite high. For this to work well, you need an op-amp with a very high input impedance (e.g. JFET input).

The idea in this circuit is that R4 conveys the DC output voltage from the output of the op-amp to the non-inverting input, and the impedance at that input is so high that it draws nearly zero current, allowing such a high valued resistor to be used.

Even without doing any calculations, I think a much lower resistance for R4 would still work there.

-
So, would you say a 1MOhm resistor would be more appropriate? I was told that if it were too low, the circuit would not work correctly. –  user1083734 May 15 '12 at 8:35
Pick a frequency, like 100Hz and compute the capacitive reactances of C1 and C2 at that frequency. (The reactances at 1000Hz and 10,000Hz are then just 10x and 100x smaller.) From the reactances you can determine the impedances of various branches of the circuit at those frequencies, giving you a sense of what the signal is facing, and how significant is a given value of R4 in that picture. –  Kaz May 15 '12 at 21:08
Many thanks for clearing this up :) –  user1083734 May 16 '12 at 8:24
I understand that this circuit could be used as a treble control circuit with treble gain occuring when R3 is set so a=b, and treble attenuation occuring when R3 is 22kOhms across a and b. When comparing this circuit to high and low pass filters, I do not understand what is happening: C2 will always have a lower impedance for high frequencies and so surely adjusting R3 will only alter positive gain for high frequencies. Can you help me understand this, or should I post a new question? –  user1083734 May 16 '12 at 8:52
@user1083734 It's not clear what you mean, but your assessment is right. The circuit's control does not sweep over the frequency range. It is just gain for high frequencies, a treble control. –  Kaz May 16 '12 at 15:11

I agree with what the others have said about what R4 does in the circuit. However, I would put it accross C2 only, not where it is now. That way the high pass filter rolloff frequency it causes won't change with other parameters in the system. For example, if you wanted the high pass rolloff to be 20 Hz, then a resistor just accross C2 would be 8.0 kΩ, so 10-15 kΩ would be good if this is audio.

Having the high pass filter rolloff too low causes long startup transients and glitches. You want to block frequencies below what you care about, but you also don't want the time constant to get to steady state operation to be too long. 1 µF and 4.7 MΩ is a time constant of 4.7 seconds, and it could take multiple time constants before the system settles to steady state operation. That's definitely unacceptable if this is a ordinary audio device.

-
Olin, I think you mean R4 across just C2, rather than C2 + R2, right? About the RC time constant, why would we care about C2 versus R4, when C2 is not charging through R4? Thanks. –  Kaz May 14 '12 at 21:49
@Kaz: Yes, sorry, that somehow got lost in scrolling back and forth between typing the answer and the schematic. Fixed. –  Olin Lathrop May 14 '12 at 22:39
I understand that this circuit could be used as a treble control circuit with treble gain occuring when R3 is set so a=b, and treble attenuation occuring when R3 is 22kOhms across a and b. When comparing this circuit to high and low pass filters, I do not understand what is happening: C2 will always have a lower impedance for high frequencies and so surely adjusting R3 will only alter positive gain for high frequencies. Can you help me understand this, or should I post a new question? –  user1083734 May 16 '12 at 8:53