# Second order all-pass filter using a single op-amp

Is it possible to build an active second order all-pass filter using a single op-amp and no inductors? After Googling it I've found no less than three different circuit topologies, but when simulating them they all have a non-flat frequency response. I've also tried analysing them using some simple Laplace transforms and some algebra, but have failed to get anything similar to the transfer function that a second order all-pass filter should have. This might be because the algebra does get slightly messy, and I don't handle messy algebra very well when tired.

It would be great if such a circuit does exist, as I'm (purely for fun) designing a phasing network to obtain a fairly flat 90 degrees phase difference (quadrature) in the output over a fairly wide range of frequencies, to be used in a phasing SSB receiver for side-band rejection. Currently I'm using a software (called QuadNet) that outputs a phasing network for me, but it uses first order segments, which results in a whole lotta op-amps. The goal is to halve the necessary number of op-amps.

Just for reference; the transfer function of an all-pass filter takes on the following form $$\frac{s^2-As+B}{s^2+As+B}.$$

To be clear, I'm simply looking for a circuit topology that provides this transfer function (2nd order all-pass filter) using a single op-amp and no inductors, and nothing else. Assuming ideal components is totally fine for my purposes.

I'm eagerly awaiting enlightenment!

• Well, no op-amp is going to have a flat response across all frequencies. What range do you need a flat response across? May 21, 2017 at 20:17
• Well, that's obviously true, but it only needs to be flat in a part of the audible range, so max 20 kHz. Assuming ideal components during the design phase is totally fine for this application.
– Fors
May 21, 2017 at 20:22
• What I want is a circuit that provides a transfer function of the same form as in my initial question. These circuit "segments" will then be stacked and put in parallel to provide a fairly flat phase difference between something like 150 Hz and 6 kHz. The magnitude must be flat in this area as well, but ideally as flat as possible everywhere (as provided by an all-pass filter). The circuit in the link that you provided is a first order all-pass filter, which is what I'm currently using. Two of these in series yield a second order filter, but I'm looking for a way to eliminate one op-amp.
– Fors
May 21, 2017 at 20:32
• Ok, great, that clarifies things. Might be worth putting some of that into your question. May 21, 2017 at 20:37
• @Fors "These circuit "segments" will then be stacked and put in parallel to provide a fairly flat phase difference between something like 150 Hz and 6 kHz." This is a common technique for SSB modulation. Have you looked into that? May 22, 2017 at 1:33

One option for a second order all-pass filter with one OpAmp is the Delyiannis structure, as shown here (p.2): The transfer function of this filter is given by

$$H(s)=\frac{R_4}{R_3+R_4}\cdot \frac{s^2-s\frac{2}{R_2C}+\frac{1}{R_1R_2C^2}}{s^2+s\frac{2}{R_2C}+\frac{1}{R_1R_2C^2}}\tag{1}$$

where

$$\frac{R_2R_3}{R_1R_4}=4\tag{2}$$

must be satisfied.

For a given center frequency $\omega_0$, a given quality factor $Q$, and a chosen value of $C$, the resistors $R_1$ and $R_2$ must be chosen as

$$R_1=\frac{1}{2Q\omega_0C},\quad R_2=\frac{2Q}{\omega_0C}\tag{3}$$

and $R_3$ and $R_4$ must be chosen to satisfy $(2)$. One possibility (as suggested in above document) is $R_1=R_3$ and $R_4=R_2/4$. (Note there is an error in the definition of $R_4$ in the document cited above).

From Eqs $(2)$ and $(3)$ it is straightforward to show that the filter gain is related to the quality factor $Q$ by

$$g=\frac{R_4}{R_3+R_4}=\frac{Q^2}{1+Q^2}\tag{4}$$

• Thanks a lot! The phase response I get when replacing two first order networks is spot on in my simulation, but alas, that gain of R4/(R3+R4) makes it tricky to work with, and it's seems to be more finicky with regards to component tolerances (as it affects both the flatness of the gain as well as the phase response). I suppose that is the trade-off here, there's no such thing as a free lunch in this world.
– Fors
May 21, 2017 at 23:23
• Since you're paralleling these filters, can you normalise the gains in your (presumed) summing amplifier stage? May 21, 2017 at 23:34
• That's certainly a possibility, but the accumulated gain loss seems to be quite large, so I do worry about adding unnecessary noise when recovering the gain. I will certainly look into using this Delyiannis structure with gain normalisation, but I'm leaning towards using first order stages.
– Fors
May 21, 2017 at 23:49
• An alternative allpass topology can be derived from the Sallen-Key bandpass filter using the "complementary approach". For this purpose, the "normal" bandpass input is grounded and the signal is fed into the grounded nodes.
– LvW
May 22, 2017 at 6:33
• @LvW: I suppose you mean using the relation $H_{AP}(s)=1-2H_{BP}(s)$, where $H_{AP}$ and $H_{BP}$ are allpass and bandpass transfer functions, respectively. However, I don't see how to do this with a Sallen-Key BP in the way you described. By exchanging input and ground you effectively get a new transfer function $H(s)=1-H_{SK}(s)$ (where $H_{SK}(s)$ is the transfer function of the Sallen-Key BP). But since the Sallen-Key filter is an inverting BP, we have $H_{SK}(s)=-c\cdot H_{BP}(s)$, and we obtain $H(s)=1+c H_{BP}(s)$ (instead of a minus sign), which is not an allpass filter. May 22, 2017 at 13:06

Her comes my circuit: simulate this circuit – Schematic created using CircuitLab

1.) The first diagram shows the classical Sallen-Key bandpass. The bandpass transfer function Hbp can be transferred into the corresponding allpass function Hap using the relation Hap=1-Hbp for the special case gain=2 (RR=R0).

2.) This complementary relation between both functions is identical to (a) grounding the bandpass input and (b) lifting all grounded bandpass elements and use it as input for the allpass circuit. This circuit is shown in the second diagram.

• For this all-pass filter RR=R0; C5=C3=C; R1=R; R2=2*R; R4=4*R; Delay time = 5*R*C. Aug 2, 2022 at 13:11