I don't think you can assume E stays the same. What you can assume is that the wave function immediately before and after the transition are the same
I have a hard time getting my head around this one. Math wise I could do the work and re-calculate E, but a) too lazy and b) prefer to think of the physics instead.
I may have jumped on ##E \rightarrow \frac{1}{2} E## and claimed that E stays the same a little too quickly, but on the other hand: the full wave function ##|\psi(x,t)>## and its first derivatives are supposed to be continuous. And the time derivative has E in it. An argument to expect E stays the same ?
Now the exercise has the particle in a well specified state ##|\psi_{E_0}(x,t)> = \phi_{E_0} \; \exp (-i\hbar E_0/t) ##. Potential function changes from ##{1\over 2} {mg\over L} x^2## to ##{1\over 8} {mg\over L} x^2##, giving the impression that, indeed, E changes ?
By now, John must have 'simply' done the ##\ <\phi_{E_0, 4L} | \phi_{E_0, L} >\ ## inner product (answer ?), but I wonder what happened to the difference between ##\ E_{0, L}\ ## and ##\ \sum_{i = 0}^\infty \ <\phi_{E_{2i}, 4L} | \phi_{E_0, L} > ##
Perhaps Vela can shed some light on this ? All I can come up with is that time derivative doesn't have to be continuous under such drastic instantaneous changes.