(************** Content-type: application/mathematica ************** Mathematica-Compatible Notebook This notebook can be used with any Mathematica-compatible application, such as Mathematica, MathReader or Publicon. The data for the notebook starts with the line containing stars above. To get the notebook into a Mathematica-compatible application, do one of the following: * Save the data starting with the line of stars above into a file with a name ending in .nb, then open the file inside the application; * Copy the data starting with the line of stars above to the clipboard, then use the Paste menu command inside the application. Data for notebooks contains only printable 7-bit ASCII and can be sent directly in email or through ftp in text mode. Newlines can be CR, LF or CRLF (Unix, Macintosh or MS-DOS style). NOTE: If you modify the data for this notebook not in a Mathematica- compatible application, you must delete the line below containing the word CacheID, otherwise Mathematica-compatible applications may try to use invalid cache data. For more information on notebooks and Mathematica-compatible applications, contact Wolfram Research: web: http://www.wolfram.com email: info@wolfram.com phone: +1-217-398-0700 (U.S.) Notebook reader applications are available free of charge from Wolfram Research. *******************************************************************) (*CacheID: 232*) (*NotebookFileLineBreakTest NotebookFileLineBreakTest*) (*NotebookOptionsPosition[ 7245, 263]*) (*NotebookOutlinePosition[ 8335, 299]*) (* CellTagsIndexPosition[ 8207, 292]*) (*WindowFrame->Normal*) Notebook[{ Cell[TextData[{ "PolarDensityPlot ", StyleBox["and", FontWeight->"Plain"], " ListPolarDensityPlot" }], "Section"], Cell[TextData[StyleBox["Selwyn Hollis\nslhollis@mac.com\n", FontSize->10]], "Text"], Cell[TextData[{ "This loads the package, presuming it\[CloseCurlyQuote]s in ", StyleBox["AddOns\[ThinSpace]:\[ThinSpace]Applications", FontFamily->"Helvetica"], "." }], "Text"], Cell[BoxData[ \(<< PolarDensity.m\)], "Input", CellLabel->"In[60]:="], Cell[TextData[{ "If you choose to place the package in the ", StyleBox["Graphics", FontFamily->"Helvetica"], " subdirectory, then load it by entering" }], "Text"], Cell[BoxData[ \(<< Graphics`PolarDensity`\)], "Input", CellLabel->"In[6]:="], Cell[CellGroupData[{ Cell["PolarDensityPlot", "SubsectionIcon", FontFamily->"Helvetica"], Cell[CellGroupData[{ Cell[BoxData[ \(\(?PolarDensityPlot\)\)], "Input", CellLabel->"In[61]:="], Cell[BoxData[ \("PolarDensityPlot[ f[r,\[Theta]], {r, r1, r2}, {\[Theta], \[Theta]1, \ \[Theta]2} ] \ngenerates a polar density plot of f[r,\[Theta]]."\)], "Print", CellTags->"Info3237617818-3710010"] }, Open ]], Cell[TextData[{ StyleBox["PolarDensityPlot", FontFamily->"Courier"], " functions in essentially the same way as ", StyleBox["DensityPlot", FontFamily->"Courier"], ". As with ", StyleBox["DensityPlot", FontFamily->"Courier"], " the default ", StyleBox["ColorFunction", FontFamily->"Courier"], " is ", StyleBox["GrayLevel", FontFamily->"Courier"], ", but unlike ", StyleBox["DensityPlot", FontFamily->"Courier"], " the default value of ", StyleBox["Mesh", FontFamily->"Courier"], " is ", StyleBox["False", FontFamily->"Courier"], "." }], "Text", CellDingbat->None], Cell[BoxData[ \(PolarDensityPlot[ Cos[2 r\ \[Theta]], {r, .5, 2}, {\[Theta], \[Pi]/3, 11 \[Pi]/6}]\)], "Input", CellLabel->"In[45]:="], Cell[TextData[{ "The default value of ", StyleBox["PlotPoints", FontFamily->"Courier"], " is ", StyleBox["{", FontFamily->"Courier"], "15, ", Cell[BoxData[ \(TraditionalForm\`p\_\[Theta]\)]], StyleBox["}", FontFamily->"Courier"], ", where ", Cell[BoxData[ \(TraditionalForm\`p\_\[Theta] = \[LeftFloor]4 \( \[Theta]2 - \[Theta]1\ \)\/\(2 \[Pi]\)\[CenterDot]15\[RightFloor]\)]], ". For any specification of the form ", StyleBox["PlotPoints\[ThinSpace]\[Rule]", FontFamily->"Courier"], "\[ThinSpace]", Cell[BoxData[ \(TraditionalForm\`p\_r\)]], ", the actual ", StyleBox["PlotPoints", FontFamily->"Courier"], " value becomes ", StyleBox["{", FontFamily->"Courier"], Cell[BoxData[ \(TraditionalForm\`p\_r\)]], ", ", Cell[BoxData[ \(TraditionalForm\`p\_\[Theta]\)]], StyleBox["}", FontFamily->"Courier"], ", where ", Cell[BoxData[ \(TraditionalForm\`p\_\[Theta] = \[LeftFloor]4 \(\( \[Theta]2 - \ \[Theta]1\)\/\(2 \[Pi]\)\) p\_r\[RightFloor]\)]], ". " }], "Text"], Cell["The following uses a finer grid and a few options.", "Text"], Cell[BoxData[ \(PolarDensityPlot[ Cos[2 r\ \[Theta]], {r, .5, 2}, {\[Theta], 0, 11 \[Pi]/6}, PlotPoints \[Rule] 30, ColorFunction \[Rule] \((Hue[0, 1, #] &)\), Frame \[Rule] False]\)], "Input", CellLabel->"In[47]:="] }, Closed]], Cell[CellGroupData[{ Cell["ListPolarDensityPlot", "SubsectionIcon", FontFamily->"Helvetica"], Cell[TextData[{ StyleBox["ListPolarDensityPlot", FontFamily->"Courier"], " functions in essentially the same way as ", StyleBox["ListDensityPlot", FontFamily->"Courier"], ". " }], "Text"], Cell[CellGroupData[{ Cell[BoxData[ \(\(?ListPolarDensityPlot\)\)], "Input", CellLabel->"In[57]:="], Cell[BoxData[ \("ListPolarDensityPlot[matrix] generates a polar density plot from an \ array of height values. Rows of matrix correspond to constant angles, and \ columns of matrix correspond to constant radii."\)], "Print", CellTags->"Info3237617732-4556062"] }, Open ]], Cell["This generates a matrix of numbers.", "Text"], Cell[BoxData[ \(\(polardata = Table[Cos[2 \[Pi]\ r\ ]\ Sin[3\ \[Theta]], {\[Theta], 0, 47 \[Pi]/24, \[Pi]/24}, {r, .1, 1, .1}];\)\)], "Input", CellLabel->"In[49]:="], Cell["Here is the density plot.", "Text"], Cell[BoxData[ \(ListPolarDensityPlot[polardata]\)], "Input", CellLabel->"In[50]:="], Cell[TextData[{ "This uses ", StyleBox["PlotRange", FontFamily->"Courier"], " to plot the same data over an annular sector. (This is not a truncation \ of the previous plot.)" }], "Text"], Cell[BoxData[ \(ListPolarDensityPlot[polardata, PlotRange \[Rule] {{1, 4}, {\[Pi]/3, \[Pi]}, Automatic}]\)], "Input", CellLabel->"In[51]:="] }, Closed]], Cell[CellGroupData[{ Cell[TextData[StyleBox["Pretty Pictures", FontSize->14, FontWeight->"Plain"]], "SubsectionIcon"], Cell[BoxData[ \(PolarDensityPlot[ r\ Cos[3 \[Theta]] - \ Sin[4 r + 5 \[Theta]], {r, 0, 6}, {\[Theta], 0, 8 \[Pi]/4}, PlotPoints \[Rule] 45, ColorFunction \[Rule] \((Hue[#, 1, #] &)\), Frame \[Rule] False]\)], "Input", CellLabel->"In[58]:="], Cell[BoxData[ \(PolarDensityPlot[ Cos[3 \[Pi]\ r]\ \ Cos[\ \[Pi]\ Sin[2 \[Theta]] + 1], {r, 0, 1}, {\[Theta], 0, 2 \[Pi]}, PlotPoints \[Rule] 30, ColorFunction \[Rule] \((CMYKColor[1 - .5 #, 1 - #\^2, #, 0] &)\), Frame \[Rule] False]\)], "Input", CellLabel->"In[59]:="] }, Closed]] }, FrontEndVersion->"4.1 for Macintosh", ScreenRectangle->{{0, 1600}, {0, 1178}}, WindowSize->{542, 357}, WindowMargins->{{101, Automatic}, {Automatic, 120}}, ShowCellLabel->False, ImageMargins->{{72, Inherited}, {Inherited, Inherited}}, Magnification->1, StyleDefinitions -> "HelpBrowser.nb" ] (******************************************************************* Cached data follows. If you edit this Notebook file directly, not using Mathematica, you must remove the line containing CacheID at the top of the file. The cache data will then be recreated when you save this file from within Mathematica. *******************************************************************) (*CellTagsOutline CellTagsIndex->{ "Info3237617818-3710010"->{ Cell[2644, 93, 206, 3, 35, "Print", CellTags->"Info3237617818-3710010"]}, "Info3237617732-4556062"->{ Cell[5474, 205, 266, 4, 50, "Print", CellTags->"Info3237617732-4556062"]} } *) (*CellTagsIndex CellTagsIndex->{ {"Info3237617818-3710010", 7983, 282}, {"Info3237617732-4556062", 8097, 285} } *) (*NotebookFileOutline Notebook[{ Cell[1705, 50, 123, 5, 51, "Section"], Cell[1831, 57, 85, 1, 57, "Text"], Cell[1919, 60, 186, 5, 21, "Text"], Cell[2108, 67, 75, 2, 25, "Input"], Cell[2186, 71, 172, 5, 21, "Text"], Cell[2361, 78, 82, 2, 25, "Input"], Cell[CellGroupData[{ Cell[2468, 84, 69, 1, 35, "SubsectionIcon"], Cell[CellGroupData[{ Cell[2562, 89, 79, 2, 25, "Input"], Cell[2644, 93, 206, 3, 35, "Print", CellTags->"Info3237617818-3710010"] }, Open ]], Cell[2865, 99, 628, 26, 47, "Text"], Cell[3496, 127, 158, 4, 25, "Input"], Cell[3657, 133, 1073, 40, 43, "Text"], Cell[4733, 175, 66, 0, 21, "Text"], Cell[4802, 177, 245, 5, 40, "Input"] }, Closed]], Cell[CellGroupData[{ Cell[5084, 187, 73, 1, 25, "SubsectionIcon"], Cell[5160, 190, 203, 7, 21, "Text"], Cell[CellGroupData[{ Cell[5388, 201, 83, 2, 25, "Input"], Cell[5474, 205, 266, 4, 50, "Print", CellTags->"Info3237617732-4556062"] }, Open ]], Cell[5755, 212, 51, 0, 21, "Text"], Cell[5809, 214, 197, 4, 40, "Input"], Cell[6009, 220, 41, 0, 21, "Text"], Cell[6053, 222, 89, 2, 25, "Input"], Cell[6145, 226, 197, 6, 21, "Text"], Cell[6345, 234, 153, 3, 40, "Input"] }, Closed]], Cell[CellGroupData[{ Cell[6535, 242, 100, 2, 23, "SubsectionIcon"], Cell[6638, 246, 279, 6, 40, "Input"], Cell[6920, 254, 309, 6, 56, "Input"] }, Closed]] } ] *) (******************************************************************* End of Mathematica Notebook file. *******************************************************************)