Complex Numbers expression This question may sound too basic, but I am new to complex numbers.
We all know $e^{it}=\cos t+i\sin t$. Given a real diagonal matrix $P$, what does $e^{itP}$ look like? I am guessing it would be: $e^{itP}=\cos P_{11} t +i\sin P_{22} t$, where $P_{11}$ and $P_{22}$ are diagonal entries. But I am pretty sure my guess is not correct.
 A: Let's do things using the "complicated formula":
$$
e^{itP} = \sum_{k=0}^\infty \frac 1{k!}(itP)^k = 
\sum_{k=0}^\infty \frac 1{k!}i^k t^k P^k = 
\sum_{k=0}^\infty \frac 1{k!}i^k t^k \pmatrix{P_{11}^k & 0 \\0 & P_{22}^k} = \\
\pmatrix{\sum_{k=0}^\infty \frac 1{k!}i^k t^k P_{11}^k & 0 \\0 & \sum_{k=0}^\infty \frac 1{k!}i^k t^k P_{22}^k} = 
\pmatrix{e^{iP_{11}t} & 0\\ 0 & e^{iP_{22}t}}=\\
\pmatrix{\cos P_{11}t + i \sin P_{11}t & 0\\ 0 & \cos P_{22}t + i \sin P_{22}t} = \\
\pmatrix{\cos P_{11}t & 0\\ 0 & \cos P_{22}t}
+ i \pmatrix{\sin P_{11}t & 0\\ 0 & \sin P_{22}t} = \\
\cos(Pt) + i \sin (Pt)
$$
A: Of course, Omnomnomnom has already given a good answer to your question. Let me replace your question with a slightly different one:

Calculate $e^{tJ}$ where $J = \left[ \begin{array}{cc} 0 & -1 \\
1 & 0 \end{array} \right]$

Then, since $J^2 = \left[ \begin{array}{cc} -1 & 0 \\
0 & -1 \end{array} \right] = -I$ we find $J^3 = -J$ and $J^4=I$. In other words, $J$ behaves as $i \in \mathbb{C}$. Thus, $J^{2k} = (-1)^kI$ and $J^{2k+1}=(-1)^kJ$ so we calculate the matrix exponential as follows:
\begin{align} e^{tJ} &= \sum_{k=0}^{\infty} \frac{(tJ)^{2k}}{(2k)!} + 
\sum_{k=0}^{\infty} \frac{(tJ)^{2k+1}}{(2k+1)!} \\
&= \left(\sum_{k=0}^{\infty} \frac{(-1)^kt^{2k}}{(2k)!}\right)I + 
\left(\sum_{k=0}^{\infty} \frac{(-1)^kt^{2k+1}}{(2k+1)!}\right)J \\
&= \cos(t) I + \sin(t)J
\end{align}
In fact, $M_{\mathbb{C}}(a+ib) = \left[ \begin{array}{cc} a & -b \\ b & a \end{array} \right]$ defines the regular representation of $\mathbb{C}$. In particular $M_{\mathbb{C}}(1) = I$ and $M_{\mathbb{C}}(i)=J$ and you can verify that $M_{\mathbb{C}}(zw)= M_{\mathbb{C}}(z)M_{\mathbb{C}}(w)$ and $M_{\mathbb{C}}(z+w) = M_{\mathbb{C}}(z)+M_{\mathbb{C}}(w)$. In addition, it's interesting to note:
$$ M_{\mathbb{C}}(e^{it}) = M_{\mathbb{C}}(\cos( t)+i \sin t) = \cos (t) M_{\mathbb{C}}(1)+\sin(t)M_{\mathbb{C}}(i) = \cos( t) I + \sin (t) J.$$
Or, $M_{\mathbb{C}}(e^{it}) = e^{tJ} = e^{M_{\mathbb{C}}(it)}.$ This identity is true for many algebras.
