op amp gain calculator

Calculate Closed-Loop Op-Amp Gain

Use this calculator for inverting and non-inverting op-amp designs. You can solve for gain, feedback resistor, or input/ground resistor.

Inverting formula: Av = -Rf / Rin

What this op amp gain calculator does

This tool helps you quickly compute closed-loop voltage gain for common operational amplifier circuits. It supports two standard topologies:

  • Inverting amplifier (output is phase-inverted by 180°).
  • Non-inverting amplifier (output stays in phase with input).

In addition to direct gain calculation, you can choose a target gain and solve for the required resistor values. This is useful when selecting components for analog filters, signal conditioning stages, sensor interfaces, and preamp circuits.

Core formulas

Inverting amplifier gain

Av = -Rf / Rin

  • Rf: feedback resistor between output and inverting input.
  • Rin: input resistor from signal source to inverting input.
  • Negative sign indicates phase inversion.

Non-inverting amplifier gain

Av = 1 + (Rf / Rg)

  • Rf: feedback resistor from output to inverting input.
  • Rg: resistor from inverting input to ground.
  • Gain is always positive and greater than or equal to 1 in ideal form.

Gain in decibels

Once voltage gain is known, convert to decibels with: Gain(dB) = 20 * log10(|Av|).

How to use the calculator

  1. Select Configuration: inverting or non-inverting.
  2. Select Solve for: gain, Rf, or Rin/Rg.
  3. Enter the known values in kΩ and click Calculate.
  4. Read the result, including gain magnitude and dB equivalent where applicable.

Design tips for real-world op amp circuits

1) Keep resistor values reasonable

Typical resistor choices from about 1 kΩ to 100 kΩ are common. Very low values increase current draw; very high values can increase noise and bias-current error.

2) Check gain-bandwidth product (GBW)

Closed-loop gain and bandwidth trade off against each other. If your op amp has limited GBW, high gain can significantly reduce usable frequency response.

3) Verify output swing and supply rails

Even if gain math is correct, output clipping occurs if expected output exceeds what the op amp can deliver on your supply voltage.

4) Consider slew rate at higher frequencies

A large, fast output signal may become distorted if the device cannot change voltage quickly enough.

5) Mind tolerance and offset

Real components have tolerance. Use precision resistors where gain accuracy matters, and account for offset and input bias currents in precision applications.

Quick examples

Example A: Inverting stage

If Rf = 47 kΩ and Rin = 10 kΩ, then Av = -47/10 = -4.7.

Example B: Non-inverting stage

If Rf = 100 kΩ and Rg = 10 kΩ, then Av = 1 + 100/10 = 11.

FAQ

Can I enter resistor values in ohms instead of kΩ?

Yes, as long as both resistor inputs use the same unit. The ratio determines gain, so units cancel.

Why does inverting gain show a negative sign?

The negative sign indicates a 180° phase shift between input and output, not a negative amplitude in the physical sense.

Can I use this for AC signals?

Yes for mid-band closed-loop gain estimates. For full AC behavior, also analyze input/output coupling capacitors, frequency compensation, and source/load impedances.

🔗 Related Calculators