# Electronics/Op-Amps/Linear Configurations

## Inverting Op Amp

The closed loop gain "mon then" of an Inverting Op Amp is

${\displaystyle R_{1}=R_{in}}$
${\displaystyle A_{f}=-{\frac {R_{f}}{R_{1}}}}$ (i)

Input Impedance of this configuration is ${\displaystyle Z_{in}=R_{in}}$ (because ${\displaystyle V_{-}}$ is a virtual ground, no current flows into the Op Amp ideally.)

To get formula (i) we take a KVL loop with ${\displaystyle V_{in}}$, ${\displaystyle R_{1}}$ and the inputs of the Op Amp. This gives

${\displaystyle V_{in}=i_{in}R_{1}+v_{d}\,}$

Where ${\displaystyle v_{d}}$ is ${\displaystyle v_{+}-v_{-}}$ the voltage between the non-inverting and inverting inputs. But for ideal Op Amps ${\displaystyle v_{d}}$ is approximately zero. ${\displaystyle v_{d}}$ is zero because the input impedance is infinite, which means the current through the impedance must be zero by Ohms law. The zero current means that there is no voltage drop across the impedance. This gives:

${\displaystyle i_{in}={\frac {V_{in}}{R_{1}}}}$ (5)

Using this idea.

${\displaystyle i_{f}={\frac {V_{out}}{R_{f}}}}$(6)

If we take KCL at the inverting input then

${\displaystyle i_{in}=i_{d}-i_{f}\,}$

For an ideal Op Amp there is no input current because there is infinite resistance. So using equations 5 and 6.

${\displaystyle -{\frac {V_{in}}{R_{1}}}={\frac {V_{out}}{R_{f}}}}$

Since

${\displaystyle A_{f}={\frac {V_{out}}{V_{in}}}=-{\frac {R_{f}}{R_{1}}}}$

Example 1

Design an Inverting Amplifier to amplify a 100mV signal to 1V signal. Assume: No source impedance.

Solution:

Step 1: Work out required gain.

${\displaystyle |A_{f}|={\frac {1}{0.1}}=10}$

Step 2: Select an ${\displaystyle R_{f}}$ value.

Choose ${\displaystyle R_{f}=100k\Omega }$.

Step 3: Work out the required value of ${\displaystyle R_{1}}$ using equation (i).

${\displaystyle R_{1}={\frac {100k}{10}}=10k\Omega }$

Example 2

Design an Inverting Amplifier to amplify a 10mV signal to a 1V signal. The signal has a 100 ${\displaystyle \Omega }$ source impedance. The amplifier must not invert the signal.

Solution:

Since the voltage cannot be inverted then there must be an even number of stages. For simplicity let us choose two stages. Assume an ideal Op Amp.

Step 1: Work out the required gain.

${\displaystyle A_{f_{tot}}={\frac {1}{0.01}}=100}$

Step 2: Choose the required gain for each stage.

The gain will be 10 for both stages. But in the first stage we must worry about loading.

Step 3: Choose a value of input impedance i.e. choose ${\displaystyle R_{1}}$.

Choose ${\displaystyle 10k\Omega }$. We can now calculate the voltage that input to the Op Amp by voltage divider.
${\displaystyle V_{in}={\frac {R_{1}V_{s}}{R_{1}+R_{s}}}={\frac {(10k)(10mV)}{10k+100}}=9.9mV}$

We want the output of this stage to be 100mV.

${\displaystyle A_{f1}={\frac {100}{9.9}}=10.1}$

Step 4: Use ${\displaystyle A_{f1}}$ to work out ${\displaystyle R_{f1}}$.

Using equation (i) ${\displaystyle R_{f}=A_{f1}R_{1}=101k\Omega }$

Step 5: Choose a ${\displaystyle R_{f}}$ for the second stage.

Choose 100k.

Step 6: Calculate ${\displaystyle R_{1}}$ using equation (i).

${\displaystyle R_{1}=10k\Omega }$

## Non-Inverting Op Amp

An op-amp connected in the non-inverting amplifier configuration

The closed loop gain of a Non Inverting Op Amp is

${\displaystyle A_{f}=1+{\frac {R_{2}}{R_{1}}}}$ (ii)

The input impedance of this configuration is Zin = ∞ (realistically, the input impedance of the op-amp itself, 1 MΩ to 10T Ω).

#### Ideal Op Amp Derivation

Take a KVL with the inputs of the Op Amp and R1.

${\displaystyle V_{in}=v_{d}+V_{R1}\,}$

But ${\displaystyle v_{d}}$ is zero since the Op Amp is ideal. Therefore

${\displaystyle V_{in}=V_{R1}\,}$(3)

According to voltage divider rule

${\displaystyle V_{R1}={\frac {V_{out}R_{1}}{R_{1}+R_{2}}}}$(4)

