Solution of $x'=Ax$ is not what it is supposed to be

57 Views Asked by At

Consider a system of ODEs $x'=\begin{bmatrix} 0 &1 \\ -1&0 \end{bmatrix}x$.

Wolfram Alpha says that the solution is $x(t) = \begin{bmatrix} \cos t &\sin t \\ -\sin t& \cos t \end{bmatrix}x_0$. However, I can't get the same solution and I can't understand what my error is.

The method that I use is as follows.

(1) Find the eigenvalues: $\lambda =\pm i$.

(2) Find the vectors for $P$ from the eigenvectors of $A$, so $P=\begin{bmatrix} -1 & 0 \\ 0&2 \end{bmatrix}$, $P^{-1}=\begin{bmatrix} -1 & 0 \\ 0&1/2 \end{bmatrix}$.

(3) Thus $e^{At}=P\begin{bmatrix} \cos t & -\sin t \\ \sin t&\cos t \end{bmatrix}P^{-1}= \begin{bmatrix} \cos t & \frac{1}{2} \sin t \\ -2 \sin t&\cos t \end{bmatrix}$, which is not the answer that Wolfram Alpha gives.

Some advice would be appreciated.