# How is measurement modelled when using the density operator?

I've just learned about the density operator, and it seems like a fantastic way to represent the branching nature of measurement as simple algebraic manipulation. Unfortunately, I can't quite figure out how to do that.

Consider a simple example: the state $$|+\rangle$$, which we will measure in the computational basis (so with measurement operator $$I_2$$). The density operator of this state is as follows:

$$\rho = |+\rangle\langle+| = \begin{bmatrix} \frac{1}{\sqrt{2}} \\ \frac{1}{\sqrt{2}} \end{bmatrix} ⊗ \begin{bmatrix} \frac{1}{\sqrt{2}}, \frac{1}{\sqrt{2}} \end{bmatrix} = \begin{bmatrix} \frac 1 2 & \frac 1 2 \\ \frac 1 2 & \frac 1 2 \end{bmatrix}$$

Since measuring $$|+\rangle$$ in the computational basis collapses it to $$|0\rangle$$ or $$|1\rangle$$ with equal probability, I'm imagining there's some way of applying the measurement operator $$I_2$$ to $$\rho$$ such that we end up with the same density operator as when we don't know whether the state is $$|0\rangle$$ or $$|1\rangle$$:

$$\rho = \frac 1 2 \begin{bmatrix} 1 \\ 0 \end{bmatrix} ⊗ \begin{bmatrix} 1, 0 \end{bmatrix} + \frac 1 2 \begin{bmatrix} 0 \\ 1 \end{bmatrix} ⊗ \begin{bmatrix} 0, 1 \end{bmatrix} = \begin{bmatrix} \frac 1 2 & 0 \\ 0 & 0 \end{bmatrix} + \begin{bmatrix} 0 & 0 \\ 0 & \frac 1 2 \end{bmatrix}$$

From there, we can continue applying unitary transformations to the density operator so as to model a measurement occurring mid-computation. What is the formula for applying a measurement operator to the density operator? Looking in the Mike & Ike textbook section on the density operator, I only see the density operator measurement formula for a specific measurement outcome. I'd like to know the density operator measurement formula which captures all possible results of the measurement.

As a followup question, I'm also curious as to the formula when measuring some subset of multiple qubits.

To define a measurement, you need a set of measurement operators $P_i$, one for each possible measurement outcome, that satisfy a completeness relation $$\sum_iP_i=\mathbb{I}$$ Let me specialise to the case of projective measurements, where $P_i^2=P_i$. To calculate the probability of a given density operator $\rho$ giving outcome $i$, you simply calculate $$p_i=\text{Tr}(P_i\rho),$$ and the state that you get as output is $$\rho_i=\frac{P_i\rho P_i}{p_i}.$$ So, in the case of the measurement of a single qubit in the computational basis, you have $$P_0=|0\rangle\langle 0|\qquad P_1=|1\rangle\langle 1|,$$ and you'll get $p_0=p_1=\frac12$. At that point, you proceed with using the separate measurement outcomes separately, unless there is a case where some other user doesn't know what the outcome was. Then they use a standard Bayesian approach to describe their state of knowledge as $$\tilde\rho=\sum_ip_i\rho_i.$$ In this case, that's the maximally mixed state $\mathbb{I}/2$. But for anybody who knows what the measurement result is, you just keep going with the separate results. If it's too painful having to do the full calculation twice, you might do a trick like writing a state $$\frac12(P_0+P_1\pm(P_0-P_1)).$$ Then you just do the calculation once and, at the end, choose either the + sign to see what happens for the 0 measurement result, or - to see what happens for the 1 result. But it probably doesn't actually reduce your workload.
If you want to talk about $n$ qubits where you measure just the first one, then you use the measurement operators $$P_0=|0\rangle\langle 0|\otimes\mathbb{I}^{\otimes(n-1)}\qquad P_1=|1\rangle\langle 1|\otimes\mathbb{I}^{\otimes(n-1)}$$ and apply all the same formalism as before.
• Thanks! Are the measurement operators $P_i$ always the outer product of the eigenvectors of the measurement observable, and subscripted with the eigenvalue? Also to clarify in the multi-qbit state, say to measure the middle qbit of a 3-qbit system $P_0$ would be $\mathbb{I}_2⊗|0\rangle\langle0|⊗\mathbb{I}_2$? Aug 31, 2018 at 19:46