I am currently trying to model parts of an electronic system in Simulink using standard (discrete) blocks.
I'd like to model two capacitors connected in parallel incl. their series resistances (ESR). In SPICE this would look like this:
Writing down some equations for voltages and currents was straightforward:
$$ i_{total} = i_{C1} + i_{C2} $$ $$ i_{C1} = (V_{ES}-V_{C1}) / R1 $$ $$ i_{C2} = (V_{ES}-V_{C2}) / R2 $$ $$ V_{ES} = V_{C1} + i_{C1} \times R1 = V_{C2} + i_{C2} \times R2 $$
My main problem now is that I do not find a formulation for how the total current splits into \$i_{C1}\$ and \$i_{C2}\$, since this depends on the voltage \$V_{ES}\$.
Another problem with my approach: I have the current \$i_{total}\$ as my block input and I try to find the correct "split ratio" to feed it into my integrators (= ideal caps). Since the voltages on the capacitors rise at different rates, I would also have to take the current flow between the caps into account, such that with \$t \rightarrow \infty \$ and no input current \$V_{ES} = V_{C1} = V_{C2}\$.
Does anyone have a suggestion?