Author Topic: Two capacitors and a resistor in a circuit.  (Read 23575 times)

0 Members and 1 Guest are viewing this topic.

Offline Hunter1Topic starter

  • Newbie
  • Posts: 7
  • Country: 00
Two capacitors and a resistor in a circuit.
« on: September 20, 2013, 06:01:57 pm »
I'd like to know which equation can be used to calculate the current flowing in the circuit below. The voltage in both capacitors are measured with a DMM. Initially the capacitor 1 is charged, and has 20 volts; the second has 0 volts.
If the capacitor 1 were replaced with a voltage source, the equation would be i = Vsource/Resistance * (1-e(-t/RC)).
I'm noob in both forum and electronics, so please be nice, thanks. Any explanations are welcome.


 

Online Zero999

  • Super Contributor
  • ***
  • Posts: 19492
  • Country: gb
  • 0999
Re: Two capacitors and a resistor in a circuit.
« Reply #1 on: September 20, 2013, 06:18:35 pm »
The charge will balance so the voltage across both of the capacitors is the same.

The steady state voltage is the charge in C1 but spread across both capacitors connected in parallel.

The formula for calculating the current will be similar, except the capacitance will be equal to both capacitors connected in series.
 

Offline smashedProton

  • Frequent Contributor
  • **
  • Posts: 641
  • Country: us
Re: Two capacitors and a resistor in a circuit.
« Reply #2 on: September 20, 2013, 06:32:16 pm »
Don't forget that there is also energy loss in the resistor.  The nost precise way to do this is use conservation of energy rather than charge
http://www.garrettbaldwin.com/

Invention, my dear friends, is 93% perspiration, 6% electricity, 4% evaporation, and 2% butterscotch ripple.
 

Online IanB

  • Super Contributor
  • ***
  • Posts: 11859
  • Country: us
Re: Two capacitors and a resistor in a circuit.
« Reply #3 on: September 20, 2013, 06:37:26 pm »
Don't forget that there is also energy loss in the resistor.  The nost precise way to do this is use conservation of energy rather than charge

That's exactly why conservation of energy is a poor way to do it.

Charge is conserved in a closed circuit, energy is not conserved.

The best model to use will be one where a conservation law can be applied.
 

Offline Hunter1Topic starter

  • Newbie
  • Posts: 7
  • Country: 00
Re: Two capacitors and a resistor in a circuit.
« Reply #4 on: September 20, 2013, 06:43:42 pm »
The charge will balance so the voltage across both of the capacitors is the same.

The steady state voltage is the charge in C1 but spread across both capacitors connected in parallel.

The formula for calculating the current will be similar, except the capacitance will be equal to both capacitors connected in series.

you meant series in the red mark right?
So, i use the same fomula, but for the capacitance i use the equivalent capacitance in series? is that right?
 

Offline Hunter1Topic starter

  • Newbie
  • Posts: 7
  • Country: 00
Re: Two capacitors and a resistor in a circuit.
« Reply #5 on: September 20, 2013, 06:45:33 pm »
I also tried to make transient analysis in LTSpice, but i don't know how, so if anyone can give a hint...
 

Offline c4757p

  • Super Contributor
  • ***
  • Posts: 7799
  • Country: us
  • adieu
Re: Two capacitors and a resistor in a circuit.
« Reply #6 on: September 20, 2013, 06:52:34 pm »
You can specify the initial conditions. First label a node (press F4), then press "s" and enter

Code: [Select]
.ic V(node_name)=node_voltage

And give the uic option ("skip initial operating point solution") to tell it to use the .ic statements.
No longer active here - try the IRC channel if you just can't be without me :)
 

Offline Hunter1Topic starter

  • Newbie
  • Posts: 7
  • Country: 00
Re: Two capacitors and a resistor in a circuit.
« Reply #7 on: September 20, 2013, 07:02:05 pm »
You can specify the initial conditions. First label a node (press F4), then press "s" and enter

Code: [Select]
.ic V(node_name)=node_voltage

And give the uic option ("skip initial operating point solution") to tell it to use the .ic statements.

Just done it, thanks.
 

Online IanB

  • Super Contributor
  • ***
  • Posts: 11859
  • Country: us
Re: Two capacitors and a resistor in a circuit.
« Reply #8 on: September 20, 2013, 07:02:30 pm »
This is an interesting scenario.

In the initial state with one capacitor charged and the other empty the energy in the system is:

E1 = 0.5 C V12

If we now "close the switch" and allow the two capacitors to equalize their voltages, the new energy of the system is:

