Main content
Electrical engineering
Course: Electrical engineering > Unit 2
Lesson 4: Natural and forced response- Capacitor i-v equations
- A capacitor integrates current
- Capacitor i-v equation in action
- Inductor equations
- Inductor kickback (1 of 2)
- Inductor kickback (2 of 2)
- Inductor i-v equation in action
- RC natural response - intuition
- RC natural response - derivation
- RC natural response - example
- RC natural response
- RC step response - intuition
- RC step response setup (1 of 3)
- RC step response solve (2 of 3)
- RC step response example (3 of 3)
- RC step response
- RL natural response
- Sketching exponentials
- Sketching exponentials - examples
- LC natural response intuition 1
- LC natural response intuition 2
- LC natural response derivation 1
- LC natural response derivation 2
- LC natural response derivation 3
- LC natural response derivation 4
- LC natural response example
- LC natural response
- LC natural response - derivation
- RLC natural response - intuition
- RLC natural response - derivation
- RLC natural response - variations
© 2023 Khan AcademyTerms of usePrivacy PolicyCookie Notice
LC natural response - derivation
Formal derivation of the LC natural response, where we discover the frequency of oscillation. Written by Willy McAllister.
We derive the natural response of the inductor-capacitor, , circuit.
This is where sine waves are born.
Background
This article walks you step-by-step through the solution to a nd-order differential equation. I don't assume you have previous experience with this type of equation. Sal has videos on 2nd-order equations, too. st-order differential equations are solved step-by-step in the articles on and natural response. You can also check out Sal's videos on 1st-order differential equations.
What we're building to
The natural response of an circuit is described by this homogeneous second-order differential equation:
The solution for the current is:
Where is the natural frequency of the circuit and is the starting voltage on the capacitor.
In electrical engineering, we use the letter as the .
(The letter is already taken for current.)
(The letter
Second-order systems
Now we look at a circuit with two energy-storage elements and no resistor. Circuits with two storage elements are second-order systems, because they produce equations with second derivatives.
This article covers the circuit, one of the last two circuits we will solve with full differential equation treatment. The last circuit to get this treatment is the (in the next article). The mathematics of differential equations keeps getting harder. Fortunately, after we are done with the and , we learn a really nice shortcut to make our lives simpler.
We stick with differential equations instead of going straight to the shortcut because I want to show you where sine waves come from in electronics. Sine waves emerge from the solution to second-order equations. Sine waves are important. They are the building block for all other types of signals.
Second-order systems are the first systems that rock back and forth in time, or oscillate. The classic example of a mechanical second-order system is a clock with a pendulum. In electronics, the classic second-order system is the circuit.
Natural response
We want to find the natural response of the circuit. The natural response is what a circuit does when there is no external driving force. Natural response is always an important part of the total response of a circuit.
Natural response of a nd-order circuit
To get going on a precise answer for the natural response, let's set up the circuit with some initial energy. The components are labeled with careful attention to the sign convention for passive components. The inductor has an initial current of because the switch starts in the open position. We assume the capacitor has an initial voltage before the switch closes, . (
Notice how has its sign at the bottom.) We let the switch close at .
As with every circuit analysis, we begin by writing one of Kirchhoff's Laws. In this case, we'll go with Kirchhoff's Voltage Law (KVL) around the loop, starting at the lower left and going around clockwise.
This KVL equation contains an integral, which is awkward to deal with. The way to get rid of an integral (also known as an anti-derivative) is to take its derivative. We take the derivative of every term in the equation.
This gives us the second derivative of the term, gets rid of the integral in the term, and still leaves us with on the right side.
The equation is tidier if the first term has no coefficient, so we divide through by . This second-order differential equation captures the essence of our circuit.
Propose a solution
When we solved the first-order and circuits, we guessed at an exponential solution for . Guessing works with second-order equations, too. Our second-order equation has similar requirements: we want the function and its derivatives to look like each other so they can all add up to . The exponential function fits the description. We propose an exponential function with some adjustable parameters:
Now we substitute our proposed function into the differential equation and check to see if it makes the equation true.
Let's work on the first term by taking two derivatives. The first derivative is:
And now the second derivative:
We plug our new second derivative back into the equation:
And do some factoring to pull to the side:
How many ways can we make this equation true?
That leaves the interesting solution when the ( term equals :
This equation is called the characteristic equation of our circuit.
We want to find the roots of the characteristic equation (the value(s) of that make left side equal zero).
Whoa, look what's about to happen. We're about to take the square root of a negative number. We are about to generate an imaginary number.
Electrical engineers use the letter to indicate the imaginary unit, , since we already use for current.
As a shorthand, we give a name to the square root term:
The roots of the characteristic equation can be expressed in terms of as:
How about that! The circuit produces two complex natural frequencies, and . And one of the natural frequencies is negative. So curious. This will turn out to be very interesting.
Either or by itself is a root of the equation. For our proposed solution we allow the possibility of both natural frequencies, and . So we write a general solution as a linear combination of two terms, with two adjustable constants.
At this point you might be thinking, "Complex exponents? Negative frequency? Is this really happening?" The answer is, yes. So please hang in there while we work with these expressions.
Euler's identities
To work with these complex exponents, we resort to an important identity.
In the linked video, anytime Sal says , we will say .
These identities let us turn the strange thing to a normal complex number. The real and imaginary parts come from a cosine or sine function, so both the real and imaginary components are somewhere in the range to .
Use Euler's identities
We can use Euler's identities in our proposed solution.
Multiply through the constants:
and gather the cosine terms and sine terms together:
We don't know or , or their sum or difference. It seems perfectly ok to replace the unknown 's with different unknown 's, just to make things appear a bit simpler.
If we let , and ), then is:
We used Euler's identities to rearrange the complex exponentials into a sum of trig functions. This equation is the very first time in electronics we see a sine or cosine as a function of time (a sinusoidal waveform).
(Notice how we defined to include , so no longer directly appears in the proposed solution.)
Test the proposed solution
Next, we check our proposed solution by plugging it into the second-order differential equation. If we can come up with values for the constants that make the differential equation true, the proposed solution is a winner.
Figure out the initial conditions
The initial conditions needed for a second-order circuit are a little more involved than for a first-order circuit.
When we did this for first-order circuits, or , we had to know a single value, a starting current or voltage. With a second-order circuit, we need to know two things: the current and the derivative of the current when the switch closes.
We write down everything we know about (the moment just before the switch closes):
- The switch is open, so
- The starting capacitor voltage is specified:
.
If is the moment just after the switch closes, our goal is to find and .
We know some properties of inductors and capacitors that will take us from to :
- Inductor current cannot change instantly, so
- Capacitor voltage cannot change instantly, so
(After the switch closes there is only one , so we'll just call it from now on.)
Now we have , but not , yet. Where can we get this derivative? How about from the inductor's - equation?
Now we have our second initial condition. This says the moment just after the switch closes, the current in the inductor starts changing with a slope of amperes every second.
Summary of the initial conditions
Use the initial conditions to find and
We use our initial conditions one at a time to solve for the constants. The first initial condition is at . Let's plug it into the proposed solution and see where it takes us:
Now we go after using the second initial condition. The derivative of at is:
Take the derivative of the proposed :
Evaluating this expression at :
We can expand into and to get:
And finally, after a lot of hard work, the solution for the current is:
Real component values
To demonstrate what the solution looks like, we assign component values henry and farad, and a starting voltage on the capacitor of .
The natural frequency, is:
The current as a function of time is:
The current starts up the moment the switch closes:
The current takes off in a sine wave pattern that continues forever. (There is no resistor in this ideal circuit, so the energy never dissipates. In a real-world circuit there would be small resistances that eventually dissipate the energy.)
The natural frequency of the sine wave is . We can convert from radians per second to cycles per second, (also known as hertz, or ) knowing that full cycle of a sine function corresponds to radians. We usually use the symbol for cycles per second. The conversion is:
The natural frequency of the circuit in cycles per second, hertz, , is:
or equivalently, the current completes a full cycle every seconds.
A quick look back at the initial conditions
We can look in close to the origin to see how the solution accounted for the initial conditions. The sine wave starts at the origin, . And notice how the slope of the blue sine wave near the origin matches the slope of the straight black line, .
Voltage,
At this point we have solved the current. If you want to press on a little further, have a go at solving for the voltage, .
Find an expression for after the switch closes.
Probably the quickest route is to use the inductor - equation to solve for in terms of .
Summary
We derived the natural response of an circuit by first creating this homogeneous second-order differential equation:
Then we assumed a solution of the form , which gave us the characteristic equation for the circuit:
When computing the roots of the characteristic equation we ran head on into a very strange expression: , an exponential with complex exponent. We reached deep into our bag of tricks and pulled out:
Euler's identities
These identities let us express the complex exponential as a combination of sine and cosine functions. (In electrical engineering, we use the letter as the name for )
Then we looked carefully at the circuit to find the initial conditions. For a second-order system, we found an initial and an initial .
We found a function for that satisfied the differential equation:
(This solution applies when the starting current in the inductor is .)
Want to join the conversation?
- Under First Order Systems in the Introduction, would it be right to call the natural response of a first order an exponential decay in terms of the graph? Thank you!(2 votes)
- Correct. All RC and RL circuits follow this curve. Don't forget there is another related curve to describe charging.(2 votes)
- After solving quadratic, we concluded that two roots are S1 and S2. But why did we are both to get general solution ? Isn't answer supposed to be one of the roots ?(1 vote)
- You can't decide ahead of time what the answer is 'supposed' to be. You have to see what the math tells you. We proposed a very general solution, with terms that included S1 and S2. Then we proceeded to test the proposed solution by plugging it into the differential equation and testing to see if the equation came out true. Along the way we computed the leading constants. In the end we got a true solution, which makes us very happy and also makes us love the proposed solution.
What would have happened to the math if our fancy 2-term proposed solution was too fancy? The derivation would cause one of the terms to drop out. This would happen for example if K2 turned out to be 0. That didn't happen, did it?(2 votes)
- Its stated that capacitor voltage can't change instantly, so v(0-) = v(0+) = Vo. But v(0-) is -Vo. Why were signs changed ?(1 vote)
- Sorry for the confusion. I could have been clearer. The capacitor voltage has its positive sign at the bottom of the capacitor (to respect the passive sign convention). In the section on Figure out the Initial Conditions I started with this definition, but then in the second circuit diagram where the switch is closed I change over to calling the voltage just "v" and flipped it to be positive at the top. I mentioned "v" before showing you what it is. Sorry.
There's an improved version of this article at https://spinningnumbers.org/a/lc-natural-response-derivation.html.(2 votes)
- Why can we write i(t) = K1 * e^jwt + K2 * e^-jwt? I would expect that we work out i(t) separately for each of s. Do I miss something?(1 vote)
- If you go down two parallel branches solving separately for each complex exponential term you eliminate solutions where both K's are non-zero at the same time. In fact, both K's can be non-zero, which results in the most interesting solutions.(2 votes)
- I think there is a typo in the last sentence.(1 vote)
- How did the imaginary j in A2 disappear after we solved for it? Does that mean (K1 - K2) is an imaginary number?(1 vote)
- The j is simply a component of A2. Since A2=j(K1-K2), and A2 is a real number, then (K1-K2) is also imaginary. We can try and solve for K1 and K2, but there is no need as K1 and K2 are not actually part of the solution that we need for i.(1 vote)
- Wouldn't it have been simpler to just use i=Ksin(st) as the initial guess for solving the 2nd order ODE? Since we know that the double derivative of a sine function ends up as a -sine function, you would always have some +sine + -sine = 0. Which fulfils the ODE.
Then you wouldn't have to mess around with complex numbers and Euler's formulae to get to the same answer. I tried it out on paper from i=Ksin(st) when I first saw you going with exponentials and got to the same result much faster.
Is there any reason to use exponentials other than trying to keep the same pattern as the derivations from the previous circuits?(1 vote)- If you are a great guesser then yes, you could go for a sine guess. Your last point is the main reason for walking through the complex exponential. You will see it again when you visit the RLC derivation.
I did a pretty good rewrite of this article here: https://spinningnumbers.org/t/topic-natural-and-forced-response.html#lc(1 vote)