Solution 1:

Consider Laplace's equation in three dimensional space, $$\nabla^2 V({\bf r}) = 0.$$ Such a function is called harmonic. Harmonic functions describe a multitude of physical objects, typically called potentials. There are gravitational, electric, and fluid potentials, for example. In addition, Laplace's equation is used to study the steady state heat equation.

Let's focus on the gravitational potential. If we can calculate the solution to Laplace's equation obeying the appropriate boundary conditions, we can use this information to find the force acting on a test particle and thus determine its trajectory. If the object under consideration is roughly spherical (the earth, for example) it is appropriate to use spherical coordinates---we wish to solve Laplace's equation, i.e., find harmonic functions, in spherical coordinates. It turns out that such solutions naturally factor into an $r$-dependent part and a part depending on $\theta$ and $\phi$. This leads to an expansion of our solution in terms of a collection of basic solutions, called eigenfunctions. This is analogous to the expansion of a function in terms of a Fourier series. The eigenfunctions of the spherical part of the Laplace operator are just the spherical harmonics. The spherical harmonics naturally form a complete, countable, orthonormal basis for functions on $(\theta,\phi)$.

If we are interested in the solution for points not inside the earth (for example, the location of a satellite) and demand the potential at infinity vanish we find $$\begin{eqnarray} V({\bf r}) &=& \sum_{l=0}^\infty\sum_{m=-l}^l \frac{1}{r^{l+1}} a_{lm} Y_l^m(\theta,\phi) \\ &=& \frac{1}{r} a_{00} Y_0^0 + \frac{1}{r^2} \sum_{m=-1}^1 a_{1m} Y_1^m(\theta,\phi) + \frac{1}{r^3} \sum_{m=-2}^2 a_{1m} Y_2^m(\theta,\phi) + \ldots . \end{eqnarray}$$ The first term can be recognized as having the right form for the potential of a point mass ($Y_0^0 = \frac{1}{2} \sqrt{\frac{1}{\pi}}$ is constant). In fact, $a_{00} Y_0^0 = -G M$, where $M$ is the mass of the earth. The higher order terms tell us how much the potential of the earth deviates from that of a point mass. The second term, the dipole, vanishes for gravity. The third term, the quadrupole, does not vanish. It gives the first measurable deviation of the potential from that of a point mass. The five terms involving the spherical harmonics $Y_2^m$ for $m=-2,\ldots,2$ encode the most important angular variation of the potential of the earth. The spherical harmonics for $m\ne 0$ have azimuthal dependence (i.e., dependence on $\phi$). Since the earth is oblate and has roughly no azimuthal variation we find that the most important term in the quadrupole is due to $Y_2^0(\theta,\phi) = \frac{1}{4}\sqrt{\frac{5}{\pi}} (3\cos^2\theta -1)$. We can even infer from the form of $Y_2^0$ that the sign of $a_{20}$ is positive since the magnitude of the potential should be larger at the equator and $a_{00}$ is negative. To encode more fully the irregularity of the earth in density and shape we would need higher harmonics.

The coefficients in the series for $V({\bf r})$ can be computed using the orthonormality of the spherical harmonics. This is exactly like getting the coefficients in a Fourier series. We find $$a_{lm} = R_0^{l+1} \int_0^{2\pi} d\phi \int_0^\pi \sin\theta \ d\theta\ V(R_0,\theta,\phi) {Y_l^m}^*(\theta,\phi)$$ where ${}^*$ indicates complex conjugation and where $R_0$ is some reference radius, larger than the radius of the earth, on which the potential is known.

Solution 2:

If you have any sort of physics background, I would highly recommend picking up a simple book on quantum mechanics or electromagnetism, such as Griffiths "Introduction to Quantum Mechanics." Even if you don't have a physics background it will help you to look at any decent mathematical methods textbook, such as "Mathematical Methods in the Physical Sciences" by Boas. This book will not assume any physics background. There are numerous interpretations for spherical harmonics and I think it will benefit you to see them in action in the context of problems in the physical sciences.