Using Dirac notation to find matrix representation

I am currently reading Sakuria, and I cannot get my head around how one uses the completeness relation to derive the matrix representations of outer products. In the first chapter he states that an operator X can be represented as $$X = \sum_{a^{\prime\prime}}\sum_{a^{\prime}}|a^{''}\rangle \langle a^{''} | X|a^{'}\rangle \langle a^{'}|.$$ This is fine and it helps do the problems, but I don't understand how this works. I have a bachelors in physics so I know how matrix multiplication works and all that, its the notation itself that I'm struggling with.

If $\langle a^{"}|a^{\prime} \rangle = \delta_{a^{"}a^{'}}$, then wouldn't the equation above always yield a matrix with all zeros except for the diagonal because

\begin{align} X =& \sum_{a^{2}}\sum_{a^{1}}|a^{2}\rangle \langle a^{2}|X|a^{1} \rangle \langle a^{1}| \\ X =& \sum_{a^{2}}\sum_{a^{1}} \langle a^{2}|X|a^{1} \rangle \langle a^{1}|a^{2}\rangle ; \quad \langle a^{1}|a^{2}\rangle = 0 \end{align}

EDIT: As pointed out this is an error, but I still don't see how the equation above generates the matrix for X.

I think I'm just missing something silly, and any help would be greatly appreciated.

• Isolated bras and kets do not commute, so you can't turn an outer product into an inner product. – probably_someone Apr 24 '18 at 19:54

Be careful, $|a^1\rangle \langle a^2| \neq \langle a^2|a^1\rangle$. This is at the core of the bra-ket notation. The left side is an operator whereas the right side is just a number. As an example, an identity which is used all over the place is the completeness relation which is given by $$\sum_i |a^i\rangle \langle a^i | = \mathbb{1}$$

where the $\mathbb{1}$ stands for the identity matrix.

On the other hand $$\sum_{i=1}^{\dim V} \langle a^i|a^i \rangle = \dim V$$.

Edit: Why the above is called a matrix is just that we want to express the operator in a particular basis. Choosing our basis as the $|a^i\rangle$ from before we get by applying the completeness relation $\mathbb{1}$ from above on both sides

$$X = \sum_{i} \sum_{j} |a^i\rangle\langle a^i |X|a^j\rangle \langle a^j| = \sum_{i} \sum_{j} X_{ij} |a^i\rangle \langle a^j|$$

where the $X_{ij} =\langle a^i |X|a^j\rangle$ are just numbers for each pair of indices which can be regarded as a (maybe infinite) matrix.

Writing states in this basis $|\phi \rangle = \sum_k c_k |a^k\rangle$ we get $$X |\phi \rangle = \sum_i \sum_j X_{ij}c_j |a^i\rangle$$

thus the coefficients after applying $X$ are $\sum_j X_{ij}c_j$ which is just a matrix multiplication $X\, \vec{c}$.

If you don't see the parallel yet, please tell me.

• Yeah I see what I did incorrectly now. Unfortunately I still don't understand how this equation generates the matrix of X. Could you explain that aspect? Thanks – AstroZ4ch Apr 24 '18 at 20:04
• I tried to add some more steps, let me know if it helps. – thi Apr 24 '18 at 20:23
• Thank you this makes it pretty clear. My problem seems to be getting the hang of the notation. I find Dirac notation really interesting and impressive, but also to have a pretty steep learning curve. Maybe Sakurai isn’t the best book for me at the moment. – AstroZ4ch Apr 24 '18 at 21:21
• Hang in there, it takes some getting used to but it makes your computations a lot tidier. Griffiths is a solid choice as well if you're looking for alternatives. – thi Apr 24 '18 at 21:26