Answer
See the detailed answer below.
Work Step by Step
We are asked to calculate the average value of $ r $ in terms of $ a_B $ (Bohr radius) for the electron in the $1s$ and 2p states of hydrogen.
This is based on the radial probability density function, $ P_r(r) $, which is the probability of finding an electron at a distance $ r $ from the nucleus in a hydrogen atom. The average value of $ r $ is given by:
$$
r_{\text{avg}} = \int_0^\infty r P_r(r) \, dr\tag 1
$$
where $P_r(r) = 4\pi r^2 |R_{nl}(r)|^2$, where the radial wave function for the $1s$ state and it is given by $
R_{1s}(r) = \dfrac{1}{\sqrt{\pi a_B^3}} e^{-r/a_B}$
Thus,
$$P_r(r) = 4\pi r^2\left[\dfrac{1}{\sqrt{\pi a_B^3}} e^{-r/a_B}\right]^2=4\pi r^2 \dfrac{1}{ \pi a_B^3} e^{-2r/a_B} $$
$$P_r(r) = \dfrac{4}{ a_B^3} r^2e^{-2r/a_B}$$
Plug into (1);
$$
r_{\text{avg}} = \int_0^\infty\dfrac{4}{ a_B^3} r^3e^{-2r/a_B}\, dr
$$
Factor out the constants:
$$
r_{\text{avg}} =\dfrac{4}{ a_B^3} \int_0^\infty r^3e^{-2r/a_B}\, dr \tag 2
$$
- The integral of the form $ \int_0^\infty x^n e^{-\alpha x} \, dr $ is a standard integral from mathematical tables.
$$\int_0^{\infty} x^n e^{-\alpha x} \, dx = \frac{n}{\alpha^{n+1}}$$
So, In this case:
$$
\int_0^\infty r^3 e^{-2r/a_B} \, dr = \frac{3!}{(2/a_B)^4}= \frac{6a_B^4}{16}
$$
Plug into (2);
$$
r_{\text{avg}} =\dfrac{4}{ a_B^3} \cdot \frac{6a_B^4}{16}
$$
$$
r_{\text{avg}} =\color{red}{\bf 1.5} \,a_B
$$
For the $2p$ state, the radial wave function is different, and hence the probability density function $ P_r(r) $ is also different.
where $P_r(r) = 4\pi r^2 |R_{nl}(r)|^2$, where the radial wave function for the $2p$ state and it is given by $
R_{2p}(r) = \frac{1}{\sqrt{24\pi a_B^3}} \left(\frac{r}{2a_B}\right) e^{-r/2a_B}$
Thus,
$$P_r(r) = 4\pi r^2\left[ \frac{1}{\sqrt{24\pi a_B^3}} \left(\frac{r}{2a_B}\right) e^{-r/2a_B}\right]^2$$
$$
= 4\pi r^2\left[ \frac{1}{{24\pi a_B^3}} \left(\frac{r^2}{4a_B^2}\right) e^{-r/a_B}\right]$$
$$
P_r(r)=\frac{ 1}{{24a_B^5}} r^4e^{-r/a_B} $$
Plug into (1);
$$
r_{\text{avg}} = \int_0^\infty \frac{ 1}{{24a_B^5}} r^5e^{-r/a_B} \, dr
$$
$$
r_{\text{avg}} = \frac{ 1}{{24a_B^5}} \int_0^\infty r^5e^{-r/a_B} \, dr
$$
Using the same integral formula as above,
$$
r_{\text{avg}} = \frac{ 1}{{24a_B^5}} \cdot \frac{5!}{(1/a_B)^6}
$$
$$
r_{\text{avg}} = \frac{ 1}{{24a_B^5}} \cdot 120 a_B^6
$$
$$
r_{\text{avg}} =\color{red}{\bf 5.0}\, a_B
$$