4.0 Non-Linear Applications of the Op-Amp
4.1 Comparators
A comparator is a fundamental non-linear application of an operational amplifier. It is a circuit that compares two input voltages and produces a binary output that indicates which of the two inputs is greater. Op-Amps are well-suited for this task because their very high open-loop gain causes the output to saturate at either its positive or negative supply limit, effectively producing a high/low digital signal. This is typically achieved by operating the Op-Amp in an open-loop configuration (without negative feedback).
Inverting Comparator
In an inverting comparator configuration, the input voltage (V_i) is applied to the inverting terminal, while a fixed reference voltage (V_{ref}) is applied to the non-inverting terminal.
Operation: The circuit compares V_i to V_{ref} and drives the output to one of two saturation levels:
- If the input voltage is greater than the reference voltage (V_{i} > V_{ref}), the output will switch to the negative saturation voltage, .
- If the input voltage is less than the reference voltage (V_{i} < V_{ref}), the output will switch to the positive saturation voltage, .
Example: Inverting Zero Crossing Detector A common application is the zero crossing detector, where the reference voltage V_{ref} is set to 0V (ground).
- During the positive half-cycle of a sinusoidal input, V_i > 0V, so the output is held at -V_{sat}.
- During the negative half-cycle of the input, V_i < 0V, so the output switches to +V_{sat}. The output waveform is a square wave that is inverted relative to the input sine wave, with transitions occurring every time the input signal crosses zero.
Non-Inverting Comparator
In a non-inverting comparator configuration, the roles of the inputs are reversed. The input voltage (V_i) is applied to the non-inverting terminal, and the reference voltage (V_{ref}) is applied to the inverting terminal.
Operation: The transfer characteristic is inverted relative to the inverting comparator:
- If the input voltage is greater than the reference voltage (V_{i} > V_{ref}), the output will switch to the positive saturation voltage, .
- If the input voltage is less than the reference voltage (V_{i} < V_{ref}), the output will switch to the negative saturation voltage, .
Example: Non-Inverting Zero Crossing Detector With the reference voltage V_{ref} set to 0V:
- During the positive half-cycle of a sinusoidal input, V_i > 0V, so the output is held at +V_{sat}.
- During the negative half-cycle of the input, V_i < 0V, so the output switches to -V_{sat}. The resulting output is a square wave that is in phase with the input sine wave, again with transitions occurring at the zero crossings.
Following comparators, another important class of non-linear circuits involves those that perform logarithmic mathematical operations.
4.2 Logarithmic and Anti-Logarithmic Amplifiers
By incorporating non-linear components such as diodes or transistors into the feedback path, Op-Amps can be configured to perform complex mathematical functions like finding the logarithm and anti-logarithm (exponentiation) of a signal. These circuits are invaluable in applications such as signal compression, where a wide dynamic range needs to be managed, and in the linearization of sensor outputs that have an exponential response.
Logarithmic Amplifier
A logarithmic amplifier, or log amp, is a circuit that produces an output voltage proportional to the natural logarithm of its input voltage. This is achieved by placing a diode in the feedback path of an inverting Op-Amp configuration.
Output Voltage Derivation:
- The nodal equation at the inverting terminal (virtual ground) is: \frac{0-V_i}{R_1}+I_{f}=0 \implies I_{f}=\frac{V_i}{R_1} \quad \text{(Equation 1)}
- The current (I_f) flowing through the forward-biased diode is described by the diode equation: I_{f}=I_{s} e^{(\frac{V_f}{nV_T})} \quad \text{(Equation 2)} where I_s is saturation current, V_f is the forward voltage across the diode, and nV_T is a thermal constant.
- From the feedback loop, the voltage across the diode V_f is related to the output voltage V_0 by V_f = -V_0.
- Equating the expressions for I_f from Equation 1 and Equation 2, and substituting V_f = -V_0: \frac{V_i}{R_1}=I_{s}e^{\left(\frac{-V_0}{nV_T}\right)}
- Rearranging and applying the natural logarithm to both sides: In\left(\frac{V_i}{R_1I_s}\right)= \frac{-V_0}{nV_T}
- Solving for the output voltage V_0: V_{0}=-{nV_T}In\left(\frac{V_i}{R_1I_s}\right)
The final expression shows that the output voltage is proportional to the natural logarithm of the input voltage. The negative sign indicates that the output is inverted.
Anti-Logarithmic Amplifier
An anti-logarithmic amplifier, or anti-log amp, performs the inverse operation, producing an output voltage that is proportional to the exponential (anti-natural logarithm) of its input voltage. This is achieved by swapping the positions of the resistor and diode from the log amp configuration; the diode is now the input element.
Output Voltage Derivation:
- The nodal equation at the inverting terminal is: -I_{f}+\frac{0-V_0}{R_f}=0 \implies V_{0}=-R_{f}I_{f} \quad \text{(Equation 4)}
- The current I_f flowing through the input diode is governed by the diode equation. From the input loop, the voltage across the diode V_f is equal to the input voltage V_i. I_{f}=I_{s} e^{\left(\frac{V_f}{nV_T}\right)} = I_{s} e^{\left(\frac{V_i}{nV_T}\right)}
- Substituting this expression for I_f into Equation 4 gives the final output voltage: V_{0}=-R_{f}{I_{s} e^{\left(\frac{V_i}{nV_T}\right)}}
The result shows that the output voltage is proportional to the exponential of the input voltage. As with the log amp, the negative sign indicates an inverted output.