Linearising Opamps (preamp design); Noise; and MHz...

GroupDIY Audio Forum

Help Support GroupDIY Audio Forum:

This site may earn a commission from merchant affiliate links, including eBay, Amazon, and others.

jBam

Well-known member
GDIY Supporter
Joined
Jan 31, 2016
Messages
121
Location
Melbourne
Hi all - been a while... hope all are well and good and happy!

As always, I've drifted into a weird theoretical concept, spent a few solid weeks thinking in my spare time, and just today compiled my thoughts and did some SPICE sims...

This time, I'm on Mic Pre design (opamp based - possibly relates to other approaches too).  After much reading I've come to learn a reasonable amount about gain / freq roll off and phase delay within opamps.  I thought: "well, I wonder how you can get rid of that" and started my spare-time-thinking...  Phase shifts? filters... inverting this; doing that...

The goal - not specifically for sonics, but just out of interest in learning: to see about a developing a super flat mic pre with negligible phase delay...

As is typical, most of my ideas kind of didn't make sense in practice (well - simulated practice), but some were close and I've now developed up something pretty cool actually (I think) - have a few questions though that I'm hoping someone can help me with...?!

I've developed a way to really remove phase delay & freq / gain roll off on the opamps I've looked at (primarily the LT 1115) - take a look at the attachment (scroll right), showing an LTspice AC sim where:

  • Left axis = gain (solid lines of a given colour);
    Right Axis = Phase (dotted line of the same colour);
    Bottom axis is freq from 1Hz to 100kHz;
    Blue is an example instrumentation Amp (LT 1167);
    Red is a single LT 1115 pumped up to 80 dB gain;
    Green is my circuit also at around 80dB gain - note the dotted green line at the top is my circuit at roughly zero phase delay, and the solid dB line is basically flat (to within 0.0-something of a dB at least).

So I'm pretty stoked with this result in theory!

Here's the initial questions:

a) I've now realised that roll off and phase delay for ultra fast opamps (e.g. GHz) is well beyond audio range...  But audio Opamps (those toted for use with audio) almost always have phase delay right through to the 100's of Hz and a roll off around 10kHz, often with 3dB drop within hearing spectrum... why aren't audio opamps optimised for gain / freq roll off beyond audio range like GHz opamps are?!.. bound to be a reason?!..  I find the concept of e.g.90 degree phase delay within the audio spectrum pretty odd for an "audio opamp"... Almost a bit sloppy to be honest?!

b) I've also plotted circuit noise - but realised I don't know what I'm looking at??!  my design (at a reduced 60dB gain) clocks up "9uV/Hz 1/2" (that's at 1kHz)... I truly don't understand what that means though...  I've of course read online and done some math, and used some online calculators etc...  But I'm not sure I trust my numbers for use in audio...  Is anyone able to assist me in calculating this as a noise floor in dB for line level audio?!  and explain it too please!!... and at 60dB gain- is this good or crap as a noise level?!

As always - I really appreciate any insight...  Also interested to know if "you always do tricks in a mic pre to combat phase delay & gain/freq issues", or if my results are possibly kinda cool...??!!

:)
 

Attachments

  • Linear OpAmp.jpg
    Linear OpAmp.jpg
    220.6 KB
A basic rule of minimum-phase circuits is taht the phase-response and the amplitude response are closely related; basically, phase starts to deviate from 0 when the gain starts to deviate from the mid-band response. Your graph suggests that the usual roll-off does not appear in the simulation frequency span. Redo your sim with a much higher upper frequency limit. You should reach a point where the response starts to decrease and the phase change. If not, you have invented an extraordinary circuit!
Indeed, designing with a very high roll-off frequency is a guarantee of very low phase-shift/propagation delay. The issue is that it's generally very difficult to achieve, using expensive active devices and ending with a circuit that is very sensitive to lay-out and parasitics. Most of the times, this results in not-so-good noise performance.

9nV/sqrtHz is the noise voltage density; that's the noise voltage over a BW of 1Hz. Since the nominal BW in audio is 20kHz, this figure must be multiplied by 141.4 (sqrt of 20 000), resulting in 1.27uV. To put in perspective with the noise of a 200r resistors (standard mic impedance), which is 0.25uV. Your circuit generates 5 times more noise than the source, for a noise factor of 14dB. A good solid-state mic pre has a NF of about 1-2dB.
Can you post the .asc file here (changing the extension to .txt) or on the LTspice group?
 
Many op amps have an internal pole at quite a low frequency as a brute force method of ensuing stability at unity gain. This is known as the dominant pole technique. The op amps you tried clearly have such dominant poles. Looks like your design has avoided this or, as abbey has suggested, your pole i above 100KHz. If you are going to extend the open loop bandwidth in this way then you will probably find you will not be able to ensure stability  at unity gain but only at some higher value, say 10dB of gain. One of the early Neve discrete op amps  had its dominant pole well outside the audio band and was only stable a gains of 10dB and above.

This is a perennial problem for audio op amps. You want lots of open loop gain so that NFB can reduce distortion to tiny levels but this gives stability problems if you don't restrict the  open loop response. A solution is to design an op amp where the open loop gain AND the closed loop gain vary together.  The means the amount of NFB can be held nearly constant so stability is ensured. This way you can have a pole outside the audio band yet ensure stability at any gain setting. Of course, nothing is new and this technique is commonly known as a transamp .It is about time someone designed a good discrete transamp - I look forward to seeing your new design.

Cheers

Ian
 
jBam said:
Hi all - been a while... hope all are well and good and happy!

As always, I've drifted into a weird theoretical concept, spent a few solid weeks thinking in my spare time, and just today compiled my thoughts and did some SPICE sims...

This time, I'm on Mic Pre design (opamp based - possibly relates to other approaches too).  After much reading I've come to learn a reasonable amount about gain / freq roll off and phase delay within opamps.  I thought: "well, I wonder how you can get rid of that" and started my spare-time-thinking...  Phase shifts? filters... inverting this; doing that...

The goal - not specifically for sonics, but just out of interest in learning: to see about a developing a super flat mic pre with negligible phase delay...

As is typical, most of my ideas kind of didn't make sense in practice (well - simulated practice), but some were close and I've now developed up something pretty cool actually (I think) - have a few questions though that I'm hoping someone can help me with...?!

I've developed a way to really remove phase delay & freq / gain roll off on the opamps I've looked at (primarily the LT 1115) - take a look at the attachment (scroll right), showing an LTspice AC sim where:

  • Left axis = gain (solid lines of a given colour);
    Right Axis = Phase (dotted line of the same colour);
    Bottom axis is freq from 1Hz to 100kHz;
    Blue is an example instrumentation Amp (LT 1167);
    Red is a single LT 1115 pumped up to 80 dB gain;
    Green is my circuit also at around 80dB gain - note the dotted green line at the top is my circuit at roughly zero phase delay, and the solid dB line is basically flat (to within 0.0-something of a dB at least).

So I'm pretty stoked with this result in theory!

Here's the initial questions:

a) I've now realised that roll off and phase delay for ultra fast opamps (e.g. GHz) is well beyond audio range...  But audio Opamps (those toted for use with audio) almost always have phase delay right through to the 100's of Hz and a roll off around 10kHz, often with 3dB drop within hearing spectrum... why aren't audio opamps optimised for gain / freq roll off beyond audio range like GHz opamps are?!.. bound to be a reason?!..  I find the concept of e.g.90 degree phase delay within the audio spectrum pretty odd for an "audio opamp"... Almost a bit sloppy to be honest?!

b) I've also plotted circuit noise - but realised I don't know what I'm looking at??!  my design (at a reduced 60dB gain) clocks up "9uV/Hz 1/2" (that's at 1kHz)... I truly don't understand what that means though...  I've of course read online and done some math, and used some online calculators etc...  But I'm not sure I trust my numbers for use in audio...  Is anyone able to assist me in calculating this as a noise floor in dB for line level audio?!  and explain it too please!!... and at 60dB gain- is this good or crap as a noise level?!

As always - I really appreciate any insight...  Also interested to know if "you always do tricks in a mic pre to combat phase delay & gain/freq issues", or if my results are possibly kinda cool...??!!

:)
Coincidentally I was asked off list for a link to this old article I wrote.  http://www.johnhroberts.com/des_art_1.pdf  While several decades old, the op amp basics still hold water.

JR

PS: ignore the part where I misspelled bus...  :eek:
 
First Up:

Thanks so much for the responses guys... Bloody legends :)  I stumble across info from you all on my many web searches (often on other forums and in some articles etc) ---> Always love some discussion, but this is already a very useful thread for me :)...

Thanks for all those links too - the internet can be hard to navigate through the swathes of crap - always nice to have a personally written one in there too John ;)

Abbey - thanks so much the calcs / explanation on noise there...  I fear somewhat that I've made myself a "noise party" though - my value is 9uV/sqrHz... not 9nV  :(

But - I still don't quite understand how this noise sim is working; and I haven't really looked into minimising noise just yet...  So maybe I can improve it (or maybe it's just a byproduct of the approach I'm using.. which'd be a shame!)

The Spice file itself is a mess - I might tidy it up to some degree; but I also feel like you'll all laugh when you see the simplicity of what I've done! :)

To save myself too much laughter, I'll run through the idea and process...!

I started out thinking "ok, so there's a roll off when you increase gain due to the phase delay of higher freqs; SO let's reverse that effect with a filter; OR lets try some differential trickery to grab the original, boost it to get the phase shifts; drop it; invert it against an untouched original; sum them; blah blah blah..." 

The differential trickery version was almost getting there, and then not working (basically created a differential conundrum!); and the filter approach (which I DO actually think would work) was getting a little confusing too...

So in fine jBam style, I stumbled upon a strange phenomenon during this test and then nailed the solution I posted... Well suits my idea for an audio company I've mentioned here before: "Oops Audio Electronics"  ;D

What I realised is that:

At very very low gain (anything above unity; but e.g. lower than 6dB), the opamps I've been looking at actually have a reverse phase effect on the signal for a given range (resonance for want of a better expression)...  At mid to high gain, this drops off to be more like a standard 1 pole filter with zero resonance...  This roll off commences at roughly the same point regardless, which I assume is defined by internal resistance / capacitance(?) within the opamp...

So within the audio spectrum, we have the ability to have a positive phase angle shift; and a negative phase angle shift with the same component type --> Cool!

Somewhere between these values is a flat line (in theory, although I couldn't really get that :)...)... And it's all about the divider network chosen in the amp path...  e.g. if you have 50k in the feedback loop; then a certain R to ground value in the divider can be adjusted to tweak negative phase shift upward toward positive phase shift until it's basically flat...  I found this to be VERY interesting and cool; as it's exactly the outcome I was after!!

Also interesting is that a different feedback loop value (e.g. 10k) has a very different relationship with the divider value to achieve zero phase - assumed to relate back to the internal resistance / capacitance of the opamp...  The point that I've realised is:  any given feedback resistor has a corresponding divider value that minimises phase delay!

I've now actually pushed ahead with a multiple opamp daisy-chained design with a first opamp amping it up quite a lot with notable phase delay; and a second one at very low gain being used to then adjust this phase delay back to zero through the audio band.  This is the attached doc (now also expanded out to 10MHz; where we can see:

- Red - same instrumentation amp at around 80dB gain;
- Green - Same single opamp cranked up to around 80dB gain;
- Blue - my circuit - nice and flat through to 200kHz, but yes - almost resonating up around 1MHz (which I assume I can filter out with a steeper filter and avoid phase issues "down south"  :)

And yes - at the bottom there... one version of my embarrassingly simple circuit!.. all tweaked out to get the performance noted.  The first two opamps are a pair, combating each other's phase alignment; and the second two are a pair as well doing the same... (4 opamps in the chain; but effectively really only two gain stages)

Daisy chaining is possibly why my noise is high (if that IS high... still confused of course!!)

Naturally having a continuously variable gain would be an insane nightmare to set up - as noted above, the relationship between the loop and divider resistors is very finicky; and both would need to vary to get correct performance... I shudder at the thought of calibrating that even if it were possible with non-custom pots haha...  Although maybe I'm missing something here; perhaps they have a basic relationship that I'm missing or something (they probably will - this is all math at the end of the day!)... Anyway, I'll aim for a fixed resistor network / switching etc...  I'll chat more about ideas for this another time though... This post is getting insanely long (sorrry!)...
 

Attachments

  • Basic Linear Amp and AC Plot.jpg
    Basic Linear Amp and AC Plot.jpg
    293.2 KB
Any opamp falls at the top.

A unity-stable opamp at low gain may rise before it falls.

You are magic-value tinkering to get the two effects to "cancel" inside the audio band.

Who needs gain of 80dB in audio? -120dB EIN comes out at -40dB, or 44dB signal to noise re: a +4dB nominal level. "Average AM radio". SM58 on a Fender Twin comes out at 1,000 Volts!! (or is clipped flat at 13V like a well ironed shirt).

How are you going to turn-down that gain for various acts?

Your hiss is at-least the 1K resistor in the first stage, audibly higher than the hiss of 200 Ohm microphone. If you honestly want high gain with low hiss, that 1K should be smaller.

 
PRR said:
Who needs gain of 80dB in audio?

Certainly not me!!  ;D...  Sorry - should've been more pragmatic in my typical excited-style post!...  Just pulled this graph from one of many versions I was tweaking... Kind of interested in how far I could push it, as roll off and phase delay move lower down the frequency spectrum with gain...  I have another 140dB gain version if you like PRR!  ::) :p :-X

PRR said:
You are magic-value tinkering to get the two effects to "cancel" inside the audio band.

Yup!  totally :)...  Note that with a more practical design (that I hope to develop), I'd be looking to do a stepped resistor configuration though - so not intended to be a fixed gain amp hitting only the sweet spot for one resistor combo!... Basically, I've observed that larger resistor values (in general) allow MORE gain at the sweet spot; lower values less gain etc...  but yes - so reading you comments quoted below, this does raise noise concerns if a resistor over 200Ohms is actually a noise problem(?!)...  This would limit gain to around 30dB if I recall correctly from my sims...  Bit lean in my opinion!...  But still super linear :)

PRR said:
Your hiss is at-least the 1K resistor in the first stage, audibly higher than the hiss of 200 Ohm microphone. If you honestly want high gain with low hiss, that 1K should be smaller.

Yes - cool ok... I'm only really just now starting to learn about / investigate noise and its sources...  A quick question - so if I have a 200Ohm impedance only in a circuit; does that ADD to a 200Ohm source noise; or does it mean that it is negligible to the source noise (matches it)...  If that makes sense?!  As always - - -  a LOT to learn still :)...
 
LT1115 has perhaps the wonkiest phase response of any general purpose chip opamp. That is why you are getting contradictory responses in hi-gain and low-gain stages which you may try to balance-off.

The datasheet says the chip is mostly not suitable for low gain. They are warning you off from its wonkiness.

The absolute value of the NFB resistors should NOT be "magic" for the gain/phase response; only the relative values. Try 4K7 and 100r instead of 47K and 1K. If SPICE tells you different, suspect model error.

Real chips will NOT match the model. The inflections in the phase curve will vary +/-30% depending how they cook the wafer that day. While this *may* "match" between your low-gain and your high-gain (assuming same wafer), it may not. Undocumented and only indirectly controlled (by currents and diffusions).

The datasheet is good, to a point. I suspect there are un-mentioned vipers that get angry when you work it to the corners of frequency and gain. But there's good examples of low-hiss design (not the transformerless mike amp, that's just piss).

The path to high gain AND wide bandwidth (flat phase) is VERY well trod by Radar, IF, and Video amplifiers, and especially oscilloscope circuits. For any available technology, GBW is limited. To get both, build low gain high bandwidth stages and cascade them as needed. NFB is problematic over multiple stages, take it a few stages at a time. ("Distributed" amplifiers are the alternative, but make sense only when working at the very maximum frequency of the technology, >400MHz for penny transistors, and then only when total gain is not large.)
 
jBam said:
A quick question - so if I have a 200Ohm impedance only in a circuit; does that ADD to a 200Ohm source noise; or does it mean that it is negligible to the source noise (matches it)...  If that makes sense?!  As always - - -  a LOT to learn still :)...
The two noise sources are uncorrelated and of equal power. When these powers add the total noise is 3dB higher.

