Author Topic: Current into the IC question  (Read 14896 times)

theonlyrobkeyser

Current into the IC question
« on: August 02, 2007, 07:03:52 PM »
Iím having some trouble understanding why the voltage divider networks in this circuit and in the Dist+ are so different.  I realize they have the same function (to provide Vref at 4.5V so that there is the maximum allowable voltage swings between 0 and 9V right?) but why does this circuit use 22K resistors?  The Dist+ uses 1M, which lowers the current going into the IC, right? 

Maybe Iím not thinking about this in the right way (itís been a few years since my one EE class and I always had trouble with the voltage vs. current idea).  Is it just that the 741 has a wide range of allowable input currents and either way works fine?  Or is it really the same and I just need to work out the appropriate Ohmís law calculations to see that?

Thanks - Rob

gaussmarkov

Re: Current into the IC question
« Reply #1 on: August 02, 2007, 08:15:34 PM »
you know, there's more uncertainty here than I first realized myself.  there is a third resistor involved that is also part of this story and that is the bias resistor connecting the junction of the voltage divider to the noninverting input (+) of the IC.  i took the 470k resistor value for this bias resistor from the schematic at generalguitargadgets.com.  but i have since discovered that if you look at tonepad.com, you will see a 1M resistor there.  this is also involved in the differences in current supplied.  so the plot thickens ...

you are correct about the higher valued resistors lowering the current, but not the voltage at the junction of the voltage divider.  ohm's law, V = I x R, implies that for a given voltage level (half supply in this case) a higher R requires a lower I.

as far as the effects of this difference, a no lesser light than Mark Hammer has wondered about this in this thread.  i may have missed a discussion of it myself.  it would be interesting to hear an analysis by one of the forum greats.  but in the mean time, we can take the breadboard experiment discussed in this project and try it ourselves.  :icon_biggrin:

i'm ready, when someone wants to compare notes!  :icon_wink:

mac

Re: Current into the IC question
« Reply #2 on: August 04, 2007, 01:10:33 AM »
Maybe the 22k/22k/1M network can keep a better 4.5v than the 1M/1M/1M arrangement. Also less thermal noise.  :icon_question:

mac
mac@mac-pc:~$ sudo apt-get install ECC83 EL84

gaussmarkov

Re: Current into the IC question
« Reply #3 on: August 04, 2007, 01:30:56 AM »
Maybe the 22k/22k/1M network can keep a better 4.5v than the 1M/1M/1M arrangement. Also less thermal noise.  :icon_question:

mac

hi mac!  R.G.'s stuff about quiet biasing certainly suggests that there will be less thermal noise.  on the other hand, he was discussing a 10M/10M voltage divider, IIRC.

i don't know about holding the 4.5v better.  my guess is that the decoupling capacitor is the most critical element for that.

here's what i was thinking:  we should use our ears for one comparison.  when i get the chance, i will record something and then run it back through the circuit with both sets of resistor values.  joe kramer suggested this to me once, based on using a reamp circuit.  i've been planning to put one together for sometime -- in fact i had built one but i altered it for another use.  so i need to build another first.

GuitarLord5000

Re: Current into the IC question
« Reply #4 on: August 30, 2007, 10:04:04 PM »
Hey gaussmarkov,

Great project!  It was very informative, and done in a simple, easy to understand format.  Thanx!

As for the voltage divider differences, after reading the thread you linked to, it was proposed that the 1M 1M 1M network was designed to "starve" the opamp, and cause it to distort a fair amount on its own, before being re-clipped by the diodes.

If you do indeed do some comparison recordings, I would suggest doing it with both networks, as well as with the clipping diodes in/out.  Im very curious as to what you'd find.  Hell, I'd do it myself, but am at work right now, and wont be near my breadboard for a few more days at least.

Cheers!
Life is like a box of chocolates.  You give it to your girlfriend and she eats up the best pieces and throws the rest away.

gaussmarkov

Re: Current into the IC question
« Reply #5 on: August 31, 2007, 01:36:29 AM »
nice.  and thanks for mentioning it.   :icon_biggrin:

i still haven't made the comparison myself.  :icon_rolleyes:  so much to do ... so little time.  :icon_cool:  and i'm still hoping someone else will jump in.  :icon_wink:

demonstar

Re: Current into the IC question
« Reply #6 on: August 31, 2007, 06:29:06 AM »
I've tried both bias networks on a breadboard and also with some knowledge I gained from R.G I believe I have it understood.

