Confusion about extension of scalars Define the algebraic group $SO(2)$ over $\mathbb{Q}$ by the functor that sends a $\mathbb{Q}$-algebra $R$ to the set of $2 \times 2$ matrices with top row $a,b$ and bottom row $-b,a$ where $a,b \in R$ and $a^2+b^2=1$. Over any field containing a square root of $-1$, such a matrix can be diagonalized ("Cayley transform") to the matrix $diag[a-bi,a+bi]$. I am confused about how it follows that the extension of scalars of $SO(2)$ to $\mathbb{Q}(i)$ is isomorphic to $\mathbb{G}_m$.
The extension of scalars $SO(2)_{\mathbb{Q}(i)}$ is the functor that sends a $\mathbb{Q}(i)$-algebra $S$ to a certain set of matrices. By diagonalizing, we get another functor that sends $S$ to $diag[a-bi,a+bi]:a,b \in S$ and $a^2+b^2=1$. That is not the same as what the functor $\mathbb{G}_m$ does: it should send $S$ to $S^\times$. 
I'm sure this is a "stupid question," but I think my main point of confusion is from abuse of notation and/or a misunderstanding of some definitions. I see that what you get from the conjugation is diagonal matrices but I'm not seeing how it is exactly $\mathbb{G}_m$.
 A: The system $z=a+bi, z^{-1}=a-bi$ for any $z\in S^\times$ implies the equation $a^2+b^2=1$, and allows you to solve $a,b$ in terms of $z,z^{-1}$. Conversely $a^2+b^2=1$ implies that $(a+bi)^{-1}=a-bi$, and consequently $a+bi\in S^\times$.
So we have two functors:


*

*$\mathbb{G}_m$ that maps $S$ to the multiplicative group $S^\times$ (with the obvious morphisms)

*a functor that maps $S$ to the group of matrices of the form $diag(z,z^{-1})$ with $z$ ranging over $S^\times$ (with the obvious morphisms).


It looks like these two are naturally isomorphic, doesn't it?
A: There is a natural isomorphism from $S^\times$ to the group of diagonal matrices you describe by taking $c\in S^\times$ to $diag[c,c^{-1}]$.  Indeed, note that if you define $a=(c+c^{-1})/2$ and $b=i(c-a)$, then $c=a-bi$, $c^{-1}=a+bi$, and $a^2+b^2=c\cdot c^{-1}=1$, so this map does land in your group.  This map is clearly an injective homomorphism, and it is surjective because the restriction that $a^2+b^2=1$ means that $a+bi$ must be the inverse of $a-bi$.
