# Op-Amp & Integrator Basics

Here is another tip of the hat tip of the soldering iron to one of the Planet Analog archived posts. This post gives an explanation of how op-amps work in general and how an integrator works in particular. Unlike some of my recent blogs that point at archived posts, this time we'll dive in deeper.

Understanding this circuitry is essential if you are doing any sort of design with op-amps. How much of this is taught to engineers today?

Let's assume that you set up an op-amp circuit like this:

This circuit will have a gain that's determined by the ratio of the feedback resistor (RF ) to the input resistor (RI ). It also inverts the signal, so a positive voltage swing at the input produces a negative voltage swing at the output. Note that to simplify this discussion, we assume that there are positive and negative voltage power supplies for the op-amp. Hence, VOUT can swing above and below ground. Let's make both resistors 1.0kΩ. There are a few different ways to examine what the circuit will do. From a macroscopic view, VOUT = – VIN * (RF / RI ). But why?

The op-amp is a tiny servo system that will move its output around so as to force the voltage at the negative input to be equal to the voltage at the positive input. Since the positive input is at ground (0.00V), the negative input (or summing junction, since it sums voltage sources from two different directions) should end up at 0.00V. So if you put +1.00V at VIN , VOUT will go to -1.00V. Half way between those two equal-value resistors (voltage divider rule) is at 0.00V.

You can also work through this by analyzing current flow. Recall Kirchhoff's circuit rules for current (conservation of charge), sometimes called Kirchhoff's first law: All the current flowing into a node (from one or more paths) has to flow out of the node (again, it can be through one or more paths). By assigning the appropriate sign to the flow (“into” is positive; “out of” is negative) it has to sum to zero. No current flows into/out of the input pin.

OK, not true — there is a tiny current flow, but it is usually so small that it can be ignored in most applications. In very high impedance circuits, circuits amplifying extremely small signals, or some track-and-hold/integrating circuits, that tiny current can be trouble. For now, we'll ignore it.

So, no current into or out of the input pin means that any current that flows into RI (due to the voltage source VIN ) must flow through RF and into the output of the op-amp. We can reverse the current flow (change its sign) and have it flow the other way, but that's just a sign on a number, so the analysis is the same.

When you change the feedback resistor to a capacitor, the circuit becomes an integrator.

To analyze this, Kirchhoff's current rule proves the most helpful because you charge (and discharge, but that's the same thing except for a change in sign) a capacitor. The equations work out a little more neatly via a current analysis. With this in mind, if you now refer back to the archived integrator article that I cited at the beginning of this blog, clarity should ensue. To the extent that it does not, please post your comments below.

## 12 comments on “Op-Amp & Integrator Basics”

1. amrutah
February 28, 2013

Yes, I agree that “Understanding this circuitry (integrator) is essential if you are doing any sort of design with op-amps… ” and especially any sort of analog filters.

And analyzing the filter circuits, derving the transfer functions to locate the poles and zeros, many times Kirchoff's current law proves to be more effective. Analog Filter by Van Valkenberg gives a good insight about 1st, 2nd and nth order integrators.

The 18 part series on OPAMP by William Klein is great and very useful for understanding the OPAMPS.

Thanks for sharing.

February 28, 2013

Yes – once you understand the integrator, then the active filter circuitry starts to make a lot more sense. Not familiar with the work by Van Valkenberg or the op-amp series by William Klein. I'll look for both.

3. SunitaT
February 28, 2013

The 18 part series on OPAMP by William Klein is great and very useful for understanding the OPAMPS.

@amruthah, true. 18 part series of OPAMP by William klein has explained the OPAMP beautifully. I would also recommend Analog Integrated Circuit Design by David Johns/Ken MArtin and CMOS Analog Circuit Design by Allen/Holberg.

4. SunitaT
February 28, 2013

once you understand the integrator, then the active filter circuitry starts to make a lot more sense.

@Brad, I agree with you. Understanding the integrator basics is essential to understand the filter circuitry. I realised this when I was studying Sigma-Delta ADC where the integrator present in the path helps in noise shaping. Brad would you recommend any particular material which covers the integrator concepts in detail ?

5. amrutah
February 28, 2013

SunitaT,

I would seriously recommend the Analog Filter Design by M.E. Van Valkenberg as of the good materail.  Also look for OPAMPS For Everyone design guide byt TI.

6. jbike
March 2, 2013

I used Analog Filter Design by M.E. Van Valkenberg as a text in college 26 years ago! Here is a thought: Let's find a place to organize the best reference material here on planet analog. It would be easy if we all would post the  titles  and authors (not the actual material) to text books/articles/application notes that each of us found to be well written and educational. There is so much material out there I am sure that a little help may be appreciated.

7. audiocal
March 6, 2013

I highly recommend Walt Jung's op amp books:

IC Op Amp Cookbook (1974), 2nd edition (1980), 3rd edition (1986) all by Howard Sams. The later Prentiss-Hall editions reportedly have a number of errors.

Audio Op Amp Applications (1975), 2nd edition (1978). 3rd edition (1986) all by Howard Sams.

Op Amp Applications Handbook (originally a 2001 Analog Devices Seminar handbook, then published by Newnes in 2006)

8. DEREK.KOONCE
March 6, 2013

When I explain opamps, the key I drive is that the output will do what it takes to make the inputs at the same voltage. Thus changing the referece level of the non-inverting side will also shift all the values. So look at what the non-inverting is set at to find out what the output will be driven to. Then do the exercise of moving the feedback onto the non-inverting side of the opamp and see what happens. I had my intern last year do this exercise. He found it quite useful to see how the opamp really works.

I find using a part in a different manner can open up some ideas as to the versatility of a part.

Oh, and the Van Valkenburg Analog Filter Design is always within reach of my desk. Great book from my college days in the late 80's. Goes to show that good basics are never expired – like that OpAmp Cookbook from TI from the early 80's.

9. djhk
March 6, 2013

The Op-amp analysis in most texts derives correct formulas via a Comedy of Errors.

See http://dknollman.50webs.com/k9analysis/intro.html .

K9Analysis provides a Dog-Gone-Simple way to analyze Op-Amp circuits.

Even a 3 op-amp State variable filter is trivial.

You can use Plato's gain formula to design non-inverting integrators.

10. kris1949
March 6, 2013

I would recommend “The Art of Electronics” by Paul Horowitz and Winfield Hill. It's the best from what I encountered so far.