Both the divider networks provide a large enough current to the opamp to not starve it. We must also remember the opamp only draws the current it needs; the bias current (that info is on the datasheet). The 470k or the 1M bias resistor set the input impedance of the pedal but don't effect the current flowing into the opamp (well not at the sizes we're talking about here. It may at values way higher than 1M but I don't know much about that and I don't think theres any reason to go there). Also the bias current (from the datasheet) which flows through this bias resistor must be 1/10th or smaller than the current flowing through the potential divider to keep things stable. I found I had to trust the calculations because the bias current is so small I couldn't really measure it properly The 10% is an engineering standard I believe.

As for difference it tone.... None at all that I could tell and if there is it's probably to do with the input impedance thats being altered by the bias resistor not the current into the opamp.

To the best of my knowledge all of this information is correct but I'm still fairly new around here so I can't promise but when I've put it into practice it works so it must be pretty close.

Hope thats cleared it up a bit because this topic was bothering me too and isn't too well documented properly. Theres lots of myths and theories. R.G has a good article on it though at geofex. :)

"If A is success in life, then A equals x plus y plus z. Work is x; y is play; and z is keeping your mouth shut"  Words of Albert Einstein

gaussmarkov

Re: Current into the IC question
« Reply #7 on: August 31, 2007, 10:24:33 AM »
I've tried both bias networks on a breadboard and also with some knowledge I gained from R.G I believe I have it understood.

alright! :icon_cool:

Both the divider networks provide a large enough current to the opamp to not starve it. We must also remember the opamp only draws the current it needs; the bias current (that info is on the datasheet). The 470k or the 1M bias resistor set the input impedance of the pedal but don't effect the current flowing into the opamp (well not at the sizes we're talking about here. It may at values way higher than 1M but I don't know much about that and I don't think theres any reason to go there). Also the bias current (from the datasheet) which flows through this bias resistor must be 1/10th or smaller than the current flowing through the potential divider to keep things stable. I found I had to trust the calculations because the bias current is so small I couldn't really measure it properly The 10% is an engineering standard I believe.

you understand op amps better than i do!  i was able to confirm your reasoning with a simulation using LTspice/SwitcherCadIII (free software from linear technolgies).  i didn't think of trying this until i read your post.  as you say, the op amp draws the same current at the noninverting input for various resistor values in the divider or for the bias resistor.  the current through the bias resistor and the input resistor both change, which has to be if the op amp is going to draw the same current.  but what's going through the noninverting input is always the same.

As for difference it tone.... None at all that I could tell and if there is it's probably to do with the input impedance thats being altered by the bias resistor not the current into the opamp.

and that's what your reasoning predicts, isn't it?  once we have determined that the same current goes into the noninverting input, there aren't any differences left to find.

To the best of my knowledge all of this information is correct but I'm still fairly new around here so I can't promise but when I've put it into practice it works so it must be pretty close.

Hope thats cleared it up a bit because this topic was bothering me too and isn't too well documented properly. Theres lots of myths and theories. R.G has a good article on it though at geofex. :)

i'm convinced.  :icon_biggrin:  time to go back and do some more reading at geofex.com! :icon_cool:

GuitarLord5000

Re: Current into the IC question
« Reply #8 on: August 31, 2007, 02:39:23 PM »
Great job demonstar!

Thanks for taking the time to shed some light for us!

As far as the input impedance being changed, Im not sure it would make much difference (if any), due to the fact that the input has a 2.2M resistor to ground.  The impedance still should be pretty high regardless of the bias resistor being 470k or 1M?????
« Last Edit: August 31, 2007, 02:49:12 PM by GuitarLord5000 »
Life is like a box of chocolates.  You give it to your girlfriend and she eats up the best pieces and throws the rest away.

theonlyrobkeyser

Re: Current into the IC question
« Reply #9 on: August 31, 2007, 04:08:45 PM »
Yeah, good job demonstar, that helps a lot.  And thanks to RG for explaining that the IC only drws as much current as it needs, I had a mini-epiphany when I read that.   

About the impedances though, I think we're getting the impedance of the pedal and the impedance of the power supply and bias voltage divider mixed up.  As I undersand it, you can think of the the voltage divider has having it's own impedance (or even resistance since it is a resistor).  The 1M network's output  impedance/resistance is high (Is it 1M though or different because there are two 1M's? I don't know), meaning that it's hard to draw current out of it.  This doesn't matter becasue the IC has a large input resistance as well (2M from the data sheet) that counteracts the bias networks output impedance/resistance and allows the IC to draw what little current it needs anyway.  This is a different than the impedance of the pedal itself, which does have a high input impedance (set by the 2.2M input resistor) meaning it is easy for the pedal to pull current from whatever is before it in the signal chain.

