Confusion between the de Broglie wavelength of a particle and wave packets So I learned that the de Broglie wavelength of a particle, $\lambda = \frac{h}{p}$, where h is Planck's constant and p is the momentum of the particle. I also learned that a quantum mechanics description of a particle is a wave packet. I learned that a wave packet is a summation of different basis functions overlapped over each other at say $x = 0$, and these basis functions are the wave functions, $\Psi(x,t)$. Or is it the probability density, $|\Psi(x,t)|^2$ ??? Please correct me on this.
I learned that the more localized the wave packet is in position space, the more un-localized or uncertain you are about the spread of momentum functions. Please also edit my statement I just said because I don't think I stated it in the best way.
My question is, you have a particle that is represented by a wave packet that is localized, thus, it has a spread of momentum, so how can you then know it's de Broglie wavelength? Do you average together all the different momentum the particle has and then plug that average momentum into $\lambda = \frac{h}{\langle p\rangle}$ ??
 A: I think it would help you to study the theory of Fourier transforms! Then this momentum/position duality becomes much more apparent.
A wavepacket is, like you write, a sum of many momentum states (not probability densities). If you look in the momentum space, the wider the spread of the momentum states, the smaller the spread of the position states will be. This is quite obvious from the Fourier theory which is why I recommend studying this. The Heisenberg uncertainty relation of position/momentum is related to this duality - when you make the momentum spread thinner, the position spread will increase and vice versa so there is a non-zero minimum of uncertainty (width of the distribution) where you have made both position and momentum as localized as you can.
The de Broglie relations simply relate momentum p to wavelength lambda - actually not more interesting than the simple observation that a sinusodial wave has a frequency and a wavelength. Short wavelength means higher momentum. So if you have a state with an uncertainty in momentum you also have an uncertainty in the de Broglie wavelength. If you want to take an average of it, go ahead as long as you know it's an average of a distribution of a certain width. This will be OK for many applications, but for some the detailed spread will be crucial also of course. 
Addendum: Also please note that the position and momentum descriptions are a duality. You cannot specify both, the full information of the state is in either one of them and then you can Fourier-transform between them to extract a better understanding of the problem or extract some numerical predictions etc. This point is lost in some introductions so I'll take the opportunity here to mention it :)
A: Bjorn gave a great answer.
To condense: if you can determine the space position of the particle the momentum will be uncertain [wave packet spread]. If the space position is indeterminate then the momentum-and-wavelength will be relatively certain/defined. Wavelength is always an average, sometime a close average sometimes not. If you conduct an experiment with a large number of wave-like particle the dispersion average will approach the formula wavelength...
Paul
