In quantum mechanics, the expectation value of an observable
represents the average result from measuring
on a large number of systems (an ensemble)
prepared in the same state ,
known as a pure ensemble or (somewhat confusingly) pure state.
But what if the systems of the ensemble are not all in the same state?
To work with such a mixed ensemble or mixed state,
the density operator or density matrix (in a basis) is useful.
It is defined as follows, where is the probability
that the system is in state ,
i.e. the proportion of systems in the ensemble that are
in state :
Do not let is this form fool you into thinking that is diagonal:
need not be basis vectors.
Instead, the matrix elements of are found as usual,
where and are basis vectors:
However, from the special case where are indeed basis vectors,
we can conclude that is positive semidefinite and Hermitian,
and that its trace (i.e. the total probability) is 100%:
These properties are preserved by all changes of basis.
If the ensemble is purely ,
then is given by a single state vector:
From the special case where is a basis vector,
we can conclude that for a pure ensemble,
is idempotent, which means that:
This can be used to find out whether a given
represents a pure or mixed ensemble.
Next, we define the ensemble average
as the mean of the expectation values of for states in the ensemble.
We use the same notation as for the pure expectation value,
since this is only a small extension of the concept to mixed ensembles.
It is calculated like so:
To prove the latter,
we write out the trace as the sum of the diagonal elements, so:
In both the pure and mixed cases,
if the state probabilities are constant with respect to time,
then the evolution of the ensemble obeys the Von Neumann equation:
This equivalent to the Schrödinger equation:
one can be derived from the other.
We differentiate with the product rule,
and then substitute the opposite side of the Schrödinger equation: