C625 of 57
0 XP
  1. Hook
  2. Play
  3. Predict
  4. Name it
  5. Check
  6. Explain

C6 · Lesson 25 · Integrators and differentiators

Calculus with a capacitor and an op amp

Swap the feedback resistor of an inverting amplifier for a capacitor, and the op amp integrates its input: the input current flows into the capacitor, so the output records the running total. Swap the input resistor for a capacitor instead, and it differentiates. Before digital computers, rooms of these circuits solved the differential equations of flight and ballistics. Today integrators shape waveforms, set filter characteristics and turn currents into voltages in every measurement chip.

Play

  • An inverting integrator: a square wave in, through R, into the capacitor's virtual ground. The large resistor across C keeps the output from drifting. (The scope shows the circuit a second after it was switched on, once its start-up offset has died away.)
  • What shape is the output? How steep are its slopes?
  • Halve R, or halve C. What happens to the slopes?

Predict

An integrator with R = 10 kΩ and C = 100 nF has a steady +1 V input. How fast does its output change?

Name it

Integrator and differentiator

Integrator. Input resistor R, feedback capacitor C. The input current vin/R flows into C (rule 1), and the capacitor's voltage is the output's, negated (rule 2):

vout(t)=−1RC∫vindt

In the frequency domain, H=−1jωRC: gain 1/(ωRC), falling 20 dB per decade, with +90° of phase (an inversion and a 90° lag).

Why it drifts. At DC the capacitor is open, so the op amp has no feedback, and any tiny input offset is integrated without limit. A large resistor across C (here 1 MΩ) gives DC feedback, turning the circuit into a low-pass with a corner at 1/(2πRPC) that behaves as an integrator well above it.

Differentiator. Input capacitor C, feedback resistor R:

vout=−RCdvindtH=−jωRC

Its gain grows with frequency without limit, so it amplifies noise and tends to oscillate. Practical differentiators add a small resistor in series with C to cap the gain at high frequencies.

Uses. Integrators: triangle-wave and ramp generators, the integrating ADCs in multimeters, PID controllers (D3), and charge amplifiers. Differentiators: edge detectors, rate sensors.

Worked example

An integrator has R = 100 kΩ and C = 10 nF, and its output saturates at −12 V. A steady 1 V is applied. What happens?

Show the solution
  1. Ramp rate. −1VRC=−1V/ms
  2. Time to saturate. At that rate it reaches −12 V after 12 ms.
  3. Afterward. It stays at −12 V until the input changes sign.

Answer the output ramps down at 1 V/ms, saturates at −12 V after 12 ms and stays there until the input changes sign.

Worked example

The same integrator gets a ±1 V square wave at 500 Hz. What comes out, and what leak resistor across C keeps it from drifting while affecting 500 Hz little?

Show the solution
  1. Output. Each 1 ms half cycle ramps by 1 V, so the output is a 1 V peak-to-peak triangle.
  2. Leak resistor. A 10 MΩ leak puts the integrating corner at f=12π×10M×10nF=1.6Hz far below 500 Hz.

Answer a 1 V peak-to-peak triangle comes out, and a 10 MΩ leak resistor keeps it from drifting.

Worked example

A differentiator has C = 10 nF and Rf = 10 kΩ. A 100 Ω resistor is added in series with C. What's its gain at 1 kHz, at 10 kHz, and far above?

Show the solution
  1. Corner of the series pair. fc=12π×100×10nF=159kHz
  2. Below the corner. It still differentiates, and the gain is ωRfC: 1kHz:0.62810kHz:6.28
  3. Far above. The capacitor is a short, and the gain levels off at Rf100Ω=100
  4. Why the resistor is there. The bare differentiator's gain would keep rising with frequency, amplifying noise and, combined with the op amp's own pole, ringing or oscillating. The series resistor caps it.

Answer the gain is 0.628 at 1 kHz, 6.28 at 10 kHz, and levels off at 100 far above.

Check

An integrator with R = 22 kΩ and C = 47 nF has a steady 1 V input. How fast does its output change?

Write units the way you normally would: 1.5 V/ms, 1500 mV/ms and 0.0015 kV/ms are the same answer.

Check

What's the gain of an integrator (R = 10 kΩ, C = 10 nF) at 1000 Hz?

Check

A ±1 V square wave at 100 Hz drives an integrator (R = 22 kΩ, C = 220 nF). What's the peak-to-peak swing of the triangle that comes out?

Write units the way you normally would: 1.5 V, 1500 mV and 0.0015 kV are the same answer.

Check

A differentiator has R = 10 kΩ and C = 10 nF. Its input rises at 10 V/ms. What's its output?

Write units the way you normally would: 1.5 V, 1500 mV and 0.0015 kV are the same answer.

Check

An integrator has RP = 1 MΩ across its 10 nF capacitor to stop drift. Below what frequency does it stop acting like an integrator?

Write units the way you normally would: 1.5 Hz, 1500 mHz and 0.0015 kHz are the same answer.

Check

A differentiator has C = 10 nF and Rf = 10 kΩ, with 220 Ω in series with C.

(a)

What's its gain at 1 kHz, well below the series corner?

(b)

Where does its gain level off at high frequency?

Check

An integrator has input resistor R and capacitor C, with a leak resistor L across C, and a steady input V.

Step 1

How fast does its output ramp at first?

Type it the way you would write it, like 3sin(2πft) or 3*sin(2*pi*f*t). Angles can be in radians or carry a degree sign, like 45°.

Explain why

Why does an ideal op-amp integrator drift, and how does a resistor across the capacitor stop it?

Practice

Keep practicing

9 kinds of problem on this topic, dealt one at a time with new numbers every time, for as long as you like.