An operational amplifier or operational amplifier is simply a linear integrated circuit (IC) with multiple terminals. An operational amplifier can be considered a voltage-amplifying device designed to be used with external feedback components such as resistors and capacitors between its output and input terminals. It is a high-gain electronic voltage amplifier with differential inputs and usually single-ended outputs. Operational amplifiers are one of the most widely used electronic devices today, as they are used in a large number of consumer, industrial, and scientific equipment.
Definition
A comparator compares two input voltages and outputs a binary signal indicating which is larger. If the non-inverting (+) input is greater than the inverting (-) input, the output goes high. If the inverting input is greater than the non-inverting, the output goes low.
What is a comparator used for?
The most frequent application for comparators is comparing a voltage and a stable reference. Comparators have many applications, including threshold detectors/discriminators, zero-crossing detectors, and oscillators.
What are the types of comparators?
The two basic types of voltage comparators are inverting and non-inverting, depending on which terminal the input signal is applied to.
In an inverting comparator (or negative voltage comparator), the input signal is applied to the inverting terminal and the reference voltage is at the non-inverting terminal. This creates a positive voltage output if the input voltage is less than the reference voltage.
In a non-inverting comparator, the input signal is applied to the non-inverting terminal and the reference voltage is at the inverting terminal. This creates a positive voltage output if the input voltage exceeds the reference voltage.
How does it differ from an op-amp?
The basic function of a high-gain comparator is to determine whether an input voltage is higher or lower than a reference voltage—and to present that decision as one of two voltage levels, established by the output’s limiting values. Comparators have a variety of uses, including polarity identification, 1-bit analog-to-digital conversion, switch driving, square/triangular-wave generation, and pulse-edge generation.
In principle, any high-gain amplifier can be used to perform this simple decision. But “the devil is in the details.” So there are some basic differences between devices designed as op-amps and devices designed to be comparators. For example, for use with digital circuitry, many comparators have latched outputs, and all are designed to have output levels compatible with digital voltage-level specifications. There are some more differences of importance to designers—they will be discussed here.
Operational amplifiers and comparators are commonly used devices in circuits, and they often encounter doubts when using them. What is the difference between these two materials? Let me explain them in combination with their use in work. The classic device is TI's LM2903 (comparator ) and LM2904 (op-amp).
Comparator: The internal structure is generally an open-collector structure, so a pull-up resistor needs to be added when outputting. The output level amplitude depends on the logic level connected to the pull-up and is generally connected to a digital circuit. It is often used to compare the voltage output at high and low levels as the driving signal of the relay.
Operational amplifier: The internal generally adopts a push-pull bipolar output structure. In actual use, various computing functions are generally realized by building a feedback loop, which is often used in signal amplification, voltage follower, voltage inversion, adder, subtractor, etc.
Comparators:
The input is analog and the output is digital, which is often used for signal conversion between analog circuits and digital circuits.
In terms of response speed, the magnitude of the response speed of the comparator is ns, so it cannot be used directly in practical applications. Generally, it can be used as a hysteresis comparator or a window comparator.
There is no feedback loop inside the comparator, and the structure is simple.
Op amp:
The input is analog, and the output is also analog. Generally used in analog circuits.
In terms of response speed, the magnitude of the response speed of the op-amp is us.
There is a phase compensation circuit inside the operational amplifier, so the operational amplifier is more stable than the comparator.
Frequently Asked Questions and Answers
Can a comparator be used interchangeably with an op amp?
Answer: Generally, they cannot be used interchangeably, but op amps can be used instead of comparators in low-profile circuits that do not require feedback.
But a comparator cannot replace an op amp in a feedback loop.