Energy in an infinite potential well in one dimension 
We consider a particle in an infinite potential well in one dimension. The particle is describe by the arbitrary wave function $\psi(x)$. 
For our particle, we have to show that:
  \begin{equation}
\langle{E}\rangle\geq{E}_{1}
\end{equation}

This is a problem I found in the Introductory quantum mechanics of Richard L. Liboff. I tried to solve the problem this way.
\begin{equation}
\langle{Q(x,p)}\rangle=\int\Psi^{*}Q\Big(x,\frac{\hbar}{i}\frac{\partial}{\partial{x}}\Big)\Psi{d}x
\end{equation}
Because we can write the energy as $E=\frac{p^2}{2m}$ we have that:
\begin{equation}
\langle{E}\rangle=\int\Psi^{*}\hat{E}\Psi{d}x=-\frac{\hbar^2}{2m}\int\Psi^{*}\frac{\partial^2\Psi}{\partial{x}^2}dx
\end{equation}
But if we use the time-independant Schrödinger equation, we have (because the potential energy is zero):
\begin{equation}
\langle{E}\rangle=\int\Psi^{*}E\Psi{d}x=E\int\Psi^{*}\Psi{d}x=E
\end{equation}
This is what I get, and I think it's logic because the energy conservation. My problem is to talk about the inequality. Do we have $\langle{E}\rangle\geq{E}_{1}$ because $E$ is the summation of all the energy $E_{n}$ associated with a stationary state $\psi_{n}(x)$? My idea is that, because we don't have negative energy, if we only take one term on a summation we have a smaller value than the summation of all $E_{n}$. The only way to b equal mean that $\psi(x)=\psi_{1}(x)$. 
I'm not sure if I'm doing mistakes or not or if my mathematics are rigorous or if there is a little something I don't understand.  
 A: For a infinite quantum well from $x=0$ to $x=a$, the Hamiltonian (energy operator) and the wave function are:
$$H=-\frac{\hbar^2}{2m}\frac{d^2}{dx^2}$$
$$\psi(x)=A\sin kx$$
where A is defined by the normalization condition. And $k=\frac{\sqrt{2mE}}{\hbar}$.
From the boundary condition, we can find out $E_n$.
For the energy expectation value:
$$\langle{E}\rangle=\int\limits_{0}^{a}\psi H\psi dx$$
From those, you can compare $\langle{E}\rangle$ and $E_1$.
A: An arbitrary state can be written as a linear combination of the energy normalized eigenstates ${{\Psi }_{n}}$:
$\Psi =\sum\limits_{n}{{{c}_{n}}{{\Psi }_{n}}}$
and the mean energy would be calculated as:
$\left\langle E \right\rangle :=\left\langle \Psi ,H\Psi  \right\rangle =\sum\limits_{n,m}{c_{n}^{*}{{c}_{m}}\left\langle {{\Psi }_{n}},H{{\Psi }_{m}} \right\rangle }=\sum\limits_{n}{{{\left| {{c}_{n}} \right|}^{2}}{{E}_{n}}}$
where we have used the energy eigenvalues equation: $H{{\Psi }_{n}}={{E}_{n}}{{\Psi }_{n}}$ and the orthogonallity condition: $\left\langle {{\Psi }_{n}},{{\Psi }_{m}} \right\rangle ={{\delta }_{nm}}$. Since ${{E}_{n}}\ge {{E}_{1}}>0\ ,\ \forall n\in \mathbb{N}$ we deduce that:
$\left\langle E \right\rangle =\sum\limits_{n}{{{\left| {{c}_{n}} \right|}^{2}}{{E}_{n}}}\ge {{E}_{1}}\sum\limits_{n}{{{\left| {{c}_{n}} \right|}^{2}}}={{E}_{1}}$
where we have used the normalization condition:
$\left\langle \Psi ,\Psi  \right\rangle =1\Rightarrow \sum\limits_{n}{{{\left| {{c}_{n}} \right|}^{2}}}=1$
