Into the Laplace domain
The 2 kg cart from the equations-of-motion lesson obeys 2ẍ + 4ẋ + 50x = f(t), where ẋ is velocity and ẍ is acceleration. The push f(t) is the input; the position x(t) is the output. Re-solving it for every push is slow.
The Laplace transform turns a function of time into a function of a new variable, s. Its key trick: if the cart starts at rest, a derivative becomes a multiplication by s. So ẋ becomes sX(s) and ẍ becomes s²X(s).
Transform each term: 2ẍ becomes 2s²X(s), 4ẋ becomes 4sX(s), 50x becomes 50X(s) and f(t) becomes F(s). The differential equation is now plain algebra: (2s² + 4s + 50)X(s) = F(s).
The transfer function
Divide the output by the input: G(s) = X(s)/F(s) = 1/(2s² + 4s + 50). That ratio is the transfer function. It holds only the cart's mass, damper and spring, and nothing about how hard we push.
Draw the cart as one box holding G(s). An arrow carries the input F(s) in and another carries the output X(s) out. The box has one rule: output equals G(s) times input. This picture is a block diagram.
Push with a steady 10 N from t = 0. Its transform is F(s) = 10/s, so X(s) = 10/(s(2s² + 4s + 50)). A transform table turns that back into x(t): the cart overshoots to 0.305 m, then settles.
Reading the block
Set s = 0: G(0) = 1/50 = 0.02 m per newton, the DC gain. The final value theorem says a steady 10 N push ends at 10 × 0.02 = 0.2 m, the same answer as kx = F.
Where 2s² + 4s + 50 = 0, G(s) blows up. Those values, s = −1 ± 4.90j, are the poles. The −1 sets the e^−t envelope the swings shrink inside. The 4.90 rad/s sets their 1.28 s period.
Now strike the cart with a quick tap of 2 N·s, an impulse. Its transform is just 2, so X(s) = 2G(s). Same box, new input: the cart jumps to 0.151 m, rings at the same rate and returns to rest.
In Python, G(s) is just a function. G(0) gives the DC gain, and the quadratic formula on the denominator gives the poles. The python-control library builds the same object with ct.tf([1], [2, 4, 50]).
Working
# step 1/10 · recap # about: Equation card the cart: m = 2 kg b = 4 N·s/m k = 50 N/m 2x'' + 4x' + 50x = f(t) input f(t) push on the cart (N) output x(t) position (m) Goal of this lesson: one object, G(s), that holds everything the cart does to ANY push.
Every curve in the figure is the exact inverse transform of X(s), sampled every 0.02 s, and the tests check it against a direct simulation of 2ẍ + 4ẋ + 50x = f(t). A transfer function exists only for a linear, time-invariant system, and it is defined with every initial condition zero. A cart that starts moving adds terms that G(s) does not hold.