calculate the transfer function
 User Name Stay logged in? Password
 Home Forums Rules Articles diyAudio Store Blogs Gallery Wiki Register Donations FAQ Calendar Search Today's Posts Mark Forums Read Search

 Solid State Talk all about solid state amplification.

 Please consider donating to help us continue to serve you. Ads on/off / Custom Title / More PMs / More album space / Advanced printing & mass image saving
davidel94
diyAudio Member

Join Date: Jul 2012
Location: Verona
calculate the transfer function

in this circuit i considered the gain of the op.amp to be equal to 1, so v1=vout, then i calculated vs using the voltage divider rule which gives:
vs= v1*(R8/(R8+((R2*(R7+R10))/(R2+R7+R10))))
then i wrote a node equation in v1
(vin-v1)sC4-v1/R1-(v1-vs)/R2=0
considering v1=vout i substituted for vs in the second equation which gives:
vout/vin=-C4 s/(-C4 s+(-1+R8/(R2 (R7+R10)/(R2+R7+R10)+R8))/R2-1/R1)
then i calculated the magnitude which gives:
|vout/vin|=C4 w/(sqrt ((-C4 w)^2+((-1+R8/(R2 (R7+R10)/(R2+R7+R10)+R8))/R2-1/R1)^2))
ltspice gives a -3dB point at 3.140kHz.
where is my mistake?
Attached Images
 Presentazione standard1.jpg (22.4 KB, 195 views)

 26th December 2012, 11:31 AM #2 Mooly   diyAudio Moderator     Join Date: Sep 2007 Boxing day and formulas aren't a good combination I see an amp with positive feedback (potentially unstable). C4 and the source resistance play a big part in what happens at HF as the input frequency rises.
JMFahey
diyAudio Member

Join Date: Mar 2009
Location: Buenos Aires - Argentina
1)
Quote:
 3.140kHz
IMPORTANT: are you using the European convention ( "." means one thousand) or the USA one ("." is a decimal point )?
Not the same by a factor of 1000 .

2) your comparison is meaningless.
You are comparing a formula/equation for which you do not provide a numerical value, to a number.

3) *FULLY* agree with Mooly's assessment, of course.
Only adding that since we are studying a high pass filter, its effect will be seen at some low or mid cutoff frequency.
That said, you are showing a poorly designed active high pass filter.
R2 presents an "active" value larger than the normal one, because it is bootstrapped
As an example of the two extremes, if it were straight grounded, it would show its regular value: 2K2.
If it were connected to U1's out, it would show "infinite" value.
If it were connected to a point receiving 1/2 V out, it would show double its value.
In that case, without need to simulations, a simple mental calculation tells me that this high pass filter has a corner frequency around 6500Hz .
*But* in a proper designed active filter, R2 value should be much higher than that of R7/8/10 ... which is not the case.
Try again but with R2, say, 22K ; R8/10 1K and R7 180 ohms and results will be more in line with what is expected.

And really R7 in series with R10 is unnecessary, drop one and if necessary adjust the value of the other.

MarcelvdG
diyAudio Member

Join Date: Mar 2003
Location: Haarlem, the Netherlands
Quote:
 Originally Posted by davidel94 in this circuit i considered the gain of the op.amp to be equal to 1, so v1=vout, then i calculated vs using the voltage divider rule which gives: vs= v1*(R8/(R8+((R2*(R7+R10))/(R2+R7+R10)))) then i wrote a node equation in v1 (vin-v1)sC4-v1/R1-(v1-vs)/R2=0 considering v1=vout i substituted for vs in the second equation which gives: vout/vin=-C4 s/(-C4 s+(-1+R8/(R2 (R7+R10)/(R2+R7+R10)+R8))/R2-1/R1) then i calculated the magnitude which gives: |vout/vin|=C4 w/(sqrt ((-C4 w)^2+((-1+R8/(R2 (R7+R10)/(R2+R7+R10)+R8))/R2-1/R1)^2)) ltspice gives a -3dB point at 3.140kHz. where is my mistake?
Everything is fine up to the nodal equation and the decision to substitute v1=vout. From there onwards I can't understand the equations anymore due to the huge numbers of parentheses.

