# Finding current and charge in a RC circuit.

1. Mar 25, 2014

### U.Renko

1. The problem statement, all variables and given/known data
A resistor with resistance R and a capacitor with capacitance C are connected in series to a direct current battery ε.
find the current and charge on the circuit as function of time.

it looks more like a review of differential equations, so I'm not really sure if I should post here or in the calculus forum....feel free to move it if you think it's better.

2. Relevant equations

potential at resistor: $V_r = Ri$

potential at capacitor:$V_c = \frac{q}{C}$

3. The attempt at a solution

Applying one of the Kirchhoff's law:
$\epsilon - Ri - \frac{q}{C} = 0$
$\epsilon = Ri +\frac{q}{C}$
since $i = \frac{dq}{dt}$ we can rewrite the equation as

$\frac{\epsilon}{R} = \frac{dq}{dt} + \frac{q}{RC}$ and solve with an integration factor $e^{\frac{t}{RC}}$
so we have:
$\frac{\epsilon}{R} e^{\frac{t}{RC}} = \frac{d}{dt}(q e^{\frac{t}{RC}})$
and then:

$\int \frac{\epsilon}{R} e^{\frac{t}{RC}} dt = q e^{\frac{t}{RC}}$

here I'm kinda stuck:
because the problem did not give any initial conditions, should I just solve an indefinite integral or integrate from zero to an arbitrary t??

also: $q e^{\frac{t}{RC}}$ comes from integrating $\int_{a}^{b} \frac{d}{dt}(q e^{\frac{t}{RC}})dt$ and applying the fundamental theorem of calculus.
However, don't I need the values a and b to properly use it?

2. Mar 26, 2014

### ehild

The resistor and capacitor are connected in series to a battery. You can count the time from the instant when you close the circuit. At that instant you can assume zero charge on the capacitor, if it is not stated otherwise.

The differential equation for q is correct,

$$\frac{\epsilon}{R} = \frac{dq}{dt} + \frac{q}{RC}$$

Solve for q(t) with the initial condition q(0)=0.

ehild

3. Mar 26, 2014

### U.Renko

hmm let's see:

$\int_{0}^{t} \frac{\epsilon}{R}e^{\frac{t}{RC}}dt = qe^{\frac{t}{RC}$
solving the left hand side by substitution gives:
$C\epsilon\left(e^{\frac{t}{RC} -1 \right) = qe^{\frac{t}{RC}$
and so:

$q(t)= e^{\frac{-t}{RC}C\epsilon\left(e^{\frac{t}{RC} -1 \right)$

$q(t)= C\epsilon\left(1-e^{\frac{-t}{RC} \right)$
and
$i(t) = \frac{\epsilon}{R}e^{\frac{-t}{RC}$

is that correct?

Last edited: Mar 26, 2014
4. Mar 26, 2014

### Rellek

Made some corrections. Are these the equations you meant?

5. Mar 26, 2014

### Rellek

And if so, then yes, you are correct.

6. Mar 26, 2014

### U.Renko

yes, that is what I meant.

I honestly don't know where I messed up with the LaTeX though...

7. Mar 26, 2014

### Rellek

Just missed a few brackets here and there. That's enough to break it though haha