2
$\begingroup$

Suppose $\mathbf{x}\sim\mathcal{CN}\left(\mathbf{0},\mathbf{I}_n\right)$ is a circular complex Gaussian random vector, and $\mathbf{Q}$ is a Hermitian matrix. How do I calculate the variance of the Hermitian form, i.e., $\text{Var}\left(\mathbf{x}^H\mathbf{Q}\mathbf{x}\right)$?

Here is what I know:

\begin{equation} \begin{aligned} \text{Var}\left(\mathbf{x}^H\mathbf{Q}\mathbf{x}\right)&=\mathbb{E}\left(\mathbf{x}^H\mathbf{Q}\mathbf{x}\mathbf{x}^H\mathbf{Q}\mathbf{x}\right)-\mathbb{E}^2\left(\mathbf{x}^H\mathbf{Q}\mathbf{x}\right) \end{aligned} \end{equation}

But I don't know what to do next.

$\endgroup$
7
  • $\begingroup$ Such a form is just a quadratic form in the real and imaginary parts of $\mathbf x,$ so the answer at stats.stackexchange.com/questions/427332/… is directly applicable. $\endgroup$
    – whuber
    Commented Apr 9, 2022 at 15:17
  • $\begingroup$ Thank you so much for your answer. If we let $\mathbf{x}=\mathbf{a}+j\mathbf{b}$, where $\mathbf{a}$ and $\mathbf{b}$ represent the real and imaginary part of $\mathbf{x}$, then we can get $\mathbf{x}^H\mathbf{Q}\mathbf{x}=(\mathbf{a}^T-j\mathbf{b}^T)\mathbf{Q}(\mathbf{a}+j\mathbf{b})=\mathbf{a}^T\mathbf{Qa}+j\mathbf{a}^T\mathbf{Qb}-j\mathbf{b}^T\mathbf{Qa}+\mathbf{b}^T\mathbf{Qb}$, then how to deal with the inner 2 cross terms? Thank you again. $\endgroup$
    – Raymond
    Commented Apr 11, 2022 at 16:58
  • $\begingroup$ Create a vector by concatenating $\mathbf a$ and $\mathbf b.$ Split $\mathbf Q$ into its real and imaginary parts. In terms of that vector, there are no cross terms and the coefficients of the form are the real and imaginary parts of $\mathbf Q.$ Try it with 1D vectors and then 2D vectors to see the pattern. $\endgroup$
    – whuber
    Commented Apr 11, 2022 at 17:03
  • 1
    $\begingroup$ Amazing!! The correct expression should be $\mathbf{x}^H\mathbf{Qx}=\left(\begin{matrix}\mathbf{a}^T&\mathbf{b}^T\end{matrix}\right)\left(\begin{matrix}\mathbf{Q}_r&-\mathbf{Q}_i\\ \mathbf{Q}_i&\mathbf{Q}_r\end{matrix}\right)\left(\begin{matrix}\mathbf{a}\\ \mathbf{b}\end{matrix}\right)$, and the inner matrix is a real symmetric matrix now. Thank you so much for your help. $\endgroup$
    – Raymond
    Commented Apr 11, 2022 at 20:17
  • 1
    $\begingroup$ Oh yes, the row 1 column 2 entry of the inner matrix should be the transpose of $\mathbf{Q}_i$. Actually uh... the minus is equivalent to the transpose. $\endgroup$
    – Raymond
    Commented Apr 12, 2022 at 14:18

1 Answer 1

2
$\begingroup$

It's useful to know how to convert the notation of Complex numbers into a more familiar Real notation. Here are the details.

Hermitian matrices and real-valued Complex forms

$\mathbf Q = (q_{ij})$ is a square matrix representing a real-valued quadratic form. This means that we don't really care about the details of $\mathbf Q:$ what matters is the function of the (Complex) vector $\mathbf z = (z_1, z_2, \ldots, z_n)^\prime$ defined via matrix multiplication by

$$Q(\mathbf z) = \mathbf z^{*}\, \mathbf Q\, \mathbf z = \sum_{i=1}^n \sum_{j=1}^n \bar z_i\, q_{ij}\, z_j.\tag{1}$$

Writing $z_i = x_i + y_i\mathbf i$ in terms of its real and imaginary parts, the overline refers to the complex conjugate $\bar z = x_i - y_i\mathbf i$ and the conjugate transpose operation transposes a vector and conjugates all its components,

