📐 Op-Amp Lab

📐 Operational Amplifier — FAQ

The two golden rules of the ideal op-amp, and the amplifier circuits you build from them.

What is an operational amplifier?

An operational amplifier (op-amp) is a high-gain differential voltage amplifier. It amplifies the difference between its two inputs (V+ and V-) by a very large open-loop gain, typically 100,000 or more. With negative feedback it becomes a precise, predictable building block for analogue circuits.

What are the two golden rules of an ideal op-amp?

Rule 1: no current flows into either input (infinite input impedance). Rule 2: with negative feedback, the op-amp drives its output so that V+ equals V- (the virtual short). Almost every op-amp circuit can be analysed using just these two rules.

What is a virtual ground?

In an inverting amplifier the non-inverting input (V+) is tied to ground, so the golden rules force V- to sit at ground potential too — without actually being connected to ground. This node is called a virtual ground: it stays at 0 V while still carrying signal current through the resistors.

What is the gain of an inverting amplifier?

For an inverting amplifier the closed-loop gain is -Rf/Rin, where Rin is the input resistor and Rf the feedback resistor. The minus sign means the output is inverted (180 degrees out of phase) relative to the input.

What is the gain of a non-inverting amplifier?

For a non-inverting amplifier the gain is 1 + Rf/Rin. The output is in phase with the input and the gain is always at least 1. Setting Rf = 0 (or Rin = infinity) gives a unity-gain buffer.

How does a summing amplifier work?

A summing amplifier feeds several inputs through their own resistors into the virtual ground of an inverting amp. Because the node is held at 0 V, the currents simply add: Vout = -Rf(V1/R1 + V2/R2 + ...). With equal resistors it produces a weighted (or plain) inverted sum.

What does an integrator op-amp do?

An integrator replaces the feedback resistor with a capacitor. The input current charges the capacitor, so the output voltage is the time-integral of the input: Vout = -(1/RC) times the integral of Vin dt. A square-wave input becomes a triangle wave at the output.

Why does the inverting amplifier flip the signal?

The input signal enters the inverting (-) input through Rin. When the input rises, the op-amp output must fall to keep the virtual ground at 0 V via the feedback resistor. That opposing action is what produces the 180 degree phase inversion.

What is clipping or saturation?

A real op-amp cannot output more than its supply rails. If the input times the gain exceeds the rail voltage, the output flattens at the rail — this is clipping or saturation. The simulation shows the waveform flat-topping when the requested output exceeds the supply.

What are op-amps used for in real circuits?

Op-amps are everywhere: audio preamplifiers, active filters, voltage followers, comparators, oscillators, sensor signal conditioning, analogue computers, and instrumentation. Their predictable feedback behaviour makes them the workhorse of analogue electronics.

About this simulation

Written by MySimulator Team · Reviewed by MySimulator Editorial Review

Last updated: 9 July 2026

This lab models an ideal operational amplifier (op-amp) wrapped in negative feedback, obeying two golden rules: no current flows into either input, and feedback forces the two inputs to the same voltage. In the inverting, summing and integrator layouts that pins the inverting input to 0 V — a virtual ground — even though it is not wired to ground. From there, closed-loop gain falls out of resistor ratios alone: −Rf/Rin for inverting, 1+Rf/Rin for non-inverting, or a time-integral when the feedback resistor is swapped for a 1 µF capacitor. A live circuit diagram and scrolling oscilloscope trace show the input and output waveforms updating every frame, including hard clipping once the output would exceed the supply rails.

🔬 What it shows

Four op-amp topologies — inverting, non-inverting, summing and integrator — computed frame by frame from the same two golden rules. The circuit diagram redraws its resistors, feedback element and virtual-ground node live, while a scope panel plots 240 samples of Vin and Vout so you can watch gain, phase inversion and clipping happen in real time.

🎮 How to use it

Pick a topology with the four config buttons, then drag the Rin, Rf and (for summing) R2 sliders to change resistor values in kilohms. Amplitude and Frequency shape the input signal, and Supply rails (±Vcc) set the clipping limit. Pause freezes the animation, Reset restores the defaults, and the "?" button opens a full equation reference.

💡 Did you know?

The op-amp's name dates back to 1940s analogue computers, where these circuits performed mathematical "operations" — summing, inverting and, as reproduced by the integrator mode here, time-integration — to solve differential equations mechanically, decades before digital computers took over the job.

Frequently asked questions

What are the two "golden rules" this simulation relies on?

Rule 1: no current ever flows into either op-amp input, because an ideal op-amp has infinite input impedance. Rule 2: negative feedback makes the op-amp drive its output until the two inputs sit at the same voltage (a "virtual short"). Every gain formula used in this simulator — inverting, non-inverting, summing and integrator — is derived from just these two rules applied to the resistor network you build with the sliders.

Why does the inverting input sit at 0 V even though it isn't grounded?

In the inverting, summing and integrator configurations the non-inverting input (V+) is tied to real ground. Rule 2 then forces the inverting input (V-) to match V+, so it also sits at 0 V — without a wire to ground. This is the virtual ground the simulation labels on the circuit diagram; it still carries current through Rin and the feedback element even while its voltage stays at zero.

How is the gain calculated for each configuration?

Inverting mode uses Av = -Rf/Rin; non-inverting uses Av = 1 + Rf/Rin; summing computes Vout = -Rf·(V1/R1 + V2/R2) so each input channel gets its own weight; and the integrator mode replaces Rf with a fixed 1 µF capacitor, so Vout = -(1/RC)·∫Vin dt. The readout panel shows the live equation and numeric gain for whichever mode is selected.

What does the integrator mode actually simulate?

With the feedback resistor replaced by a capacitor, the current through Rin charges the capacitor instead of flowing straight to the output, so the output becomes the running time-integral of the input, scaled by -1/RC. The simulation feeds the integrator a square wave and numerically accumulates -(1/RC)·Vin·dt every animation frame (with a small 0.05% per-frame leak to stop the value drifting away forever), which is why a square-wave input produces a triangle-wave output.

Why does the waveform flatten out at the top and bottom sometimes?

That is clipping (saturation). A real op-amp cannot output more voltage than its supply rails allow, so once amplitude × gain would exceed the ±Vcc you set with the Supply rails slider, the simulation clamps Vout to that limit and marks the readout "(CLIP)". Raising the rails or lowering the gain removes the flat-topping.