E2 = 2 [ 0.5 C (V1/2)2 ] = 0.25 C V12

Half of the original energy has been lost.

We can also note that the entropy of the system has increased. This is an irreversible process since energy has been lost to the surroundings and there is no way to get it back.

Note also that the energy loss is independent of the value of the resistor. The resistor only affects how long it takes to reach equilibrium.
 

Offline Hunter1Topic starter

  • Newbie
  • Posts: 7
  • Country: 00
Re: Two capacitors and a resistor in a circuit.
« Reply #9 on: September 20, 2013, 07:10:31 pm »
This is an interesting scenario.

In the initial state with one capacitor charged and the other empty the energy in the system is:

E1 = 0.5 C V12

If we now "close the switch" and allow the two capacitors to equalize their voltages, the new energy of the system is:

E2 = 2 [ 0.5 C (V1/2)2 ] = 0.25 C V12

Half of the original energy has been lost.

We can also note that the entropy of the system has increased. This is an irreversible process since energy has been lost to the surroundings and there is no way to get it back.

Note also that the energy loss is independent of the value of the resistor. The resistor only affects how long it takes to reach equilibrium.
Interesting right, it's always half.
My teacher said an electromagnetic pulse is generated. You could think the bigger the resistance, more energy is dissipated through heat, but that's not the case...
 

Online Zero999

  • Super Contributor
  • ***
  • Posts: 19492
  • Country: gb
  • 0999
Re: Two capacitors and a resistor in a circuit.
« Reply #10 on: September 20, 2013, 09:43:45 pm »
The charge will balance so the voltage across both of the capacitors is the same.

The steady state voltage is the charge in C1 but spread across both capacitors connected in parallel.

The formula for calculating the current will be similar, except the capacitance will be equal to both capacitors connected in series.

you meant series in the red mark right?
So, i use the same fomula, but for the capacitance i use the equivalent capacitance in series? is that right?
No, the steady state voltage across both of the capacitors is equivalent to the charge on C1 when it's split equally between both of the capacitors which are connected in parallel.

To determine the steady state voltage, calculate the charge on C1 on coulombs, then re-arrange  the formula for voltage but with the sum of C1 and C2 for the capacitance.
My teacher said an electromagnetic pulse is generated. You could think the bigger the resistance, more energy is dissipated through heat, but that's not the case...
Yes in the real world EMP is generated and the intensity will depend on the physical dimensions of the circuit as well as the resistance which will determine how much energy is released as radiation.
« Last Edit: September 20, 2013, 09:46:30 pm by Hero999 »
 

Offline Dave

  • Super Contributor
  • ***
  • Posts: 1352
  • Country: si
  • I like to measure things.
Re: Two capacitors and a resistor in a circuit.
« Reply #11 on: September 20, 2013, 10:06:10 pm »
It's really simple, actually. You replace the charged capacitor with a model circuit of a voltage source and capacitor in series. So when you have the equation i(t) = Vsrc / R * (1-e^(-t/RC)), C is actually the equivalent capacitance of the two capacitors in series (C1*C2/(C1+C2)).
<fellbuendel> it's arduino, you're not supposed to know anything about what you're doing
<fellbuendel> if you knew, you wouldn't be using it
 

Offline free_electron

  • Super Contributor
  • ***
  • Posts: 8517
  • Country: us
    • SiliconValleyGarage
Re: Two capacitors and a resistor in a circuit.
« Reply #12 on: September 20, 2013, 11:21:41 pm »
i'm intrigued by this little 'problem'
the voltage should be slightly lower than 10 volt as some energy was lost into heat while the charge was balancing ( current through resistor * voltage across = heat ...)

should try this with a 5 ohm resistor and 1 Farad capacitors charged to 100 volts ( so we burn off some power )

Let's see how much of a 'lie' spice will generate ...
Professional Electron Wrangler.
Any comments, or points of view expressed, are my own and not endorsed , induced or compensated by my employer(s).
 

Offline Dave

  • Super Contributor
  • ***
  • Posts: 1352
  • Country: si
  • I like to measure things.
Re: Two capacitors and a resistor in a circuit.
« Reply #13 on: September 20, 2013, 11:30:59 pm »
i'm intrigued by this little 'problem'
the voltage should be slightly lower than 10 volt as some energy was lost into heat while the charge was balancing ( current through resistor * voltage across = heat ...)
With ideal components, voltage will be exactly 10 volts. The energy loss is accounted for. The stored energy in a capacitor is W = 1/2 * C * V^2. If the voltage is halved, the energy is reduced to a quarter. You have two capacitors, so you have two quarters. Half of the total energy is transformed into heat.
<fellbuendel> it's arduino, you're not supposed to know anything about what you're doing
<fellbuendel> if you knew, you wouldn't be using it
 