$$\mathbf z^* = (\bar z_1, \bar z_2, \ldots, \bar z_n).$$

Because $Q$ is required to be a real number for all such vectors $\mathbf z,$ it must equal its conjugate, whence (by swapping the symbols "$i$" and "$j$" in the sums) we see

$$Q(\mathbf z) = \overline {Q(\mathbf z)} = \sum_{i=1}^n \sum_{j=1}^n z_i\, \bar q_{ij}\, \bar z_j = \sum_{j=1}^n \sum_{i=1}^n z_j\, \bar q_{ji}\, \bar z_i$$

Comparing this to $(1)$ shows that for equality to hold for all $\mathbf z,$ necessarily $q_{ij} = \bar q_{ji}$ for all indexes $i$ and $j.$ Such a matrix is called Hermitian and this operation of transposing a matrix while taking complex conjugates is evidently a generalization of the conjugate transpose, allowing us to write

$$\mathbf Q^{*} = (\bar q_{ji}) = \overline{\mathbf Q}^{\prime}.$$

In other words,

A Complex quadratic form $Q$ is real if and only if the matrix $\mathbf Q$ representing $Q$ is Hermitian.

Writing Complex forms as equivalent Real forms

Write $q_{ij} = a_{ij} + b_{ij}\mathbf i.$ The Hermitian property of $\mathbf Q$ is

$$a_{ji} - b_{ji}\mathbf i = \bar q_{ji} = q_{ij} = a_{ij} + b_{ij}\mathbf i.$$

Comparing real and imaginary parts and assembling them into matrices $\mathbf A = (a_{ij})$ and $\mathbf B = (b_{ij})$ shows

$$\mathbf A = \mathbf A^\prime\ \text{and}\ \mathbf B = -\mathbf{B}^\prime.\tag{2}$$

$\mathbf A = \Re (\mathbf Q)$ is the real part of $\mathbf Q$ and $\mathbf B = \Im (\mathbf Q)$ is its imaginary part. If these (simple) relationships are not perfectly clear, see the concrete example (with $n=2$) offered at the end of this post.

Let $i$ and $j$ be arbitrary indexes. Let's examine how the real and imaginary parts of $z_i$ and $z_j$ appear in $Q(\mathbf z).$ This product appears in at most two terms in the sum $(1),$ which can be combined using the Hermitian property of $\mathbf Q.$ Here is the calculation when $i\ne j.$ We only have to compute the real part of the result, knowing the imaginary part will be zero.

$$\begin{aligned} \bar z_iq_{ij}z_j + \bar z_jq_{ji}z_i &= (x_i - y_i\mathbf i)(a_{ij} + b_{ij}\mathbf i)(x_j + y_j\mathbf i) + (x_j - y_j\mathbf i)(a_{ji} + b_{ji}\mathbf i)(x_i + y_i\mathbf i)\\ &= (x_i - y_i\mathbf i)(a_{ij} + b_{ij}\mathbf i)(x_j + y_j\mathbf i) + (x_j - y_j\mathbf i)(a_{ij} - b_{ij}\mathbf i)(x_i + y_i\mathbf i)\\ &= 2x_i\, a_{ij}\, x_j + 2y_i\, a_{ij}\, y_j - 2x_i\, b_{ij}\, y_j + 2 x_j\, b_{ij}\, y_i \end{aligned}$$

(I leave the calculation for $i=j$ as a simple exercise.)

This is a quadratic form in the $2n$ dimensional real vector $\mathbf z_{\Re} = (x_1,x_2,\ldots, x_n;y_1,y_2,\ldots,y_n).$ In block matrix notation its matrix is

$$\mathbf Q_{\Re} = \pmatrix{\mathbf A & -\mathbf B \\ \mathbf B & \mathbf A}.\tag{3}$$

Because $\mathbf A$ is symmetric and $\mathbf B$ is antisymmetric (according to $(2)$ above), evidently $\mathbf Q_{\Re}$ is a real, symmetric matrix -- as it must be, because we have already seen it represents a real-valued quadratic form in the real variables $x_1, \ldots, y_n.$

Solution to the problem in the question

Our thread at Variance of quadratic form for multivariate normal distribution shows that

$$\operatorname{Var}\left(\mathbf z^* \mathbf Q\, \mathbf z\right) = \operatorname{Var}\left(\mathbf z_{\Re}^\prime\, \mathbf Q_{\Re}\, \mathbf z_{\Re}\right) = 2\operatorname{tr}\left(\mathbf Q_{\Re}^2\right).$$

