Introduction to Acitve Filter Theory
In order to understand how active filters work, you should first understand 3 basic circuits: the voltage divider, the R-C circuit, and the op amp buffer stage. I'm going to go through each of these in great detail, because once you get them, you'll understand basic active filter principles, and won't need any equations to get a gut feeling of how each part of the filter works.
The Voltage Divider: Vout = Vin X (R2 / (Rtotal)), where Rtotal = R1 + R2
+ --------R1---
+ ---------R1------------O (Vout)
|
|
|
|
9V battery R2
= 9V
R2
|
|
|
|
- ---------------
GND
GND
This is used to decrease the voltage level of a signal. Remember that voltage is always measured BETWEEN TWO POINTS. In most cases, the signal (or voltage out) is measured in comparison to GND, so we leave out the GND 'wire' in the schematic because we always assume it's somewhere nearby. Whenever we want to connect to it in the schematic, we simply indicate so as in the above (second) figure, or with a triangle, or other symbol. Note, therfore, that the above two circuits are identical. In the second one, the minus terminal is defined as GND. Also in the second one, I put an extension from between the two R's labeled 'Vout.' Note that nothing is really 'coming out' of here - there's no place for the current to go. The current is simply traveling around the loop to GND as in the first depiction.
So what is the voltage measured at the out terminal in the above diagram? Current flows in loops from more + to more - voltages, then gets boosted back up to + by the battery, and goes around again (this is conventional current, not electron flow, but they can be considered in exactly the same way). The voltage will drop across each R as you travel around the circuit from the + terminal, to R1, to R2, then ground. It must be 9V at the + terminal, and zero at GND. If R1 and R2 are equall, you can expect that the voltage will have dropped 1/2 way, since this is 1/2 the 'distance' between the + and GND. However, if R1 were much greater than R2, you can see that the current will travel most of the total 'distance' through R1, with just a little hop through R2. In this case, the voltage measured at the output would be closer to GND (1Vout if Vin=9V, R1=8K, and R2=1K). When I look at this circuit, I dont think of any equations. I just see that 8K is a lot farther from the +9V than 1K is from GND (0V). Therefore, I know that the voltage here will be closer to GND (0V). Too see HOW MUCH closer, I then look at the ratio of resistors, get a gut feeling, and finally pull out a calculator if I must.
Note that Rt = R1 + R2 because the resistors are in SERIES. If both resistors spanned between the +9V and GND rails, they would be in PARALELL. In this case Rt = (R1 X R2) / (R1 + R2). For the simple case where R1 = R2 = 1K, we see that Rt = R/2, or .5 K. Just remember that two R's can be used in series to get twice the resistance, and two 2 R's can be used in parallel to get 1/2 the resistance.
Excercise:
-----------------
|
|
9 Volts
R
|
R <---------O Vout
|
|
-----(GND)-----
The two R's with the arrow pointing at them represent a potentiometer. A pot typically has three pins. The resistance across the outer 2 of them is constant (these are connected between the + and - of the battery in the above diagram). The resistance between the outer pins and the center pin (the wiper) will change as you dial the pot around. The wiper is connected to Vout in the above diagram. If you were to measure the voltage between Vout and GND as you dialed the pot around, what would you measure? (A: 9V when the wiper was dialed to the 'top' of the pot, 0V when dialed all the way to the bottom, 4.5V when dialed 1/2 way, and continuously variable in between all these points).
Further info found in any basic Physics text, or Mims' Radio Shack book: Getting Started in Electronics.
The R - C circuit:
---------R------
Vin O---------R---------------O Vout
|
|
|
9 Volt
C
=
C
|
|
|
-----------------
GND
A cap is two plates seperated by a dielectric. These two plates are not touching electrically, so current cannot flow BETWEEN the plates. However, this device can STORE charge, and also release it. The first part of the diagram shows an R-C circuit. When the battery is first connected, current will flow through the resistor to charge C1. As one plate recieves an electron, the other plate gives one up to complete the 'circular' current flow through the circuit. The rate of current flow will depend on the applied volatage level (Vin), the size of the resistor (resistance to flow), and how much the cap can hold (measured in Farads, or uF - this is the diameter of the 'charge bucket'). In this 'water analogy', the DEPTH of the bucket is the cap's voltage rating. Put in more volts than it can hold, and the bucket will burst (electrolytic caps can be made to explode if you force too much in - be carefull).
Lets start over before the battery is connected. We will connect a volt meter across the cap (between Vout and GND) before connecting the battery. At this point, the meter will read 0V. Lets make R very big (100K ohms). Now connect the battery. The cap will charge very slowly because of our giant R. Because the cap is charging so slowly, the voltage across the cap (our volt-meter reading) will rise very slowly. Do you see how this circuit is opposing fast changes in voltage at the output? This is a highcut (lowpass) filter! (a.k.a. an RC integrator). In summary, then, the voltage difference across C slowly increases as the C charges up.
Now lets swap the postion of the R and the C. In the first diagram, this really makes no difference. It would be just as easy to move the voltmeter to read the voltage across R instead of C. The second diagram, however, implies where the the volt-meter is reading (between Vout and GND). There, you must swap the postion of the R and C in your mind.
OK. Lets do the same thought-experiment. With R very large, and the meter reading the voltage across R, lets connect the battery (at time = 0). Vout immediately reads 9V - this is the voltage difference across R. Remeber how we measured the voltage diff across C at t=0 above and it was 0? Therefore, the entire drop is across R. Now, as C charges, there will start to be a voltage difference across C (just like above). This will reduce the voltage difference across R, so our reading across R will start to drop. When the cap is charged all the way, the entire drop will be across C, and there will be none acoss R. At this point, our meter will read 0V. Therefore, you can see that this configuration opposes a constant DC voltage (i.e. low freq's). This is a lowcut (highpass) filter! (a.k.a. an RC differentiator).
Look again to see how the voltage drop across R and across C changes with time. At first, the entire drop is across R. With time, C charges untill the entire drop is across C, and no more current flows. The bigger the R, the slower this happens, due to the resistance to current flow. Also, the bigger the C, the slower this happens (cause it takes longer to fill a larger 'diameter' charge bucket). If you cut either R or C in half, the process will go twice as fast. (This will cut the time constant of your filter in half, and therefore double the 'center freq' (Fc) of your filter.)
In order to remeber the difference between these two filters when looking at a schematic, I just keep in mind the fact that CAPS BLOCK CONSTANT DC (and low freq's) from being transmitted through them.
All of the above tutorials are based on using a 9 volt battery, but they also hold true for complex AC signals (such as music). These are examples of first order Butterworth filters. You have now learned much of what you need to know about designing first order Butterworth active cross-overs!
Let's now review the term impedance. Start by thinking of impedance as 'resistance to current flow'. How is this different from resistance? Well, reistance remains CONSTANT, no matter what freq of voltage is applied to it, whereas impedance changes depending on the freq applied. Note that the RC integrator (highcut) demonstrated above will impede high freq's, whereas the lowcut will impede low freq's.
Op Amp Buffers
The nice thing about op amps is that they have a high input impedance. For our purposes, just consider them to have a high input RESISTANCE. This means, that they will act kind of like your multi-meter, in that they can observe and amplify voltages without affecting the circuit itself. This becomes important when you want to isolate (buffer) one piece of the circuit from the next so that all your passive components don't start interacting. The output impedance of op amps is very low, which means they can hold a steady voltage even as they are sourcing current (like a battery). This provides a 'fresh, strong isolated signal' for the next part of your circuit. The op amp buffer allows you to cut and paste functions together without worrying about passive component interactions.
First Order Butterworth Filters:
Look at the Alternate Filter Schematic, 1st Butterworth filter. The first thing shown is a block called "Buffer" which corresponds to the op amp which buffers between your preamp and the crossover. Note how this buffer feeds 2 filters identical to the ones we just described (RC filters). The output of each of these filters is then passed through another op amp which acts as a buffer between the filter and your main amp. You now see how an active crossover works! The center (cut-off) frequency is determined by the values of R and C by the following formula:
Fc = 1/(2*Pi*C*R) = 1/(2*3.1416*C(uF)*R(Kohms)*.001)
What would happen if you put 2 first order Butterworths in series? You'd get a 2cd order L-R.
Second Order Unity-Gain Sallen-Key Butterworth (&L-R) Filters:
Now look at the "Filters" diagram schematic. A 4th order L-R is made of two 2cd order Butterworths in series. Find the points labeled "High Out 2cd Butterworth" and "Low out 2cd Butterworth". If you wanted these functions instead of the L-R's you could omit all the components found to the right of these points. Note that the 'filter block' after these points is identical to the one preceeding them. Each one of these 'blocks' is really just a second order unity-gain Sallen-Key Butterworth filter. Cascading these (or any buffered) identical filters does not change the center (cut-off) freq, but it DOES change the Q. Multiply the Q of the first section by the Q of the second. Butterworth Q = .707. L-R Q = (.707) * (.707) = .5
A detailed explaination of these filters is beyond the scope of what I'm trying to do. BUT, the function of this filter is very well defined, and it can be stacked with other functions without worrying about passive interactions (these interactions are buffered by op amps). Note that the formula for calculating the R's and C's for this type of Butterworth filter is a little different than the one above due to this ciruit's topolgy:
Fc = 1/(2*3.1416*1.414*C(uF)*R(K ohms)*.001). Many other types of filters can be made using this topology. Look it up.
Second Order Equal Component Sallen-Key Filters:
These are amoung the most powerfull filters for the audio Do-It-Yourselfer. Only one value of C is needed for any single filter, and two values of C can cover the entire usefull audio range. You can specify nearly any combination of Q and Fc you desire by manipulating a few R's. Furthermore, Fc and Q are controlled independantly, so you don't need to solve multiple simultaneous equations. A minor downside it that you will have to accept a certain amount of Q-independent gain with this alignment. This is really no problem at all, cause you need a way to control the voltage level (volume) to your individual drivers anyways, and you can use this control to compensate for any gain realized here.
I recently wrote an Excel program to help you realize nearly *any* filter you'd like using the ecSK filters. You'll probably want to use ecSK filters to design bass-boost and other Q - altering filters. The Shiva Active EQ posted on the net demonstrates a ecSK filter that could easily be designed with this spreadsheet. Click here to see sample spreadsheet.
Relavant Formulas:
Damping (D) = 1/Q (definition)
Filter Components: Fc = 1/(2PiRC) = 1/(2*3.1416*C(uF)*R(K ohms)*.001).
Gain reisitors: R2 = R1 * (2 - d)
Output Gain = 3 - d Note that this refers to gain at ALL freq's (like
a volume control). The Q 'bump' gain (and attendant distortion) will depend
on the Q value, just like it does for a sealed cabinet.
Q and Fc-dependant dB gain peak near Fc: dB(peak) = 20Log(SqrRoot(Q^4/(Q^2
- 0.25)))
Cascading Electrical and Acoustic Filters for Higher Order:
If you cascade 2 or more 2cd order SK filters with the same Fc, then the total Q = Q1 * Q2* Qn. The kit's main 4th L-R filter is based on this. Two Butterworths (Q1=Q2=0.707) are cascaded to make a 4th L-R (.707*.707=0.50). You can see that an 8th L-R, would NOT be made from four 2cd order Butterworth filters. Instead, you might build it from cascading four 2cd order filters with the following Q's: Q1=.541, Q2=1.307, Q3=.541, Q4=1.307. Q1*Q2*Q3*Q4 = .50 = 8th L-R filter. Generally, it is held that higher - Q sections should come *later* in the cascaded circuit sequentially. For simplicity, I didn't follow this rule, and instead chose the above values based on cascading two textbook 4th Butterworths, each of which is composed of two 2cd ecSK filters.
Note that you can also cascade *acoustic* filters with the active electronic filters. For example, lets say I had a sealed midrange that I wanted to cross to my woofer with a 4th L-R. I could start by designing a Butterworth sealed cabinet. This is the most standard sealed cabinet alignment generally discussed, which results in an *acoustic* second-order lowcut with a Q of .707. Cascading this with a 2cd order Butterworth active filter lowcut, yields a 4th L-R lowcut total acoustical response. This would mate nicely with an active 4th L-R highcut on your woofer. This is a very elegant and simple solution for mid to woofer crosses.
The odd-order filters typically discussed in audio are the Butterworth variety. These can be made by cascading an active 1st Butterworth with a 2cd order, Q=1 ecSK filter. I don't believe its possible to alter the Q of a first-order filter. Therefore, if you wanted a 3rd order sealed woofer lowcut acoustic response, you should design your cabinet to have a sealed Q of 1, and cascade it from a 1st Butterworth active filter.