# How would I compute a density matrix of a complex qubit mixed state?

I am currently reading Nielsen & Chuang, and one of the questions asks to calculate a density matrix with the following mixed state,

$$\frac{1}{9}\begin{bmatrix} 5 & 1 & −i \\ 1 & 2 & -2i \\ i & 2i & 2 \end{bmatrix}$$

and retrieving the probability of measuring

$$|0\rangle = \begin{pmatrix} 1 \\ 0\\ 0\\ \end{pmatrix}$$

How would I do this?

• Welcome to QCSE! Please ask one focused question per post. It's no problem to submit multiple posts :-) Feb 23 at 1:43
• Regarding the first part of your question, does this post answer it? Feb 23 at 1:53
• @AdamZalcman Hi, sorry I didnt realise, my apologies. I did try a few times but I cant seem to get the results for either, also shall I submit a new post with these questions seperately or is it okay to keep this post as it is and remember for future? Feb 23 at 1:58
• You an edit this post so it contains only one question and submit the other as a separate post. That said, the first part of this question (density matrix of $|0\rangle$) is really a duplicate of the question I linked to above (just with different numbers substituted into the same formula). Feb 23 at 2:02
• @lambda.: Please mention from which exercise this is taken. (page number of the book) Feb 23 at 2:36

Let $$\rho$$ denote the density matrix specified in the question. The probability of obtaining the result corresponding to $$|0\rangle$$ when measuring $$\rho$$ in the computational basis is
$$p(0|\rho) = \mathrm{tr}(P_0\rho) = \mathrm{tr}(|0\rangle\langle 0|\rho) = \langle 0|\rho|0 \rangle = \frac{5}{9}$$
where $$P_0=|0\rangle\langle 0|$$ is the projector onto the subspace spanned by $$|0\rangle$$. See equation $$(2.159)$$ on page 102 in Nielsen & Chuang where $$M_m = P_0$$ and note that $$P_0=P_0^\dagger$$ and $$P_0^2 = P_0$$.