# Generating rotations in $\mathbb{R}^n$

I want to be able to computationally generate a rotation matrix for $\mathbb{R}^n$ where $n$ might go as high as $10^4$. The naive technique would be to generate the rotation in each plane then proceed by matrix multiplication. This seems unwise.

Ignoring the special cases $n=1$, $n=2$; Can I generate the matrix of rotation about $\binom{n}{2}$ planes for $\mathbb{R}^n$ without using the naive technique?

-
What do you want the actual matrix for? If you just want to apply an arbitrary rotation in $\mathbb{R}^{n}$, it can be expressed as a product of ${{n}\choose{2}}=\frac{1}{2}n(n-1)$ rotations, one in each $2$-dimensional axis-aligned subspace. – mjqxxxx Sep 29 '12 at 16:22
What do you mean by "the matrix of rotation about $n$ angles"? Do you mean "by/through" $n$ angles? Do you have $n$ angles given? If so, do you also have the planes in which to rotate through these angles? – joriki Sep 29 '12 at 16:25
@mjqxxxx: Or it can be expressed as a product of $\lfloor n/2\rfloor$ rotations in $2$-dimensional subspaces (not necessarily axis-aligned). – joriki Sep 29 '12 at 16:26
So I'm actually generating eigenvectors of an estimate of a (unknown) Hamiltonian (along with a set of eigenvalues); which when normalized and placed in a matrix by columns turns out to be an element of SO(n, R); thus I can parameterize these vectors by the angles (which I'm using as part of the genome of a genetic algorithm). In essence I'm generating a change of basis matrix from a set of $n$ parameters. – Michael Conlen Sep 29 '12 at 17:22
joriki: I think what I actually mean is about $n$ dimensions. I do have the particular angles. – Michael Conlen Sep 29 '12 at 17:29