This tool simulates a series RLC circuit: a resistor, an inductor and a capacitor connected in a single loop with a voltage source. The charge on the capacitor follows the ODE below, where q is the charge at time t, q′ = i is the current, q″ is the rate of change of the current, L, R and C are the inductance, resistance and capacitance, and E(t) is a source voltage you choose from a family of common functions.
Set the parameters and the source, then watch the circuit, the charge–current phase portrait, and the time series move together. The circuit obeys the same kind of equation as a spring–mass–damper, with L playing the role of the mass, R the damping and 1/C the spring constant (see Physics & Mathematics).
The phase portrait is shown only when the equation is autonomous, that is, when the source voltage does not change with (no source, or a constant voltage).
With the current , the direction field changes from moment to moment, so a single – portrait does not describe the motion. Follow it in the time series instead.
The charge in a series RLC circuit is modeled by a 2nd-order linear ODE. It comes from Kirchhoff's voltage law: going once around the closed loop, the voltage drops across the resistor, the inductor and the capacitor add up to the voltage supplied by the source. Each drop follows a simple law in terms of the charge on the capacitor and the current , the rate at which charge arrives there, so :
Here is the inductance, the resistance and the capacitance. Positive current flows clockwise in the drawing, so means the top plate of the capacitor holds the positive charge. The "show voltages" option in the Motion block draws , , and as arrows, and at every moment the three drops add up to . Without a source, , the equation is homogeneous, and the charge flows back and forth between the plates.
With a source, every solution is a homogeneous solution plus one particular solution:
The homogeneous part solves and carries the two constants and , which the initial conditions set. (These are integration constants, not capacitances.) Its two building blocks and are listed in the four-cases table in the next section. The particular part is any one solution of the full equation and has no free constants. The next two sections find each part in turn.
When , both characteristic roots have negative real part, so decays to zero and approaches . For a periodic source, is therefore called the steady state. In the time series, the "show " and "show " options overlay each part on the charge plot, and at every moment the two add up to . When , never decays, so the natural oscillation stays mixed in with the forced one.
Without a source the equation is . Because it is linear with constant coefficients, look for solutions of the form . Substituting gives , and since is never zero, must solve the characteristic equation
The quadratic formula gives its roots. Their two terms are worth naming, because they reappear in every case below:
When , the square root is imaginary, , which is where the form comes from. (The in the roots is the imaginary unit; the current is always written or .)
Dividing by puts the characteristic equation in standard form, which defines the natural frequency and the damping ratio :
Because the leading coefficient is now 1, the product and the sum of the roots give both of them back:
For complex roots , this means , the distance of the roots from the origin in the complex plane, and . For real roots, is the arithmetic mean of and divided by their geometric mean, so , with equality only when the two roots coincide.
The sign of the discriminant , or equivalently whether is less than, equal to, or greater than 1, decides the case. The two roots are the values listed as eigenvalues in the Signatures panel, and the case name there matches the table below. Each parameter preset puts the circuit in one of these cases.
| Case | Condition | Roots | Behavior | |
|---|---|---|---|---|
| Undamped | The charge flows back and forth between the plates forever, with constant amplitude and period . | |||
| Underdamped | Oscillates inside the decaying envelope , with quasi-period , longer than the undamped period. | |||
| Critically damped | (repeated) | No oscillation, and the charge changes sign at most once. This is the fastest discharge without oscillating for a given and . | ||
| Overdamped | , both negative | No oscillation, and the charge changes sign at most once. The discharge gets slower as grows, because moves toward 0. | ||
| Unstable (feedback) | positive real part | the same forms, with or | Grows without bound: a growing oscillation when , runaway growth without oscillation otherwise. This needs an amplifier; see below. |
Here is the repeated root, and , with the root closer to zero.
A resistor always has : it turns electrical energy into heat. An amplifier can do the opposite and push energy into the circuit, which acts like a negative resistance. With , is positive, so the homogeneous solution grows instead of decaying:
This is how microphone feedback starts: the speaker's sound reaches the microphone, is amplified, and comes out louder, at the frequency where the loop responds best. Because the growth is exponential, the sound stays quiet for a moment and then suddenly becomes loud. Setting slightly below 0, for example −0.1, shows it, and Listen plays it at audio speed.
A real amplifier cannot supply unlimited energy, so the growth stops once it saturates. One way to model this is a resistance that depends on the charge, negative for small and positive for large :
This is the van der Pol equation. Its solutions grow until they settle on a fixed closed loop in the phase plane, called a limit cycle. That nonlinear behavior is outside this linear simulator, which is why its solutions grow forever. Listen imitates the saturation by clipping the sound at a maximum level.
There are two standard methods for finding .
This method applies when is a polynomial, an exponential, a sine or cosine, or sums and products of these. Take the trial form listed for your source in the source-family table below, substitute it into , and solve for its coefficients. If the trial form already solves the homogeneous equation, multiply it by . For example, with and the trial form is itself a homogeneous solution, so becomes . That is pure resonance, and it is the case the page flags.
This method works for any continuous . The formula needs a leading coefficient of 1, so divide the equation by first, which makes the source term . With and from the homogeneous solution,
Integrate and to get and . The Wronskian is never zero, and for each case it is
| Case | |||
|---|---|---|---|
| Undamped | |||
| Underdamped | |||
| Critically damped | |||
| Overdamped |
Variation of parameters handles sources that have no trial form, such as the square and sawtooth waves, at the cost of two integrals. When a trial form exists, undetermined coefficients is usually faster.
A step or a pulse is constant on each time interval, so on each interval while the source is on and 0 while it is off: a battery charges the capacitor until its voltage matches . At each switch, and carry over continuously, and and are found again from those values. A voltage spike leaves continuous but makes the current jump, because the inductor absorbs the whole spike:
After the spike the circuit is free, starting from that new current.
Let and , with and . Transforming the equation turns it into algebra in :
The first term comes from the initial conditions alone. Its inverse transform is the free response that starts from and , which is a homogeneous solution. The second term comes from the source alone, with the capacitor uncharged and no current at the start. Both terms share the denominator , the characteristic polynomial with in place of , so its zeros, the poles of , are exactly the characteristic roots. For the first term, partial fractions and the inverse transform give each of the four cases directly, with the constants already fixed by the initial conditions:
| Case | Condition and roots | Denominator | Partial fractions | Free response |
|---|---|---|---|---|
| Undamped | ||||
| Underdamped | ||||
| Critically damped | ||||
| Overdamped |
Completing the square in the underdamped denominator is what produces the shift , and the first shifting theorem turns that shift into the envelope . A repeated pole gives , whose inverse transform is , which is where the extra factor of in the critically damped case comes from.
The source term works the same way once from the source-family table is multiplied in. Its denominator then also contains the poles of , and those poles produce . When a pole of lands on a characteristic root, that pole becomes repeated. This is the Laplace view of the multiply-by- rule for resonance.
Laplace transforms are especially convenient for switched sources. The second shifting theorem,
turns a delay into the factor . That is why the step, pulse and impulse in the source-family table have such simple transforms, and why the response to a source switched on at is the response to the same source switched on at 0, shifted to start at . For a voltage spike with the capacitor uncharged and no current, , the impulse response of the circuit.
Trial forms use undetermined coefficients and . If a trial form already solves the homogeneous equation, multiply it by . The square and sawtooth waves have no finite trial form, so use their Fourier series term by term, variation of parameters, or the Laplace transform.
| Name | Parameters | Trial form of |
|---|
For an alternating source, or , with , the homogeneous part dies out and the charge oscillates at the source frequency with steady-state amplitude and phase lag :
is largest where the expression under the square root is smallest. Setting its derivative with respect to equal to zero gives
This is the practical resonance frequency of the charge. It exists only when , that is . For more resistance, decreases steadily from = 0 and there is no practical resonance. With no resistance, = and is unbounded there, which is pure resonance.
In a circuit the quantity usually measured is the current, not the charge. In the steady state the current has amplitude , which simplifies to
The term in parentheses vanishes when , that is at , for every value of . There the current amplitude reaches its largest value , as if the inductor and capacitor were not there at all. This is why the resonant frequency of an RLC circuit is quoted as , while the charge on the capacitor peaks a little lower, at .
The circuit equation has exactly the same form as the equation of a spring–mass–damper, . Matching the coefficients term by term pairs each part of the circuit with a part of the mechanical system:
| Spring–mass–damper | Series RLC circuit | Role |
|---|---|---|
| displacement | charge | the unknown |
| velocity | current | its rate of change |
| mass | inductance | resists changes in the rate (inertia) |
| damping coefficient | resistance | dissipates energy as heat |
| spring constant | pushes back toward zero, storing energy | |
| external force | source voltage | drives the system |
| kinetic energy | magnetic energy | energy of the motion |
| spring energy | electric energy | stored energy |
A large capacitance is therefore a soft spring: it holds a lot of charge for a small voltage. Every formula on this page has a mechanical twin obtained by the same substitution, for example becomes .
Differentiating the circuit equation once, and using , gives an equation for the current directly:
It has the same characteristic equation, so the same four cases and the same and apply to the current. Only the source term changes, from to its derivative . A constant battery voltage therefore drives no current in the long run, which matches the charged capacitor blocking a steady current.