After that, we will solve the homogeneous equation, in the .... It is convenient that
Mathematica has returned the polynomial in factored form, from which we see ...
ME 406 Using Eigenvector Methods with Mathematica to Solve Linear Autonomous Systems of First Order Differential Equations ‡ 1. Introduction In this notebook, we use the methods of linear algebra -- specifically eigenvector and eigenvalue analysis -- to solve systems of linear autonomous ordinary differential equations. Although the Mathematica routines DSolve and NDSolve could be used to attack these problems directly, we do not use them here. Our purpose is to make clear the underlying linear algebra, and to use Mathematica to do all of the calculations. The canonical problem under consideration is the following: ° X = AX + b ,
(1)
X(0) = X0 ,
(2)
where A is a constant n x n matrix, b is a constant n x 1 vector, and X0 , the initial vector, is a given n x 1 vector. The general approach to this problem is the following. We first find a particular solution, which is defined to be any solution of equation (1). We call the particular solution X p . The general solution Xg of the equation is then Xg = Xh + X p ,
(3)
where Xh is the most general solution of the homogeneous equation: ° Xh = AXh .
H1L
(4)
The homogenous equation (4) has n linearly independent solutions. We call them X , X , . . . XHnL . The most general Xh is a linear combination of these. To solve the initial-value problem, we form the general solution Xg in terms of n constants a1 , a2 , . . . , an : Xg = X p + a1 XH1L + a2 XH2L + . . . + an XHnL .
H2L
(5)
We now impose the initial condition (2) on the solution (5). This gives the following set of linear equations to solve for the coefficients ai : a1 XH1L + a2 XH2L + . . . + an XHnL = X0 - X p at t = 0. HiL
(6)
The linear independence of the vectors X guarantees that the matrix in the above equations is nonsingular and hence the solution for the coefficients ai is unique.
2
lineig.nb
The rest of this notebook provides the details in carrying this out, and shows how to use Mathematica to advantage at each step. We will begin with a brief review of matrix manipulations in Mathematica. Then we will consider the problem of finding the particular solution. After that, we will solve the homogeneous equation, in the following sequence of cases of increasing difficulty: distinct real eigenvalues; distinct complex eigenvalues; repeated eigenvalues. Detailed examples will be done at each step.
‡ 2. Basic Matrix Manipulations in Mathematica In Mathematica, a matrix is a list of lists. Each component list is a row of the matrix. As an example, we define a matrix named A for Mathematica, and then use MatrixForm to print it out in traditional form. A = 881, -2, 3