I just get started to play around designing analog circuits after I have learnt something about it in my high school 20 years back, so forgive me if this question is dumb for you.
Here is my attempt to design an integrator - this is LTSpice, the opamp is ideal.
I am expecting the output to be the integral of the input. Here is my idea:
The negative feedback of the opamp should drive the negative input of the opamp to 0. (I learnt this rule in high school, but why? I am not sure)
With that in mind, the current from power source to Vout through R1 and C1 is:
$$ \frac{V}{R_1} = I = C_1\frac{dV_{out}}{dt} $$
Rearranging, getting:
$$ V_{out} = \int\frac{V_{in}dt}{R_1 C_1} $$
But here is the simulation result, something I don't expect, the negative input of the opamp is not exactly 0, it changes:
That is a small range of error, but for the opamp, it is sufficient to drive the output crazy.
- How does opamp drive the negative input to match with the positive input, and
- Why doesn't the negative input got drive to zero, and
- What's wrong with my design?
Feel free to fiddle with the design in LTSpice by downloading it from here