|q⟩ Bad Qubits

intermediate · Physics · Operators, Eigenvalues & Spectral Theorem

Functions of Operators

The spectral theorem does more than diagonalize an operator — it tells you how to take any function of it. Want the square root of an operator? Its exponential? Its logarithm? You apply the ordinary scalar function to the eigenvalues and leave the eigenvectors alone. This functional calculus is what gives meaning to expressions like the time-evolution operator eiHt/e^{-iHt/\hbar}.

The definition

Let AA be Hermitian (or, more generally, normal) with spectral decomposition A=kλkkkA = \sum_k \lambda_k |k\rangle\langle k|. For any scalar function ff defined on the eigenvalues, define

f(A)=kf(λk)kk.f(A) = \sum_k f(\lambda_k)\,|k\rangle\langle k|.

The eigenvectors k|k\rangle are unchanged; only the weights are transformed from λk\lambda_k to f(λk)f(\lambda_k). In the eigenbasis, where A=diag(λ1,,λn)A = \operatorname{diag}(\lambda_1, \dots, \lambda_n), this is simply

f(A)=diag(f(λ1),,f(λn)).f(A) = \operatorname{diag}\big(f(\lambda_1), \dots, f(\lambda_n)\big).

Apply the function entry by entry along the diagonal — that is the whole idea.

Why this is the right definition

For a polynomial f(x)=mcmxmf(x) = \sum_m c_m x^m there is no choice: f(A)f(A) must mean mcmAm\sum_m c_m A^m, where AmA^m is repeated operator multiplication. But powers of AA are easy in the eigenbasis, Amk=λkmkA^m|k\rangle = \lambda_k^m |k\rangle, so

f(A)k=mcmAmk=(mcmλkm)k=f(λk)k.f(A)|k\rangle = \sum_m c_m A^m |k\rangle = \Big(\sum_m c_m \lambda_k^m\Big)|k\rangle = f(\lambda_k)|k\rangle.

The spectral formula agrees with the polynomial definition. For more general ff (square roots, exponentials, logarithms) we define f(A)f(A) by the same rule, and it matches the limit of polynomial approximations whenever the power series converges. Consistency requires only that ff be defined at each eigenvalue.

The operator exponential

The most important example is f(x)=exf(x) = e^x. The exponential of an operator,

eA=m=0Amm!=keλkkk,e^{A} = \sum_{m=0}^{\infty} \frac{A^m}{m!} = \sum_k e^{\lambda_k}\,|k\rangle\langle k|,

is what turns a Hermitian Hamiltonian into a unitary evolution. If HH is Hermitian with real eigenvalues EkE_k, then

U(t)=eiHt/=keiEkt/EkEkU(t) = e^{-iHt/\hbar} = \sum_k e^{-iE_k t/\hbar}\,|E_k\rangle\langle E_k|

has eigenvalues eiEkt/e^{-iE_k t/\hbar} of modulus one — a unitary, exactly as promised in the unitary- operators lesson. Each energy eigenstate simply picks up a rotating phase.

A trace shortcut

Because the trace is basis-independent and equals the sum of the eigenvalues, the trace of f(A)f(A) is just

Tr(f(A))=kf(λk).\operatorname{Tr}\big(f(A)\big) = \sum_k f(\lambda_k).

You never have to build the matrix f(A)f(A) to get its trace — sum ff over the spectrum. For instance, with A=(3113)A = \begin{pmatrix} 3 & 1 \\ 1 & 3\end{pmatrix} (eigenvalues 44 and 22), the operator square root satisfies Tr(A)=4+2=2+2\operatorname{Tr}(\sqrt{A}) = \sqrt4 + \sqrt2 = 2 + \sqrt2. The same logic gives the partition function Tr(eβH)=keβEk\operatorname{Tr}(e^{-\beta H}) = \sum_k e^{-\beta E_k} of statistical mechanics for free.

Try it

Using the spectral rule, compute A\sqrt{A} for A=(3113)A = \begin{pmatrix} 3 & 1 \\ 1 & 3\end{pmatrix} and return its trace Tr(A)\operatorname{Tr}(\sqrt{A}) as a plain number.

Run your code to see the quantum state.

Sign in on the full site to ask questions and join the discussion.