# How to determine the transient response of a circuit to causal periodic inputs?

As you know, analyzing a circuit with phasors provides only the steady-state response, and is only useful for sinusoidal signals and DC signals. Fourier series allow us to analyse a circuit with general periodic signal that aren't necessarily sinusoids, but it still only provides the steady-state response, and I'd like to also determine the transient response.

On the other hand, the Laplace transform (and the Fourier transform according to some webpages) allows us to analyse a circuit with signals such as a decaying exponential (damped signal), a sinusoid, a damped sinusoid, a step, a ramp, an impulse, a piece-wise signal, etc.; and it provides both the steady-state and the transient response.

So far, so good. This is where my question comes. For a circuit with a sinusoidal AC input, the Laplace transform allows us to obtain the transient response. And for a circuit with a non-sinusoidal AC input, the Fourier series allow us to obtain the steady-state response. But how do we obtain the transient response of a circuit with a non-sinusoidal AC input? According to the above, do we have to apply the Laplace transform (or Fourier transform) of a Fourier series? Have you ever read or done an example like this?

### An example

Just to say an example, let's suppose we have a series RC circuit with a sawtooth input (expression shown below), zero initial conditions (for simplifications), and we're interested in finding the complete response (transients + steady-state) of the voltage of the capacitor, assuming the input is zero for $$\ t \lt 0 \$$ and is active for $$\ t \gt 0 \$$. The circuit diagram is:

We are told that one period of the input is given by

$$\ v_{s_{1}}(t) = \begin{cases} 2 t & , 0 < t < 5 \\ 0 & , 5 < t < 10 \end{cases} \tag*{} \$$

where the period of the whole input $$\ v_{s}(t) \$$ is $$\ 10 \$$. Now, in order for the circuit to have transients, the input should be activated at $$\ t = 0 \text{ s} \$$ instead of $$\ -\infty \$$, because if the input was activated a long time ago (i.e. since $$\ -\infty \$$) then the circuit would have already reached steady-state at $$\ 0 \text{ s} \$$, and so transients would have disappeared and we could find the capacitor's voltage with Fourier series (and phasors) only, without the Laplace transform. Because of this, we have to multiply our input by the unit step or Heaviside function, $$\ u(t) \$$; this makes our input a causal signal.

My question is then how do we solve such an example?

### What I've tried

What I tried in the previous example is my proposed solution: finding the Laplace transform of a trigonometric Fourier series. First, let's find the Fourier series of the input. The fundamental frequency of $$\ v_{s}(t) \$$ is $$\ \omega_0 = \frac{\pi}{5} \frac{\text{rad}}{\text{s}} \$$. I could prove that the average value of $$\ v_{s}(t) \$$ is

$$\ a_0 = \dfrac{5}{2} \tag*{} \$$

while its Fourier coefficients are

$$\ a_n = 10 \dfrac{(-1)^n - 1}{(\pi n)^2}; b_n = - \dfrac{10 (-1)^n}{\pi n} \tag*{} \$$

Thus, the trigonometric Fourier series of $$\ v_{s}(t) \$$ is

$$\ v_{s}(t) = \left[ \dfrac{5}{2} + \displaystyle \sum_{n=1}^{\infty} \left( 10 \dfrac{(-1)^n - 1}{(\pi n)^2} \cos {\dfrac{\pi n t}{5}} - \dfrac{10 (-1)^n}{\pi n} \sin {\dfrac{\pi n t}{5}} \right) \right] u(t) \text{ V} \tag*{} \$$

In the following image, the black curve is the waveform of $$\ v_{s}(t) \$$, and the red curve is the waveform of the previous expression up to the 60th harmonic:

