The Core Op Amplifier Gain Formula and Symbol Definitions

When designing analog front-ends, the op amplifier gain formula dictates how your input signal scales to the output. While an ideal operational amplifier has an infinite open-loop gain (typically 100,000 to 1,000,000 in real silicon), we never use it open-loop for linear amplification. Instead, we use negative feedback to set a precise, stable closed-loop gain.

The two foundational topologies are the Non-Inverting and Inverting configurations. The non-inverting formula is the most common source of bench errors because of the easily forgotten +1 term.

Non-Inverting Closed-Loop Gain:
A_v = 1 + (R_f / R_i)

Inverting Closed-Loop Gain:
A_v = -(R_f / R_i)

Symbol Definitions and Typical Bench Values
Symbol Definition Typical Bench Range
A_v Closed-loop voltage gain (dimensionless ratio, V/V) 1 to 100 (linear)
V_out Output voltage relative to ground Bounded by supply rails (e.g., 0V to 5V)
V_in Input voltage at the non-inverting (+) or inverting (-) terminal mV to low V range
R_f Feedback resistor (connects output to inverting input) 1 kΩ to 1 MΩ
R_i Input/Ground resistor (connects inverting input to signal or ground) 1 kΩ to 100 kΩ
Core Assumption: These formulas assume an ideal op-amp: infinite input impedance (no current enters the input pins), zero output impedance, and infinite open-loop gain. For 95% of DC and low-frequency audio applications using parts like the TL072 or NE5532, this assumption holds true enough for hand calculations.

Rearranged Forms: Solving for Any Variable

On the bench, you rarely solve for A_v directly. Usually, you know your required gain and your available resistor values, or you know your signal levels and need to find the resistor ratio. Here are the algebraic rearrangements for the non-inverting topology:

  • Solve for Feedback Resistor: R_f = R_i * (A_v - 1)
  • Solve for Input Resistor: R_i = R_f / (A_v - 1)
  • Solve for Output Voltage: V_out = V_in * (1 + (R_f / R_i))
  • Solve for Input Voltage: V_in = V_out / (1 + (R_f / R_i))
  • Solve for Gain (from voltages): A_v = V_out / V_in

Note: For the inverting topology, drop the +1 and apply a negative sign to A_v when calculating resistor ratios. The magnitude of the gain is simply |A_v| = R_f / R_i.

Bench-Tested Solved Problems with Unit Tracking

Abstract math fails when units get mixed. Here are two worked examples with explicit unit tracking to prevent scaling errors.

Problem 1: Non-Inverting Sensor Amplifier

Goal: Amplify a 15 mV thermocouple signal to exactly 3.0 V using a non-inverting configuration. You have a 2.2 kΩ resistor for R_i. What value must R_f be?

  1. Calculate Required Gain:
    A_v = V_out / V_in
    A_v = 3.0 V / 0.015 V = 200 V/V
  2. Rearrange Formula for R_f:
    R_f = R_i * (A_v - 1)
  3. Substitute and Track Units:
    R_f = 2.2 kΩ * (200 - 1)
    R_f = 2.2 kΩ * 199
    R_f = 437.8 kΩ

Bench Reality: 437.8 kΩ is not a standard E24 resistor value. You would use a 430 kΩ fixed resistor in series with a 10 kΩ trimpot to dial in the exact gain during calibration.

Problem 2: Inverting Audio Preamp

Goal: Design an inverting preamp stage with a gain magnitude of 10. If R_f is chosen as 100 kΩ to minimize thermal noise, what is R_i and what is the output if the input is -50 mV?

  1. Calculate R_i:
    |A_v| = R_f / R_iR_i = R_f / |A_v|
    R_i = 100 kΩ / 10 = 10 kΩ
  2. Calculate V_out with Unit Tracking:
    V_out = V_in * (-R_f / R_i)
    V_out = -50 mV * (-100 kΩ / 10 kΩ)
    V_out = -50 mV * (-10) = +500 mV (or 0.5 V)

Real-World Scenario: When the Math Meets the Silicon

