Quick confirmation about opamps - Page 1
Forum section: electronics / beginners

author: ilbs
author_rank: Contributor
timestamp: October 22, 2013, 06:15:05 pm
content: Hello,I would like to lead up to something. But before I do, can someone confirm that the attachment is correct:

author: ilbs
author_rank: Contributor
timestamp: October 22, 2013, 07:22:03 pm
content: Sorry, guys, I got what I was trying to solve.... sometimes I am sleeping on the gaz!!!!So don't mind me!

author: Andy Watson
author_rank: Super Contributor
timestamp: October 22, 2013, 07:23:29 pm
content: Why am I getting that strange déjà-vu feeling about this?First problem: I calculate G1 to be closer to 1.

author: ilbs
author_rank: Contributor
timestamp: October 22, 2013, 07:27:08 pm
content: Hi Andy,It would work fine with G1 being 2 no?

author: Andy Watson
author_rank: Super Contributor
timestamp: October 22, 2013, 07:36:05 pm
content: No.

author: ilbs
author_rank: Contributor
timestamp: October 22, 2013, 07:45:35 pm
content: But I built that circuit and it does exactly that... 9 to 12 in gives 3.5 to 6.3V outboffyes, on the diagram G1 is 1 not 2... !But what I meant was:G1=(1+rf/ra) where G1 is 2G1 being the gain at non invert input

author: ilbs
author_rank: Contributor
timestamp: October 22, 2013, 08:54:05 pm
content: So getting back at my initial question, if going down this calculation path works for the circuit, thenusing the same calculation technique wouldn't work if we kept everything the same but wanted say, 3.5 to 6.0Vdc as Vout !!!So what now?

author: Andy Watson
author_rank: Super Contributor
timestamp: October 22, 2013, 09:58:08 pm
content: Quote from: ilbs on October 22, 2013, 08:54:05 pmHint, your original circuit would give better results if Rf was 9.8k, i.e. G1 (by your revised definition) should actually be 1.98, not 2.

author: ilbs
author_rank: Contributor
timestamp: October 22, 2013, 10:07:51 pm
content: QuoteThat's not my question, I know that 1.98 it would work as well... and on top of that, r1 and r2 would need to change to 5286 and 4713 respectively.But what I am saying is that in reference to my initial circuit, those resistors and that calculation... it does check out with a G1 of 2.0 see attachment below.However my question is, if we redo the exact circuit with the same calculations as in initial post except that the Vout is 3.5 to 6.0Vdc.... it doesn't work because somehow in those calculations we are not taking into account the full ramp? I am trying to use the same method of calculations as I did in the initial example but for a different Vout ramp of 3.5-6.0 Vdc instead of 3.5-6.3Vdc

author: Andy Watson
author_rank: Super Contributor
timestamp: October 22, 2013, 10:21:51 pm
content: Because it's only a 1% difference. I note your Vout isapprox6.333V. Try Rf=9.8k, R2=4.72k, R1=5.286.(And good luck finding those resistor values)Quote from: ilbs on October 22, 2013, 10:07:51 pmThe original question involved an input range of 9-12V, and an output range of 3.5-6.3, i.e. an overall gain of 2.8/3, as near to 1.0 as makes little difference. But the latest question requires an output range of 3.5-6, i.e 2.5/3, that's a much bigger difference.Edit: "...as near to 1.0 as makes little difference" when you take G2 in to account too.

author: ilbs
author_rank: Contributor
timestamp: October 23, 2013, 03:13:10 am
content: Quoteexactly! And how can we calculate r1, r2, and rf usingthe same calculation method shown in initial post???my guess is we can't!!!!I know how to solve it using a different method...which is not a problem, but don't think we can usingthe mathematical method as shown in initial circuit???thanks

author: Andy Watson
author_rank: Super Contributor
timestamp: October 23, 2013, 09:27:00 am
content: I still think that defining this problem as formulae obfuscates the circuit action. However, see if this gets you somewhere:Define G1= Rf/ Ra.Define G2= R2/ (R1+ R2).Vout= V2[G2( 1 + G1)] - V1G1. This is the first equation that you have in one of your posts above. I'm guessing the bit that you're stuck on is defining the part in square brackets, [G2(1 + G1)] ? Lets define this as Gdash. So. Vout= V2Gdash- V1G1.Take the maximum value of Voutand subtract the minimum (i.e. the range).Vout Max- Vout Min= (V2 Max- V2 Min) Gdash- V1G1- - .V1G1.V1G1has cancel out, leaving Gdash= (Vout Max- Vout Min) / ((V2 Max- V2 Min). Now you have a value for Gdash, plug it back into the formula for Voutwith any pair of Voutand V2values to find G1. You can do the rest.

author: ilbs
author_rank: Contributor
timestamp: October 24, 2013, 02:36:03 pm
content: Hi Andy,I did what you said, but it don't work for me. Gdash works for 9.0 volts in, but for 12 volts in, Vout is wrong!Here is my work!Discouraged!ilbs

author: Andy Watson
author_rank: Super Contributor
timestamp: October 24, 2013, 04:42:48 pm
content: Ok, I give in. Here's the working, in full:

author: ilbs
author_rank: Contributor
timestamp: October 26, 2013, 03:36:42 pm
content: Thank you Andy!That's very nice of you to provide the solution in full....The way I see it, we really can't solve by simply using the math equation as shown in my initial thread which was:((Vin)(Gn)-Vgnd)(G1)=Vout-Vgndsince there is two unknowns (Gn and G1) and since we need to know atleast one of the correct gains, the equation won't work. I tried plugging in a value for Gn or G1 and solving for the other, but this didn't work for other examples, and as you said, it worked above because it was a fluke that G1 was really very close to 2, and coincidentally, it was the same number I had selected. I think that the equation shown above can be used as a check formula... I guess!Thanks for the solution I appreciate it... I apologize for the delay of my response....