bass boost shelving filter equations
Feb 4, 2005 at 6:39 AM Post #16 of 64
Quote:

Originally Posted by morsel
Hi Drew, thanks for your reply. I tried what you suggested about a month ago and plotted it, but the graph is a regular low pass filter, no shelving. I think there should be multiple exponentiated terms.


Try looking at the equation under two conditions - as f approaches zero and as f approaches infinity.

Quote:

Originally Posted by morsel

This is how I reduced the equation:

Ao = (Rbb||Cbb+R4)/R3+1
Ao = ((Rbb/(2πfCbb)/(Rbb+1/(2πfCbb))+R4)/R3)+1
Ao = 1+(Rbb/(2πfCbbRbb+1)+R4)/R3

Tossing j is legitimate in this case, right?



It reduces just like that. By looking at the equation's behavior as it approaches the two frequency extremes, you should be able to see that it's correctly modeling the way that the circuit works. You don't have to toss j because it is integral to the capacitor's function - and at the frequency extremes, you get this:

Ao = (Rbb+R4)/R3+1 as f approaches zero.

and

Ao=R4/R3+1 as f approaches infinity.

Instead of zero and infinity, just think low and high frequencies. So for low frequencies, Rbb is in play, effectively increasing the gain of the system. At high frequencies, Rbb is out of the circuit, so the gain approaches the normal gain without the bass boost.

Now, tossing j, you should be able to observe the shelving function of the circuit in terms of gain, assuming that you are using a log scale plot.

Let me throw in this caveat that it's been a few years since I did any signal analysis by hand and that was in college, where everything was nice and predictable.

-Drew
 
Feb 4, 2005 at 6:46 AM Post #17 of 64
What you do is like drewd wrote, a normal feedback equation where you replace impedances with what's in your schematics. Impedance of a capacitor is 1/jwC, for a steady state periodic signal. You get a complex number equation. Then, to calculate gain variation with frequency, which is what Morsel wants, you would calculate modulo of that expression. If you want phase, you calculate phase.

I got the transfer function as

A + jwB
-------
1 + jwC

where

A = 1 + R4/R3 + Rbb/R3

B = Cbb * Rbb * (R3+R4)/R3

C = Cbb^2 * Rbb^2

Which would yield modulo of

sqrt( ( (1 + R4/R3)^2 + Rbb^2/R3^2 + 2*Rbb/R3(1+R4/R3) + 4*pi^2/f^2 * Cbb^2 * Rbb^2 * (1 + R4^2/R3^2 + 2*R4/R3) ) / (1 + 4*pi^2/f^2 * Cbb^2 * Rbb^2) )
 
Feb 4, 2005 at 9:03 AM Post #18 of 64
Aos, I don't understand how you arrived at your result, nor your usage of the word "modulo" in this context, but I plotted your suitably complex equation and it didn't work, perhaps due to some parenthetical ambiguity. I have tried what Drew suggested in various ways but it has not worked.

Drew, I'm using the same component values that generated the bass boost graph, so I should see shelving if an equation is correct. Perhaps Mathematica is not doing what I think it should be doing. I will look at this again in the morning.
 
Feb 4, 2005 at 9:36 AM Post #19 of 64
Since no one has given Morsel all that she has asked for, this seems like a good time for me to stop lurking and lend a hand. This would have been up sooner but there sure is a long wait between registering and being permitted to post.

Everything is in the attached file. The pole and zero frequencies should be good enough for fs and fc. I could derive more precise equations but I don't think that it's worth the effort.
BassBoost_TF.jpg


BassBoost_TF.pdf
 
Feb 4, 2005 at 4:43 PM Post #20 of 64
Quote:

Originally Posted by SnoopyRocks
Everything is in the attached file. The pole and zero frequencies should be good enough for fs and fc. I could derive more precise equations but I don't think that it's worth the effort.

BassBoost_TF.pdf



Have you checked the permissions on this file? I do not have access to it (403).

Taking j into account, and after manipulating my equation, I agree with Snoop's derivations.

Nice work. Snoopy Rocks!

Later,
 
Feb 4, 2005 at 5:36 PM Post #22 of 64
Yeah, that pretty much maches the equation I wrote above, but you did it in a much more readable way, plus you explicitly calculated the pole and zero.

