Time-domain model of a capacitor when the capacitance is varying with time

The current through a capacitor as a function of time is given by;

$$i(t)=C\cdot \frac{d}{dt}U(t)$$

When assuming that the capacitance $$C$$ does not vary with time.

But what if it does?

I don't know how to derive the equation above from Gauss's law, so here is instead my attempt at a "common-sense" kind of solution, I don't know whether this is valid or nonsense.

Integrating the equation above;

$$Q(t)=\int i(t) dt=C\cdot U(t)$$

..we get the equation for charge $$Q=C\cdot U$$,

I assume that this is always valid, even if $$C$$ is a function of time (let's ignore relativity and quantum mechanics for a moment).

If that is true then to get back to the original equation all I need to do is differentiate, this time letting $$C$$ be a function of time;

$$i(t)=\frac{d}{dt}Q(t)=\frac{d}{dt}[C(t)\cdot U(t)]=\frac{d}{dt}C(t)\cdot U(t)+C(t)\cdot \frac{d}{dt}U(t)$$

..which gives the result;

$$i(t)=\frac{d}{dt}C(t)\cdot U(t)+C(t)\cdot \frac{d}{dt}U(t)$$

Is this equation valid? Or how do you solve for the current through a capacitor with varying capacitance and voltage?

The first equation correctly expresses the charge as an integral of the current: $$Q(t)=\int_{-\infty}^{t}i(\tau)d\tau.$$ The problem however is with the definition of capacitance, used in the second equation, as a proportionality coefficient between the charge and the potential difference, $$Q(t)=C(t)U(t)$$, since there is no reason to think that charge instantaneously responds to a change in the potential! In fact, for this to be true we would need to have infinite current, which would make meaningless the first equation.

The closest working solution to defining linear capacitance is relating teh charge and the potential via a convolution integral: $$Q(t) = \int_{-\infty}^tC(t-\tau)U(\tau).$$ While this may appear as a complication, it is in fact a simplification from the point of view of the circuit theory, since in the frequency domain (i.e., after the Laplace or Fourier transform) we would get $$\tilde{Q}(\omega)=\tilde{C}(\omega)\tilde{U}(\omega),$$ i.e. convenient linear relation.

Update
While the discussion above focused on the incompatibility between the expressions relating charge&current and charge&potential in the question, it missed the essential point - that the capacitance is changing in time. This means that we need to use $$C(t,\tau)$$ rather than $$C(t -\tau)$$, which further complicates the issue.

• Assuming an ideal capacitor, no inductance or resistance, isn't it the case that if I was to instantaniously change the potential then the charge would also have to change instantaniously, ie. The current would in fact be infinite (which hence of course would be impossible). Im confused? – Vinzent Jul 21 at 16:50
• you seem to have dismissed the formula $Q(t)=C(t)V(t)$ as not being valid but in fact it is at the basis of all tunable radio circuits where $C=C(t) =f (V_1(t))$ and $v(t)$ is small RF signal, so that $q(t)=C(t)v(t)$ while $|v|<<V_1$ so the diode is always backbiased and $V_1(t)$ is the slowly time varying back bias voltage. – hyportnex Jul 21 at 17:14
• @hyportnex it is slowly varying and therefore effectively treated as static. This is a valid approximation, but not the general case. But I appreciate your comment - I think it adds value here. – Vadim Jul 21 at 17:19
• @Vinzent I added an update, since there was actually a problem with my initial answer: it took into account the finite charging time, but not the time varying capacitance. With time variation the Laplace transform won't work. – Vadim Jul 21 at 17:30
• The slow variation is a practical/application requirement for tunable circuit. In general, the "smallness" of $v$ is more important as the diode's charge depends on the total voltage $Q(v+V_1) \approx Q(V_1)+(dQ/dv) v$. and then $q(t) \approx (dQ/dv) v = f(V_1) v$ and $c=f(V_1)$ is the differential capacitance. If you vary $V_1$ "fast" you can get parametric amplification of the signal $v(t)$, this is rarely if ever used nowadays, but was a dominant technology 50 years ago... – hyportnex Jul 21 at 17:34

Yes your equation for i(t) is right

• Thank you for the answer, I will accept it if no better answers are given. Specifically I would like to see just a bit of rationale behind the answer. – Vinzent Jul 21 at 15:03
• but you gave the rational behind it yourself with Q=C(t)*U(t) and dQ/dt=i – trula Jul 21 at 15:07
• okay but then you could at least add to the answer that the reason it is correct is that my rationale is correct ;). I can't read from your answer whether you came to that conclusion by following your own different line of thinking, or added some knowledge/insight that I don't have.. – Vinzent Jul 21 at 15:19
• sorry not mentioning your reasoning, you should be more confident of your arguments. – trula Jul 21 at 15:48