Here I'm assuming $M_{2 \times 2}(\mathbb{R}) \cong \mathbb{R}^{4}$. The definition of $\mathrm{SO}(2)$ is:
$\mathrm{SO}(2)=\{ \ A \in M_{2 \times 2}(\mathbb{R}) \ | \ \det(A)=1 \mathrm{\ and\ }AA^{T}=I\ \}$
With some work I have shown that this is equivalent to:
$\mathrm{SO}(2)=\left\{ \ A \in M_{2 \times 2}(\mathbb{R}) \ \bigg| \ A=\left[ \begin{matrix} \ a & b\ \\ -b & a\ \end{matrix} \right]\mathrm{\ such\ that\ }a^2+b^2=1 \ \right\}$
I would like to find a smooth function $F:M_{2 \times 2}(\mathbb{R}) \cong \mathbb{R}^{4} \to \mathbb{R}^{2}$ such that:
$\mathrm{SO}(2)=\{\ A \in M_{2 \times 2}(\mathbb{R})\ | \ F(A) = 0\ \}$
I know that such a function must exist, but I can't quite figure it out. My idea was to set:
$F\left( \left[ \begin{matrix} \ a & b\ \\ \ c & d\ \end{matrix} \right] \right) = \left[ \begin{matrix} \ a - d \\ \ b + c\ \end{matrix} \right]$
But I don't think this is correct. The above function forces $d=a$ and $c=-b$ but I don't know how to force the $a^2+b^2=1$ condition. What am I missing?