Impact factor for posts is a measurement of importance.

Impact factor for users reflect their authority, reputation and contribution on a particular topic.

Rating reflects the quality of posts.

Rating on Voofie is not a simple average of all ratings, but a weighted average of rating, weighted by the impact factor of users who rated.

Explore exciting communities of

Solving system of first order linear differential equations with matrix exponential method

04 Feb 10

I will teach the general theory of how to solve first order linear differential equations in this tutorial.

Bookmark and Share

Content

The problem

In this tutorial, the type of problem that we would like to solve is of the form:

\f$\begin{cases}  & \text{ } a_{1,1} x_1'(t) + a_{1,2} x_2'(t)+...+ a_{1,n} x_n'(t) + b_{1,1} x_1(t) +...+ b_{1,n} x_n(t) = g_1(t) \\   & \text{ } a_{2,1} x_1'(t) + a_{2,2} x_2'(t)+...+ a_{2,n} x_n'(t) + b_{2,1} x_1(t) +...+ b_{2,n} x_n(t) = g_2(t)  \\   & \text{ ... } \\    & \text{ } a_{n,1} x_1'(t) + a_{n,2} x_2'(t)+...+ a_{n,n} x_n'(t) + b_{n,1} x_1(t) +...+ b_{n,n} x_n(t) = g_n(t)  \\  \end{cases} \f$ .................(1)

Notation

Let's denote:

\f$\mathbf{x} (t)  = \left\{ x_1(t), x_2(t), ... ,x_n(t) \right\} \f$

\f$\mathbf{g} (t)  = \left\{ g_1(t), g_2(t), ... ,g_n(t) \right\} \f$

\f$A = \left\{ a_{i,j} \right\}\f$

\f$B = \left\{ b_{i,j} \right\}\f$

And equation (1) can be written as:

\f$A \mathbf{x}'(t) + B \mathbf{x} (t) = \mathbf{g} (t)\f$

Notice that the matrix A need to be invertible, otherwise the system of equations cannot be solved.

Therefore we can multiple A inverse to both side, and we can consider the following equation instead.

\f$\mathbf{x}'(t) + A \mathbf{x} (t) = \mathbf{g} (t)\f$ .......................(2)

Of course here, A and g will be different from the original definition.

 The method

If we treat the matrix A, vector x and g as scalar, (2) can be solved in a simple way using integrating factor. (I have written another tutorial about differential equation, and it teaches integrating factor as well if you need references.)

In short, the solution of equation (2) is given by:

\f$\mathbf{x}(t) = e^{-A t} \left(\int e^{A t} \mathbf{g}(t) dt + \mathbf{C}\right)\f$ ...................(3)

However, since we are dealing with matrices and vectors, we need to check if the solution is indeed valid. Now I will explain the meaning of exponential of matrix A in the next session.

Exponential of Matrix

Here we will use the following power series for exponential function:

\f$e^x = \sum_{k=0}^{\infty }{ \frac{x^k}{k!}}\f$

Therefore, for exponential of a matrix A,

\f$e^A = \sum_{k=0}^{\infty }{ \frac{A^k}{k!}}\f$

The infinity sum of matrix seems impossible to evaluate, but once we have diagonalize A, it's exponential can be found easily.

If A can be diagonalized, it can be written as:

\f$A = P D P^{-1}\f$

And D is a diagonal matrix. Powers of A can be found very easily since:

\f$A^n = P D P^{-1} P D P^{-1} ... P D P^{-1}\f$

\f$A^n = P D (P^{-1} P) D (P^{-1}  P) ...  (P^{-1} P) D P^{-1}\f$

\f$A^n = P D^n P^{-1}\f$

Therefore:

\f$e^A = P \sum_{k=0}^{\infty }{ \frac{D^k}{k!}} P^{-1}\f$

Differentiating exponential of matrix

What if we need to differentiate \f$e^{ A t}\f$ ?

We will get back to the power series expansion:

\f$\frac{d}{dt} e^{ A t } = \frac{d} {dt} \sum_{k=0}^{\infty} { \frac{(A t)^k} {k!} }\f$

\f$= \sum_{k=0}^{\infty}{ \frac{d}{dt} \frac{A^k t^k}{k!} } \f$

\f$= \sum_{k=1}^{\infty}{ \frac{k A^k t^{k-1} }{k!} } \f$

\f$= A \sum_{k=0}^{\infty}{\frac{(A t)^k} {k!}} \f$

\f$= A e^{A t}\f$

In general, if A is a function of t, it's derivative cannot be found easily in this way. Since:

\f$\frac{d}{dt} A^2(t)= A'(t) A(t) + A(t) A'(t) \f$

Since \f$A'(t)\f$  does not communte with \f$A(t)\f$  generally, therefore we cannot simplify it into \f$2 A(t) A'(t)\f$ . So the above derivation won't work in general.

Verifying the solution

Given (3), we would like to show that it indeed satisfies (2).

\f$\frac{d \mathbf{x} (t) }{ d t } = \frac{d e^{-A t} }{ d t } (\int e^{A t} \mathbf{g}(t) dt + \mathbf{C}) + e^{-A t} \frac{d} {dt} \int e^{A t} \mathbf{g}(t) dt\f$

\f$= -A e^{-A t} (\int e^{A t} \mathbf{g}(t) dt + \mathbf{C}) + (e^{-A t} e^{A t}) \mathbf{g}(t)\f$

\f$= -A \mathbf{x}(t)+ \mathbf{g}(t)\f$

\f$\Rightarrow  \mathbf{x}'(t) + A \mathbf{x}(t) = \mathbf{g}(t)\f$

Therefore I have verified that, (3) is solution to (2).

Example

Please refer to A worked example of solving system of first order linear differential equation for example.

0 Comments

Please login to post comment.

What is Voofie?

Voofie organizes knowledge, discovers useful resources and recognizes knowledgable users.

Bookmark your blog in Voofie to get more traffic as well as building a reputation in your field!

Explore more about it. Become a member—our FREE Registration takes just seconds.

Page Info
101Impacts
3.8/2 rates
7224
Your Rating:
Version: 2
Last update: 04 Feb 10
History Permalink
Author
Avatar for ross_tang

Ross Tang (ross_tang)

Degree in Physics and Mathematics, Master in Physics
香港

  • Ordinary differential equation
  • 672
  • Mathematics
  • 809