The block matrix expression for this form's matrix enables us to compute this trace in terms of the real and imaginary parts of $\mathbf Q,$

$$\operatorname{tr}\left(\mathbf Q_{\Re}^2\right) = \operatorname{tr}\left(\pmatrix{\mathbf A & -\mathbf B \\ \mathbf B & \mathbf A}^2\right) = \operatorname{tr}\pmatrix{\mathbf A^2 - \mathbf B^2 & -2\mathbf A \mathbf B\\2\mathbf B \mathbf A & \mathbf A^2 - \mathbf B^2} = 2\operatorname{tr}\left(\mathbf A^2\right) - 2\operatorname{tr}\left(\mathbf B^2\right).$$

Thus,

$$\operatorname{Var}\left(\mathbf z^* \mathbf Q\, \mathbf z\right) = 4\operatorname{tr}\left(\mathbf A^2 - \mathbf B^2\right) = 4\left(\operatorname{tr}\Re(\mathbf Q)^2 - \operatorname{tr}\Im(\mathbf Q)^2\right).$$


Checking the result

I generated a random $2\times 2$ Complex covariance matrix $\mathbf Q,$ computed $Q(\mathbf z)$ for $100$ iid standard Normal complex vectors $\mathbf z,$ and estimated their variance. Upon repeating this five thousand times I obtained an empirical representation of this distribution. If the preceding result is correct, then the ratio of each of these variance estimates to the calculated variance should be centered at zero. Here is the histogram

Figure

It's exactly as expected. I repeated this process several times for $2\times 2$ through $5\times 5$ Complex covariance matrices and observed comparable results.

To illustrate the block matrix notation used above, here are the computer representations of $\mathbf Q$

              [,1]          [,2]
[1,]  0.203+0.000i -0.211+0.204i
[2,] -0.211-0.204i  0.600+0.000i

and $\mathbf Q_{\Re}$

       [,1]   [,2]   [,3]   [,4]
[1,]  0.203 -0.211  0.000 -0.204
[2,] -0.211  0.600  0.204  0.000
[3,]  0.000  0.204  0.203 -0.211
[4,] -0.204  0.000 -0.211  0.600

for the original simulation. Comparing them will make their relationship clear.

Here is the R code used for this check.

#
# Create real symmetric and antisymmetric matrices.
#
set.seed(17)                          # Comment out to produce different random results
n <- 2                                # The complex dimension, 1 or greater
A <- cov(matrix(rnorm(2*n^2), ncol=n))
B <- matrix(rnorm(n^2, 0), n); B <- B - t(B)
while(TRUE) {
  #
  # Verify they represent a Complex covariance.
  #
  Q.Re <- rbind(cbind(A, -B), cbind(B, A))
  if(min(eigen(Q.Re, only.values = TRUE)$values) >= 0) break
  B <- B / 2 # Shrink B and try again
}
#
# Represent it as a Complex hermitian matrix.
#
Q <- A + B * 1i
#
# Verify it is hermitian.
#
if(1 + sum(Mod(Q - Conj(t(Q)))) != 1) stop("Q is not hermitian.")
#
# Compute the variance.  (This is the main result.)
#
var.Q <- 4 * (sum(diag(A %*% A)) - sum(diag(B %*% B)))
#
# Generate standard Complex normal vectors.
#
N.sim <- 1e2
X <- replicate(5e3, {
  XY <- matrix(rnorm(2*n * N.sim), N.sim)
  Z <- XY[, seq_len(n), drop=FALSE] + XY[, seq_len(n) + n, drop=FALSE] * 1i
  #
  # Compute the form for each vector.
  # Because Q is hermitian, the result will be real, so we store it that way.
  #
  q <- Re(apply(Z, 1, function(z) Conj(z) %*% Q %*% z))
  #
  # Report its variance.
  #
  var(q)
})
hist(log(X / var.Q), xlab="Value", 
     main="Histogram of Log(Simulated/Calculated)", cex.main=1)
abline(v = 0, col="Red", lwd=2)
#
# Display the matrices of the form.
#
print(round(Q, 3))    # The n X n complex matrix
print(round(Q.Re, 3)) # The equivalent 2n X 2n real matrix
$\endgroup$
1
  • 2
    $\begingroup$ That's really helpful, thank you so much for your kind help! $\endgroup$
    – Raymond
    Commented Apr 13, 2022 at 15:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.