# How to define initial conditions for complex RC circuit?

I need to calculate $$\U_2 (t)\$$. See the circuit below:

Given $$\E\$$, $$\R_1\$$, $$\R_2\$$, $$\C_1\$$, $$\C_2\$$, $$\C_3\$$.

The first Kirchhoff's rule:

$$i_1 = i_2 + i_3 = i_4$$

Now find the all currents:

$$i_1 = \frac{E-U_1}{R_1} \\ i_2 = (C_2 + C_3)\frac{d(U_1-U_2)}{dt} \\ i_3 = \frac{U_1 - U_2}{R_2} \\ i_4 = C_1 \frac{dU_2}{dt}$$

Now I made the substitution. The currents in the Kirchhoff's rule are substituted with their actual expressions, and $$\C=C_2+C_3\$$. I've got the differential equation:

$$\frac{d^2U_2}{dt^2} + \frac{(C_1+C+\frac{R_1 C_1}{R_2})}{R_1C_1C} \frac{dU_2}{dt} + \frac{U_2}{R_1R_2C_1C}=\frac{E}{R_1R_2C_1C}$$

The solution is:

$$U_2(t)=E+K_1e^{t(\varphi+\lambda)} + K_2e^{t(\varphi-\lambda)}$$

where

$$\varphi=-\frac{1}{2}(\frac{1}{C_1R_1}+\frac{1}{CR_1}+\frac{1}{CR_2}) \\ \lambda=\frac{\sqrt{C^2R_2^2-2CC_1R_1R_2+2CC_1R_2^2+C_1^2R_1^2+2C_1^2R_1R_2+C_1^2R_2^2}}{2CC_1R_1R_2}$$

The solution has two integration constants, so I need two initial conditions. The first is trivial - $$\U_2(0)=0\$$. And what about the second condition? How can I define it? Measuring real value in simulation or real circuit? I wouldn't do this, I prefer to calculate real equation.

• Perhaps you could get the 2nd condition from the steady state as t approaches infinity? What do you think what the steady state U2 will be when all capacitors are charged and no more current is flowing through them? By the way, you need to define what happens at t=0. Without any switches in the circuit, there is no way of knowing what the initial condition was.
– Bart
Commented Jan 16, 2023 at 9:09
• I would not do it in the time-domain. Laplace seems helpfull here. Commented Jan 16, 2023 at 10:12
• @Bart, is you propose to take any big number t, and get U2(t)=12V? Taking 1ms, 1s, 100s, 100000s will give the same values of K1, K2? Commented Jan 16, 2023 at 10:57
• In retrospect I don't think that will work. I remember now when solving a 2nd order DE one of the initial conditions if often a time derivative of the solution. You could try determining the initial current when the circuit switches on and use that in your equations.
– Bart
Commented Jan 16, 2023 at 11:00
• @ElectronicsStudent, Laplace also needs initial conditions, doesn't it? Commented Jan 17, 2023 at 2:35

When circuit is switched on, $$\U_1(0^+)=0\$$. Let's find current i1=i4:

$$i_4(0^+)=\frac{E}{R_1}$$

On the other hand,

$$i_4=C_1\frac{dU_2}{dt}$$

We can substitute $$\dU_2/dt\$$ with found expression and make the equality:

$$C_1\frac{d(E+K_1e^{t(\varphi-\lambda)}+K_2e^{t(\varphi+\lambda)})}{dt}=\frac{E}{R_1}$$

Now find the derivative:

$$C_1((\varphi-\lambda)K_1e^{t(\varphi-\lambda)}+(\varphi+\lambda)K_2e^{t(\varphi+\lambda)})=\frac{E}{R_1}$$

Now substitute $$\t=0\$$:

$$C_1((\varphi-\lambda)K_1+(\varphi+\lambda)K_2)=\frac{E}{R_1}$$

Finally, there is the system of equations with unknown integration constants K1, K2:

$$\begin{cases} (\varphi-\lambda)K_1+(\varphi+\lambda)K_2=\frac{E}{R_1C_1}\\ K_1+K_2=-E \end{cases}$$