# The Wave Function 04

— 1.5. Momentum and other Dynamical quantities —

Let us suppose that we have a particle that is described by the wave function ${\Psi}$ then the expectation value of its position is (as we saw in The Wave Function 02):

$\displaystyle =\int_{-\infty}^{+\infty}x|\Psi(x,t)|^2\, dx$

Neophytes interpret the previous equations as if it was saying that the expectation value coincides with the average of various measurements of the position of a particle that is described by ${\Psi}$. This interpretation is wrong since the first measurement will make the wave function collapse to the value that is actually obtained and if the following measurements of the position are done right away they’ll just be of the same value of the first measurement.

Actually ${}$ is the average of position measurements of particles that are all described by the state ${\Psi}$. That is to say that we have two ways of actually accomplishing what is implied by the previous interpretation of ${}$:

1. We have a single particle. Then after a position measurement is made we have to able to make the particle to return to its ${\Psi}$ state before we make a new measurement.
2. We have a collection – a statistical ensemble is a more respectable name – of a great number of particles (in order for it to be statistically significant) and we arrange them all to be in state ${\Psi}$. If we perform the measurement of the position of all this particles, then average of the measurements should be ${}$.

To put it more succinctly:

The expectation value is the average of repeated measurements on an ensemble of identically prepared systems.

Since ${\Psi}$ is a time dependent mathematical object it is obvious that ${}$ also is a time dependent quantity:

{\begin{aligned} \dfrac{d}{dt}&= \int_{-\infty}^{+\infty}x\dfrac{\partial}{\partial t}|\Psi|^2\, dx \\ &= \dfrac{i\hbar}{2m}\int_{-\infty}^{+\infty}x\dfrac{\partial}{\partial x}\left( \Psi^*\dfrac{\partial \Psi}{\partial x}-\dfrac{\partial \Psi^*}{\partial x}\Psi \right)\, dx \\ &= -\dfrac{i\hbar}{2m}\int_{-\infty}^{+\infty}\left( \Psi^*\dfrac{\partial \Psi}{\partial x}-\dfrac{\partial \Psi^*}{\partial x}\Psi \right)\,dx \\ &= -\dfrac{i\hbar}{m}\int_{-\infty}^{+\infty}\left( \Psi^*\dfrac{\partial \Psi}{\partial x}\right)\,dx \end{aligned}}

where we have used integration by parts and the fact that the wave function has to be square integrable which is to say that the function is vanishingly small as ${x}$ approaches infinity.

(Allow me to go on a tangent here but I just want to say that rigorously speaking the Hilbert space isn’t the best mathematical space to construct the mathematical formalism of quantum mechanics. The problem with the Hilbert space approach to quantum mechanics is two fold:

1. the functions that are in Hilbert space are necessarily square integrable. The problem is that many times we need to calculate quantities that depend not on a given function but on its derivative (for example), but just because a function is square integrable it doesn’t mean that its derivative also is. Hence we don’t have any mathematical guarantee that most of the integrals that we are computing actually converge.
2. The second problem is that when we are dealing with continuous spectra (later on we’ll see what this means) the eigenfunctions (we’ll see what this means) are divergent

The proper way of doing quantum mechanics is by using rigged Hilbert spaces. A good first introduction to rigged Hilbert spaces and their use in Quantum Mechanics is given by Rafael de la Madrid in the article The role of the rigged Hilbert space in Quantum Mechanics )

The previous equation doesn’t express the average velocity of a quantum particle. In our construction of quantum mechanic nothing allows us to talk about the velocity of particle. In fact we don’t even know what the meaning of

velocity of a particle

is in quantum mechanics!

Since a particle doesn’t have a definitive position prior to is measurement it also can’t have a well defined velocity. Later on we’ll see how how to construct the probability density for velocity in the state ${\Psi}$.

For the purposes of the present section we’ll just postulate that the expectation value of the velocity is equal to the time derivative of the expectation value of position.

$\displaystyle =\dfrac{d}{dt} \ \ \ \ \ (24)$

As we saw in the lagrangian formalism and in the hamiltonian formalism posts of our blog it is more customary (since it is more powerful) to work with momentum instead of velocity. Since ${p=mv}$ the relevant equation for momentum is;

$\displaystyle

=m\dfrac{d}{dt}=-i\hbar\int_{-\infty}^{+\infty}\left( \Psi^*\dfrac{\partial \Psi}{\partial x}\right)\,dx \ \ \ \ \ (25)$

Since ${x}$ represents the position operator operator we can say in an analogous way that

$\displaystyle \frac{\hbar}{i}\frac{\partial}{\partial x}$

represents the momentum operator. A way to see why this definition makes sense is to rewrite the definition of the expectation value of the position

$\displaystyle =\int \Psi^* x \Psi \, dx$