Modulo is the same thing as magnitude, and for a complex number
a + jb it's sqrt ( a^2 + b^2 ). Since my and SnoopyRocks formula are identical in the beginning it should work - it's possible I made a mistake somewhere trying to unwind all the squares in the expression. You can probably just write it in original form since you're using a program to calculate it.

By the way, pole is any root of the denominator while zero is any root of the nominator. A "root" is a value of the variable where the polynomial evaluates to zero. Typically a transfer function for passive circuits (R,L,C) is a fraction of two polynomials. You can write a polynomial in the form

a0 + a1*x + a2*x^2 + ... + an*x^n

or in the form

(x-x0) * (x - x1) * ... (x - xn)

where roots are values x0, x1... xn. Calculating roots manually for higher order polynomials can be tricky although there are methods that you can use - it's just that they will be very time consuming. That means that precise manual analysis when there's more than 3 L or C in the circuit is hard and in practice is rarely done. Engineers would just go through the formula and eliminate most of the terms by realizing that some values are much larger or smaller than the others and therefore some terms can be ignored. That's how they get simple equations. However this filter is simple enough to allow manual manipulation.

Oh yes, why calculate poles and zeros? Because it's then very simple to draw Bode diagrams of magnitude and phase. You simply have flat line at A0 (DC gain), then whenever you encounter a pole you slope the line by 20dB / decade and every time you run into a zero you slope it up by the same amount. Bode diagrams are approximations but they're very close to the real thing
 
Feb 4, 2005 at 6:00 PM Post #23 of 64
fixed.
biggrin.gif


Quote:

Originally Posted by stadams
Have you checked the permissions on this file? I do not have access to it (403).

Taking j into account, and after manipulating my equation, I agree with Snoop's derivations.

Nice work. Snoopy Rocks!

Later,



 
Feb 4, 2005 at 7:36 PM Post #26 of 64
Is the analysis step value set for 10? It looks as if the software does not have enough points between 1 and 10. Try increasing the number of analysis points by a factor of 10.

Later,
 
Feb 4, 2005 at 8:30 PM Post #27 of 64
Holy hacksaws, Batman! This problem has been torturing me for years. Mathematica v5 defaults to only 25 plot points. Of course this means I have to go back and retry all the rejected equations.
I grovel before you in thanks.
f89f7ac7_hail.gif


1ba2c3d2_Ao.gif

 
Feb 4, 2005 at 9:30 PM Post #28 of 64
It's nice to see that you got it to work. You probably don't need to go back and check all the equations - there are minor mistakes to be found. Speaking of which, I made one too. omega_z=Abb*omega_p (no minus sign ... it's in the left half plane). The documents have been updated.

Quote:

Originally Posted by morsel
Holy hacksaws, Batman! this problem has been torturing me for years. Mathematica defaults to only 25 plot points. Of course this means I have to go back and retry all the rejected equations.
I grovel before you in thanks.



 
Feb 4, 2005 at 10:49 PM Post #29 of 64
Ao was only a means to an end. The really useful things to know are fs, fc, and Abb. I want to see if some of the previous equations I discarded, including some that were not posted here, work with fewer terms.

Can you suggest any websites or books that explain how to derive equations like yours? Back in a bit, going for lunch.
 
Feb 4, 2005 at 11:24 PM Post #30 of 64
Well, in this case it's easy since you already have the formula for the gain of the amplifier - the ratio of two resistors + 1. Now, in this case that works for general impedances, not just resistors, so if you simply write the impedances you've got on your schematics, you get the formula immediately, in the first step. Calculating magnitude and phase is nothing but mathematics. So there was really nothing to derive here, just to write down and perhaps simplify.

If you're asking where do impedances of inductors and capacitors come from, and why is the complex calculus used for steady state periodic signals, that's basic EE network theory, it should be covered in any introductory EE book, if you want to see how it's derived. But the formulas for impedance are easy to remember, Zl = jwL for inductor and Zc=1/jwC for capacitor where w = angular frequency, i.e. 2 * pi / f, and j is imaginary number one. Incidentally mathematicians use i, and EE's use j, because i is usually used to denote current intensity.
 

Users who are viewing this thread

Back
Top