Toolvito

Works on this device

Op Amp Gain Calculator

An operational amplifier (op amp) with two resistors makes an amplifier whose gain depends only on those resistors. Choose the kind of stage and enter the resistors to get the gain as a number and in decibels. You can also find the resistor for a gain you want.

Enter your values

The signal goes through Rin to the inverting (−) input, and Rf goes from the output back to that input. The output is upside down.

Your values

From the signal source to the inverting (−) input.

From the output back to the inverting (−) input.

With a voltage, the result also shows the output voltage. A negative value is allowed.

From the data sheet of the op amp, where it is also called unity-gain bandwidth. With it, the result shows the bandwidth of the stage.

Your values are worked out in this browser. They are not sent to a server.

Your result will show here

Fill in the values, then choose Calculate.

How to use this calculator

  1. Choose the kind of stage: Inverting amplifier, Non-inverting amplifier, Differential amplifier or Summing amplifier.
  2. Under Find, choose the gain, or the resistor for a gain you want.
  3. Enter the resistors and pick the unit of each: Ω, kΩ or MΩ.
  4. To get the output voltage, enter an input voltage. To get the bandwidth of the stage, enter the gain-bandwidth product from the data sheet of your op amp.
  5. Choose Calculate. The result shows the gain, the gain in decibels and the working.

The op amp gain equations

  • Inverting amplifier: gain = −Rf ÷ Rin. The output is upside down.
  • Non-inverting amplifier: gain = 1 + Rf ÷ Rg. The gain is never below 1.
  • Differential amplifier: Vout = V2 × (R4 ÷ (R3 + R4)) × (1 + R2 ÷ R1) − V1 × (R2 ÷ R1). With R2 ÷ R1 = R4 ÷ R3 this is (R2 ÷ R1) × (V2 − V1).
  • Summing amplifier: Vout = −Rf × (V1 ÷ R1 + V2 ÷ R2 + …).
  • Gain in decibels: 20 × log10(gain). A gain of 10 is 20 dB, and a gain of 100 is 40 dB.
  • Bandwidth: gain-bandwidth product ÷ noise gain. The noise gain is 1 + Rf ÷ Rin for an inverting stage and the gain itself for a non-inverting stage.
  • Rf is the feedback resistor, from the output to the inverting (−) input.

Worked examples

Inverting. Rin = 10 kΩ and Rf = 100 kΩ: gain = −100 ÷ 10 = −10, which is 20 dB. An input of 0.1 V gives an output of −1 V. With an op amp whose gain-bandwidth product is 1 MHz, the noise gain is 11 and the bandwidth is 1,000,000 ÷ 11 = 90.9 kHz.

Non-inverting. Rg = 10 kΩ and Rf = 100 kΩ: gain = 1 + 100 ÷ 10 = 11, which is 20.83 dB. With the same op amp the bandwidth is also 90.9 kHz.

Differential. All ratios 100 kΩ to 10 kΩ, V1 = 2.4 V and V2 = 2.5 V: the output is 10 × (2.5 − 2.4) = 1 V. The 2.4 V that both inputs share is rejected.

Summing. Rf = 10 kΩ with inputs of 1 V through 10 kΩ, 2 V through 20 kΩ and −0.5 V through 10 kΩ: Vout = −(1 + 1 − 0.5) = −1.5 V.

What an ideal op amp means

  • No current flows into the two inputs.
  • The gain of the op amp itself is so large that its two inputs stay at the same voltage. This is why the gain of the stage depends only on the resistors.
  • The output can supply any voltage. A real output stays inside its supply voltages, and many types stop a volt or two short of them.
  • A real op amp is close to this at low frequency. As the frequency rises its own gain falls, and the stage loses gain above its bandwidth.

Limits you should know

  • The gain is for an ideal op amp and exact resistors. Resistor tolerance changes the real gain: two 1% resistors can move it by up to about 2%.
  • No op-amp data is built in. The gain-bandwidth product and the slew rate come from the data sheet of your part, and the example values are only for trying the tool.
  • The bandwidth value is for small signals and an op amp with one pole. Offset voltage, bias current, noise and stability with a capacitive load are not worked out.
  • The tool does not design filters. Active filters need their own formulas.
  • This is arithmetic for learning and for low-voltage electronics. It is not professional advice; check a real design against the data sheet of the op amp.

Related tools