I have a problem where I am trying to model the voltage across a capacitor in the following circuit:

enter image description here

We can see we have a reference voltage source of 1.25V driving a buffer. For T/2 the Capacitor is connected to the 1V supply, such that the voltage across it is 1V. After T/2 it then switched to the output of the buffer and is charged to 1.25V. My goal is to find the voltage across the capactior, \$V_c(t)\$, as a function of time.

1st Approach

Initially I just thought to model the voltage across the cap as a 1.25V source charging a capacitor through the output resistance of an Opamp, as follows:

enter image description here

Given the capacitor starts at a voltage of 1V, we model the charging as:

$$V_c(t) = 1.0 + (1.25 - 1.0)(1 - e^{t/\tau}) = 1.0 + 0.25(1 - e^{t/\tau})$$

since the buffer provides a fixed 1.25v charging voltage. However, I was told this may be incorrect since the voltage used to charge the capacitor is itself a function of time, dependent on the voltage across the capacitor, so I tried another approach ...

2nd Approach

Using a model for the OpAmp, we replace the buffer circuit with a dependent voltage source as follows

enter image description here

The voltage generated by the OpAmp is \$A_{OL}(V_+ - V_-)\$, where \$A_{OL}\$ is the open loop gain of the OpAmp. In this case \$V_+ = 1.25v\$ and \$V_- = V_c(t)\$, yielding the above model. We can then model this as an RC circuit as before, this time the charging voltage a dependent voltage source:

enter image description here

Therefore, the voltage across the capacitor is

$$V_c(t) = 1.0 + [A_{OL}(1.25 - V_c(t)) - 1.0](1 - e^{t/\tau})$$

which can be re-arranged for \$V_c(t)\$ to give:

$$V_c(t) = \frac{1.0 + A_{OL}(1.25)(1-e^{-t/\tau}) - (1-e^{-t/\tau})}{1 + A_{OL}(1-e^{-t/\tau})}$$


Plotting both these results in desmos yields : (https://www.desmos.com/calculator/9yzrm6hsnm)

enter image description here

where the red curve is method 1, and the purple is method 2. Now, i'd like to know people's opinion on which is the correct approach, or are BOTH wrong?

The reason I suspect that there is an error here is because I also have the conditions that \$V_c(0.48*T) = 1.249511\$, where \$T = 1/20Mhz\$, which yields a time constant of \$\tau_1 = 1.758e-7\$ for method 1 and \$\tau_2 = 7.93e-8\$ for method 2 (using the information \$A_{OL} = 4000\$). Dividing each by the load capacitance (1.5pF) yields output resistances for the OpAmp of \$119k\Omega\$ and \$52.8k\Omega\$ respectively, while I expect this value to be on the order of Mega Ohms.

  • \$\begingroup\$ Which op-amp is it? Usually op-amp outputs are not supposed to be connected to capacitors, so why are you modeling it? \$\endgroup\$
    – Justme
    Mar 10, 2023 at 18:22
  • \$\begingroup\$ I am designing the OpAmp. But before I do so, I'm deriving the system specification (Gm, Bandwidth) based on a high level description of settling error, and DC gain error etc. The load is capacitive as I am driving the input of an ADC which use the 1.25V capacitor as a reference. This reference discharged to 1v during the conversion phase and must be charged (as shown above) to 1.25v on the acquisition phase. \$\endgroup\$
    – Jonah F
    Mar 10, 2023 at 18:28
  • \$\begingroup\$ If so, would the resistance of the switch also affect the capacitor charging, and at the same time provide some isolation from direct short circuit to capacitor? \$\endgroup\$
    – Justme
    Mar 10, 2023 at 18:49
  • \$\begingroup\$ @JonahF, I would think this is a large signal phenomenon that you are trying to model and hence, can model the output as staying at 1V till the amplifier loop delay after which the cap charges linearly at a rate depending on the max current output of the amplifier till it comes close to 1.25V. \$\endgroup\$
    – sai
    Mar 11, 2023 at 17:07

1 Answer 1


Neither is really correct, because you should end up with a piecewise function for the T/2 switching. If you are trying to model this, it also matters if this is a real world model or ideal.

If the capacitor is connected to the opamp, and then switched to 1V, it will do so instantaneously because the 1V source has the capability to source infinite current (in the ideal world).

If the capacitor is connected to the 1V source and then to the opamp, the capacitor will not charge instantaneously because of the source resistance of the opamp. so before \$ T_{0} \$ the capacitor will be at 1V. Whenever it switches it will decay with an RC time constant to 1.25V because the opamp's negative feedback will always try to move the output of the to the V+ input in a voltage follower configuration.

If a real world model is needed, the capacitor will also need inductance and resistance in it's model and the 1V source will also need source resistance.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.