In almost all designs, the final noise is dominated by the noise of the very first stage. To make it insignificantly less than the noise of the source resistance the lowest noise source in the first stage needs to be 10dB below the noise of the source which means the the circuit resistance needs to be one tenth - so for a 200 ohm source this needs to be 20 ohms.

Cheers

Ian
 
JohnRoberts said:
Coincidentally I was asked off list for a link to this old article I wrote.  http://www.johnhroberts.com/des_art_1.pdf  While several decades old, the op amp basics still hold water.

JR

PS: ignore the part where I misspelled bus...  :eek:

Ignore where I misspelled bus, but reading the rest of the article I linked to could answer some of your questions about op amp behavior wrt closed loop gain.

I see no point in repeating specific points when the link was this handy. 

The article may be almost 40 YO but op amps and negative feedback are even older.    8)

JR
 
Phase response does not have to be zero to have "no effect", it can also just be linear. A linear phase response is equivalent to a delay, and since the whole point of recording and reproduction is to insert a user controlled delay between the performance and the playback, any extra delay should be seen as part of the desired effect. Delay alone has no "sound".

It's also helpful to distinguish between the open loop response of an amplifier and its closed loop response. Open loop is the result of what the metal does, and closed loop is what actually you get when you use the raw amplifier in a real circuit. So, even though a dominant pole op amp has (hopefully) 90 degrees of open loop phase shift almost everywhere,  the closed loop phase can be close to zero at low frequencies, and then increasing as you approach the unity gain turnover.

Arranging for a feedback loop to result in a linear closed loop output phase or magnitude is a worthwhile goal, but it's not usually done by messing with the open loop amplifier - that usually is not possible with a monolithic amplifier anyway, nor is it desirable.
 
Monte McGuire said:
Phase response does not have to be zero to have "no effect", it can also just be linear. A linear phase response is equivalent to a delay, and since the whole point of recording and reproduction is to insert a user controlled delay between the performance and the playback, any extra delay should be seen as part of the desired effect. Delay alone has no "sound".

It's also helpful to distinguish between the open loop response of an amplifier and its closed loop response. Open loop is the result of what the metal does, and closed loop is what actually you get when you use the raw amplifier in a real circuit. So, even though a dominant pole op amp has (hopefully) 90 degrees of open loop phase shift almost everywhere, 
Actually the open loop phase shift is only above the dominant pole... Some op amps have a pole that starts relatively low, some in the upper midrange.  This is not hugely import for low closed loop gain circuits, where a high loop gain margin and NF reduce it to insignificance.

Hopefully the phase shift will be controlled and relatively insignificant within the audio band.

JR

PS: This is in my article too
the closed loop phase can be close to zero at low frequencies, and then increasing as you approach the unity gain turnover.

Arranging for a feedback loop to result in a linear closed loop output phase or magnitude is a worthwhile goal, but it's not usually done by messing with the open loop amplifier - that usually is not possible with a monolithic amplifier anyway, nor is it desirable.
 
Hi all -really appreciate the responses all :)...  Have a had a hectic few things pop up at work, so only really reading through all of this stuff now!

PRR - many thanks for your time and comments there too - you and many others here obviously have a wealth of experience, and I'm really pleased to have an opportunity to draw on it all as I fumble around in electronics and ideas!  e.g. - totally wouldn't have guessed that the LT1115 is effectively a wonky piece of kit from the data sheet; but I now have a few tips on how to keep an eye out for questionable phase performance!

