A Leaf in the Fall

Here is an interesting polar plot adapted from Andre Heck's Introduction to Maple, section 14.4.

<< "Graphics`Graphics`"; 
s = 100/(100 + (t - Pi/2)^8); 
r = s (3.5 - Sin[7 t] - Cos[30 t]/2);
PolarPlot[r, {t, -Pi/2, 3 Pi/2}, PlotPoints -> 1000,
   Axes -> False];

[Graphics:Images/leaf_gr_1.gif]

The leafs have been peak here in Asheville the last few days so I found myself motivated to add some color to this example.  Here's the result.

r = r /. t -> If[x > 0, ArcTan[y/x], ArcTan[y/x] + Pi]; 
Show[Graphics[RasterArray[Table[If[x^2 + y^2 < r^2,
        Hue[(x^2 + (y - 0.5)^2)^0.33/17], RGBColor[1, 1, 1]],
    {y, -1, 5, 0.03}, {x, -4, 4, 0.03}]]],
    AspectRatio -> Automatic];

[Graphics:Images/leaf_gr_2.gif]


Converted by Mathematica      October 31, 1999