Offline free_electron

  • Super Contributor
  • ***
  • Posts: 8517
  • Country: us
    • SiliconValleyGarage
Re: Two capacitors and a resistor in a circuit.
« Reply #14 on: September 20, 2013, 11:53:39 pm »
i'm intrigued by this little 'problem'
the voltage should be slightly lower than 10 volt as some energy was lost into heat while the charge was balancing ( current through resistor * voltage across = heat ...)
With ideal components, voltage will be exactly 10 volts. The energy loss is accounted for. The stored energy in a capacitor is W = 1/2 * C * V^2. If the voltage is halved, the energy is reduced to a quarter. You have two capacitors, so you have two quarters. Half of the total energy is transformed into heat.

that can't be right...  that equation is only valid if you are charging from a fixed voltage.
in this case , as one capacitor charges, the other side discharges ( the voltage goes down )

Professional Electron Wrangler.
Any comments, or points of view expressed, are my own and not endorsed , induced or compensated by my employer(s).
 

Online IanB

  • Super Contributor
  • ***
  • Posts: 11859
  • Country: us
Re: Two capacitors and a resistor in a circuit.
« Reply #15 on: September 20, 2013, 11:57:03 pm »
i'm intrigued by this little 'problem'
the voltage should be slightly lower than 10 volt as some energy was lost into heat while the charge was balancing ( current through resistor * voltage across = heat ...)