and to rewrite equation 25 in a more compelling way

$\displaystyle

= \int \Psi^*\left( \frac{\hbar}{i}\frac{\partial}{\partial x} \right) \Psi \, dx$

After knowing how to calculate the expectation value of these two dynamical quantities the question now is how can one calculate the expectation value of other dynamical quantities of interest?

The thing is that all dynamical quantities can be expressed as functions of of ${x}$ and ${p}$. Taking this into account one just has to write the appropriate function of the quantity of interest in terms of ${p}$ and ${x}$ and then calculate the expectation value.

In a more formal (hence more respectable) way the equation for the expectation value of the dynamical quantity ${Q=Q(x,p)}$ is

$\displaystyle =\int\Psi^*Q\left( x,\frac{\hbar}{i}\frac{\partial}{\partial x} \right)\Psi\, dx \ \ \ \ \ (26)$

As an example let us look into what would be the relevant expression for the kinetic energy the relevant definition can be found at Newtonian Mechanics 01. Henceforth we’ll use ${T}$ to denote the kinetic energy instead of ${K}$ in order to use the same notation that is used in Introduction to Quantum Mechanics (2nd Edition).

$\displaystyle T=\frac{1}{2}mv^2=\frac{p^2}{2m}$

Hence the expectation value is

$\displaystyle =-\frac{\hbar ^2}{2m}\int\Psi^*\frac{\partial ^2\Psi}{\partial x^2}\, dx \ \ \ \ \ (27)$

 Exercise 3 Why can’t you do integration by parts directly on $\displaystyle \frac{d}{dt}=\int x\frac{\partial}{\partial t}|\Psi|^2 \, dx$ pull the time derivative over onto ${x}$, note that ${\partial x/\partial t=0}$ and conclude that ${d/dt=0}$? Because integration by parts can only be used when the differentiation and integration are done with the same variable.

 Exercise 4 Calculate $\displaystyle \frac{d}{dt}$ First lets us remember the the Schroedinger equation: $\displaystyle \frac{\partial \Psi}{\partial t}=\frac{i\hbar}{2m}\frac{\partial^2\Psi}{\partial x^2}-\frac{i}{\hbar}V\Psi \ \ \ \ \ (28)$ And its complex conjugate $\displaystyle \frac{\partial \Psi^*}{\partial t}=-\frac{i\hbar}{2m}\frac{\partial^2\Psi^*}{\partial x^2}+\frac{i}{\hbar}V\Psi^* \ \ \ \ \ (29)$ for the time evolution of the expectation value of momentum is {\begin{aligned} \dfrac{d}{dt} &= \dfrac{d}{dt}\int\Psi ^* \dfrac{\hbar}{i}\dfrac{\partial \Psi}{\partial x}\, dx\\ &= \dfrac{\hbar}{i}\int \dfrac{\partial}{\partial t}\left( \Psi ^* \dfrac{\partial \Psi}{\partial x}\right)\, dx\\ &= \dfrac{\hbar}{i}\int\left( \dfrac{\partial \Psi^*}{\partial t}\dfrac{\partial \Psi}{\partial x}+\Psi^* \dfrac{\partial}{\partial x}\dfrac{\partial \Psi}{\partial t} \right) \, dx\\ &= \dfrac{\hbar}{i}\int \left[ \left( -\dfrac{i\hbar}{2m}\dfrac{\partial^2\Psi^*}{\partial x^2}+\dfrac{i}{\hbar}V\Psi^* \right)\dfrac{\partial \Psi}{\partial x} + \Psi^*\dfrac{\partial}{\partial x}\left( \dfrac{i\hbar}{2m}\dfrac{\partial^2\Psi}{\partial x^2}-\dfrac{i}{\hbar}V\Psi \right)\right]\, dx\\\ &= \dfrac{\hbar}{i}\int \left[ -\dfrac{i\hbar}{2m}\left(\dfrac{\partial^2\Psi^*}{\partial x^2}\dfrac{\partial\Psi}{\partial x}-\Psi^*\dfrac{\partial ^3 \Psi}{\partial x^3} \right)+\dfrac{i}{\hbar}\left( V\Psi ^*\dfrac{\partial\Psi}{\partial x}-\Psi ^*\dfrac{\partial (V\Psi)}{\partial x}\right)\right]\, dx \end{aligned}} First we’ll calculate the first term of the integral (ignoring the constant factors) doing integration by parts (remember that the boundary terms are vanishing) two times {\begin{aligned} \int \left(\dfrac{\partial^2\Psi^*}{\partial x^2}\dfrac{\partial\Psi}{\partial x}-\Psi^*\dfrac{\partial ^3 \Psi}{\partial x^3}\right)\, dx &= \left[ \dfrac{\partial \Psi^*}{\partial x^2} \dfrac{\partial \Psi}{\partial x}\right]-\int\dfrac{\partial \Psi^*}{\partial x}\dfrac{\partial ^2 \Psi}{\partial x^2}\, dx- \int \Psi^*\dfrac{\partial ^3 \Psi}{\partial x^3}\, dx \\ &=-\left[ \Psi ^*\dfrac{\partial ^2 \Psi}{\partial x^2} \right]+\int \Psi^*\dfrac{\partial ^3 \Psi}{\partial x^3}\, dx - \int \Psi^*\dfrac{\partial ^3 \Psi}{\partial x^3}\, dx \\ &= 0 \end{aligned}} Then we’ll calculate the second term of the integral {\begin{aligned} \int \left( V\Psi ^*\dfrac{\partial\Psi}{\partial x}-\Psi ^*\dfrac{\partial (V\Psi)}{\partial x} \right)\, dx &= \int \left( V\Psi ^*\dfrac{\partial\Psi}{\partial x}-\Psi ^* \dfrac{\partial V}{\partial x}\Psi-\Psi ^*V\dfrac{\partial \Psi}{\partial x} \right)\, dx\\ &= -\int\Psi ^* \dfrac{\partial V}{\partial x}\Psi\, dx\\ &=<-\dfrac{\partial V}{\partial x}> \end{aligned}} In conclusion it is $\displaystyle \frac{d}{dt}=<-\dfrac{\partial V}{\partial x}> \ \ \ \ \ (30)$ Hence the expectation value of the momentum operator obeys Newton’s Second Axiom. The previous result can be generalized and its generalization is known in the Quantum Mechanics literature as Ehrenfest’s theorem

# The Wave Function 03

— 1.4. Normalization —

The Scroedinger equation is a linear partial differential equation. As such, if ${\Psi(x,t)}$ is a solution to it, then ${A\Psi(x,t)}$ (where ${A}$ is a complex constant) also is a solution.

Does this mean that a physical problem has an infinite number of solutions in Quantum Mechanics? It doesn’t! The thing is that besides the The Scroedinger equation one also has condition 11 to take into account. Stating 11 for the wave function:

$\displaystyle \int_{-\infty}^{+\infty}|\Psi (x,t)|^2dx=1 \ \ \ \ \ (15)$

The previous equations states the quite obvious fact that the particle under study has to be in some place at a given instant.

Since ${A}$ was a complex constant the normalization condition fixes ${A}$ in absolute value but can’t tell us nothing regarding its phase. Apparently once again one is haunted with the perspective of having an infinite number of solutions to any given physical problem. The things is that this time the phase doesn’t carry any physical significance (a fact that will be demonstrated later) and thus we actually have just one physical solution.

In the previous discussion one is obviously assuming that the wave function is normalizable. That is to say that the function doesn’t blow up and vanishes quickly enough at infinity so that the integral being computed makes sense.

At this level it is customary to say that these wave functions don’t represent physical states but that isn’t exactly true. A wave function that isn’t normalizable because integral is infinite might represent a beam of particles in a scattering experiment. The fact that the integral diverges to infinity can then be said to represent the fact that beam is composed by an infinite amount of particles.

While the identically null wave function represents the absence of particles.

A question that now arises has to do with the consistency of our normalization and this is a very sensible question. The point is that we normalize the Schroedinger equation for a given time instant, so how does one know that the normalization holds for other times?

Let us look into the time evolution of our normalization condition 15.

$\displaystyle \frac{d}{dt}\int_{-\infty}^{+\infty}|\Psi (x,t)|^2dx=\int_{-\infty}^{+\infty}\frac{\partial}{\partial t}|\Psi (x,t)|^2dx \ \ \ \ \ (16)$

Calculating the derivative under the integral for the right hand side of the previous equation

{\begin{aligned} \frac{\partial}{\partial t}|\Psi (x,t)|^2&=\frac{\partial}{\partial t}(\Psi^* (x,t)\Psi (x,t))\\ &=\Psi^* (x,t)\frac{\partial\Psi (x,t)}{\partial t}+\frac{\partial \Psi^* (x,t)}{\partial t}\Psi (x,t) \end{aligned}}

The complex conjugate of the Schroedinger equation is

$\displaystyle \frac{\partial \Psi^*(x,t)}{\partial t}=-\frac{i\hbar}{2m}\frac{\partial^2\Psi^*(x,t)}{\partial x^2}+\frac{i}{\hbar}V\Psi^*(x,t) \ \ \ \ \ (17)$

Hence for the derivative under the integral

{\begin{aligned} \frac{\partial}{\partial t}|\Psi (x,t)|^2&=\frac{\partial}{\partial t}(\Psi^* (x,t)\Psi (x,t))\\ &=\Psi^* (x,t)\frac{\partial\Psi (x,t)}{\partial t}+\frac{\partial \Psi^* (x,t)}{\partial t}\Psi (x,t)\\ &=\frac{i\hbar}{2m}\left( \Psi^*(x,t)\frac{\partial^2\Psi(x,t)}{\partial x^2}-\frac{\partial^2\Psi^*(x,t)}{\partial x^2}\Psi (x,t)\right)\\ &=\frac{\partial}{\partial x}\left[ \frac{i\hbar}{2m}\left( \Psi^*(x,t)\frac{\partial\Psi(x,t)}{\partial x}-\frac{\partial\Psi^*(x,t)}{\partial x}\Psi(x,t) \right) \right] \end{aligned}}

Getting back to 16

$\displaystyle \frac{d}{dt}\int_{-\infty}^{+\infty}|\Psi (x,t)|^2dx=\frac{i\hbar}{2m}\left[ \Psi^*(x,t)\frac{\partial\Psi(x,t)}{\partial x}-\frac{\partial\Psi^*(x,t)}{\partial x}\Psi(x,t) \right]_{-\infty}^{+\infty} \ \ \ \ \ (18)$

Since we’re assuming that our wave function is normalizable the wave function (and its complex conjugate) must vanish for ${+\infty}$ and ${-\infty}$.

In conclusion

$\displaystyle \frac{d}{dt}\int_{-\infty}^{+\infty}|\Psi (x,t)|^2dx=0$

In conclusion one can say that if one normalizes the wave equation for a given time interval it stays normalized for all time intervals.

 Exercise 1 At time ${t=0}$ a particle is represented by the wave function $\displaystyle \Psi(x,0)=\begin{cases} Ax/a & \text{if } 0\leq x\leq a\\ A(b-x)/(b-a) & \text{if } a\leq x\leq b \\ 0 & \text{otherwise}\end{cases} \ \ \ \ \ (19)$   where ${A}$, ${a}$ and ${b}$ are constants. Normalize ${\Psi}$. {\begin{aligned} 1&=\int_{-\infty}^{+\infty} |\Psi|^2\,dx\\ &=\int_0^a|\Psi|^2\,dx+\int_a^b|\Psi|^2\,dx\\ &=\dfrac{|A|^2}{a^2}\int_0^a|x^2\,dx+\dfrac{|A|^2}{(b-a)^2}\int_a^b(b-x)^2\,dx\\ &=\dfrac{|A|^2}{a^2}\left[ \dfrac{x^3}{3} \right]_0^a+\dfrac{|A|^2}{(b-a)^2}\left[ \dfrac{(b-x)^3}{3} \right]_a^b\\ &=\dfrac{|A|^2a}{3}+\dfrac{|A|^2}{(b-a)^2}\dfrac{(b-a)^3}{3}\\ &=\dfrac{|A|^2a}{3}+|A|^2\dfrac{b-a}{3}\\ &=\dfrac{b|A|^2}{3} \end{aligned}} Hence for ${A}$ it is $\displaystyle A=\sqrt{\dfrac{3}{b}}$ Sketch ${\Psi(x,0)}$In ${0\leq x \leq a}$ ${\Psi(x,0)}$ is a strictly increasing function that goes from ${0}$ to ${A}$.In ${a \leq x \leq b}$ ${\Psi(x,0)}$ is strictly decreasing function that goes from ${A}$ to ${0}$.Hence the plot of ${\Psi(x,0)}$ is (choosing the following values ${a=1}$, ${b=2}$ and ${A=\sqrt{b}=\sqrt{2}}$):   Where is the particle most likely to be found at ${t=0}$? Since ${x=a}$ is maximum of the ${\Psi}$ function the most likely value for the particle to be found is at ${x=a}$. What is the probability of finding the particle to the left of ${a}$? Check the answers for ${b=a}$ and ${b=2a}$.{\begin{aligned} P(xAt first let us look into the ${b=a}$ limiting case. We can imagine that this is the end result of ${b}$ getting nearer and nearer to ${a}$. That is to say that the domain of the strictly decreasing part of ${\Psi(x,0)}$ is getting shorter and shorter and when finally ${b=a}$ ${\Psi(x,0)}$ doesn’t have a domain where its is strictly decreasing and ${\Psi(x,0)}$ is defined by its strictly increasing and vanishing features (in the appropriate domains). That is to say that to the right of ${a}$ the function is ${0}$. Hence the probability of the particle being found to the left of ${a}$ is ${1}$.From the previous calculation ${P(x which is indeed the correct result. The ${b=2a}$ case can be analyzed in a different way. In this case: ${x=a}$ is the half point of the domain of ${\Psi(x,0)}$ where ${\Psi(x,0)}$ is non vanishing (end points of the domain are excluded). ${\Psi(x,0)}$ is strictly increasing in the first half of the domain (${0\leq x\leq a}$). ${\Psi(x,0)}$ is strictly decreasing in the second half of the domain (${a\leq x\leq b}$). ${\Psi(x,0)}$ is continuous. Thus one can conclude that ${\Psi(x,0)}$ is symmetric around ${a}$ and consequently the probability of the particle being found to the left of ${a}$ has to be ${1/2}$. From the previous calculation ${P(x which is indeed the correct result. What is the expectation value of ${x}$?{\begin{aligned} &= \int_a^b x|\Psi|^2\,dx\\ &=\dfrac{|A|^2}{a^2}\int_0^a x^3\,dx+\dfrac{|A|^2}{(b-a)^2}\int_a^b x(b-x)^2\,dx\\ &=\dfrac{|A|^2}{a^2}\left[ \dfrac{x^4}{4} \right]_0^a+\dfrac{|A|^2}{(b-a)^2}\left[ 1/2x^2b^2-2/3x^3b+x^4/4 \right]_a^b\\ &=\dfrac{2a+b}{4} \end{aligned}}
 Exercise 2 Consider the wave function $\displaystyle \Psi(x,t)=Ae^{-\lambda |x|}e^{-i\omega t} \ \ \ \ \ (20)$   where ${A}$, ${\lambda}$ and ${\omega}$ are positive real constants. Normalize ${\Psi}$ {\begin{aligned} 1&=\int_{-\infty}^{+\infty} |\Psi|^2\,dx\\ &=\int_{-\infty}^{+\infty} |A|^2e^{-2\lambda |x|}\,dx\\ &=2|A|^2\int_0^{+\infty}e^{-2\lambda |x|}\,dx \\ &=2|A|^2\int_0^{+\infty}e^{-2\lambda x}\,dx \\ &=-\dfrac{|A|^2}{\lambda}\left[ e^{-2\lambda x} \right]_0^{+\infty}\\ &=\dfrac{|A|^2}{\lambda} \end{aligned}} Hence it is $\displaystyle A=\sqrt{\lambda}$ Determine ${}$ and ${}${\begin{aligned} &=\int_{-\infty}^{+\infty} x|\Psi|^2\,dx\\ &=|A|^2\int_{-\infty}^{+\infty} xe^{-2\lambda |x|}\,dx\\ &=0 \end{aligned}}The integral is vanishing because we’re calculating the integral of an odd function between symmetrical limits.{\begin{aligned} &=\int_{-\infty}^{+\infty} x^2|\Psi|^2\,dx\\ &=2\lambda\int_0^{+\infty} x^2e^{-2\lambda x}\,dx\\ &=2\lambda\int_0^{+\infty} \dfrac{1}{4}\dfrac{\partial^2}{\partial \lambda ^2}\left( e^{-2\lambda x} \right)\,dx\\ &=\dfrac{\lambda}{2} \dfrac{\partial^2}{\partial \lambda ^2}\int_0^{+\infty}e^{-2\lambda\,dx} x \,dx\\ &= \dfrac{\lambda}{2} \dfrac{\partial^2}{\partial \lambda ^2} \left[ -\dfrac{e^{-2\lambda\,dx}}{2\lambda} \right]_0^{+\infty}\\ &= \dfrac{\lambda}{2}\dfrac{\partial^2}{\partial \lambda ^2}\left(\dfrac{1}{2\lambda} \right)\\ &=\dfrac{\lambda}{2}\dfrac{\partial}{\partial \lambda}\left(-\dfrac{1}{\lambda ^2} \right)\\ &=\dfrac{\lambda}{2}\dfrac{1}{\lambda^3}\\ &= \dfrac{1}{2\lambda^2} \end{aligned}} Find the standard deviation of ${x}$. Sketch the graph of ${\Psi ^2}$. What is the probability that the particle will be found outside the range ${[-\sigma,+\sigma]}$? $\displaystyle \sigma ^2=-^2=\frac{1}{2\lambda ^2}-0=\frac{1}{2\lambda ^2}$ Hence the standard deviation is $\displaystyle \sigma=\dfrac{\sqrt{2}}{2\lambda}$ The square of the wave function is proportional to ${e^{-2\lambda |x|}}$. Dealing for piecewise definitions of the square of the wave function, its first derivative in order to ${x}$ and its second derivative in order to ${x}$ $\displaystyle |\Psi|^2=\begin{cases} e^{2\lambda x} & \text{if } x < 0\\ e^{-2\lambda x} & \text{if } x \geq 0 \end{cases} \ \ \ \ \ (21)$   $\displaystyle \dfrac{\partial}{\partial x}|\Psi|^2=\begin{cases} 2\lambda e^{2\lambda x} & \text{if } x < 0\\ -2\lambda e^{-2\lambda x} & \text{if } x \geq 0 \end{cases} \ \ \ \ \ (22)$   $\displaystyle \dfrac{\partial ^2}{\partial x ^2}|\Psi|^2=\begin{cases} 4\lambda ^2 e^{2\lambda x} & \text{if } x < 0\\ 4\lambda ^2 e^{-2\lambda x} & \text{if } x \geq 0 \end{cases} \ \ \ \ \ (23)$   As we can see the first derivative of ${|\Psi|^2}$ changes its sign on ${0}$ from positive to negative. Hence it was strictly increasing before ${0}$ and it is strictly decreasing after ${0}$. Hence ${0}$ is a maximum of ${|\Psi|^2}$. The second derivative is always positive so ${|\Psi|^2}$ is always concave up (convex). Hence its graphical representation is: The probability that the particle is to be found outside the range ${[-\sigma, +\sigma ]}$ is {\begin{aligned} P(-\sigma, +\sigma)&= 2\int_\sigma^{+\infty}|\Psi|^2\,dx\\ &= 2\lambda\int_\sigma^{+\infty}e^{2\lambda x}\\ &= 2\lambda\left[ -\dfrac{e^{2\lambda x}}{2\lambda} \right]_\sigma^{+\infty}\\ &=\lambda \dfrac{e^{2\lambda x}}{2\lambda}\\ &=e^{-2\lambda\dfrac{\sqrt{2}}{2\lambda}}\\ &=e^{-\sqrt{2}} \end{aligned}}

# The Wave Function Exercises 01

Exercise 1

• ${^2=21^2=441}$

${=1/N\sum j^2N(J)=\dfrac{6434}{14}=459.6}$

• Calculating for each ${\Delta j}$
 ${j}$ ${\Delta j=j-}$ 14 ${14-21=-7}$ 15 ${15-21=-6}$ 16 ${16-21=-5}$ 22 ${22-21=1}$ 24 ${24-21=3}$ 25 ${25-21=4}$

Hence for the variance it follows

${\sigma ^2=1/N\sum (\Delta j)^2N(j)=\dfrac{260}{14}=18.6}$

Hence the standard deviation is

$\displaystyle \sigma =\sqrt{18.6}=4.3$

• ${\sigma^2=-^2=459.6-441=18.6}$

And for the standard deviation it is

$\displaystyle \sigma =\sqrt{18.6}=4.3$

Which confirms the second equation for the standard deviation.

Exercise 2 Consider the first ${25}$ digits in the decimal expansion of ${\pi}$.

• What is the probability of getting each of the 10 digits assuming that one selects a digit at random.

The first 25 digits of the decimal expansion of ${\pi}$ are

$\displaystyle \{3, 1, 4, 1, 5, 9, 2, 6, 5, 3, 5, 8, 9, 7, 9, 3, 2, 3, 8, 4, 6, 2, 6, 4, 3\}$

Hence for the digits it is

 ${N(0)=0}$ ${P(0)=0}$ ${N(1)=2}$ ${P(1)=2/25}$ ${N(2)=3}$ ${P(2)=3/25}$ ${N(3)=5}$ ${P(3)=1/5}$ ${N(4)=3}$ ${P(4)=3/25}$ ${N(5)=3}$ ${P(5)=3/25}$ ${N(6)=3}$ ${P(6)=3/25}$ ${N(7)=1}$ ${P(7)=1/25}$ ${N(8)=2}$ ${P(8)=2/25}$ ${N(9)=3}$ ${P(9)=3/25}$
• The most probable digit is ${5}$. The median digit is ${4}$. The average is ${\sum P(i)N(i)=4.72}$.

• ${\sigma=2.47}$

 Exercise 3 The needle on a broken car is free to swing, and bounces perfectly off the pins on either end, so that if you give it a flick it is equally likely to come to rest at any angle between ${0}$ and ${\pi}$. Along the ${\left[0,\pi\right]}$ interval the probability of the needle flicking an angle ${d\theta}$ is ${d\theta/\pi}$. Given the definition of probability density it is ${\rho(\theta)=1/\pi}$. Additionally the probability density also needs to be normalized. $\displaystyle \int_0^\pi \rho(\theta)d\theta=1\Leftrightarrow\int_0^\pi 1/\pi d\theta=1$ which is trivially true. The plot for the probability density is Compute ${\left\langle\theta \right\rangle}$, ${\left\langle\theta^2 \right\rangle}$ and ${\sigma}$. {\begin{aligned} \left\langle\theta \right\rangle &= \int_0^\pi\frac{\theta}{\pi}d\theta\\ &= \frac{1}{\pi}\int_0^\pi\theta d\theta\\ &= \frac{1}{\pi} \left[ \frac{\theta^2}{2} \right]_0^\pi\\ &= \frac{\pi}{2} \end{aligned}} For ${\left\langle\theta^2 \right\rangle}$ it is {\begin{aligned} \left\langle\theta^2 \right\rangle &= \int_0^\pi\frac{\theta^2}{\pi}d\theta\\ &= \frac{1}{\pi} \left[ \frac{\theta^3}{3} \right]_0^\pi\\ &= \frac{\pi^2}{3} \end{aligned}} The variance is ${\sigma^2=\left\langle\theta^2 \right\rangle-\left\langle\theta\right\rangle^2 =\dfrac{\pi^2}{3}-\dfrac{\pi^2}{4}=\dfrac{\pi^22}{12}}$. And the standard deviation is ${\sigma=\dfrac{\pi}{2\sqrt{3}}}$. Compute ${\left\langle\sin\theta\right\rangle}$, ${\left\langle\cos\theta\right\rangle}$ and ${\left\langle\cos^2\theta\right\rangle}$. {\begin{aligned} \left\langle\sin\theta \right\rangle &= \int_0^\pi\frac{\sin\theta}{\pi}d\theta\\ &= \frac{1}{\pi}\int_0^\pi\sin\theta d\theta\\ &= \frac{1}{\pi} \left[ -\cos\theta \right]_0^\pi\\ &= \frac{2}{\pi} \end{aligned}} and {\begin{aligned} \left\langle\cos\theta \right\rangle &= \int_0^\pi\frac{\cos\theta}{\pi}d\theta\\ &= \frac{1}{\pi}\int_0^\pi\cos\theta d\theta\\ &= \frac{1}{\pi} \left[ \sin\theta \right]_0^\pi\\ &= 0 \end{aligned}} We’ll leave ${\left\langle\cos\theta^2 \right\rangle}$ as an exercise for the reader. As a hint remember that ${\cos^2\theta=\dfrac{1+\cos(2\theta)}{2}}$.

 Exercise 4 In exercise ${1.1}$ it was shown that the the probability density is $\displaystyle \rho(x)=\frac{1}{2\sqrt{hx}}$ Hence the mean value of ${x}$ is {\begin{aligned} \left\langle x \right\rangle &= \int_0^h\frac{x}{2\sqrt{hx}}dx\\ &= \frac{h}{3} \end{aligned}} For ${\left\langle x^2 \right\rangle}$ it is {\begin{aligned} \left\langle x^2 \right\rangle &= \int_0^h\frac{x}{2\sqrt{hx}}dx\\ &= \frac{1}{2\sqrt{h}}\int_0^h x^{3/2}dx\\ &= \frac{1}{2\sqrt{h}}\left[\frac{2}{5}x^{5/2} \right]_0^h\\ &= \frac{h^2}{5} \end{aligned}} Hence the variance is $\displaystyle \sigma^2=\left\langle x^2 \right\rangle-\left\langle x \right\rangle^2=\frac{h^2}{5}-\frac{h^2}{9}=\frac{4}{45}h^2$ and the standard deviation is $\displaystyle \sigma=\frac{2h}{3\sqrt{5}}$ For the distance to the mean to be more than one standard deviation away from the average we have two alternatives. The first is the interval ${\left[0,\left\langle x \right\rangle+\sigma\right]}$ and the second is ${\left[\left\langle x \right\rangle+\sigma,h\right]}$. Hence the total probability is the sum of these two probabilities. Let ${P_1}$ denote the probability of the first interval and ${P_2}$ denote the probability of the second interval. {\begin{aligned} P_1 &= \int_0^{\left\langle x \right\rangle-\sigma}\frac{1}{2\sqrt{hx}}dx\\ &= \frac{1}{2\sqrt{h}}\left[2x^{1/2} \right]_0^{\left\langle x \right\rangle-\sigma}\\ &= \frac{1}{\sqrt{h}}\sqrt{\frac{h}{3}-\frac{2h}{3\sqrt{5}}}\\ &=\sqrt{\frac{1}{3}-\frac{2}{3\sqrt{5}}} \end{aligned}} Now for the second interval it is {\begin{aligned} P_2 &= \int_{\left\langle x \right\rangle+\sigma}^h\frac{1}{2\sqrt{hx}}dx\\ &= \ldots\\ &=1-\sqrt{\frac{1}{3}+\frac{2}{3\sqrt{5}}} \end{aligned}} Hence the total probability ${P}$ is ${P=P_1+P_2}$ {\begin{aligned} P&=P_1+P_2\\ &= \sqrt{\frac{1}{3}-\frac{2}{3\sqrt{5}}}+1-\sqrt{\frac{1}{3}+\frac{2}{3\sqrt{5}}}\\ &\approx 0.3929 \end{aligned}}

 Exercise 5 The probability density is ${\rho(x)=Ae^{-\lambda(x-a)^2}}$ Determine ${A}$. Making the change of variable ${u=x-a}$ (${dx=du}$) the normalization condition is {\begin{aligned} 1 &= A\int_{-\infty}^\infty e^{-\lambda u^2}du\\ &= A\sqrt{\frac{\pi}{\lambda}} \end{aligned}} Hence for ${A}$ it is $\displaystyle A=\sqrt{\frac{\lambda}{\pi}}$ Find ${\left\langle x \right\rangle}$, ${\left\langle x^2 \right\rangle}$ and ${\sigma}$. {\begin{aligned} \left\langle x \right\rangle &= \sqrt{\frac{\lambda}{\pi}}\int_{-\infty}^\infty (u+a)e^{-\lambda u^2}du\\ &= \sqrt{\frac{\lambda}{\pi}}\left(\int_{-\infty}^\infty ue^{-\lambda u^2}du+a\int_{-\infty}^\infty e^{-\lambda u^2}du \right)\\ &=\sqrt{\frac{\lambda}{\pi}}\left( 0+a\sqrt{\frac{\pi}{\lambda}} \right)\\ &= a \end{aligned}} If you don’t see why ${\displaystyle\int_{-\infty}^\infty ue^{-\lambda u^2}du=0}$ check this post on my other blog. For ${\left\langle x^2 \right\rangle}$ it is {\begin{aligned} \left\langle x^2 \right\rangle &= \sqrt{\frac{\lambda}{\pi}}\int_{-\infty}^\infty (u+a)^2e^{-\lambda u^2}du\\ &= \sqrt{\frac{\lambda}{\pi}}\left(\int_{-\infty}^\infty u^2e^{-\lambda u^2}du+2a\int_{-\infty}^\infty u e^{-\lambda u^2}du+a^2\int_{-\infty}^\infty e^{-\lambda u^2}du \right) \end{aligned}} Now ${\displaystyle 2a\int_{-\infty}^\infty u e^{-\lambda u^2}du=0}$ as in the previous calculation. For the third term it is ${\displaystyle a^2\int_{-\infty}^\infty e^{-\lambda u^2}du=a^2\sqrt{\frac{\pi}{\lambda}}}$. The first integral is the hard one and a special technique can be employed to evaluate it. {\begin{aligned} \int_{-\infty}^\infty u^2e^{-\lambda u^2}du &= \int_{-\infty}^\infty-\frac{d}{d\lambda}\left( e^{-\lambda u^2} \right)du\\ &= -\frac{d}{d\lambda}\int_{-\infty}^\infty e^{-\lambda u^2}du\\ &=-\frac{d}{d\lambda}\sqrt{\frac{\pi}{\lambda}}\\ &=\frac{1}{2}\sqrt{\frac{\pi}{\lambda^3}} \end{aligned}} Hence it is {\begin{aligned} \left\langle x^2 \right\rangle &= \sqrt{\frac{\lambda}{\pi}}\int_{-\infty}^\infty (u+a)^2e^{-\lambda u^2}du\\ &= \sqrt{\frac{\lambda}{\pi}}\left(\int_{-\infty}^\infty u^2e^{-\lambda u^2}du+2a\int_{-\infty}^\infty u e^{-\lambda u^2}du+a^2\int_{-\infty}^\infty e^{-\lambda u^2}du \right)\\ &= \sqrt{\frac{\lambda}{\pi}}\left( \frac{1}{2}\sqrt{\frac{\pi}{\lambda^3}}+0+a^2\sqrt{\frac{\pi}{\lambda}} \right)\\ &=a^2+\frac{1}{2\lambda} \end{aligned}} The variance is $\displaystyle \sigma^2=\left\langle x^2 \right\rangle-\left\langle x \right\rangle^2=\frac{1}{2\lambda}$ Hence the standard deviation is $\displaystyle \sigma=\frac{1}{\sqrt{2\lambda}}$

— Mathematica file —

The resolution of exercise 2 was done using some basic Mathematica code which I’ll post here hoping that it can be helpful to the readers of this blog.

// N[Pi, 25]

piexpansion = IntegerDigits[3141592653589793238462643]

digitcount = {}

For[i = 0, i <= 9, i++, AppendTo[digitcount, Count[A, i]]]

digitcount

digitprobability = {}

For[i = 0, i <= 9, i++, AppendTo[digitprobability, Count[A, i]/25]]

digitprobability

digits = {}

For[i = 0, i <= 9, i++, AppendTo[digits, i]]

digits

j = N[digits.digitprobability]

digitssquared = {}

For[i = 0, i <= 9, i++, AppendTo[digitssquared, i^2]]

digitssquared

jsquared = N[digitssquared.digitprobability]

sigmasquared = jsquared - j^2

std = Sqrt[sigmasquared]

deviations = {}

deviations = piexpansion - j

deviationssquared = (piexpansion - j)^2

variance = Mean[deviationssquared]

standarddeviation = Sqrt[variance]