Formulas assume ideal components. Silicon has hard physical limits. Here is a classic bench failure that demonstrates why you must look past the op amplifier gain formula and check the datasheet.

The Setup:
You need to amplify a 0–50 mV DC sensor signal to a 0–5.0 V range for an Arduino ADC. You choose a non-inverting topology. You power an LM358 op-amp from a single 5.0 V supply (V_CC = 5V, GND = 0V). You select R_i = 1 kΩ and R_f = 99 kΩ.

The Numbers:
A_v = 1 + (99 kΩ / 1 kΩ) = 1 + 99 = 100.
At maximum input (V_in = 50 mV), the math predicts:
V_out = 50 mV * 100 = 5000 mV = 5.0 V.

The Outcome:
You breadboard the circuit. At 10 mV input, the output reads 1.0 V (perfect). At 30 mV input, it reads 3.0 V (perfect). But at 50 mV input, your multimeter reads 3.6 V. The signal is heavily clipped and non-linear above 38 mV input.

What Went Wrong:
The math didn't fail; the component choice did. The LM358 is a legacy bipolar op-amp. It is not a rail-to-rail output device. According to the Texas Instruments LM358 datasheet, the maximum output voltage swing on a 5V supply is typically V_CC - 1.5 V. Therefore, the physical silicon cannot push the output pin above ~3.5 V to 3.8 V, regardless of what the gain formula demands. The op-amp saturated.

The Fix: To get a true 0–5V swing from a 5V supply, you must swap the LM358 for a modern CMOS rail-to-rail I/O op-amp like the MCP6001 or TLV2462, or increase the LM358's supply voltage to 9V and use a voltage divider at the output.

Critical Assumptions and Unit Mistakes That Break the Math

To use the op amplifier gain formula reliably, you must understand its boundaries. Here is when the formula applies, what realistic magnitudes look like, and the unit traps that ruin prototypes.

When the Formula Applies (and When It Doesn't)

The closed-loop gain formulas assume you are operating within the mid-band frequency range and within the output voltage swing limits. If you design a non-inverting amplifier with a gain of 100 using a TL072 (Gain-Bandwidth Product of 3 MHz), the formula A_v = 100 is only valid up to 30 kHz. At 300 kHz, the op-amp runs out of internal open-loop gain, and your actual closed-loop gain will drop significantly below 100. Always verify your target frequency against the op-amp's GBWP.

What a Realistic Answer Magnitude Looks Like

Beginners often confuse open-loop gain with closed-loop gain. If your calculation yields an A_v of 120,000, you have likely calculated the open-loop gain (or made a unit error). In practical linear circuits, closed-loop gain (A_v) is almost always between 1 (a unity-gain buffer) and 100 (40 dB). Gains higher than 100 in a single stage invite excessive noise, DC offset amplification, and severe bandwidth restriction. If you need a gain of 10,000, cascade two stages of 100.

Unit Mistakes That Break the Calculation

The most common reason a calculated resistor network fails on the bench is a unit mismatch in the ratio calculations:

  • The mV vs. V Trap: When calculating required gain from signal levels, both voltages must be in the same base unit. A_v = 5 V / 50 mV is mathematically invalid if you just divide 5 by 50 to get 0.1. You must convert: 5 V / 0.050 V = 100.
  • The kΩ vs. Ω Trap: In the resistor ratio R_f / R_i, the units cancel out, but only if they match. If R_f = 100,000 Ω and R_i = 10 kΩ, dividing 100,000 by 10 yields a false gain of 10,000. Convert both to kΩ first: 100 kΩ / 10 kΩ = 10.
  • The Inverting Sign Trap: Forgetting the negative sign in A_v = -(R_f / R_i) won't change your resistor values, but it will cause you to wire your ADC or microcontroller expecting a positive voltage when the op-amp is actually driving the signal negative, potentially damaging the MCU's input pins if clamping diodes aren't present.

For a deeper dive into how feedback networks interact with op-amp input bias currents and offset voltages, refer to the comprehensive guides on Electronics Tutorials and All About Circuits. Mastering the formula is step one; respecting the silicon's physical limits is step two.