Anyway, I find a time constant of 50.87787832 us, corner frequency of 3128.175709 Hz when I start with the equations I can still read and write out everything else myself. That is not far from 3140 Hz. Like you, I've assumed that the electrolytic caps are short circuits, maybe that explains the remaining 12 Hz somehow.

Have you done any dimensional checks? If you are for example adding a dimensionless number to an admittance somewhere, you know there is a mistake.

I also wonder why the circuit is so complicated. For example, R2 could be disposed of altogether when you tweak the resistors in the voltage divider a bit to make its output resistance 2200 ohm higher.

Last edited by MarcelvdG; 26th December 2012 at 09:50 PM.

 27th December 2012, 06:53 AM #5 MarcelvdG   diyAudio Member   Join Date: Mar 2003 Location: Haarlem, the Netherlands In fact you could replace the whole thing with a simple RC high-pass followed by a voltage follower. You probably have some good reason for not doing that, but it is not clear from the schematic why you don't.
 27th December 2012, 06:58 AM #6 davidel94   diyAudio Member   Join Date: Jul 2012 Location: Verona the transfer function i wrote is right, the problem was my calculator which is not working right. I forgot to write that the combination R10 and R8 is a potentiometer divided into two resistances to make the cutoff frequency variable. For Marcel, I get 3128Hz too.
 27th December 2012, 05:39 PM #7 JMFahey   diyAudio Member     Join Date: Mar 2009 Location: Buenos Aires - Argentina Short answer: make the pot value 1/10 of R2, or the "parasitic" pot resistance you are adding throws calculations out of whack. Slightly longer: the concept behind this design is varying the impedance of R2 by applying a fraction of the output voltage on its "ground" end. As I mentioned above, if this end is connected to ground, its impedance is its resistive "passive" value: 2K2 . If you connect it to V out, its value is infinite. At intermediate values, the impedance will take an intermediate value too Vs. *BUT*, if you get Vs from a potentiometer, you are introducing new, unwanted, "passive" resistance in the net. So best would be to add a buffer between the pot slider and R2 or, as a compromise solution, use a low value pot. 1/10 the R2 value would be acceptable. Yet you chose a 22K pot, 10X R2's value !!! A poor choice. And, among other things, it throws the transfer curve out of whack. So, redo your design with more sensible values. Or forget the "active" part, replace R1 with a 47K pot, follow it with a unity gain buffer, and call it a day.
 28th December 2012, 07:42 AM #8 MarcelvdG   diyAudio Member   Join Date: Mar 2003 Location: Haarlem, the Netherlands Why do you assume that the potmeter's output resistance is unwanted? OK, it makes the mathematics somewhat more complicated, but davidel94's calculations already include this effect. To me it makes more sense to choose a potmeter value that provides a pleasant control, and I have no idea if that would mean a small or a large potmeter resistance.
JMFahey
diyAudio Member

Join Date: Mar 2009
Location: Buenos Aires - Argentina
Quote:
 To me it makes more sense to choose a potmeter value that provides a pleasant control,
Exactly, that's the point.
And the pot value chosen does not provide it.
Quote:
 and I have no idea if that would mean a small or a large potmeter resistance.
