HallsofIvy said:
[tex]\left(\begin{array}{c}\frac{dx}{dt} \\ \frac{dy}{dt}\end{array}\right)= \left(\begin{array}{ccc}0 && 1 \\-w^2 && 0\end{array}\right)\left(\begin{array}{c}x \\ y\end{array}\right)[/tex]
Taking this one step further, define [itex]\mathbf X[/itex] and [itex]\mathbf A[/itex] as
[tex]\begin{array}{rl}<br />
\mathbf X &\equiv \bmatrix x\\y\endbmatrix \\[12pt]<br />
\mathbf A &\equiv \bmatrix 0&&1\\-w^2&&0\endbmatrix<br />
\endarray[/tex]
then
[tex]\frac {d\mathbf X}{dt}= \mathbf A\mathbf X[/tex]
If [itex]\mathbf X[/itex] and [itex]\mathbf A[/itex] were scalars, the solution to the above would be the exponential
[tex]\mathbf X = e^{\mathbf A t}\mathbf X|_{t=0}[/tex]
The series expansion of the exponential function works for matrices as well as scalars (for example, see http://mathworld.wolfram.com/MatrixExponential.html" ).
In this case,
[tex]\mathbf A^2 = -w^2 \mathbf I[/tex]
where [itex]\mathbf I[/itex] is the identity matrix. Thus
[tex]\begin{array}{rl}<br />
(\mathbf A t)^{2n} &= (-1)^n (wt)^{2n} \mathbf I \\<br />
(\mathbf A t)^{2n+1} &= (-1)^n \frac 1 w (wt)^{2n+1} \mathbf A\\<br />
\end{array}[/tex]
The matrix exponential is thus
[tex]\begin{array}{rl}<br />
e^{\mathbf A t} &=\sum_{n=0}^{\infty} \frac {(\mathbf At)^n}{n!}<br />
\\[12pt]<br />
&= \sum_{n=0}^{\infty} \frac {(\mathbf At)^{2n}}{(2n)!} +<br />
\sum_{n=0}^{\infty} \frac {(\mathbf At)^{2n+1}}{(2n+1)!}<br />
\\[12pt]<br />
&= \sum_{n=0}^{\infty} (-1)^n\frac {(wt)^{2n}}{(2n)!} \mathbf I +<br />
\frac 1 w\sum_{n=0}^{\infty}(-1)^n\frac{(wt)^{2n+1}}{(2n+1)!} \mathbf A<br />
\\[12pt]<br />
&= \cos(wt) \mathbf I +\frac 1 w\sin(wt) \mathbf A<br />
\end{array}[/tex]