How to generate high dimensional random orthogonal complex vectors?

186 Views Asked by At

I'm generating a few random vectors in 1000D space and they seem to be indeed almost orthongonal as evident by dot product. However, when I make them complex-valued, I lose that orthogonality, why is that? and how to make them orthogonal?

1

There are 1 best solutions below

0
On BEST ANSWER

Let $\mathbf{a}$ and $\mathbf{b}$ be $N$-dimensional complex vectors: $$\mathbf{a} = \left [ \begin{matrix} a_1 \\ a_2 \\ \vdots \\ a_N \end{matrix} \right ], \quad \mathbf{b} = \left [ \begin{matrix} b_1 \\ b_2 \\ \vdots \\ b_N \end{matrix} \right ]$$ where $$a_k = c_k + i C_k, \quad a_k \in \mathbb{C}, ~ c_k \in \mathbb{R}, ~ C_k \in \mathbb{R}$$ and $$b_k = d_k + i D_k, \quad b_k \in \mathbb{C}, ~ d_k \in \mathbb{R}, ~ D_k \in \mathbb{R}$$ As explained by the Wikipedia Dot product article, for dot product to make any sense, it has to be redefined for complex vectors as $$\mathbf{a} \cdot \mathbf{b} = \sum_k a_k \overline{b_k}$$ where $$\overline{b_k} = d_k - i D_k$$ so that $$\left\lVert \mathbf{a} \right\rVert^2 = \mathbf{a} \cdot \mathbf{a} = \sum_k c_k^2 + C_k^2$$ which also means that $$\mathbf{a} \cdot \mathbf{b} = -\mathbf{b} \cdot \mathbf{a}$$ and leads to $$\cos \theta = \frac{\operatorname{Re}\left( \mathbf{a} \cdot \mathbf{b} \right)}{\left\lVert\mathbf{a} \right\rVert \left\lVert\mathbf{b}\right\rVert}$$

In other words, $$\mathbf{a} \perp \mathbf{b} \iff \sum_k c_k d_k + C_k D_k = \sum_k C_k d_k - c_k D_k$$

With this definition of dot product, random complex vectors are indeed almost orthogonal.

To orthogonalise a vector with respect to another, you can use the first step of Gram-Schmidt process: $$\mathbf{b}^\prime = \mathbf{b} - \mathbf{a} \frac{ \mathbf{a} \cdot \mathbf{b} }{\mathbf{a} \cdot \mathbf{a}}$$ which ensures that $\mathbf{b}^\prime \perp \mathbf{a}$.