# Is a commutator a scalar?

[A,B] = AB-BA, so the commutator should be a matrix in general, but yet
[x,p]=i*hbar...which is just a scalar. Unless by this commutator, we mean i*hbar*(identity matrix) ?

I am asking because I see in a paper the following:

tr[A,B]

Which I interpret to mean the trace of the commutator [A,B]. But if [A,B] is just a scalar, then trace of a scalar should always just be the scalar..

Yes, in this case ##i \hbar## is shorthand for "##i \hbar## times the identity operator."

Ohhh ok thanks!! I can't believe I went through all of Griffiths and this point was never made clear.

dextercioby
Homework Helper
Since Griffiths doesn't get into the mathematics of the CCRs, nor specifically treats the old matrix mechanics, it's quite understandable that he leaves out the unit operator/matrix.

The commutator of two scalars is a scalar.
The commutator of two vectors is a matrix. e.g.

[xi,pj]=iħδij

in this case it is the unity matrix. The trace of this in 4 dimensions would be 4.