Substitute equation 4 into 3.

${\displaystyle V_{in}={\frac {V_{out}R_{1}}{R_{1}+R_{2}}}}$

Thus

${\displaystyle A_{f}={\frac {V_{out}}{V_{in}}}=1+{\frac {R_{2}}{R_{1}}}}$

#### Feedback Analysis Derivation

If the output is connected to the inverting input, after being scaled by a voltage divider K = R1 / (R1 + R2), then:

V+ = Vin
V = K Vout
Vout = G(Vin − K Vout)

Solving for Vout / Vin, we see that the result is a linear amplifier with gain:

Vout / Vin = G / (1 + G K)

If G is very large, Vout / Vin comes close to 1 / K, which equals 1 + (R2 / R1).

This negative feedback connection is the most typical use of an op-amp, but many different configurations are possible, making it one of the most versatile of all electronic building blocks.

When connected in a negative feedback configuration, the op-amp will tend to output whatever voltage is necessary to make the input voltages equal. This, and the high input impedance, are sometimes called the two "golden rules" of op-amp design (for circuits that use feedback):

1. No current will flow into the inputs
2. The input voltages will be equal to each other

The exception is if the voltage required is greater than the op-amp's supply, in which case the output signal stops near the power supply rails, VS+ or VS−.

Example 3

Design a Non-Inverting Amplifier to amplify a 100mV signal to 1V signal. Assume: No source impedance.

Step 1: Work out required gain.

${\displaystyle A_{f}={\frac {1}{0.1}}=10}$

Step 2: Select an ${\displaystyle R_{2}}$ value.

Choose ${\displaystyle R_{2}=90k\Omega }$.

Step 3: Work out the required value of ${\displaystyle R_{1}}$ using equation (ii).

${\displaystyle 10=1+{\frac {90k}{R_{1}}}}$
${\displaystyle R_{1}={\frac {90k}{9}}=10k\Omega }$

Example 4 (a quick design procedure):

I want to amplify a signal A with a gain of 8. We want an output swing of at least -3 to +3 V.

We have a 5V and -5V power supply handy, so we can use that.

1. gain of 8 for A.

2. Ground gain = 1 - (8) = -7.

3. feedback-resistor value: Rf = 100 kiloOhms.

4. resistor values for each input:

• RA = 100 kΩ / 8 = 12.5 kΩ
• Rground = 100 kΩ / | -7 | = 14.3 kΩ

Since A has a positive gain, connect its resistor to V+. Since ground has a negative gain, connect its resistor to V

Example 5

Design a two stage Non-Inverting Amplifier to amplify a 10mV signal to 1V signal. The signal has a source impedance of 100 Ω.

Solution Assuming an ideal Op Amp. Since this configuration has the input impendance of the Op Amp itself. We do not have to worry about loading since the input impedance is infinite.

Step 1: Work out the required gain.

${\displaystyle A_{f}={\frac {1}{0.01}}=100}$

Step 2: Choose the gain for each stage.

Choose 10 for both stages.

Step 3: Choose a value for the ${\displaystyle R_{2}}$ resistors in both stages.

Choose 90kΩ for both.

Step 4: Work out the value of ${\displaystyle R_{1}}$.

Using equation (ii) ${\displaystyle R_{1}=10k\Omega }$.

## Voltage Follower

Voltage follower

This configuration is also known as the unity gain Buffer. Since it can be used to counter the effects of loading of the source. It provides an input impedance even higher than a normal Non-Inverting amplifier since the gain reduces that input impedance. The gain is given by equation (ii). But R_2 is short circuited and R_1 is an open circuit.

${\displaystyle A_{f}=1+{\frac {R_{2}}{R_{1}}}=1+{\frac {0}{\infty }}=1}$

## Difference amplifier

Difference amplifier

This configuration is just an Inverting and a Non-Inverting configuration connected simultaneously. Resistors R2 and R4 are a voltage divider. Consider the situation when R4 is open circuited and R2 is short circuited. Now from equations (i) and (ii) we know that the gain of V1 is

${\displaystyle A_{f1}=-{\frac {R_{3}}{R_{1}}}}$

and the gain of V2 is

${\displaystyle A_{f2}=1+{\frac {R_{3}}{R_{1}}}}$

Now if we set ${\displaystyle A_{f1}}$ to -10 then ${\displaystyle A_{f2}}$ will be 11. This means that Vout will be

${\displaystyle V_{out}=V_{1}A_{f1}+V_{2}A_{f2}=V_{2}(11)-(10)V_{1}}$

This means that if ${\displaystyle V_{1}=V_{2}}$ that Vout will be V2. This is not very useful for the most because mathematically we would like the answer to be zero. But if we make the voltage at the non-inverting input equal to 10/11 then when the voltages are equal we will have zero.

When R4 and R2 are connected the gain of V2 is