Might start tinkering with some of the recommended opamps in one of the posts here [wait - I'm I loosing my mind; I could have sworn someone posted an opamp shootout link here?!  I remember reading it!?>!...  maybe it HAS been a hectic couple of days!?!].

What I'm enjoying most with my thinking and tinkering is:  Kinda the theoretical stuff... I'm currently less concerned about whether ideas are good or bad (haha... I mean, I WANT them to be good, but happy if they're not!)... really enjoying mucking around with ideas; dreaming up concepts and solutions to issues I've read about and applying them (whether good solutions or not)... I've really learnt a heap in the past couple of years of very very part time electronics...!!  and of course, I'm learning a sh#t load from you all here... So thanks!

JohnRoberts said:
Ignore where I misspelled bus, but reading the rest of the article I linked to could answer some of your questions about op amp behavior wrt closed loop gain.
...

I'm onto it John... Looking forward to it actually - had meant to hit the front porch with a beer and your article yesterday before the work explosion - bedtime reading tonight I'm thinking ;)

On the opening topic - this concept still interests me of course!... extending linear phase responses / counteracting phase delays etc... So gonna keep pushing around in this area for a bit I think!...  AS far as I've messed around the other day; I seemed to be able to trick a handful of LT opamps into similar behavior, so charged with some new found noise concerns(!), I'm keen to keep messing around here (ideally with a really solid opamp for this purpose too!)...

Please keep the discussion going if there's things to add; or else I'll post up any new questions / discussion / solutions when they arrive!!...
 
JohnRoberts said:
Coincidentally I was asked off list for a link to this old article I wrote.  http://www.johnhroberts.com/des_art_1.pdf  While several decades old, the op amp basics still hold water.

JR

PS: ignore the part where I misspelled bus...  :eek:

Great 'nuts and bolts' view of  practical design considerations.
Figs 3 and 4 (Inverting / Non-Inverting Op amp gain stages appear to be swapped ?)
 
Newmarket said:
Great 'nuts and bolts' view of  practical design considerations.
Figs 3 and 4 (Inverting / Non-Inverting Op amp gain stages appear to be swapped ?)
Wow in almost 40 years I don't think I noticed that, or did and forgot about it.... 

Thanks for actually looking at it.

Maybe I can correct it , but not today.

JR

 
> a wonky piece of kit

The "ski jump" in the phase curve is unusual for general purpose opamps.

Compare to a very tame opamp, TL072.

In 1990s ICs, devices don't run well much over 3MHz. A multi-stage amplifier may have 3 or 4 of these 3MHz roll-offs and phase-shift tending toward 360 deg, and crossing 180 deg (oscillation) at some point.

The all-purpose fix is to pick one stage and clobber it so that the overall gain is less than unity by about 3MHz. In a high-gain (200,000X) chip the roll-off may start in audio bass. The phase shift is a constant 90 deg over many decades of frequency. Getting near 3MHz the other poles add shift. It is Generally Assumed that 135 deg shift (45 deg margin from 180 deg oscillation) is OK, more is bound to be bad.

The TL0 part has simple gain and phase and is specified to be tame down to unity gain.

TI grinds out chips a mile a minute. Linear Tech can't compete with TI in general-purpose chips. LT's niche includes a guy who computes lead-lag networks. When the LT1115's phase shift gets to 135 deg (45 deg margin), gain is manipulated with an added R-C network. This reduces phase for a while, but then it comes back worse. The net result is maybe 8X the gain and bandwidth. A drawback is that it is very critical, and *appears* to be not-stable for gain less than about 2? (Unity gain phase margin is less then zero.) For some gains around 2, the closed-loop response will bump-UP before finally falling off.
 

Attachments

  • LT1115-TL072.gif
    LT1115-TL072.gif
    19.3 KB
JohnRoberts said:
Wow in almost 40 years I don't think I noticed that, or did and forgot about it.... 

Thanks for actually looking at it.

Maybe I can correct it , but not today.

JR

You're more than welcome.
It's soooo easy to not notice that sort of thing when you 'know' what the text / diagram says and you don't really need to read it - 'cos you wrote / drew it  :)
I think I only really noticed it because reading the scan of the article on my quite poor quality screen it was difficult to be sure which were the  + / - inputs marked on the op amp symbol.
Cheers.
 
Newmarket said:
You're more than welcome.
It's soooo easy to not notice that sort of thing when you 'know' what the text / diagram says and you don't really need to read it - 'cos you wrote / drew it  :)
I think I only really noticed it because reading the scan of the article on my quite poor quality screen it was difficult to be sure which were the  + / - inputs marked on the op amp symbol.
Cheers.
Upon reflection I suspect I discovered it after it went to press and may have even printed an errata in the following issue, but that was almost 40 years ago so one of many small details I forgot over the decades.

If I am going to keep sharing it I may need to try to fix it somehow (and spell bus properly). 

JR
 
Back
Top