How does an operational amplifier compare two voltages and give a clear high or low output that can switch a circuit?
Explain the operational amplifier used as a comparator, including its very high gain and the two output states
A focused answer to the O-Level Electronics outcome on the op-amp comparator. The two inputs, very high open-loop gain, the high or low output, and using a sensor divider with a reference voltage.
Reviewed by: AI editorial process; not yet individually human-reviewed
Have a quick question? Jump to the Q&A page
Jump to a section
What this dot point is asking
SEAB wants you to explain how an operational amplifier (op-amp) is used as a comparator: how it compares the two voltages at its inputs, why its very high gain forces the output to one of two extremes, and how a sensor divider and a reference voltage make it switch at a chosen level. The central insight is that an op-amp with no feedback amplifies the difference between its inputs so strongly that the output is always slammed either fully high or fully low.
The answer
The op-amp and its two inputs
An operational amplifier has two inputs and one output:
- The non-inverting input (marked ).
- The inverting input (marked ).
The op-amp amplifies the difference between these two inputs. It also has a very high open-loop gain (the gain with no feedback), often a hundred thousand or more.
Why the output saturates
Because the open-loop gain is so enormous, even a tiny voltage difference between the inputs is multiplied to a value far larger than the supply voltage. The output cannot go beyond the supply rails, so it is driven hard against one rail or the other. The result is that the output rests at only two values, not a smooth range:
- If the non-inverting () input is higher than the inverting () input, the output goes high (near the positive supply).
- If the inverting () input is higher than the non-inverting () input, the output goes low (near or the negative supply).
Used this way, with no feedback, the op-amp is a comparator: it compares two voltages and gives a clean two-state output.
Comparing against a reference
To make a useful sensing circuit, one input is held at a fixed reference voltage (often set by a potential divider or a variable resistor), and the other is fed by a sensor divider whose voltage changes with light, temperature or another quantity:
- When the sensor voltage rises above the reference, the output switches to one state.
- When it falls below the reference, the output switches to the other.
The reference voltage sets the exact level at which switching happens, which is how a comparator decides "too bright", "too hot" or "too high".
Why a comparator is useful
A sensor divider gives a slowly changing analogue voltage, but many circuits need a sharp on-or-off decision. The comparator turns the gradual sensor voltage into a clean high-or-low output that can directly drive a transistor, a relay or a logic input. It is the bridge between analogue sensing and digital switching.
Examples in context
Example 1. A frost alarm. A thermistor divider feeds one input of a comparator and a reference set just above freezing feeds the other. As the temperature drops past the set point, the comparator output switches and sounds an alarm. The sharp two-state output means the alarm comes on decisively rather than fading in, which is exactly what a warning needs.
Example 2. A light-activated switch. An LDR divider compared against a reference switches a lamp on at a chosen darkness. Because the comparator output is clean and full-swing, it can drive a transistor and relay directly. The reference, set by a variable resistor, lets the user choose precisely how dark it must be before the lamp comes on.
Try this
Cue. State the output of a comparator when its inverting input is higher than its non-inverting input. The output goes low (near ), because the output is high only when the non-inverting input is higher.
Cue. Explain why a comparator output saturates rather than varying smoothly. The op-amp's very high open-loop gain multiplies any small input difference beyond the supply rails, so the output is driven fully high or fully low.
Cue. State the purpose of the reference voltage in a comparator sensing circuit. It sets the level the sensor voltage is compared against, fixing the exact light, temperature or value at which the output switches.
Exam-style practice questions
Practice questions written in the style of SEAB exam questions on this dot point, with worked answer explainers. The year tag is the paper they imitate, not the source.
Original4 marksAn operational amplifier is used as a comparator. Its non-inverting input is at and its inverting input is at . State the output (high or low) and explain why the output saturates.Show worked answer →
The non-inverting input () is higher than the inverting input (), so the output goes high (near the positive supply).
The op-amp has a very high open-loop gain, so even the small difference is multiplied enormously. The output cannot exceed the supply rails, so it is driven hard against the positive supply and saturates high.
What markers reward: output high because the non-inverting input is higher, and saturation because the very high gain drives the output to the supply rail it cannot exceed.
Original5 marksAn LDR potential divider feeds the non-inverting input of a comparator, and a fixed reference voltage feeds the inverting input. Explain how the comparator switches its output as the light level changes, and state the purpose of the reference voltage.Show worked answer →
The LDR divider voltage changes with light. The comparator compares this with the fixed reference. When the divider voltage rises above the reference, the output goes high; when it falls below, the output goes low.
So as the light crosses the level that makes the divider voltage equal the reference, the output switches sharply between its two states. The reference voltage sets the exact light level at which switching happens.
What markers reward: comparing the changing divider voltage with the fixed reference, the output switching high or low as it crosses, and the reference setting the trigger point. A clear threshold description earns full marks.
Related dot points
- Apply the potential divider equation to find an output voltage and explain how a sensor in a divider produces a varying voltage
A focused answer to the O-Level Electronics outcome on the potential divider. The divider equation, choosing resistors for a wanted output, and using a sensor in a divider to make a varying voltage.
- Describe the LDR and the thermistor as input transducers, state how their resistance changes, and use them in a potential divider
A focused answer to the O-Level Electronics outcome on input transducers. How the LDR and thermistor change resistance with light and temperature, and how they produce a varying voltage in a divider.
- Apply the gain equations for the inverting and non-inverting op-amp amplifier and explain the role of negative feedback
A focused answer to the O-Level Electronics outcome on op-amp amplifiers. The inverting and non-inverting gain equations, the role of negative feedback, and choosing resistors for a wanted gain.
- Define voltage gain as a ratio, calculate it, and express it in decibels using the gain equation
A focused answer to the O-Level Electronics outcome on amplifier gain. Voltage gain as the ratio of output to input, calculating it, and expressing gain in decibels.