Summation circuit using an op-amp

I have two voltage sources V1, V2

I want my output voltage to be 4V2 - V1

Im using a single op-amp and up to 4 resistors: (Only one is shown here and It's set as 10k Ohm) I can add 3 more.

I know how to create functions where I sum only negative voltages ( -V1 -4V2 - V3 ...) But I have no idea how to execute what I mentioned above, any help would be appreciated ! thanks.

My try:

Which sorts out the -V1 part of my output, but gives only 2*V2. I don't know how to procceed.

• @devnull up to 3 resistors. I will edit my post Jul 17 at 13:13
• Edward, I wonder what is the name of the simulator used for the schematics above? (I also posted an answer below). Jul 17 at 13:48

I don't know how to proceed.

This should work if I'm not too mistaken: -

If you need to use 4 resistors then 2 parallel 10k resistors = 5k. Now, all resistors are the same value too.

• This indeed works for me, I'm Still trying to figure out the thought proccess which led you to the solution. thank you! Jul 17 at 13:50
• @EdwardJosef ah the good-old thought process!!! I'm unsure myself other than to say "experience". Jul 17 at 13:53
• I'd add a 5k resistor in series to the negative input to compensate for DC offset. Jul 17 at 16:01
• @F.Heisenberg I think you mean the non-inverting input (only needed for crappy op-amps with poor input bias currents). Jul 17 at 16:11
• Sorry of course I meant the non inverting input Jul 17 at 16:12

You pretty close, here's a circuit that does 4V2 - V1.

The top op amp multiplies by 4, the bottom one multiplies by -1.

4*V1 and -1*V2

The middle between the 10k resistors is the average:

(4*V1 - 1 * V2) / 2

The last op amp multiplies by 2:

((4V1 - 1 * V2) / 2) * 2 = 4V1 - 1*V2

Could you please share in the comments the name of the simulator you used for the schematics in your question?

• It seems there is a constraint: "using a single opamp and up to 4 resistors". Jul 17 at 13:48
• You're right I see. On the other hand, I believe it was just a statement of the initial parts he's using. Jul 17 at 13:53

An inverting opamp sums inputs. I turned around the inputs so that the inverted output is positive.