# Question about number operator and density operator

1. Mar 9, 2009

### KFC

In quantum harmonic oscillator, we define the so called number operator as

$$\hat{N} = \hat{a}^\dagger\hat{a}$$

Apply $$\hat{N}$$ to the state with n number of particles, it gives
$$\hat{N}|n\rangle = n |n\rangle$$

so

$$\langle n| \hat{N}|n\rangle = \langle n| n |n\rangle = n$$

But in other textbook about statistical mechanics, it gives

$$\langle n |\hat{N}|n\rangle = \bar{n}$$

Why these two results are not the same? For later one, it seems to consider something related to the statistics, but how?

I still have another question by the trace, in harmonic oscillator, the density operator is given by

$$\hat{\rho} = \sum_n |n\rangle\langle n|$$

But sometimes, for a specific state, says $$|\varphi\rangle$$, the density operator just

$$\hat{\rho} = |\varphi\rangle\langle \varphi|$$

why there is no summation? When do we need to consider the summation?

Last edited: Mar 9, 2009
2. Mar 9, 2009

### Woozie

Did you type this first one in correctly? This doesn't look right.

$$\langle \hat{N}|n\rangle = \langle n |n\rangle = n$$

The $$\hat{N}$$ is an operator, not a vector. So it shouldn't be in a bra. Also $$\langle n |n\rangle$$ is equal to 1, not n.

What I think it should say is either

$$\hat{N}|n\rangle =n |n\rangle$$

or

$$\langle n |\hat{N}|n\rangle =\langle n |n|n\rangle= n\langle n |n\rangle =n$$

The second result being exactly consistent with what the statistical mechanics book says (except for the bar over the n).

3. Mar 9, 2009

### KFC

Yes. I just correct that.

But in $$|n\rangle$$, how come will it be average?

4. Mar 9, 2009

### Fredrik

Staff Emeritus
A density operator

$$\sum_i w_i|\alpha_i\rangle\langle\alpha_i|$$

can be interpreted in two different ways:

1. It represents an ensemble of identical physical systems, prepared so that a fraction wi of the systems are in state $|\alpha_i\rangle$.

2. It represents one physical system that is known to be in one of the $|\alpha_i\rangle$ states, but it's unknown which one. (Note that this means that it's not in a superposition of two or more of them). wi is the probability that it's in state $|\alpha_i\rangle$.

The first of your "density operators" is just the identity operator.

5. Mar 9, 2009

### Fredrik

Staff Emeritus
This should probably be

$$\langle \psi |\hat{N}|\psi\rangle = \bar{n}_\psi$$

When $$|\psi\rangle=|n\rangle$$, the right-hand side is just n.

Note that

$$\langle \psi |\hat{N}|\psi\rangle = \sum_n\langle \psi |\hat{N}|n\rangle\langle n|\psi\rangle= \sum_n n\langle \psi|n\rangle\langle n|\psi\rangle= \sum_n n|\langle n|\psi\rangle|^2$$

and that $|\langle n|\psi\rangle|^2$ is the probability that a measurement will yield result n. So the expression above represents the average value of a large number of measurements on identical systems that are all prepared in state $|\psi\rangle$.

Last edited: Mar 9, 2009
6. Mar 9, 2009

### KFC

Thanks Fredrik, it helps.

7. Mar 9, 2009

### Woozie

Let's say we want to find the average value of any dynamic variable, which we'll call $$\omega$$. Let's suppose we're working in some basis, which we'll call k. Then a general formula for the expectation value (average) is:

$$\langle k| \hat{\Omega}|k\rangle=\bar{\omega}$$

$$\langle n |\hat{N}|n\rangle = \bar{n}$$

This is the same formula I quoted above, but for the operator $$\hat{N}$$ in the n basis. Since it's the same formula, it gives the average, $$\bar{n}$$

Now, in this particular case, the basis vectors happen to be eigenvectors of the operator. As a result, the eigenvalue, n, happens to be equal to the expectation value, $$\bar{n}$$

In this derivation:

$$\langle n |\hat{N}|n\rangle =\langle n |n|n\rangle= n\langle n |n\rangle =n$$

note the importance of this particular step:

$$\langle n |\hat{N}|n\rangle =\langle n |n|n\rangle$$

The reason we can take this step is because of the fact that:

$$\hat{N}|n\rangle =n |n\rangle$$

or in other words, we can take this step because the vector happens to be an eigenvector of the operator. Because of this, the same formula that gives the average value also gives the eigenvalue. In the general case I noted above:

$$\langle k| \hat{\Omega}|k\rangle=\bar{\omega}$$

I would not be able to take that same step. So in this case, $$\omega$$ and $$\bar{\omega}$$ wouldn't follow from the same formula, so I wouldn't necessarily get $$\omega=\bar{\omega}$$

8. Mar 27, 2009

### physicsboy

In quantum stat. mech. the average of any quantity is defined as $$\overline{A} = Tr(\rhoA)$$ Where "rho" is the density operator.