I guess the only answer to my original question, why would you use a 1M bias network over the 470K one, is there is no reason to use one over the other.  Like demonstar said, the 10% rule is the guideline for current draw, but since the 741 needs so little current, and only takes what it needs, keeping the voltage steady is pretty easy.  1M's maybe overkill for this IC, but it doesn't matter and maybe for another IC it would help.

Thanks for you help everyone - Rob

demonstar

Re: Current into the IC question
« Reply #10 on: September 01, 2007, 04:02:15 AM »
I'm sure I've been told that the bias resistor (1M or 470k) was setting the input impedance along with the 2M2 pull down resistor. If you think why shouldn't it because it is going to the vbias point in the divider which for AC signals (the guitar signal) it is shorted straight to ground via the large cap in parallel with the 2nd resistor to ground in the bias divider. Which is exactly what the 2M2 to ground is doing. ie going straight from signal to ground. So, both resistors do that so therefore they should both set the input impedance I think.

Whether this makes a difference I don't know.
Maybe we could test this.
"If A is success in life, then A equals x plus y plus z. Work is x; y is play; and z is keeping your mouth shut"  Words of Albert Einstein

gaussmarkov

Re: Current into the IC question
« Reply #11 on: September 01, 2007, 11:23:58 AM »
i hope you all don't mind if i back up to an earlier point in the analysis.  it may be relevant to this discussion of impedance.

i went back and read about op-amps again (not much, but just enough  :icon_wink:) and i am wondering whether we could describe the similarity for different resistor values in simpler, and maybe more familiar, terms.  the input impedance of an ideal op-amp is infinite.  in other words, no current will flow into the inputs.  that's not inconsistent with what you said, demonstar.  it's just simpler:  no matter what resistor values we put in there, the current will be zero.

in the simulation that i did, the amplitude of the current is 200pA.  quite small.  if the ideal is a good place to start understanding the possible effects of the resistor values, then isn't the notion of "starving" an op-amp for current looking in the wrong place?  another thread pointed in that direction and maybe it's a red herring?

now here's the relevance for the input impedance discussion:  starting with an infinite input impedance for the op-amp, it follows that the bias resistor affects the input impedance for the circuit.  (i have to run so i cannot expand on that right now.  but maybe someone else can comment before i get back.)

thanks all!  gm

demonstar

