# Trying to understand a phase shift oscillator diagram

I can't fully understand this circuit below "Phase Shift Oscillator," especially the part about the three capacitors in the transistor base line and the three resistors.

I know that there is a switching on and off the transistor, but I don't know exactly how that happens.

What is happening in this part with respect to current behavior?

• One R is also part of the BJT biasing. So a design is a little bit nuanced. But without getting quantitative, the BJT is already going to provide 180 degrees of shift at the collector and one RC cannot quite get to a 90-degree phase shift by itself. You need a full 360 degrees so that the feedback is positive. Since one RC can't do 90 and therefore two RC's can't do 180, this means you need at least three RC's to get 180 degrees (when each gives 60 degrees.) There must be enough gain to make up for all the losses, too. That's about it. Can you follow quantitative analysis, if given? Jan 29, 2023 at 6:05
• unfortunately, that schematic uses 'dots' and line crossings inconsistently, so the circuit can't be read correcltly. This version on wikipedia is consistent for the frequency determining components, but is over-simplified for the BJT bias and so will not work as well. Where on the elprocus.com site is the article? Jan 29, 2023 at 6:30
• hey guys, i have read before about the informations that you given, but i am trying to understand the behavior and movement of current in the BJT base line with the three capacitors.
– user320546
Jan 29, 2023 at 8:09
• @Straight-Adhi there will be no oscillating current movement with the schematic you have drawn (read Neil's comment above). Jan 29, 2023 at 14:06
• @SamGibson thanks, that was going above and beyond. Jan 30, 2023 at 9:40

Do you know the general oscillation condition (Barkhausen)? It requires a loopgain - that is the gain around a closed loop - of unity (in practice somewhat larger) at one single frequency only.

As far as the phase shift within the closed loop is concerned, this is identical with a zero phase shift requirement. The common emitter gain stage - together with the third-order RC highpass - can provide zero phase shift at a certain frequency.

That is the general working principle of the circuit. Please keep in mind that there is no "switching" (as mentioned by you) and that it is not necessary (and it makes no sense) to analyze the "current behaviour". When properly designed, the BJT works as a voltage amplifier (well-known design) and the RC-network can be designed based on also well-known formulas.

The minimum required gain value can be found by finding the attenuation of the RC-network at the frequency where the phase shift of the RC-chain (loaded by the input resistance at the base) is 180 deg.

Finally, be aware that the oscillation amplitudes will be clipped (supply voltage rail) because the loop gain (somewhat) larger than unity is (a) necessary for a safe start of oscillation (and to cope for tolerances) and (b) will cause a continuously growing amplitude until it reaches the physical limits. But such a hard clipping can be avoided by introducing some non-linear devices which can provide a kind of "soft-clipping" (diodes, thermistors,...)

• I don't have much knowledge about oscillators. You said (there is no switching) you mean that the BJT will be always on?.
– user320546
Jan 29, 2023 at 9:50
• A transistor can be used (1) as a linear amplifier (always "on") with a fixed DC bias point or (2) as a switch. In harmonic oscillators (as in your circuit) it is always used as an amplifier,
– LvW
Jan 29, 2023 at 9:56
• Man, now I got more confused, I always thought that the amplifier output signal is an "AC" and that its occurs of the transistor switching between on and off, I thought that the transistor who generate the oscillation, it's seems that I'm very away from understanding.
– user320546
Jan 29, 2023 at 10:32
• When you try to understand how a harmonic oscillator (intended to produce a sinusoidal signal) works, you must try to first understand the principles of positive feedback and loop gain. Both are essential parts of Barkhausens oscillation condition.. More tan that, you must know how a transistor can work as a linear amplifier..
– LvW
Jan 29, 2023 at 12:37
• Transistors can be all the way off, all the way on, or somewhere in between. If the circuit is designed so the transistor is all on or all off, then you can just think of the transistor as a switch. If the circuit (like this one) maintains the transistor as somewhere in between, then it'll act like an analog amplifier -- so, basically, if it gets a small sine wave at the base, it'll produce a large maybe-sine wave at the collector. Jan 29, 2023 at 18:55

Let's start by redrawing that diagram so that it can be read, and work.

A dot joins two wires. This site uses a quaint old schematic editor where crossing wires are indicated by a bridge, as shown by the collector connection to C1. Normally, professional engineers do not use a bridge (time consuming and fiddly to draw, they can clutter the schematic) and just cross two wires without a dot. But, bridges are acceptable, especially if they are drawn for you automatically. To add extra redundancy into the drawing to avoid error, professional engineers will never draw a dotted connection of 4 wires, though there is the opportunity to do this at both the base and collector of the transistor. A four wire connection should always be shown as two, offset, T-junctions. However, you do sometimes see a dotted four wire connection, but be very suspicious of these.

simulate this circuit – Schematic created using CircuitLab

The circuit consists of two parts, the phase-shifting feedback network on the left, and the amplifier on the right.

# The Amplifier

I've given the amplifier some nominal components to get it biassed into a reasonable amplifying state. These values will give a very tame circuit which is tolerant to temperature changes, device selection and voltage rail, and still work. The absolute values of the components are not critical, but the ratios deserve some attention.

The R3/R4 ratio sets the base at about 1/3rd rail voltage. It could be higher or lower, but that's a good place to start. The values of these resistors will contribute to the input load of this amplifier, so should not be too small.

R6 establishes a current through the transistor, which develops a voltage across R5. They are the same value, so the DC voltage drop will be the same across each. So the VCC divides roughly into equal thirds, across R5, the transistor, and R6 (neglecting VBE, for a back of the envelope first pass). The value of these resistors sets the output impedance of this amplifier, so they should not be too big.

Finally the base voltage setting string is 10x or so times R5 and R6. The transistor beta sets the upper limit to this ratio.

Without C4, this amplifier has a gain of roughly -1, or more generally, -R5/R6. As this amplifier needs a high gain to make this oscillator work, we 'short' R6 at signal frequencies by a large capacitor C4. The gain is not now infinite, but is -R5/re 1, where re is the emitter slope resistance. re is about 25m/IE (at room temperature), which for VCC = 15 V giving IE = 5 mA will be about 5 ohms (plus any residual real series resistance in the transistor), so a gain of at least -100.

# The Phase Shift Network

Each RC (C1R1, C2R2, C3(R3||R4||Q1_effective_input_resistance)) gives us a phase shift of between 0 and 90 degrees depending on frequency.

As each stage loads the next, it's not straightforward to compute exactly what the phase shift and gain are going to be at any frequency. I'm sure if you search the web you'll find a honkin' great equation. To get you into the right ballpark, the frequency where the total phase shift is 180 degrees is going to be the order of 1/2piRC (certainly within a factor of 10, maybe within a factor of 3).

# Oscillating Condition

As the amplifier gives us a phase inversion, or 180 degrees phase shift, we need the feedback network to also give a 180 degree phase shift, so that the phase shift round the entire loop is zero.

At the frequency where this network gives 180 degrees phase shift, its gain IIRC is -1/29 (somebody link to the exact figure if you want).

In order to oscillate stably, the amplifier needs a gain of exactly -29, to give a loop gain of exactly 1. More gain than this, the oscillations will grow, less than this, they will die out.

So how do we maintain the loop gain at exactly -29?

There are oscillators that adjust the loop gain according to the oscillation amplitude, using peak detectors and controlled gain devices, or just thermistors or filament lamps that naturally vary their resistance with the power they are dissipating. These methods are used if we want nice clean sine-waves.

If we are not too fussy about the waveform that comes out, there is a far easier way to control the loop gain. Just let the amplifier overload, so it saturates against the rails2. While the amplifier is in its middle region, it has a finite gain, which is our case is around -100. Once it has hit the rails however, the gain drops to zero. If the amplifier spends some time with gain -100, and some time with gain zero, then on average it will have some lower finite gain. It will self adjust to produce just the right gain to maintain a loop gain of 1. If the gain is low, the amplitude falls, and it will spend more time in the high gain middle region. If the loop gain exceeds 1, the amplitude will grow, and the amplifier will spend more time with zero gain.

As the amplifier output is slamming against the rails, it may look like it is 'switching'.

It's quite common in this type of circuit to adjust the amplifier gain to only slightly more than is required for oscillation, say -35, so that instead of hitting the rails hard to shed a lot of excess gain, the amplifier only hits the rails softly. This results in a nearly sinewave output, with just slight clipping on the peaks. This could be done by adding a small resistor R7 between the transistor emitter, and the R6/C4 junction. The gain now approximates to -R5/R7.

# Starting

If you put this circuit into a simulator, there's every chance that it won't start to oscillate. If it does a good DC bias find before starting, then it may just sit there quietly doing nothing interesting. To start it in a simulator, you may need to give it a kick, by setting the initial conditions on one of the capacitors.

In the real world, it will always self start through noise. All the resistors in the circuit will be generating Johnson noise. This noise is down in the nV, so you won't measure it with a DMM. However, it will be amplified by the transistor. Noise at the right frequency to satisfy the oscillation criteria will pass through the RC network, and return to the transistor base larger than before (if the loop gain is above 1). And then the oscillations will grow, until whatever limiting mechanism we are using stops the growth.

(1) It's generally better to say the gm of the transistor is IE/25m, and the gain is RC.gm, but it's two sides of the same coin. I'm just anticipating the expected objections.

(2) Depending on how the transistor is biassed, it may limit symmetrically, so swinging between current going to zero with output voltage going to VCC (cut off), and the transistor voltage going to zero (saturated). This is what the above bias values were intended to achieve, putting the same voltage across R5 and the collector, to centre the collector voltage, and so maximise the output swing.

However, it is also possible to bias the transistor in an offset way so that it only cuts off, or only saturates. This is a design choice. An oscillator that limits by cutting off will generally be more stable (against rail voltage, temperature, transistor selection) than one that saturates.

Given that RC oscillators in general, and this RC oscillator in particular, are not usually intended to produce 'quality' signals, we rarely bother with exactly how it limits. When making a low noise LC oscillator however, biassing the amplifier to limit in cutoff only can make a huge difference to its quality.

The BJT is in common emitter so it has lots of voltage gain but 180 degree phase shift .The RC network has losses but where the passive network has 180 degree phase shift the BJT voltage gain exceeds the losses so oscillation occurs .The BJT does not have infinite Z in and does not have zero Z out so the actual frequency will not be exact from the formulae.

The load has some importance in the behavior of all oscillators.

Here is a simulation and drawing of "loop gain" (tool within FREE microcap v12).
One can see that the condition of oscillation is that R12 (the load) must be "equal" to ~ 8 kOhm for a good "sinewave" (distortionless) at the output.
If the load is much greater, the "oscillation" has "some harmonics, so distortion.

The grey curve is with load R12 = 7 kOhm.

Nyquist curve (open loop).

Bode plot for R12 = ~ 7 kOhm

And here are the results for 3 cases of load.

And to be complete ... with R12 = 100 kOhm.
Note the change of frequency and the distorsion.

• Antonio, I would prefer to use the term "gain" instead of "load" because a good design requires that the circuit is not load-sensitive (e.g. all opamp based oscillators). Furthermore, I have a question: You have simulated the loop gain (although you call it "open loop gain", a term which - as far as I know - is commonly used for the opamp alone, Aol). You have opened the loop at a node which requires application of the full Middlebrook method (voltage and current injection). Did you use this method ? I think, a simple test voltage will not give the correct loop gain response.
– LvW
Jan 30, 2023 at 9:01
• I use the tool included with microcap v12 and this tool really open the loop. I wil add in answer the waveforms for lower load and higher load. Ok for "gain" because load is paralleled with my R1 and I did not included it. Jan 30, 2023 at 9:05
• NB: "open loop gain" can be used for all systems with feedback, I think so. Jan 30, 2023 at 9:14
• Antonio, my question again regarding the microcap tool: Does it use the full Middlebrook method or the simplified one? It is obvious that it opens the loop. Regarding the various gain expressions, I think the following is comonly excepted: (a) "open loop gain" Aol for an active device, (b) "closed-loop gain" Acl for an active device with feedback, (c) "loop gain" for the gain of the complete loop (when it is open and corrected regarding DC bias and load at the opening).
– LvW
Jan 30, 2023 at 9:45
• The tool can use 2 methods (Middlebrook and Tian). Ok, it is "loop gain", corrected. Jan 30, 2023 at 10:45