# capacitor connected across DC voltage source?

Joined Nov 24, 2011
629
Hello
Is that true, if capacitor connect across constant DC voltage source, output voltage of capacitor does not change, also the current through capacitor does not change. If yes than how to proof mathematically
Let's take example, 4F capacitor which has internal resistance is 2 ohm connected across 10 volt DC supply
1. Find out voltage across capacitor
2. Find out current through capacitor
According to definition, voltage across capacitor will be 10 DC.
We know formula i=c(dv/dt)
I=4*?
Another formula v=i*r
We know voltage drop across capacitor v=10v DC, internal resistance r=2 ohms
Thus i=10/2=5 amps

How to proof mathematically, if capacitor connected across DC voltage source neither voltage across capacitor nor current through capacitor change ,

please guide me on right direction.

Last edited:

#### AlbertHall

Joined Jun 4, 2014
11,317
The 2 Ohms is in series with the capacitor not parallel. 10V across the capacitor, 0V across the resistor, no current (after the initial time while the capacitor charges).

#### WBahn

Joined Mar 31, 2012
26,398
Who says that either the voltage or the current through the capacitor don't change?

Look at the equations you got. Is the current through the capacitor changing? Is the voltage across the capacitor changing?

Joined Nov 24, 2011
629
Who says that either the voltage or the current through the capacitor don't change?

Look at the equations you got. Is the current through the capacitor changing? Is the voltage across the capacitor changing?
I read somewhere while searching on Internet , but where I don't know
if I just put the value of t In equations, the value of current is decreasing. From the equations, it can be say that current change over time

#### MrAl

Joined Jun 17, 2014
8,257
I read somewhere while searching on Internet , but where I don't know
if I just put the value of t In equations, the value of current is decreasing. From the equations, it can be say that current change over time
Hi,

Yes but if you want to get exact then you have to figure what happen at all times before t=infinity and for what happens at t=infinity. They are two different animals.
We often call t=1e7 for example infinity, but to be exact that's not infinity so look at what is happening at t=1e7 for example and then at t=infinity. You'll find a couple interesting results.
If you look at values for t=1, t=10, t=100, t=1000, etc., up to maybe 1e50 you'll see how it changes, but when you go very high in value the usual 16 digits of precision used in most computer calculators wont be good enough. That is a hint about what is happening.

#### WBahn

Joined Mar 31, 2012
26,398
I read somewhere while searching on Internet , but where I don't know
if I just put the value of t In equations, the value of current is decreasing. From the equations, it can be say that current change over time
Instead of just trying memorize things that you read on the Internet, try understanding the underlying concepts.

I think the thing you read somewhere is related to the concept that the voltage across a capacitor cannot change INSTANTANEOUSLY. If you plot the voltage versus time it must be a continuous plot. The current through it does NOT have to be continuous. The reverse is true for an inductor. For a resistor, neither the voltage nor the current need be continuous.

When you connect a series RC branch to a DC voltage source, all of the voltage appears across the resistor since the voltage across the capacitor is initially zero (assuming it had no initial charge) and so the current through the resistor (and hence the capacitor) is initially the same as if just the resistor were placed across the voltage source. The capacitor initially behaves like a short circuit. As time goes by, the current flowing through the capacitor causes the voltage to increase. The reduces the voltage across the resistor which, in turn, results in less current in it (and thus in the capacitor as well). The result is that the rate at which the voltage builds across the capacitor slows, but it is still building. Eventually the voltage across the capacitor will be close enough to the source voltage that the current flowing in the resistor is negligible and, at that point, the voltage across the capacitor stops growing and now the capacitor is behaving like an open circuit.

Mathematically, this takes an infinite amount of time. For most practical purposes it takes about five time constants since, at that point, the current is less than 1% of its initial value and we seldom know component values to better than 1%. But even if we said that we wanted the current to be down to one-part-per-trillion (so if the initial current was 1 A we want the current to fall to 1 pA), it would only take 28 time constants. In most cases, it's fallen below the noise floor well before this.

Joined Nov 24, 2011
629
Please look at my first post. I have taken simple example. And trying to find out voltage across capacitor and current through capacitor over time. In image you will see, I tried to solve equations. But I am stuck here. Now I don't understand what I do, I need formula, but now I don't understand which formulas I have to apply so that I can find out voltage across capacitor and current through capacitor over time?

Last edited:

#### WBahn

