# Homework Help: Position of particle in a box, is this a valid way to solve?

1. Sep 7, 2009

### Monocles

1. The problem statement, all variables and given/known data
This is problem 2.4 from Griffiths, where he asks to find the expectation value of the position of a particle in a box.

2. Relevant equations
Schrodinger equation.

3. The attempt at a solution

I wrote that

$$\frac{2}{a} \int_0^a x (sin(\frac{n \pi}{a} x))^2 dx = \frac{a}{2} + \frac{2}{a} \int_{-\frac{a}{2}}^{+\frac{a}{2}} x (sin(\frac{n \pi}{a} x))^2 dx = \frac{a}{2}$$

By argument of moving the origin to a/2 and that the integrand becomes odd when you do that, and so the integral equals zero. Is this valid, or do I need to tidy up the integral some more?

2. Sep 7, 2009

### kuruman

You need to be a bit careful here because the symmetric particle in the box potential admits both even and odd solutions, i.e. sines and cosines. I would recommend that you actually do the integral and use your argument not as proof but as validation why the answer a/2 makes sense.