${\displaystyle A_{f2}={\frac {(1+{\frac {R_{3}}{R_{1}}})R_{4}}{R_{4}+R_{2}}}}$ (x)

The gain of V1 is

${\displaystyle A_{f1}=-{\frac {R_{3}}{R_{1}}}}$ (y)

If we want ${\displaystyle A_{f2}=|A_{f1}|}$

${\displaystyle {\frac {R_{3}}{R_{1}}}={\frac {(R_{1}+R_{3})R_{4}}{(R_{4}+R_{2})R_{1}}}}$

We just set ${\displaystyle R_{4}=R_{3}}$ and ${\displaystyle R_{2}=R_{1}}$.

This configuration has a low input impedance. The input impedance seen by V1 is R1 as in the Inverting Amplifier. The input impedance seen by V2 is R2 + R4.

Example 6 (a quick design procedure):

We often want to subtract one signal A from another signal B, and amplify the difference by 10. We want an output swing at least -6V to +6V. Oh, and for safety reasons, A and B each have a source impedance of 8 kΩ.

Our 5V and -5V power supply isn't adequate, so we pick a +12V and -12V power supply.

1.

• gain of +10 for B.
• gain of -10 for A.

2. Ground gain = 1 - ( +10 + -10 ) = +1.

3. feedback-resistor value: Rf = 100 kiloOhms.

4. resistor values for each input:

• RA = 100 kΩ / | -10 | = 10 kΩ
• RB = 100 kΩ / | +10 | = 10 kΩ
• Rground = 100 kΩ / | +1 | = 100 kΩ

So we connect the 100 kΩ Rf from Vout to V, another 100 kΩ from ground to V+. Then we connect a 2 kΩ from RA to V, and another 2 kΩ from RB to V+.

If the input has a source impedance, the source impedance is part of the circuit. The 8 kΩ source impedance, plus the 2 kΩ physical resistors we added, give us a total of 10 kΩ between the ideal voltage source and the op amp input.

## Inverting summing amplifier

Inverting summing amplifier

This is merely an Inverting Amplifier with extra inputs. The analysis is nearly identical but we have many currents equal to the feedback current. If we take a KCL at the Inverting input.

${\displaystyle i_{n}+\cdots +i_{2}+i_{1}=-i_{f}}$

The value of the currents can be determined by Ohm's Law using the fact that vd is zero for an ideal Op Amp.

${\displaystyle {\frac {V_{n}}{R_{n}}}+\cdots +{\frac {V_{2}}{R_{2}}}+{\frac {V_{1}}{R_{1}}}=-{\frac {V_{out}}{R_{f}}}}$

If ${\displaystyle R_{n}=\cdots =R_{2}=R_{1}}$ then

${\displaystyle {\frac {1}{R_{1}}}(V_{n}+\cdots +V_{2}+V_{1})=-{\frac {V_{out}}{R_{f}}}}$
${\displaystyle A_{f}=-{\frac {V_{out}}{V_{sum}}}=-{\frac {R_{f}}{R_{1}}}}$

Just as it is for the Inverting Amplifier.

Note: There is also a Summing Amplifier made using the Non-Inverting Amplifier configuration. The configuration is a bit more complicated and harder to use, since it requires an understanding of Superposition.

## Ideal integrator

Integrating Amplifier

The configuration is an Inverting Amplifier with the feedback resistor a Capacitor. The derivation proceeds the same.

${\displaystyle i=-i_{f}}$
${\displaystyle {\frac {V_{in}}{R}}=-C{\frac {\;dV_{out}}{\;dt}}}$
${\displaystyle {\frac {V_{in}}{RC}}=-{\frac {\;dV_{out}}{\;dt}}}$

Integrate both sides with respect to

${\displaystyle V_{out}=\int _{t_{0}}^{0}-{\frac {V_{in}}{RC}}\,dt+V_{initial}}$

Practically a Resistor is often connected in parallel with the feedback capacitor. This means that there is not infinite gain at very low frequencies, which makes the Real integrator much more stable.

## Ideal differentiator

The configuration is an Inverting Amplifier with a Capacitor as Resistor one so the derivation proceeds the same as before.

${\displaystyle i=-i_{f}\,}$
${\displaystyle C{\frac {\;dV_{in}}{\;dt}}=-{\frac {V_{out}}{R}}}$
${\displaystyle V_{out}=-RC{\frac {\;dV_{in}}{\;dt}}}$

This configuration is unstable for several reasons. The higher frequency inputs are going to have higher derivatives. Which means that circuit acts like a low pass filter, but more importantly this means that it will just saturate if a high frequency signal is put into the differentiator. This is also seen through the gain.

${\displaystyle A_{f}=-{\frac {R}{1/j\omega C}}}$

This means high frequencies mean high gain and thus saturation.

Practically a Resistor is often connected in series with the capacitor.