Unit 8, lesson 42

Systems and Conversion from Higher-Order Equations

How a state vector collects an unknown and its derivatives, how a higher-order equation becomes a first-order system with vector initial data, how linear systems take matrix form, and what makes a system autonomous.

  • Video 42
  • Systems and Eigenvalue Methods

A mass on a spring passes through its rest position. Where will it be a moment later? Its position alone cannot say, because the mass may be moving left or right, slowly or quickly, and only position and velocity together decide the motion. Collecting such quantities into one vector rewrites an equation of higher order as a system of first-order equations, here always with tt as the independent variable and a prime meaning d/dtd/dt. This lesson shows how to make that conversion, how to carry the initial data across in the right order, how to write a linear system with a matrix, and how to tell autonomous systems from time-dependent ones.

Key terms

State vector

Definition Let yy be an unknown function of tt that solves a scalar equation of order nn. Its state vector is the column

X(t)=[y(t)y′(t)⋮y(n−1)(t)],X(t) = \begin{bmatrix} y(t) \\ y'(t) \\ \vdots \\ y^{(n-1)}(t) \end{bmatrix},

which lists the unknown and its first n−1n - 1 derivatives in this fixed order. When the equation can be written as y(n)=g(t,y,y′,…,y(n−1))y^{(n)} = g(t, y, y', \ldots, y^{(n-1)}) with gg and its partial derivatives in the last nn arguments continuous near (t0,X(t0))(t_0, X(t_0)), the value X(t0)X(t_0) at one time determines the solution on an interval around t0t_0, and that is what makes XX a state. More generally, a state vector is the ordered column X=(x1,…,xn)TX = (x_1, \ldots, x_n)^{T} of the unknowns of a first-order system. Its entries xkx_k are scalar functions and XX itself is a vector function, so the state XX is kept apart from the scalar unknown yy.

In plain words The state is the list of numbers you need at one instant to predict what happens next. For a second-order equation that is the value and the slope, and for a third-order equation the second derivative joins them.

Example The functions cos⁡2t\cos 2t and cos⁡2t+sin⁡2t\cos 2t + \sin 2t both solve y′′+4y=0y'' + 4y = 0, and both equal 11 at t=0t = 0. At t=π/4t = \pi/4 the first equals 00 and the second equals 11, so the value of yy alone at one instant does not fix the future. Their state vectors at t=0t = 0 are (1,0)T(1, 0)^{T} and (1,2)T(1, 2)^{T}, and they differ in the velocity entry. For a mass on a spring the state is the column of position and velocity.

First-order system

Definition A first-order system of nn equations for unknown functions x1,…,xnx_1, \ldots, x_n of tt is

xk′=fk(t,x1,…,xn),k=1,…,n,\begin{gathered} x_k' = f_k(t, x_1, \ldots, x_n), \\[0.4em] k = 1, \ldots, n, \end{gathered}

written compactly as X′=F(t,X)X' = F(t, X) with X=(x1,…,xn)TX = (x_1, \ldots, x_n)^{T} and F=(f1,…,fn)TF = (f_1, \ldots, f_n)^{T}, where FF is defined on an open set DD of points (t,X)(t, X) with XX in Rn\mathbb{R}^n. A vector function is differentiated entry by entry. A solution on an open interval II is a differentiable vector function XX such that (t,X(t))(t, X(t)) lies in DD and X′(t)=F(t,X(t))X'(t) = F(t, X(t)) for every tt in II. Each equation contains one first derivative, but its right side may involve every unknown, so the equations are usually coupled.

In plain words Each unknown gets its own rate equation, and the rate of one unknown may depend on all the others. Solving the system means finding all the unknowns at once.

Example The system x1′=x2x_1' = x_2, x2′=−x1x_2' = -x_1 is coupled, since each rate involves the other unknown. The vector function X(t)=(sin⁡t,cos⁡t)TX(t) = (\sin t, \cos t)^{T} solves it on R\mathbb{R}, because (sin⁡t)′=cos⁡t=x2(\sin t)' = \cos t = x_2 and (cos⁡t)′=−sin⁡t=−x1(\cos t)' = -\sin t = -x_1. Right sides need not be linear, as in the predator and prey model x1′=x1(1−x2)x_1' = x_1(1 - x_2), x2′=x2(x1−1)x_2' = x_2(x_1 - 1).

Conversion of a higher-order equation to a system

Definition Suppose an equation of order nn has been solved for its highest derivative,

y(n)=g(t,y,y′,…,y(n−1)).y^{(n)} = g\big(t, y, y', \ldots, y^{(n-1)}\big).

Set x1=yx_1 = y, x2=y′x_2 = y' and so on up to xn=y(n−1)x_n = y^{(n-1)}. The definitions give the first n−1n - 1 equations and the original equation gives the last,

xk′=xk+1(k<n),xn′=g(t,x1,…,xn).\begin{aligned} x_k' &= x_{k+1} \quad (k < n), \\[0.4em] x_n' &= g(t, x_1, \ldots, x_n). \end{aligned}

The two problems are equivalent on every interval II. If yy solves the equation on II, then X=(y,y′,…,y(n−1))TX = (y, y', \ldots, y^{(n-1)})^{T} solves the system on II. Conversely, if XX solves the system on II, the first n−1n - 1 rows force x2=x1′x_2 = x_1', x3=x1′′x_3 = x_1'' and so on up to xn=x1(n−1)x_n = x_1^{(n-1)}, so y=x1y = x_1 is nn times differentiable and the last row is the original equation. An equation written as an(t) y(n)+⋯=…a_n(t)\,y^{(n)} + \cdots = \ldots must first be divided by an(t)a_n(t), which is possible only where an(t)≠0a_n(t) \ne 0. The conversion is then made separately on each interval where the leading coefficient does not vanish.

In plain words Give names to the unknown and to each derivative below the order. Most rows of the system only say that one name is the derivative of the previous one, and the last row carries the equation itself.

Example Take y′′′+2y′′−y′−2y=0y''' + 2y'' - y' - 2y = 0. Solving for the highest derivative gives

y′′′=2y+y′−2y′′.y''' = 2y + y' - 2y''.

With x1=yx_1 = y, x2=y′x_2 = y' and x3=y′′x_3 = y'', the system is

x1′=x2,x2′=x3,x3′=2x1+x2−2x3.\begin{aligned} x_1' &= x_2, \\ x_2' &= x_3, \\ x_3' &= 2x_1 + x_2 - 2x_3. \end{aligned}

Since the leading coefficient is 11, the weights in the last row are the negatives of the other coefficients of the original equation, because those terms moved across the equals sign. The nonlinear pendulum equation θ′′+sin⁡θ=0\theta'' + \sin\theta = 0 converts the same way. With x1=θx_1 = \theta and x2=θ′x_2 = \theta' it becomes x1′=x2x_1' = x_2, x2′=−sin⁡x1x_2' = -\sin x_1.

Vector initial data

Definition An initial condition for X′=F(t,X)X' = F(t, X) prescribes the whole state at one time, X(t0)=X0X(t_0) = X_0 with X0X_0 in Rn\mathbb{R}^n. For a converted equation of order nn, the scalar conditions y(j)(t0)=kjy^{(j)}(t_0) = k_j for j=0,1,…,n−1j = 0, 1, \ldots, n - 1 become

X(t0)=(k0,k1,…,kn−1)T,X(t_0) = (k_0, k_1, \ldots, k_{n-1})^{T},

in the same order as the entries of XX. The existence and uniqueness theorem carries over to systems. If FF and all the partial derivatives ∂fi/∂xj\partial f_i/\partial x_j are continuous on an open set containing (t0,X0)(t_0, X_0), the problem has a solution on some open interval containing t0t_0, and two solutions agree on every interval containing t0t_0 where both are defined. That interval may be smaller than the set of times where FF is defined.

In plain words One vector replaces the list of starting values, and its entries have to line up with the entries of the state. An equation of order nn needs exactly nn starting numbers, the value and the first n−1n - 1 derivatives at one time.

Example For the third-order equation above, take y(0)=2y(0) = 2, y′(0)=1y'(0) = 1 and y′′(0)=−1y''(0) = -1, so that X(0)=(2,1,−1)TX(0) = (2, 1, -1)^{T}. The characteristic polynomial r3+2r2−r−2=(r−1)(r+1)(r+2)r^3 + 2r^2 - r - 2 = (r - 1)(r + 1)(r + 2) suggests the candidate

y=et+2e−t−e−2t.y = e^t + 2e^{-t} - e^{-2t}.

Its derivatives are

y′=et−2e−t+2e−2t,y′′=et+2e−t−4e−2t,y′′′=et−2e−t+8e−2t.\begin{aligned} y' &= e^t - 2e^{-t} + 2e^{-2t}, \\[0.4em] y'' &= e^t + 2e^{-t} - 4e^{-2t}, \\[0.4em] y''' &= e^t - 2e^{-t} + 8e^{-2t}. \end{aligned}

At t=0t = 0 the entries of (y,y′,y′′)T(y, y', y'')^{T} are 1+2−1=21 + 2 - 1 = 2, then 1−2+2=11 - 2 + 2 = 1 and 1+2−4=−11 + 2 - 4 = -1, which is the initial vector. In y′′′+2y′′−y′−2yy''' + 2y'' - y' - 2y the coefficients of ete^t add up to 1+2−1−2=01 + 2 - 1 - 2 = 0, those of e−te^{-t} to −2+4+2−4=0-2 + 4 + 2 - 4 = 0 and those of e−2te^{-2t} to 8−8−2+2=08 - 8 - 2 + 2 = 0. So the scalar equation holds for every tt, which is the last row of the system, and the first two rows hold because each entry of XX is the derivative of the one before. Listing the data as (2,−1,1)T(2, -1, 1)^{T} instead would pose the problem with y′(0)=−1y'(0) = -1 and y′′(0)=1y''(0) = 1, whose solution is a different function.

Matrix form of a linear system

Definition A first-order system is linear when each right side is a linear combination of the unknowns plus a term that depends on tt alone. It can then be written

X′=A(t) X+G(t),X' = A(t)\,X + G(t),

where the coefficient matrix A(t)A(t) is an n×nn \times n matrix of functions of tt and the forcing G(t)G(t) is a column of functions. Entry ii of the product A(t)XA(t)X is ai1(t)x1+⋯+ain(t)xna_{i1}(t)x_1 + \cdots + a_{in}(t)x_n, so row ii of the matrix holds the weights of equation ii. The system is homogeneous when G(t)=0G(t) = 0 for every tt in the interval. If AA and GG are continuous on an open interval II, then for every t0t_0 in II and every X0X_0 the problem with X(t0)=X0X(t_0) = X_0 has exactly one solution, and that solution is defined on all of II. Converting the normalized linear equation y(n)+pn−1(t) y(n−1)+⋯+p0(t) y=g(t)y^{(n)} + p_{n-1}(t)\,y^{(n-1)} + \cdots + p_0(t)\,y = g(t) gives a matrix with ones just above the diagonal, the last row (−p0,−p1,…,−pn−1)(-p_0, -p_1, \ldots, -p_{n-1}) and zeros elsewhere, together with the forcing G=(0,…,0,g)TG = (0, \ldots, 0, g)^{T}.

In plain words The matrix is a compact table of the weights in the equations. Multiplying it into the state column rebuilds every equation, one row at a time.

Example The third-order example has G=0G = 0 and

A=[01000121−2].A = \begin{bmatrix} 0 & 1 & 0 \\ 0 & 0 & 1 \\ 2 & 1 & -2 \end{bmatrix}.

Multiplying out gives AX=(x2,x3,2x1+x2−2x3)TAX = (x_2, x_3, 2x_1 + x_2 - 2x_3)^{T}, the three right sides found before. The coefficients are constant, so every solution exists for all real tt. For the forced equation y′′+3y′+2y=cos⁡ty'' + 3y' + 2y = \cos t, the state X=(y,y′)TX = (y, y')^{T} gives

X′=[01−2−3]X+[0cos⁡t].\begin{aligned} X' &= \begin{bmatrix} 0 & 1 \\ -2 & -3 \end{bmatrix} X \\[0.4em] &\quad + \begin{bmatrix} 0 \\ \cos t \end{bmatrix}. \end{aligned}

Autonomous and time-dependent systems

Definition A system X′=F(t,X)X' = F(t, X) is autonomous if its right side does not depend on tt explicitly, so that it has the form X′=F(X)X' = F(X). Otherwise it is time-dependent, also called nonautonomous. A linear system X′=A(t)X+G(t)X' = A(t)X + G(t) is autonomous exactly when AA and GG are constant. For an autonomous system the arrow F(X)F(X) attached to a state is the same whenever that state is reached, and if X(t)X(t) is a solution, then so is the shifted function X(t−c)X(t - c) for every constant cc, on the shifted interval.

In plain words In an autonomous system the rule for change looks only at the current state, never at the clock. In a time-dependent system the same state can move differently at different times, because a coefficient or an outside input has changed.

Example The constant-matrix system above and the pendulum system x1′=x2x_1' = x_2, x2′=−sin⁡x1x_2' = -\sin x_1 are autonomous. The equation y′′+(1+t) y′+y=0y'' + (1 + t)\,y' + y = 0, whose damping coefficient grows with time, gives

A(t)=[01−1−(1+t)].A(t) = \begin{bmatrix} 0 & 1 \\ -1 & -(1 + t) \end{bmatrix}.

At the state (0,1)T(0, 1)^{T} the arrow A(t)XA(t)X is (1,−1)T(1, -1)^{T} at t=0t = 0 but (1,−2)T(1, -2)^{T} at t=1t = 1, so the system is time-dependent. The forced equation y′′+3y′+2y=cos⁡ty'' + 3y' + 2y = \cos t is time-dependent for another reason. Its matrix is constant, but its forcing changes with tt.

Check yourself

  1. Write y′′+5y′+6y=0y'' + 5y' + 6y = 0 with y(0)=1y(0) = 1 and y′(0)=−4y'(0) = -4 as a system X′=AXX' = AX with an initial vector, and check that y=2e−3t−e−2ty = 2e^{-3t} - e^{-2t} gives a solution of the system.
Show the answer

Solving for the highest derivative gives y′′=−6y−5y′y'' = -6y - 5y'. With X=(y,y′)TX = (y, y')^{T},

X′=[01−6−5]X,X(0)=[1−4].\begin{gathered} X' = \begin{bmatrix} 0 & 1 \\ -6 & -5 \end{bmatrix} X, \\[0.4em] X(0) = \begin{bmatrix} 1 \\ -4 \end{bmatrix}. \end{gathered}

The candidate has y′=−6e−3t+2e−2ty' = -6e^{-3t} + 2e^{-2t} and y′′=18e−3t−4e−2ty'' = 18e^{-3t} - 4e^{-2t}. The first row says x1′=x2x_1' = x_2, which holds because the second entry of XX is the derivative of the first. The second row needs x2′=y′′x_2' = y'' to equal

−6y−5y′=(−12+30) e−3t+(6−10) e−2t,\begin{aligned} -6y - 5y' &= (-12 + 30)\,e^{-3t} \\[0.4em] &\quad + (6 - 10)\,e^{-2t}, \end{aligned}

which is 18e−3t−4e−2t18e^{-3t} - 4e^{-2t}, so it holds too. At t=0t = 0 the state is (2−1,−6+2)T=(1,−4)T(2 - 1, -6 + 2)^{T} = (1, -4)^{T}, the required initial vector.

  1. Write (t−1) y′′−t y′+y=0(t - 1)\,y'' - t\,y' + y = 0 with y(0)=1y(0) = 1 and y′(0)=2y'(0) = 2 as a first-order system. Is the system autonomous, and on which interval does the existence theorem for linear systems guarantee exactly one solution?
Show the answer

The leading coefficient t−1t - 1 vanishes at t=1t = 1, so the equation can be solved for y′′y'' only where t≠1t \ne 1, giving y′′=(t y′−y)/(t−1)y'' = (t\,y' - y)/(t - 1). With X=(y,y′)TX = (y, y')^{T},

X′=[01−1t−1tt−1]X,X' = \begin{bmatrix} 0 & 1 \\[0.2em] -\dfrac{1}{t - 1} & \dfrac{t}{t - 1} \end{bmatrix} X,

with X(0)=(1,2)TX(0) = (1, 2)^{T}. The matrix depends on tt, so the system is time-dependent. Its entries are continuous on (−∞,1)(-\infty, 1) and on (1,∞)(1, \infty), and the initial time 00 lies in the first interval, so the theorem guarantees exactly one solution on (−∞,1)(-\infty, 1). As a check, y=et+ty = e^t + t has y(0)=1y(0) = 1, y′(0)=2y'(0) = 2 and (t−1)et−t(et+1)+et+t=0(t - 1)e^t - t(e^t + 1) + e^t + t = 0, so it is that solution.

  1. The equation y′′′−y′=0y''' - y' = 0 with y(0)=0y(0) = 0, y′(0)=1y'(0) = 1 and y′′(0)=0y''(0) = 0 is converted with the state X=(y,y′,y′′)TX = (y, y', y'')^{T}. A classmate writes the initial vector as (0,0,1)T(0, 0, 1)^{T}. Solve the correct problem and the classmate’s problem, and compare the solutions.
Show the answer

The system is x1′=x2x_1' = x_2, x2′=x3x_2' = x_3, x3′=x2x_3' = x_2, and the correct initial vector is (0,1,0)T(0, 1, 0)^{T}. The characteristic polynomial r3−r=r(r−1)(r+1)r^3 - r = r(r - 1)(r + 1) gives

y=C1+C2et+C3e−t,y = C_1 + C_2e^t + C_3e^{-t},

with y′=C2et−C3e−ty' = C_2e^t - C_3e^{-t} and y′′=C2et+C3e−ty'' = C_2e^t + C_3e^{-t}. The correct data give C1+C2+C3=0C_1 + C_2 + C_3 = 0, C2−C3=1C_2 - C_3 = 1 and C2+C3=0C_2 + C_3 = 0, so C2=12C_2 = \tfrac{1}{2}, C3=−12C_3 = -\tfrac{1}{2}, C1=0C_1 = 0 and y=sinh⁡ty = \sinh t. The classmate’s vector means y′(0)=0y'(0) = 0 and y′′(0)=1y''(0) = 1, which give C2=C3=12C_2 = C_3 = \tfrac{1}{2} and C1=−1C_1 = -1, so y=cosh⁡t−1y = \cosh t - 1. The two functions agree only at t=0t = 0, since sinh⁡t=cosh⁡t−1\sinh t = \cosh t - 1 reduces to e−t=1e^{-t} = 1. Swapping two entries of the initial vector poses a different problem.

How this lesson connects