Re: Current into the IC question
« Reply #12 on: September 01, 2007, 11:55:19 AM »
I think starving an opamp is probably the wrong place to be looking too. I think there is a lot of red herrings around in this area and I think people have kind of believed there is a "black magic" to choosing the bias resistor. The truth is probably more like unless the bias resistor is huge and impedes the flow the the 200nA bias current, the opamp will not be starved. If this is the case (which I'm not definite of) the bias resistor would have to be really really big to stop that current flowing. Especially when the 200nA I quoted is the maximum bias current for 741. So the minimum is way smaller. I think when I looked earlier the typical is around 50nA.

So yes, the input impedance is probably the only thing that is altered and if not correctly chosen, the stability of the voltage divider could be compromised too.

Hows that sound?
« Last Edit: September 01, 2007, 11:57:28 AM by demonstar »
"If A is success in life, then A equals x plus y plus z. Work is x; y is play; and z is keeping your mouth shut"  Words of Albert Einstein

GuitarLord5000

Re: Current into the IC question
« Reply #13 on: September 01, 2007, 03:16:04 PM »
OK.

Taking a look at the DOD 250 and MXR distortion + here:
http://tonepad.com/getFile.asp?id=115

And the Proco Rat here:
http://tonepad.com/getFile.asp?id=89
(Thanx tonepad!)

And knowing that the actual Rat does NOT have the 1M pulldown resistor at the input (I imagine that the guys at tonepad put that in the schem themselves?)
AND going through Jack Orman's Muff/Rat E-Book (which is a very good read coincidentally!)
My conclusion thus far is that the 1M bias resistor DOES set the input impedance of these circuits.  Jack Orman actually lowers considerably this resistor in his Rat Mods section in order to lower the noise of the Rat.  Although I dont know if the stability of the voltage divider can be compromised by incorrectly choosing the resistor value.  Can you please elaborate?
I imagine next time I decide to build an opamp circuit, I'll use whatever resistors I have handy for the volatage divider, and not worry much about it.  It seems like a very arbitrary choice.

Great stuff by the way.  I've learned more about opamps in this tutorial and subsequent posts than I've ever learned before.
Thanks a lot folks!
Life is like a box of chocolates.  You give it to your girlfriend and she eats up the best pieces and throws the rest away.

demonstar

Re: Current into the IC question
« Reply #14 on: September 02, 2007, 05:00:03 AM »
OK right basically, the long and short of it is if theres more than 10% of the current flowing through the potential divider flowing through the bias resistor Vout alters. 10% is chosen as a engineering standard I believe.

So if we know from a data sheet that we need 200nA flowing through the bias resistor to bias the opamp. We must remember in the case of an opamp whatever the size of the bias resistor the same current flows through it as the opamp only takes the current it needs. So the value of the bias resistor is unimportant in this example here.

So we know we have 0.000002A flowing through the bias resistor. This needs to be 10% or smaller of what is flowing through the voltage divider so we need...

10*0.000002=0.00002

...So that means we need 0.00002 flowing through the voltage divider. Therefore we use ohms law...

R=V/I

R=9/0.00002

R=450000

So that means as we're using two resistors in series our resistors must be 225000 each.  So each value in the divider must not be greater than 225k. Smaller is better but you must remember the smaller you go the more current the divider draws so poorer battery life. I have heard very large values can be noisy.

Oh, and you need to remember to put a cap in parallel with the divider resistor going to ground to decouple it.

Hope that helps. For a more detailed explanation and where I learnt it read "Designing Bias Supply (Vbias or Vb) Networks for Effects" at Geofex.

This is also useful...

"http://www.diystompboxes.com/smfforum/index.php?topic=60335.0"
« Last Edit: September 02, 2007, 05:07:50 AM by demonstar »
"If A is success in life, then A equals x plus y plus z. Work is x; y is play; and z is keeping your mouth shut"  Words of Albert Einstein

gaussmarkov

Re: Current into the IC question
« Reply #15 on: September 04, 2007, 01:42:38 AM »
demonstar, thanks for the link to R.G.'s comment.  it helped me a lot. :icon_cool:

i have been wrestling with the input impedance question some more.  the bottom line is that i figure the 20K/20K divider with 1M bias resistor gives an input impedance of around 1M.  Change that divider to 1M/1M and you're talking an input impedance of 1.5M.  no pull-down resistor present in the circuit for these calcs.  that would change things.  Also no cap across the input, as in the MXR Distortion+.  that makes things a lot more complicated, and may be the most important factor for explaining audible differences between a DOD Overdrive 250 and an MXR Distortion+.  in any case, the difference in voltage dividers does affect input impedance.

here's how i measured input impedance using simulation:  i put a resistor between an ideal AC source and the circuit (up to the op amp's noninverting input -- i think the rest does not matter much).  then i changed the value of the resistor until the gain at the junction between the resistor and the circuit was 50%.  that's a point where the resistance on both sides is equal (think voltage divider).  i have read (see for example, Impedance - What and Why? on geofex.com) that this is a way to actually measure impedance with real circuits.  so i just applied the idea to simulation.

notice that these values are roughly the value of the bias resistor plus the value of the divider resistors in parallel.  that actually gives 1.01M for the OD250, which is closer than 1M in the simulations. i'll bet that is how the impedance calculation could be made in general for different resistor values in this circuit.

adding the 1nF cap found in across the input of the distortion+ causes the impedance to vary quite a bit with the resistor inserted at the input.  they form a low pass filter that causes a signifiant cut in the highs.  that's why i say that it's more complicated with that cap and that it may be the primary reason for audible differences in the circuits, as opposed to the difference in voltage dividers.

