# How can the expected value $\left<x\right>$ of a given state in an harmonic oscillator differ from $0$?

In a standard harmonic oscillator potential I have the state $\left|\Psi\right> = \frac{1}{\sqrt{2}}(\left|0\right> + \left|1\right>)$ and if I calculate the expected value $\left<x\right>$ I get $\sqrt{\frac{\hbar}{2m\omega}}$, which is different from $0$. I don't quite get how some state can "prefer" a particular side of the oscillator. I know that the superposition of the two states is what you could say tilted to one side, in fact I've done the plot shown below, but I don't get the physical sense of this, and I would need an explanation. It confuses me because I've always been told that the wave function for itself doesn't have any physical meaning, it's only the function squared that we can perceive, but then with the example I've just given, couldn't we know if the ground state has a particular sign and the 1st excited the opposite sign depending on the side of the harmonic oscillator that our state "preferes"?

And here's the image:

Edit: Thanks for demonstrating to me that the expected value of the function over time is 0, but there's something I don't understand yet. In a particular instant, the eigenstates (\left|0\right> and \left|1\right>) will each have a particular sign, so if you could measure just an instant you could actually know how the wave function is, besides the square of it. I know I'm probably wrong, I just don't know where.

The solution to this is quite simple: you calculated the expectation value $\langle x \rangle$ at a particular moment in time, call it $t=0$. In order to calculate it at an arbitrary moment in time, introduce time development to the system in one of two ways:

i) Schrödinger picture. States develop according to $$i \hbar \frac{\text{d}|\psi\rangle}{\text{d}t} = \hat H |\psi\rangle.$$

ii) Heisenberg picture. Operators (which don't depend explicitly on time) develop according to $$\frac{\text d \hat O}{\text{d}t} = \frac{i}{\hbar} [\hat H, \hat O].$$

Let's consider the first way. Then, the two states $\{|0\rangle, |1\rangle\}$ develop in time according to $$|0, t\rangle = e^{-\frac{i}\hbar E_0 t}|0\rangle, \qquad |1,t\rangle = e^{-\frac{i}\hbar E_1t}|1\rangle.$$ Using the energies of the harmonic oscillator $E_n = \hbar \omega \left(n+\frac{1}{2}\right)$, we thus find $$|\psi(t)\rangle = \frac{1}{\sqrt{2}}\left(|0, t\rangle + |1, t\rangle\right)\\= \frac{e^{-iE_0t}}{\sqrt{2}}\left(|0\rangle + e^{-i\omega t}|1\rangle\right).$$ We then find the time-dependent average position to be $$\langle x(t)\rangle = \sqrt{\frac{\hbar}{2m\omega}}\cos \omega t.$$ Thus, there is no preferred side of the potential well! The current average position smoothly changes in time from one side of the well to the other. The time averaged expectation value on the other hand is located at $$\langle \bar x\rangle = \frac{1}{T} \int_0^T \langle x(t)\rangle = 0$$ as expected. ($T = \frac{2\pi}{\omega}$, the frequency of the harmonic oscillator.)

• Thanks, that's kind of what I tought, that when you include time the preference disappears, though I didn't know how to prove it so thanks for that, but anyway at a given time it still has a prefered side, so I guess it's like the case of a coherent state, where the gaussian oscillates like a classical harmonic oscillator, but then why does the superposition of two states result into this? Mar 5, 2018 at 12:00
• Intuitively, an oscillator in classical mechanics also has a non-zero x coordinate at a given moment of time. Mar 5, 2018 at 12:06
• Every state of the quantum harmonic oscillator oscillates like this - they all have a period of $T = \frac{2\pi}{\omega}$. The coherent state is the only one that doesn't change its form while it oscillates though. Thus, $\left.\langle x^n\rangle\right|_\text{coh} = \text{const.}$ for $n>1$. Mar 5, 2018 at 13:00
• can you please guide me how can one calculate expectation value of x? Is there any equation to solve? Oct 19, 2022 at 15:46

In addition to the other answer, which is doing a great job, consider this: the superposition $(|0\rangle + |1\rangle)/\sqrt2$ is not any more canonical than $(|0\rangle - |1\rangle)/\sqrt2$ or $(|0\rangle + i |1\rangle)/\sqrt2$ or any other (and they all have different expectation values of $x$, in fact they are different snapshots of the same time evolution). To justify this, take precisely what you say:

I've always been told that the wave function for itself doesn't have any physical meaning, it's only the function squared that we can perceive, [...]

but apply this to the $|0\rangle$ and $|1\rangle$ states separately. You could create a new basis of energy eigenstates – just as good as the "textbook" basis – for example,

$$|0'\rangle = |0\rangle, \quad |1'\rangle = -|1\rangle, \quad |2'\rangle = |2\rangle, \quad\ldots,\quad |n'\rangle = (-1)^n |n\rangle$$

in which "the" superposition state $(|0'\rangle + |1'\rangle)/\sqrt2$ would be mathematically the same as $(|0\rangle - |1\rangle)/\sqrt2$ (with no primes), and thus have a different $\langle x\rangle$ than $(|0\rangle + |1\rangle)/\sqrt2$ does. Now I've just picked one particular normalized solution of

$$H |n\rangle = \left(n+\frac12\right) \hbar \omega |n\rangle$$

different than yours, but there are infinitely many of these.

• In short, adding an $e^{i\theta}$ factor to $|1\rangle$ obtains $\langle x(t)\rangle = \sqrt{\frac{\hbar}{2m\omega}}\cos(\omega t -\theta)$, which again time-averages to $0$. However, we can average over $\theta$ instead to get the same result.
• @Mr.Nobody You won't find the sign of the wave function, but the relative phase of $|0\rangle$ and $|1\rangle$. This is because it contributes to the mod square. Consider in a simple case: $|e^{ix}+e^{iy}|^2=2+e^{i(x-y)}+e^{i(y-x)}=2(1+\cos(x-y))$. The global phase of the wavefunction is unphysical, but relative phases can be identified by measurements. In the above examples we always happened to keep the phase of $|0\rangle$ at zero, so the difference between the two concepts was not evident. But the measurement at an instant only revealed $\theta_1-\theta_0$. There's no contradiction. Mar 6, 2018 at 8:38