Joined Mar 31, 2012
26,398
Please look at my first post. I have taken simple example. And trying to find out voltage across capacitor and current through capacitor over time. In image you will see, I tried to solve equations. But I am stuck here. Now I don't understand what I do, I need formula, but now I don't understand which formulas I have to apply so that I can find out voltage across capacitor and current through capacitor over time?
You HAVE the voltage across the capacitor AND the current through the capacitor over time! Look at the results of your work in the image you posted! Aside from your usual refusal to use units properly, you obtained

$$i(t) \; = \; 5\.A \; e^{\frac{t}{8\,s}$$

If that isn't the current through the capacitor over time, then what do you think it is?

You still need to evaluate the integral in the second part, but if that expression isn't the voltage across the capacitor over time, then what do you think it is?

Joined Nov 24, 2011
629
You HAVE the voltage across the capacitor AND the current through the capacitor over time! Look at the results of your work in the image you posted! Aside from your usual refusal to use units properly, you obtained

$$i(t) \; = \; 5\.A \; e^{\frac{t}{8\,s}$$

If that isn't the current through the capacitor over time, then what do you think it is?

You still need to evaluate the integral in the second part, but if that expression isn't the voltage across the capacitor over time, then what do you think it is?
If initial no charge across capacitor, capacitor act as short circuit.
Look at attachments, sorry for poor quality

#### WBahn

Joined Mar 31, 2012
26,398
Why are you integrating from 0 to 1 (i.e., from 0 seconds to 1 second)? What is magical about 1 second? Why not 1 minute, or 1 hour? Why not 1 millisecond?

If you had bothered to use units properly, you might have been led to ask yourself that question.

If you want v(t), then integrate from 0 to t.

If you want v(t=∞), then integrate from 0 to t=∞.

Joined Nov 24, 2011
629
Why are you integrating from 0 to 1 (i.e., from 0 seconds to 1 second)? What is magical about 1 second? Why not 1 minute, or 1 hour? Why not 1 millisecond?

If you had bothered to use units properly, you might have been led to ask yourself that question.

If you want v(t), then integrate from 0 to t.

If you want v(t=∞), then integrate from 0 to t=∞.
I just wanted to find out voltage across capacitor and current through capacitor at 1 second, after that I will calculate for 2s,3s,...etc so I can get table than I can easily figure out what is value of voltage and current at specific time
Have you seen the answer, value of voltage is negative but it should be positive because capacitor is charging, when it begain to charge. It build some voltage

Last edited:

#### WBahn

Joined Mar 31, 2012
26,398
Have you seen the answer, value of voltage is negative but it should be positive because capacitor is charging, when it begain to charge. It build some voltage
That's because you don't know how to integrate. And because you refuse to track your units, you didn't catch that you made a mistake that messed up the units on the very first line of your attempt to do so. As a result, you wasted a bunch of time coming up with an answer that was guaranteed to be wrong, but just went ahead and tacked on the units that you WANTED it to have and called it a day.

Joined Nov 24, 2011
629
That's because you don't know how to integrate. And because you refuse to track your units, you didn't catch that you made a mistake that messed up the units on the very first line of your attempt to do so. As a result, you wasted a bunch of time coming up with an answer that was guaranteed to be wrong, but just went ahead and tacked on the units that you WANTED it to have and called it a day.
Actually I wanted to know how the voltage across capacitor and current through capacitor change over time. Than I take example to understand. The example that I have taken is hand made, I am not sure does it make any sense

#### WBahn

Joined Mar 31, 2012
26,398
Actually I wanted to know how the voltage across capacitor and current through capacitor change over time. Than I take example to understand. The example that I have taken is hand made, I am not sure does it make any sense
It makes perfectly fine sense and you can certainly use it to see how the voltage across and the current through a capacitor change over time. But only if you do the math right and since your math skills are weak you make a lot of mistakes. That's fine; you have the opportunity to learn from your mistakes if you are willing to. But your steadfast refusal to track units, particularly give your weak math skills, indicates that you don't really care about finding your mistakes, let along learning from them.

#### MrAl

Joined Jun 17, 2014
8,257
Hello again,

If you are having trouble integrating you can do it numerically first to get an idea what is happening.

If you start with 10v and 10 ohms and 1 Farad, after the first second an approximation with sample time T=1 second is:
i1=(Vcc-Vc[0])/R=(10-0)/10=1
Vc[1]=Vc[0]+i1*T*C=1*1=1v

Then:
i2=(Vcc-Vc[1])/R=(10-1)/10=0.9
Vc[2]=Vc[1]+i2*T*C=1+0.9*1*1=1+0.9=1.9v

Then:
i3=(Vcc-Vc[2])/R=(10-1.9)/10=0.81
Vc[3]=Vc[2]+0.81=1.9+0.81=2.71v

Keep doing that and see what you get. Then later you can try to decrease the time value from 1 second to 0.1 seconds.
i1=(Vcc-Vc[0])/R=(10-0)/10=1
Vc[1]=Vc[0]+i*T*C=1*0.1*1=0.1v

i2=(Vcc-Vc[1])/R=(10-0.1)/10=0.99
Vc[2]=Vc[1]+i2*T*C=0.1+0.99*0.1*1=0.1+0.099=0.199

and you can keep doing that up to 1 second or whatever you want. Then if you want to get finer detail, decrease the sample time T to 0.01 seconds and start over again.

Doing this 1000 times with increment T=0.01 seconds we get for the last four calculations (time, voltage shown):
9.970, 6.311993
9.980, 6.315681
9.990, 6.319365
10.00, 6.323046

The more exact result for 10 seconds is:
6.321206

so see that got pretty close.

Last edited:

Joined Nov 24, 2011
629
So I have to calculate voltage across capacitor from zero to infinity

#### WBahn

Joined Mar 31, 2012
26,398
Once again, if you would bother to track your units, you would discover that your first line of actual work, line 3, is wrong. Everything beyond that is wasted time and effort, for you and for anyone looking at your work.

Is there a specific reason why you don't care to catch your mistakes?

Joined Nov 24, 2011
629
Hello
My math skill is very weak, but I am trying to improve and definitely I will improve
Does this make sense

#### WBahn

Joined Mar 31, 2012
26,398
Thank you are finally tracking your units. I know that it is awkward at first, but after a while you will find it nearly impossible to NOT track your units properly.

So now let's examine the units on that bottom line. You have

Outside the square brackets you have (5A/4F)(1/8s).

From the relationship Q = CV for the charge stored on a capacitor as a function of the voltage across it we see that

1 F = 1 C/V (coulomb/volt)

Note that it is important, but a bit tricky, to keep 'C' being capacitance and 'C' being the unit of charge distinct and separate.

We also know that

1 A = 1 C/s (coulomb/second)

So let's put both of those into that expression:

$$\( \frac{5 \, A}{4 \, F}$$$$\frac{1}{8\, s}$$ \; = \; \frac{5\,A}{4\,F \, 8\,s} \; = \; \frac{4 \,\frac{C}{s}}{32\,\frac{C}{V}\,s} \; = \; 10\,\frac{V}{s^2}
\)

Then, inside the brackets, you have an exponential, which is dimensionless, and t^2, which has units of s^2. That will give you overall units of V, which is what you are looking for and so I stand corrected that the mistake you make here, while convoluted, did not actually mess up the units along the way (which is a bit unusual for the kind of mistake you made here, but it DOES happen).

So let's look at the mistake itself.

The basic form of the integral you are trying to take is

$$\int{e^{at}dt}$$

Look at any Table of Integrals and you will see that this evaluates to

$$\int{e^{at}dt} \; = \; \frac{1}{a}e^{at} \, + \, C$$

We see from the integrand that the expression on the left has units of time since the exponential is dimensionless and 'dt' has units of time. Because the exponent must be dimensionless, we also know that 'a' has to have units of inverse-time. The right side has units of invers-(inverse-time), or just time, so life is good.

You are trying to say that it evaluates to

$$\int{e^{at}dt} \; = \; a \. t^2 \. e^{at} \, + \, C$$

Here you've made two mistakes that, dimensionally, happen to cancel out. You have 'a' in the numerator instead of the denominator and then you are trying to integrate the exponent to go from t to t^2 (but, then what about the factor of 1/2 that goes along with that?). So now your expression has units of inverse-time multiplied by time-squared, which coincidentally happens to yield units of time.

The check you can make here (and it is good practice to get into) is after evaluating an integral, check to see if taking the derivative of the result yields the original integrand. This is very useful because taking derivatives accurately is generally for easier for more people than evaluating integrals.

So what is

$$\frac{d}{dt}{\( \frac{1}{a}e^{at} \, + \, C$$}
\)

Do you see that it yields

$$\frac{d}{dt}{\( \frac{1}{a}e^{at} \, + \, C$$} \; = \; e^{at}
\)

which is our original integrand (with a = -1/(8 s))?

Now think of what

$$\frac{d}{dt}{\( a \. t^2 \. e^{at} \, + \, C$$ }
\)

will yield. Without even attempting to actually evaluate this derivative, we can easily see that it will NOT yield the simple integrand we started with.