Notice that the input is only periodic for $$\ t \gt 0 \$$, because for $$\ t \lt 0 \$$ the input is zero, due to the unit step function. As a second step, we go to the $$\ s \$$ domain. With respect to the input, since the Laplace transform is a linear operator (it's an integral), it's pretty easy to prove that the Laplace transform of a trigonometric Fourier series is given by the pair

$$\ \left[ a_0 + \displaystyle \sum_{n=1}^{\infty} \left( a_n \cos {n \omega_0 t} + b_n \sin {n \omega_0 t} \right) \right] u(t) \iff \dfrac{a_0}{s} + \displaystyle \sum_{n=1}^{\infty} \left( a_n \dfrac{s}{s^2 + (n \omega_0)^2} + b_n \dfrac{n \omega_0}{s^2 + (n \omega_0)^2} \right) \tag*{} \$$

Thus,

$$\ V_s(s) = \dfrac{5}{2s} + \displaystyle \sum_{n=1}^{\infty} \left( 10 \dfrac{(-1)^n - 1}{(\pi n)^2} \dfrac{s}{s^2 + (\pi n/5)^2} - \dfrac{10 (-1)^n}{\pi n} \dfrac{\pi n/5}{s^2 + (\pi n/5)^2} \right) \tag*{} \$$

With respect to the capacitor, its equivalent impedance is simply $$\ 1/sC \$$, and it has no initial conditions.

As a third step, we solve the circuit. Applying voltage divider in the capacitor we get that

\ \begin{align} V_C(s) &= \dfrac{1/sC}{R + 1/sC} V_s(s) \\ &= \dfrac{1}{RCs + 1} \left[ \dfrac{5}{2s} + \displaystyle \sum_{n=1}^{\infty} \left( 10 \dfrac{(-1)^n - 1}{(\pi n)^2} \dfrac{s}{s^2 + (\pi n/5)^2} - \dfrac{10 (-1)^n}{\pi n} \dfrac{\pi n/5}{s^2 + (\pi n/5)^2} \right) \right] \end{align} \

Lastly we have to take the inverse Laplace transform of the previous expression. But this is where I'm stuck! I can't figure out a way to do that.

• In your first equation, $2\frac{V}{s}.t$ is confusing - you shouldn't put units inside an equation; especially when one of them is time in second (s) and you're dealing with Laplace (s).
– Chu
Aug 11, 2019 at 9:22
• Thanks for the tip @Chu. I've removed the units. Aug 11, 2019 at 12:47

1. Rewrite the input signal with unit step function instead of piecewise.
2. Understands the periodic functions properties of Laplace Transform

I'll compute it with WolframAlpha..

This is the input signal.

U(s) = (1/(1 - E^(-10 s))) Integrate[(2 t (UnitStep[t] - UnitStep[t - 5]) + 0 (UnitStep[t - 5] - UnitStep[t - 10]))*E^(- s t), {t, 0, 10}]

The $$\1/(1-e^{-sT})\$$ comes from geometric series when you are deriving its properties. The intuition is that, the integral of the transform goes from time 0 to infinity. And to get there, because it's a periodic function, we sum it up from 0 to T then T to 2T and so on till the infinity. And that resulted in the form of geometric series.

$$\ \displaystyle \mathcal{L}^{-1}\left[\frac{1}{1-e^{-sT}} F(s) \right] = \sum_{n=0}^{\infty} f(t-nT) \theta(t-nT) \$$

Someone did the derivation for this on YouTube, Inverse Laplace Transform with [1 - e^(-sT)] in the Denominator by patrickJMT

Output signal,

$$\ H(s) = \dfrac{1/sC}{R + 1/sC} \$$

$$\ Y(s) = H(s) U(s) \$$

Compute our $$\f(t)\theta(t)\$$ first, before turning it into periodic summation.

InverseLaplaceTransform[(1/(s C)/(R + 1/(s C))) ((2 E^(-5 s) (-1 + E^(5 s) - 5 s))/s^2), s, t] * UnitStep[t]

$$\ f(t) \theta(t) = \$$

$$\ f(t) \theta(t) = \$$

$$\ \displaystyle f(t-nT) \theta(t-nT) = 2\ \theta(t - nT) \left( RC (e^{-(t-nT)/(RC)} -1) + (t - nT) \right) + 2\ \theta(t-5 - nT) \left( (5 - RC) e^{-(t-5-nT)/(RC)} + RC - (t - nT) \right)\$$

with T = 10, and there you have it.

$$\ \displaystyle y(t) = \sum_{n=0}^{\infty} f(t-nT) \theta(t-nT) \$$

Assume if $$\R = 50k\$$ and $$\C = 100uF\$$, thus time constant of 5s. This is the first period graph. For the next period and so on, each overlapping magnitude will get summed.

The transient and steady state expression is rather difficult to separate, since it's difficult to find when the overlapping magnitude became steady. And that depends on the time constant, which results in asymptotic to 0 as t goes to infinity on each summation term...

Sum[2UnitStep[t-10n] ( 5 ( e^(-(t-10n)/(5) ) - 1) + t - 10n ) + 2UnitStep[t - 5 -10n] ( (5-5) e^(-(t - 5 - 10n)/(5) ) + 5 - (t - 10n) ), {n, 0, 5}]

Please correct me if I'm wrong, I know it's way too late, but it's better than nothing I guess.. haha.