Week 3A: The vector space of polynomials.

Reconsider all polynomial functions of third degree P3P_3, an example of a function in this family is y1y_1,

y1(x)=x3+2x2+3.y_1(x) = x^3 + 2x^2+3.

More generally, we can write a definition for P3P_3,

P3={a3x3+a2x2+a1x+a0|a3,a2,a1,a0โˆˆโ„›}.P_3=\{a_3x^3+a_2x^2+a_1x+a_0 \rvert a_3, a_2, a_1, a_0 \in \mathcal{R}\}.

Which motivates to introduce a vector notation,

๐š=(a0a1a2a3).\mathbf{a} = \begin{pmatrix}a_0\\a_1\\a_2\\a_3\end{pmatrix}.

But is it useful? It seems that if we say that our basis is {1,x,x2,x3}\{1, x, x^2, x^3\}, we may write,

y1(x)=x3+2x2+3=(3021).y_1(x) = x^3 + 2x^2+3 = \begin{pmatrix}3\\0\\2\\1\end{pmatrix}.

Furthermore, we can check the list of rules that a general vector space must obey. We will investigate some properties of scalar multiplication and polynomial addition to see what we are dealing with,

Lets define y2=2y1=2x3+4x2+6=(6042)y_2 = 2y_1 = 2x^3 + 4x^2 + 6 = \begin{pmatrix}6\\0\\4\\2\end{pmatrix}, which is indeed part of our proposed vector space. We can quite safely infer from this example that scalar multiplication works โ€œwellโ€ for any polynomial and scalar. What about addition? Lets say y3=y1+y2y_3 = y_1 + y_2,

y3=(1+2)x3+(2+4)x2+(6+3)=(9063).y_3 = (1+2)x^3 + (2+4)x^2 + (6+3) = \begin{pmatrix}9\\0\\6\\3\end{pmatrix}.

Great succes! The coefficients of third-degree polynomials โ€œactโ€ as components of regular vectors, without introducing special rules for scalar multiplication and addition.

Now that we have the vector four dimensional vector space of P3P_3, we can also think of a the n+1 dimensional vector spaces associated with polynomnials of degree nn (PnP_n). It is clear that P3โˆˆP4โˆˆP5P_3 \in P_4 \in P_5, etc. A neat application if that we can describe differentiation as a linear map: ddx:Pmโ†’Pmโˆ’1\frac{\mathrm{d}}{\mathrm{d}x}: P_m \rightarrow P_{m-1}. For for the differentiation of a polynomial in P3P_3, we can write, dydx:T(y)=Ay\frac{\mathrm{d}y}{\mathrm{d}x}: T(y) = Ay with AA and 3ร—43\times 4 matrix.

A=(010000200003).A = \begin{pmatrix} 0 & 1 & 0 & 0\\ 0 & 0 & 2 & 0\\ 0 & 0 & 0 & 3\\ \end{pmatrix}.

For example

dy1dx=(010000200003)(3021)=(043)=4x+3x2.\frac{\mathrm{d}y_1}{\mathrm{d}x} = \begin{pmatrix} 0 & 1 & 0 & 0\\ 0 & 0 & 2 & 0\\ 0 & 0 & 0 & 3\\ \end{pmatrix}\begin{pmatrix} 3\\0\\2\\1\end{pmatrix} = \begin{pmatrix}0\\4\\3\end{pmatrix}=4x+3x^2.

Thank you vector spaces! for shining a new light on this topic.

Week 3B: Eigen vectors for describing the evolution of a dynamical system

Consider some infection disease affecting a population. We divide the population into healthy (HH) and infected (II) people. Every day, 20% of the healthy people (HH) are infected. However, thanks to a program organized by big pharmaceutical companies, 10% of the infected people become healthy again every day. We can write a population vector consisting of the number of healthy and infected people on day nn (๐n=(HnIn)\mathbf{P}_n = \begin{pmatrix}H_n\\I_n\end{pmatrix}). We can describe how ๐n+1\mathbf{P}_{n+1} is related to ๐n\mathbf{P}_n via a matrix equation,

๐n+1=(0.80.10.20.9)๐n\mathbf{P}_{n+1} = \begin{pmatrix}0.8 & 0.1\\0.2 & 0.9\end{pmatrix}\mathbf{P}_n

We can compute the eigen values and eigen vectors of this matrix,

ฮป1=0.7\lambda_1 = 0.7

with,

๐ฏ1=(1โˆ’1)\mathbf{v}_1 = \begin{pmatrix}1\\-1\end{pmatrix}

and

ฮป2=1,\lambda_2 = 1,

with,

๐ฏ2=(12).\mathbf{v}_2 = \begin{pmatrix}1\\2\end{pmatrix}.

Can you see the meaning of v2v_2? Since ฮป2=1\lambda_2=1, the vectors that are a multiple of v2v_2 are equilibrium points. We can also study how some example population evolves. Say we start with 90 healthy people and no infected ones (๐ฉ0=(900)\mathbf{p}_0 = \begin{pmatrix}90\\0\end{pmatrix}). We may write the initial state as a sum of the eigen vectors (see figure), and find the solution.

The population at day 0 may be written as a sum of multiples of the eigen vectors (left), The dynamical evolution of the system can be readily computed (right)

Alternatively, we can write the solution ๐ฉn\mathbf{p}_n,

๐ฉn=(0.80.10.20.9)n๐ฉ0,\mathbf{p}_n = \begin{pmatrix}0.8 & 0.1\\ 0.2&0.9\end{pmatrix}^n\mathbf{p}_0,

in a more attractive form using diagonalization,

๐ฉn=PDnPโˆ’1๐ฉ0,\mathbf{p}_n = PD^nP^{-1}\mathbf{p}_0,

Where PP is the change-of-basis matrix consisting of the eigen vectors and DD the diagonal matrix with the corresponding eigen values.

๐ฉn=(211โˆ’1)(1000.7)n(131313โˆ’23)๐ฉ0.\mathbf{p}_n = \begin{pmatrix}2&1\\1&-1\end{pmatrix} \begin{pmatrix}1&0\\0&0.7\end{pmatrix}^n \begin{pmatrix}\frac{1}{3}&\frac{1}{3}\\ \frac{1}{3}&-\frac{2}{3}\end{pmatrix} \mathbf{p}_0.

Thank you diagonalization! for this favorable form.

Continue to the example of week 4โ€ฆ

The marvelous design of this website is taken from Suckless.org