one final comment for those who are also struggling with the input impedance concept:  it appears to be a little sketchy.  :icon_wink:  if i have done things right (and there's always the possibility that i have not), then it appears that input impedance actually depends on the output impedance of the source.  you can always back out the input resistance implicit in whatever gain you observe for whatever source resistor you might choose.  i tried several.  unfortunately, it's not constant and, over the range of frequencies covered by the guitar, the observed input impedance can vary by a factor of 10 for this circuit.

this is why i reverted to just taking the resistance at 50% gain.  that takes care of where to put the source resistor value.  but it also begs a question:  why do people talk about THE input impedance when it depends on the output impedance of the source?  i guess that's a question that should go in another thread.  :icon_biggrin:

gaussmarkov

Re: Current into the IC question
« Reply #16 on: September 04, 2007, 05:35:21 PM »
addendum:  i was a little confused in my report above.  the input impedance as measured above is constant for all (source) resistor values without the distortion plus cap across the input.  once that cap is in place, then the measured input impedance moves around with the source resistor value.

gaussmarkov

Re: Current into the IC question
« Reply #17 on: September 04, 2007, 11:37:51 PM »
alright.  i figured out how to compute the impedance for a circuit from reading the gain at two different source resistor values.  this gives you 2 equations in the magnitude and phase that can be solved pretty easily.  at a frequency of 4KHz, this gives an impedance magnitude of about 40K for the mxr distortion plus with the 1nF cap across the input.  that is essentially the impedance of that cap alone, so that the quick and dirty analysis is that the resistors are an open circuit relative to that cap (and can be ignored).

given that a guitar pickup has an output impedance in the neighborhood of 8K to 100K (per R.G. in Impedance - What and Why?), that will seriously load down the output of some guitars.

demonstar

Re: Current into the IC question
« Reply #18 on: September 05, 2007, 01:02:56 PM »
Sorry guys but in the post I made above there should be and extra zero in the calculation... I used 10 ^ -8 as nano but I should have used 10 ^ -9. I just realsied now that I've been using the wrong thing.

The purpose of the calc was just to explain but If you were considering using the answer I calculated above just remember it's a little bit out so I'd follow the calc through again with the extra zero in.

Sorry!
"If A is success in life, then A equals x plus y plus z. Work is x; y is play; and z is keeping your mouth shut"  Words of Albert Einstein

gaussmarkov

Re: Current into the IC question
« Reply #19 on: September 07, 2007, 07:33:15 PM »
first, demonstar rules.   :icon_biggrin:  if you didn't understand what demonstar wrote previously, then read on and maybe this will help you.  if you did understand demonstar, which i didn't, then maybe don't read on.  i am writing this as a sort of penance.  :icon_confused:

i have a better handle on input impedance analysis after spending some more time on it.  R.G.'s article on this is making more sense to me now.  here's my understanding of how to think about the dod overdrive 250/mxr distortion plus.  as already agreed, the noninverting input of the op amp has such a large input impedance that we can ignore it.  so here is a redraw of the original schem with the op amp removed and everything arranged in a way that is more suggestive for input impedance analysis.



so what you see is the pulldown resistor parallel to all the stuff for biasing the op amp.  except notice that i have replaced the voltage supply with a ground at the bottom of R7.  for analyzing AC, all constant voltage sources look the same as ground. the quick explanation is that the capacitor C1 "blocks" DC and the constant voltage source just lifts the over all level of voltage.  it doesn't affect the wiggle in the AC.

the schematic is in a form that is natural for input impedance analysis because we are basically asking what the path to ground looks like at the input of the circuit.

now for my simulations above i through out the decoupling caps in the power supply.  that, as i will explain, was a mistake.  :icon_rolleyes:  so here's effectively what i was using for my simulations in LTSpice:



if you review my previous post, you will see that i left out the pull-down resistor, and it's omitted above as well.  in this schem, it's pretty easy to see that the input impedance is the sum of the divider resistors in parallel and the bias resistor R3.  R7 and and R2 are small enough not to matter much in the calculation.  and C1 doesn't matter much either.  at the frequency f, the effective resistance of a capacitor is 1/2πfC, where π is pi, and C is the value of the capacitor.  at 4KHz, that's about 4K ohms, which is also negligible.  so a quick approximation to the input impedance in this schem is R3 + (R8 x R9)/(R8 + R9) ohms and that's what the simulations were giving me.

but if you back up to the first schem, and use the same calculation for the other capacitors, and note that the effective resistance of C7 is 4 ohms at f = 4KHz, then you see that the voltage divider doesn't even enter the calculations once the decoupling caps are in place.  and that, after all, is what they are supposed to accomplish.  :icon_redface:  C7 is like a short to ground.  so what i really should've looked at is this simplification:



i have put the pull-down resistor back in.  C1 is still approximately a short.  so we have that the pull-down resistor and the bias resistor in parallel set the impedance of either the dod overdrive 250 or the mxr distortion plus.  which is what demonstar said previously.  :icon_redface: :icon_redface: :icon_rolleyes:  given that the circuits have the same bias resistor (per tonepad), they have the same input impedance and we should expect them to sound pretty much the same.  general guitar gadgets has different bias resistor values, 470K for the 250 and 1M for the dist +, so i suppose that could make a difference for a high output impedance pickup.

now i am going to crawl back under my rock and study some more.  all the best, gm :icon_biggrin: