Legendre Expansions & Spherical Harmonics

William O. Bray

Basic Plots

The following commands give plots similar to Figures 8.2 and 8.3 in the text.

legendre-expansions_1.gif

legendre-expansions_2.gif

As functions on the sphere, we can look at the plots with the following commands.

legendre-expansions_3.gif

legendre-expansions_4.gif

An Expansion Example (Mathematica version of Example 8.1 in text)

legendre-expansions_5.gif

legendre-expansions_6.gif

legendre-expansions_7.gif

legendre-expansions_8.gif

legendre-expansions_9.gif

legendre-expansions_10.gif

legendre-expansions_11.gif

Notice that the Legendre coefficient corresponding to l=0 is zero.

legendre-expansions_12.gif

legendre-expansions_13.gif

legendre-expansions_14.gif

Spherical Harmonics

The code below generates Figure 8.6 in the text. By varying the parameters other spherical harmonics can be plotted on the sphere.

legendre-expansions_15.gif

legendre-expansions_16.gif

Spikey Created with Wolfram Mathematica 8.0