Well, I do
The idea behind modifying a resistor value by bootstrapping (it's what we are doing here) lies in applying to "the other end" a controlled fraction of the audio voltage applied to it.
Notice the word: "voltage".
The ideal voltage source has zero internal impedance.
This would be achieved by buffering the wiper voltage as I suggested earlier.
Very easy and cheap to achieve, just adding an inexpensive unity gain Op Amp.
You gain 2 advantages here by doing it the right way:
a) the pot response is *smooth*
b) the Math becomes simpler, more straightforward, because you do not need to add and compensate for, the disrupting influence of that too high value pot
BOOTSTRAPPING
See how the bootstrapped input resistor (R2 in Davide's example) appears as a *much* higher value , in this case they apply as much bootstrap *voltage* as they can; in the active filter the amount is variable.
See how simple Math becomes, when properly designed.
See also that in the equivalent circuit analysis, voltage sources are used.

Now, if you do not want to add an extra buffer (which really is as simple as specifying a dual Op Amp, instead of that single one), you may reach a very acceptable compromise by specifying a pot value quite lower than R2 resistance.
Or rising appreciably the value of R2.

MarcelvdG
diyAudio Member

Join Date: Mar 2003
Location: Haarlem, the Netherlands
One can simplify the equations a bit by defining:

Rd=R7+R8+R10

R7+R10=alpha*Rd

Hence, R8=(1-alpha)*Rd. In the original design, the minimum value of alpha is 0.08256... due to the 1.8 kohm fixed resistor.

Assuming that the voltage follower is ideal and that the electrolytic capacitors are short circuits, the cut-off radian frequency becomes:

omega_n=1/(R1*C4)+(1/(R2*C4))*(alpha/(1+(Rd/R2)*alpha*(1-alpha)))

With a voltage follower or with a negligible value of Rd, this simplifies to

omega_n=1/(R1*C4)+alpha*(1/(R2*C4))

That is, using a linear potmeter, with extra voltage follower or very low potmeter resistance you get a constant number of Hz per degree of rotation of the control knob. That's nice if that is what you want, but I could imagine that for an audio application it is more convenient to have a constant number of degrees per octave instead. In fact neither the original circuit nor the counterproposal provide a constant number of degrees per octave, but the original does come closer up to 6000 Hz or so. See the attached figure, with logaritmic Y-axis the tuning plot for the original looks somewhat more straight up to 6 kHz. Maybe some intermediate potmeter resistance would better match an exponential law than either of the two alternatives.

In the end, I don't really know what the circuit is for or what the requirements are. I know it must be something audio-related because this is the DIYaudio forum, but that's about it. Not knowing what the intentions of the designer were, I for one can't judge whether he has done his job well.
Attached Images
 variablefilter.jpg (107.9 KB, 80 views)

Last edited by MarcelvdG; 29th December 2012 at 04:18 PM.

 Posting Rules You may not post new threads You may not post replies You may not post attachments You may not edit your posts BB code is On Smilies are On [IMG] code is On HTML code is Off Forum Rules
 Forum Jump User Control Panel Private Messages Subscriptions Who's Online Search Forums Forums Home Site     Site Announcements     Forum Problems Amplifiers     Solid State     Pass Labs     Tubes / Valves     Chip Amps     Class D     Power Supplies     Headphone Systems Source & Line     Analogue Source     Analog Line Level     Digital Source     Digital Line Level     PC Based Loudspeakers     Multi-Way     Full Range     Subwoofers     Planars & Exotics Live Sound     PA Systems     Instruments and Amps Design & Build     Parts     Equipment & Tools     Construction Tips     Software Tools General Interest     Car Audio     diyAudio.com Articles     Music     Everything Else Member Areas     Introductions     The Lounge     Clubs & Events     In Memoriam The Moving Image Commercial Sector     Swap Meet     Group Buys     The diyAudio Store     Vendor Forums         Vendor's Bazaar         Sonic Craft         Apex Jr         Audio Sector         Acoustic Fun         Chipamp         DIY HiFi Supply         Elekit         Elektor         Mains Cables R Us         Parts Connexion         Planet 10 hifi         Quanghao Audio Design         Siliconray Online Electronics Store         Tubelab     Manufacturers         AKSA         Audio Poutine         Musicaltech         Holton Precision Audio         CSS         Dx Classic Amplifiers         exaDevices         Feastrex         GedLee         Head 'n' HiFi - Walter         Heatsink USA         miniDSP         SITO Audio         Twin Audio         Twisted Pear         Wild Burro Audio

 Similar Threads Thread Thread Starter Forum Replies Last Post davidel94 Solid State 7 17th December 2012 02:20 PM jenks Solid State 31 24th April 2008 08:28 PM massappeal129 Subwoofers 4 16th August 2007 10:21 PM jclouse Multi-Way 22 1st July 2006 01:19 PM Thomas B Multi-Way 4 12th March 2003 04:04 AM

 New To Site? Need Help?

All times are GMT. The time now is 05:04 PM.

 Home - Contact Us - Advertise - Rules - diyAudio Store - Sponsors - Privacy Statement - Terms of Service - Top - Opt-out policy

Search Engine Optimisation provided by DragonByte SEO (Pro) - vBulletin Mods & Addons Copyright © 2018 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 15.00%
vBulletin Optimisation provided by vB Optimise (Pro) - vBulletin Mods & Addons Copyright © 2018 DragonByte Technologies Ltd.