# Visualising linear dynamical systems directly

Suppose we have some linear dynamical system

\[\begin{bmatrix} \frac{dx}{dt} \\ \frac{dy}{dt} \end{bmatrix} = \begin{bmatrix} a & b\\ c & d \end{bmatrix} \begin{bmatrix} x \\ y\end{bmatrix}\]where \(a,b,c,d\) are real constants. Usually, we proceed to eigendecompose the matrix \(M = \begin{bmatrix} a & b\\ c & d \end{bmatrix}\) and classify the system according to its eigenvalues / eigenvectors.

However, this process is often rather contrived, even with shortcuts such as calculating \(\text{tr} M\), \(\det M\) and writing the characteristic equation as \(\lambda^2 - (\text{tr} M) \lambda + \det M\). For a surprising amount of cases, we can often just look at the coordinates \(a,b,c,d\) to determine its behvaiour.

We could visualize the vector field as follows. The red vector originating at \((1,0)\) would denote \((a,c)\) while the blue vector originating at \((0,1)\) would denote \((b,d)\). By controlling these two vectors, we could completely determine \(M\). The black vectors denote the velocity vector field that has been scaled down for readability.

**Observation:** We could see that the velocity vector’s direction at \((-1,0)\) is opposite to the red vector, with the magnitude unchanged. Similarly, the velocity vector’s direction at \((0,-1)\) is opposite to the blue vector.

**Observation:** The velocity vector at \((1,1)\) is the sum of the red and blue vector, due to linearity of \(M\). As such, it points in some direction that’s “between” the direction of the red and blue vectors.

**Example:** If \(M\) is degenerate, then the red and blue vectors point along the same direction. By linearity, the velocity vector field points along only one direction.

From this, we could guess whether the matrix is diagonalisable or not. If the range of possible directions of the velocity vector field at \((1,1)\) does not include the direction of \((1,1)\) itself, it’s unlikely there would be any eigenvectors close to the direction of \((1,1)\). One could apply such thinking on an arbtiary point as well. This idea is further explored in another blog post.

**Example:** If \(M\) is a rotation matrix, the velocity vector at any point is always “rotated away” / not parallel to the direction of the point, as such there are no eigenvectors so \(M\) is not diagonalisable.

In fact, it should be easy at this point to fully sketch the velocity vector field. One may always use linearity of the system to generate more data points from the red and blue vectors.

**Exercise:** Point the blue vector roughly along the same direction as (but not parallel to) the red vector. Increase / decrease the magnitude of the blue vector. Could you see what directions the eigenvectors of \(M\) are pointing at just from the vector field?

## Going further

Fully embracing the ideas established in a previous blog post on visualising matrices, we could obtain more information about the system at the expense of visual clarity.