The voltage on a fixed value capacitor depends only on the charge stored within it. Since charge is conserved (Kirchhoff's current law) the voltages measured on the capacitors will depend only on the redistribution of charge. The energy loss in the resistor does not have to be taken into account.
 

Offline onlooker

  • Frequent Contributor
  • **
  • Posts: 395
Re: Two capacitors and a resistor in a circuit.
« Reply #16 on: September 21, 2013, 12:08:16 am »
Equivalent voltage source is a good way. On the other hand, it is not too hard to just directly solve,

0.5*RC*dI/dt + I =0  with I|t=0 = 20/R
 

Offline Dave

  • Super Contributor
  • ***
  • Posts: 1352
  • Country: si
  • I like to measure things.
Re: Two capacitors and a resistor in a circuit.
« Reply #17 on: September 21, 2013, 12:23:49 am »
With ideal components, voltage will be exactly 10 volts. The energy loss is accounted for. The stored energy in a capacitor is W = 1/2 * C * V^2. If the voltage is halved, the energy is reduced to a quarter. You have two capacitors, so you have two quarters. Half of the total energy is transformed into heat.

that can't be right...  that equation is only valid if you are charging from a fixed voltage.
in this case , as one capacitor charges, the other side discharges ( the voltage goes down )
As I explained in my first post, a charged capacitor can be represented with an ideal voltage source connected in series with a capacitor. The voltage source has the same voltage as your charged capacitor had, the capacitance is the same. As the capacitor in your model charges, the voltage across your whole model (source+capacitor) is reduced, everything works out.

Also, the equation is always valid, as you are looking at the voltage across the capacitor, it doesn't matter how it got there.

Give me some time, I'll draw up something to explain it better.
« Last Edit: September 21, 2013, 01:15:18 am by Dave »
<fellbuendel> it's arduino, you're not supposed to know anything about what you're doing
<fellbuendel> if you knew, you wouldn't be using it
 

Offline Jeff1946

  • Regular Contributor
  • *
  • Posts: 104
Re: Two capacitors and a resistor in a circuit.
« Reply #18 on: September 21, 2013, 01:09:43 am »
Let me give you a mechanical analogy.  A moving vehicle hits a stationary one and they stick together after the collision.  Assuming they weigh the same after the impact they will have half the velocity of the first one due to conservation of momentum and half the energy due to twice the mass but one half  of the velocity.  It doesn't matter if the collision is soft (say rubber bumpers) or hard as long as they are locked together after the impact, the energy loss will be one half.

In a perfect elastic collision they first car will stop and the second have the velocity of the first, like the toy with suspended ball bearings.  I guess for an electrical analogy you would connect the charged cap to an inductor, disconnect at zero voltage, then connect the inductor to the second cap and disconnect at max voltage.  This is sort of the way buck and boost converters work.
 

Offline Dave

  • Super Contributor
  • ***
  • Posts: 1352
  • Country: si
  • I like to measure things.
Re: Two capacitors and a resistor in a circuit.
« Reply #19 on: September 21, 2013, 01:16:45 am »
I have made a simulation in LTspice to prove my theory.

The first image is the waveform plot of a charged capacitor connected to an empty capacitor. The voltage on the charged one drops while the voltage on the discharged rises. They meet in the middle.
(the .ic spice directives are there to set the initial voltage of the two capacitors; C1 charged at 20V and C2 discharged at 0V)


The second image shows the waveform of the voltages across the model charged capacitor (voltage source + cap) and discharged cap. As you can see, the waveform is identical to the waveform in the first image (ignore the spike at t=0, that was caused by the startup condition of the transient simulation; I had to use this condition, so the simulator didn't begin the simulation with already charged capacitors).


I also zoomed into the waveform at t=1h, to prove that the voltages will meet at exactly half the initial voltage (all four traces are overlapped).



Here is my LTspice simulation file, feel free to test it yourself. ;)
« Last Edit: September 21, 2013, 01:18:29 am by Dave »
<fellbuendel> it's arduino, you're not supposed to know anything about what you're doing
<fellbuendel> if you knew, you wouldn't be using it
 

Online IanB

  • Super Contributor
  • ***
  • Posts: 11859
  • Country: us
Re: Two capacitors and a resistor in a circuit.
« Reply #20 on: September 21, 2013, 02:07:15 am »
that can't be right...  that equation is only valid if you are charging from a fixed voltage.
in this case , as one capacitor charges, the other side discharges ( the voltage goes down )

The energy equation for a charged capacitor is an equation of state. You can see this from the equation itself:

    E = 0.5 C V2

The energy E depends only on the capacitance C and the charge voltage V. It does not depend on any other variables, such as how the voltage got there or what path it took. For an ideal capacitor that equation is universally true. There are no restrictions at all on how the capacitor got charged.
 

Offline Hunter1Topic starter

  • Newbie
  • Posts: 7
  • Country: 00
Re: Two capacitors and a resistor in a circuit.
« Reply #21 on: September 21, 2013, 02:14:08 am »
It's really simple, actually. You replace the charged capacitor with a model circuit of a voltage source and capacitor in series. So when you have the equation i(t) = Vsrc / R * (1-e^(-t/RC)), C is actually the equivalent capacitance of the two capacitors in series (C1*C2/(C1+C2)).

That's the best way to understand this simple circuit and see how it behaves.
 

Online Zero999

  • Super Contributor
  • ***
  • Posts: 19492
  • Country: gb
  • 0999
Re: Two capacitors and a resistor in a circuit.
« Reply #22 on: September 21, 2013, 09:54:41 pm »
Have you tried changing the capacitor values and observing the steady state voltage?

Calculate the charge on C1:
C = C1
q = CV

Now rearrange for V but this time C = C1 + C2
 

Offline free_electron

  • Super Contributor
  • ***
  • Posts: 8517
  • Country: us
    • SiliconValleyGarage
Re: Two capacitors and a resistor in a circuit.
« Reply #23 on: September 21, 2013, 10:13:55 pm »


The energy equation for a charged capacitor is an equation of state. You can see this from the equation itself:

    E = 0.5 C V2

The energy E depends only on the capacitance C and the charge voltage V. It does not depend on any other variables, such as how the voltage got there or what path it took. For an ideal capacitor that equation is universally true. There are no restrictions at all on how the capacitor got charged.

Firstlaw of nature : you cannot create energy , you cannot destroy energy. Only convert it.

As current is flowing from cap 1 to cap 2 ( as long as they don;t both have the same voltage) some of that energy is converted in heat. So after charge equalisation that energy has to be removed from the equation. this will result in a net drop of the voltage across the caps.

Otherwise you could create a perpeteuum mobile using three capacitors and a resistor. two in series , resistor , third. when balance has been achieved swap right one with one of the left ones and keep going...
« Last Edit: September 21, 2013, 10:16:24 pm by free_electron »
Professional Electron Wrangler.
Any comments, or points of view expressed, are my own and not endorsed , induced or compensated by my employer(s).
 

Offline onlooker

  • Frequent Contributor
  • **
  • Posts: 395
Re: Two capacitors and a resistor in a circuit.
« Reply #24 on: September 21, 2013, 10:26:43 pm »
Quote
Firstlaw of nature : ...

You are wrongly assuming the energy stored in a capacitor is proportional to V. But the math or physics fact is that it is proportional to V2 as listed many times in this thread. Therefore, 20V drops to 10V is the correct answer and it is consistent with all known physics or math.
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf