Spherical Harmonics

SetOptions[PolarPlot,PlotStyle->{{Black,AbsoluteThickness[2]}},PlotRange->All,Axes->None];

In this worksheet, you will examine the graphs of the spherical harmonics (Subscript[Y, l,m])(θ,ϕ).  Since the spherical harmonics are complex functions of the angular coordinates, it is not possible to plot  (Subscript[Y, l,m])(θ,ϕ).  Instead, we will plot |(Subscript[Y, l,m])(θ,ϕ)((|)^2) as a function of the angular coordinates.  The square of the norm gives the probability density in quantum mechanics.  NOTE: By looking only at the square of the norm in this worksheet, we are throwing away information about the phase.  We will explore the physical importance of the phase in a subsequent worksheet.

Define function

el=1;
m=0;
f[θ_,ϕ_]:=SphericalHarmonicY[el,m,θ,ϕ];

f[θ,ϕ]

2 - D Polar plot

ypol=PolarPlot[((Abs[N[f[θ+π/2,0]]])^2),{θ,0,2*π},ImageSize->150]

3 - D Polar plot

ymesh=SphericalPlot3D[((Abs[N[f[θ,ϕ]]])^2),{θ,0,π},{ϕ,0,2*π},PlotRange->All,ViewPoint->{2.6, 0, 1.4},Axes->False,Boxed->False,Mesh->{30,10},ImageSize->150]

Color on sphere.  Red is max, blue is min (0).

maxx=Max[Table[((Abs[N[f[θ,0]]])^2),{θ,0,π,π/100}]];

ysph=ParametricPlot3D[{Cos[v] Sin[u],Sin[v] Sin[u],Cos[u]},{u,0,π},{v,0,2*π},PlotPoints -> 50,ColorFunction->Function[{x,y,z,u,v},Hue[0.67*(1-((Abs[f[u,v]])^2)/maxx)]],ColorFunctionScaling->False,ViewPoint->{2.6, 0, 1.6},Axes->False,Boxed->False,Mesh->False,ImageSize->150]

Color on Molleweide projection

findroot[θ_]:=Module[{a=π},fr=FindRoot[2*η+Sin[2*η]==a*Cos[θ],{η,0}];η/.fr]

mg=ParametricPlot[{2*Sqrt[2]/π*ϕ*Cos[findroot[θ]],Sqrt[2]*Sin[findroot[θ]]},{ϕ,-π,π},{θ,0,π},Mesh->False,Axes->False,Frame->False,ColorFunction->Function[{x,y,ϕ,θ},Hue[0.67*(1-((Abs[f[θ,ϕ]])^2)/maxx)]],ColorFunctionScaling->False,BoundaryStyle->None,ImageSize->216]

Color on flat projection

flat=ParametricPlot[{ϕ,θ},{ϕ,0,2*π},{θ,0,π},Mesh->False,Axes->True,AxesOrigin->{0,0},AxesLabel->{ϕ,θ},Ticks->{{{0,0,{0,0.02}},{π/2,π/2,{0,0.02}},{π,π,{0,0.02}},{3*π/2,3*π/2,{0,0.02}},{2*π,2*π,{0,0.02}}},{{0,π,{0,0.02}},{π/2,π/2,{0,0.02}},{π,0,{0,0.02}}}},Frame->False,ColorFunction->Function[{x,y,ϕ,θ},Hue[0.67*(1-((Abs[f[θ,ϕ]])^2)/maxx)]],ColorFunctionScaling->False,BoundaryStyle->None,ImageSize->216]

Collage

Grid[{{ypol,ymesh,ysph,flat,mg}},Spacings->0]

Some of these plots look like electron orbitals, BUT THESE  ARE NOT THE ELECTRON ORBITALS.  Not until we have included the radial dependence in the wave function will you truly be able to see the probability distribution as a function of all three spatial coordinates.  You should think of the spherical harmonics as functions on the sphere.