[begin transmission 3/?]
This post will be a slight deviation from the main subject I was addressing in this series of posts.
It was my intent to briefly explain systems theory and dynamics before getting into optimal control.
However, in my elaboration re: dynamics, the question of how to solve differential equations came up.
Possessing a deep appreciation for history of maths and engineering, I can't help but gush about the Laplace transform.
History Lesson
Let us begin w/ a brief discussion of the background of the Laplace transform. If it wasn't already apparent to you, the technique is named after none other than Pierre-Simon Laplace, the French mathematician and scientist. The history of this technique is somewhat mysterious, as the entire Enlightenment era had tons of great thinkers (and their even greater egos) rivaling each other, often times converging onto the same kinds of ideas. As a result giving credit where credit is due can be a contentious affair. But for the most part, yes, Pierre-Simon Laplace is widely credited w/ being the primary developer of the technique, using it mostly in his work on probability.What I absolutely love about the history of the Laplace transform is that it was developed in the 18th century--remained in relative obscurity, being confined to the dusty libraries of mathematicians' minds--only to make a strong resurgence in the 20th century when the demands of warfare forced it into the mainstream. This is why, outside of teasing of course, I never give my mathematically or theory-inclined contemporaries too much of a hard time. As outlandish or worthless some abstraction may seem at the time, one that makes you think "When the hell am I ever going to use that?", one can never be too certain when a need may arise that grants a once useless concept newfound utility. Certainly Laplace couldn't have envisioned his mathematics being used to operate the fire-control systems directing the behemoth canons aboard the naval destroyers of WWII. So that ostensibly stupid idea your math friend dreamt up after his fourth pint of beer? It may just save the day in a century or two's time.
Okay, okay. That's enough history and fangirling. Let's get back to technical matters.
What Is It Though?
Technically-speaking, the Laplace transform is an integral operation that takes a time-domain function and transforms it into the complex s-domain. These words mean absolutely nothing to you, so let us unpack these concepts. An integral operation is like any other mathematical operation--just like addition, subtraction, or taking a derivative, only it involves integrals. The Laplace transform involves integration, as demonstrated by its formal definition:\begin{equation} \mathscr{L}(f(t)) = F(s) = \int_{0}^{\infty}f(t)e^{-st}dt \tag{1}\end{equation}
When you take your time-domain function f(t) (that is, a function that has its independent variable t for time; virtually all real-world signals) and plop it into the Laplace transform above, you get its s-domain representation. What is the s-domain? It is the complex frequency-domain. What is the complex frequency-domain? Well, first understand the frequency-domain. To do this, take Fourier's theorem to heart: every periodic time-domain signal can be decomposed into sinusoidal components. These sinusoids have a frequency (how many times per time unit they complete a cycle, often expressed in Hertz) associated with them. What the frequency-domain representation of a signal reveals is 'how much' of the signal is found across the frequency spectrum. Here's a figure of a simple sinusoid that illustrates this:
![]() |
Figure 1. A simple sine wave |
The complex frequency-domain, the s-domain, is complex-valued , meaning it has two components: a real part and an imaginary part. It assumes the form:
\begin{equation} s = \sigma \pm j\omega \tag{2}\end{equation}
Remember when you learned about imaginary numbers and thought to yourself "When will I ever use this?". Well...here it is, coming back to haunt you. By the way, want to know another way to determine whether someone is a mathematician or an engineer? Ask them to write down a complex number. Mathematicians favor using "i" to denote imaginary numbers; engineers use "j". The imaginary part, the part to the right of the plus minus, refers to the frequency portion of the signal. The sigma part refers to the decay/growth of the signal. You might've noticed in Equation 1 that there is an exponential; this is exactly what the sigma part represents. Intuitively, this makes sense: real-world signals can and do indeed grow or decay over time. If sigma is positive, the signal grows; if sigma is negative, it decays. Those that are paying close attention, or have a background in signal processing will be able to appreciate right now that an ever-growing signal is something that is not...not very desirable.
And that's a very brief introduction into Fourier and complex analysis. I didn't expect to get too deeply into it, yet here we are. In truth you really don't have to understand this stuff to be able to solve differential equations using the Laplace transform, but a thorough understanding helps you gain a reliable intuition as an engineer. For example, had you not known that the s-domain conveys information regarding the growth/decay of a signal, you would be able to read a root-locus plot (a tool often used in classical control theory analysis) and determine that your system is underdamped, resulting in a large overshoot or unstable response.
Application of the Laplace Transform
It's about time we solve our mass-spring-damper mathematical model. Here it is, in case you had forgotten:\begin{equation} M\ddot y + b \dot y + ky = r(t) \tag{3}\end{equation}
It is our wish to obtain y--the response of the system in the form of a vertical displacement--subject to an applied force r(t). Let's say that r(t) is a Heaviside function, also known as a step function u(t); this is reasonable, as it is often times the case in the real world that a constant force is applied to a system at any given moment in time then it is unapplied. Mathematically:
\begin{equation} u(t) = \begin{cases} 0 \quad if \quad t < 0 \\ 1\quad if \quad t > 0 \end{cases}\tag{4}\end{equation}
Graphically:
![]() |
Figure 2. Heaviside function |
So, how do we apply the Laplace transform? Well, you perform the operation term-by-term to Equation 3 and solve the integral. Honestly, solving integrals is such a pain in the ass, and we leave that kind of busy work to mathematicians. Being
\begin{equation}f(t) = u(t), \quad \mathscr{L}(f(t)) = \frac{1}{s} \tag{5}\end{equation}
\begin{equation}f(t) = e^{at}, \quad \mathscr{L}(f(t)) = \frac{1}{s-a} \tag{6}\end{equation}
\begin{equation}f(t) = t^{n}, n=1, 2, 3..., \quad \mathscr{L}(f(t)) = \frac{n!}{s^{n+1}} \tag{7}\end{equation}
\begin{equation}\mathscr{L}(f(t)) = F(s) \tag{8} \end{equation}
\begin{equation}\mathscr{L}(\dot f(t)) = sF(s) - f(0) \tag{9}\end{equation}
\begin{equation}\mathscr{L}(\ddot f(t)) = s^{2}F(s) - sf(0) -\dot f(0) \tag{10}\end{equation}
Now that we have our handy table to refer to, and keeping in mind that M, b, and k are merely constants, applying the Laplace transform to Equation 3 yields:
\begin{equation}M\mathscr{L}(\ddot y) + b\mathscr{L}(\dot y) + k\mathscr{L}(y) = \mathscr{L}(u(t))\tag{11}\end{equation}
Using the table above:
\begin{equation}M(s^{2}Y(s)-sy(0)-\dot y(0)) + b(sY(s) - y(0)) + kY(s) = \frac{1}{s}\tag{12}\end{equation}
What the hell. What are these y(0) terms? These are initial conditions. When solving differential equations, it is necessary that these are given or assumed. Because we're utilizing a frequency-domain approach, our system is assumed to be using zero'd out initial conditions. Applying our initial conditions yields:
\begin{equation}Ms^{2}Y(s) + bsY(s) + kY(s) = \frac{1}{s}\tag{13}\end{equation}
A little bit of algebraic manipulation:
\begin{equation}Y(s) = \frac{1}{s(Ms^{2}+bs+k)}\tag{14}\end{equation}
We're almost there! Problem is, we didn't declare the parameters when we formulated the problem in the previous post. We'll take care of that right now; let's suppose mass M is equal to 1, coefficient of friction b is equal to 8, and spring constant k equal to 15.
\begin{equation}Y(s) = \frac{1}{s(s^{2}+8s+15)}\tag{15}\end{equation}
Notice anything different about our dynamic equation? Noti--well, yes, very astute of you. All of the t's have been replaced by s's. But beyond that, and this is fairly key, notice that our differential equation has now been transformed into a simple algebraic equation. This is what makes the Laplace transform fairly attractive. There are no derivatives or integrals to be found here, so it's now much easier to solve. So let's solve it, utilizing the method of partial fraction decomposition. All that this method does is take a rational expression and decomposes it into constituent fractions. The set up looks something like this:
\begin{equation}\frac{1}{s(s+3)(s+5)}=\frac{A}{s}+\frac{B}{(s+3)}+\frac{C}{(s+5)}\tag{16}\end{equation}
All we did here was take the polynomial in the denominator and factored it out. Then we equated it to a sum of fractions and declared new constants A, B, and C; one for each factor. The idea here is to now solve for these constants. Next, we multiply both sides by the denominator:
\begin{equation}s(s+3)(s+5) \frac{1}{s(s+3)(s+5)}=(\frac{A}{s}+\frac{B}{(s+3)}+\frac{C}{(s+5)})s(s+3)(s+5)\tag{17}\end{equation}
Cancelling out some terms and simplifying the expression yields:
\begin{equation}1 = A(s+3)(s+5) + B(s)(s+5) + C(s)(s+3)\tag{18}\end{equation}
The next step in our approach is to set s equal to something to reduce this expression. If we set s = -3, so that the terms grouped w/ A and C go to zero, we get:
\begin{equation} 1 = -6B\Rightarrow\ B = \frac{-1}{6}=-0.166\tag{19}\end{equation}
Similarly, if we set s = -5 so that the terms grouped w/ A and B go to zero:
\begin{equation} 1 = 10C\Rightarrow\ C = \frac{1}{10}=0.1\tag{20}\end{equation}
Finally, setting s = 0, so that the terms grouped w/ B and C go to zero:
\begin{equation} 1 = 15A\Rightarrow\ A = \frac{1}{15}=0.066\tag{21}\end{equation}
Repopulating Equation 16 w/ the constants we solved for:
\begin{equation}Y(s)=\frac{0.066}{s}-\frac{0.166}{(s+3)}+\frac{0.1}{(s+5)}\tag{22}\end{equation}
Finally, at this stage we apply the inverse Laplace transform (simply going the other way in our handy little table), we can go from the s-domain back to the time-domain; we transform Y(s) back into y(t):
\begin{equation}\mathscr{L^{-1}}(Y(s))=\mathscr{L^{-1}}(\frac{0.066}{s})-\mathscr{L^{-1}}(\frac{0.166}{(s+3)})+\mathscr{L^{-1}}(\frac{0.1}{(s+5)})\tag{23}\end{equation}
\begin{equation}y(t)=(0.066 - 0.166e^{-3t}+ 0.1e^{-5t})u(t)\tag{24}\end{equation}
As a reminder, b/c I know we sort of went through a lot here that it is all too easy to lose the plot, we solved the differential equation--Equation 3--by finding y(t) that satisfies it. That is the mathematical interpretation. Practically, Equation 3 was the mathematical model for our mass-spring-damper system; y(t) is the response of the system (remember, in the form of a vertical displacement) subject to an applied force modeled by u(t).
If you made it this far, congrats. You've made it one month into an introductory course in classical control theory. Keyword here is classical. These kinds of mathematics, as I mentioned before, were in vogue in the early half of the 20th century; I don't want to say that these methods are completely outdated, as they are still used today, but what you must understand is that they are fairly limited. If there is anything at all that you take away from this post is that the Laplace transform method used here only applies to linear, time-invariant systems. You might think to yourself "Wow! How useless! Most real-world systems and phenomenon are non-linear and time-varying in nature.". That last statement is true, but the s-domain approach still has some utility, as several non-linear systems can be linearized w/o losing too much fidelity, and depending on the time scale under consideration time-variance can be made negligible.
If these notions make you feel uncomfortable, if they make you roll your eyes and scoff, I recommend you revise your attitude or get out of engineering. Although the discipline does demand a fair amount of precision, you must come to terms w/ dropping any notion of perfectionism; approximations, tolerances, and trade-offs rule the day when it comes to dealing w/ real-world problems. The world is a complex, messy place, and neat, tidy little solutions rarely, if ever, occur.
...And I'm catching myself before I get too rant-y. Right. So if the frequency-domain approach is seen as an antiquated method of solving differential equations involved in classical control theory, what is the alternative? Glad you asked. Descriptively enough, it's known as modern control theory, or state-space control. This is what's in vogue these days and w/ good reason, as it enables for the analysis of ALL kinds of systems: linear/non-linear, time-invariant/time-varying, single-input-single-output/multi-input-multi-output, deterministic/stochastic etc. Moreover, it doesn't involve any exotic transformations; you can conduct your analysis and design in the time-domain. I don't think I'll get into it, but I'll cover a few concepts related to the field, as they're prerequisite towards understanding the real good stuff: optimal control.
[end transmission 3/?]