Your browser does not support HTML5 Canvas

Notes:

A 'polar coordinates' type shape.

The equation of a Bifolium is:

r = a*sin(θ)*cos2(θ)
a is related to the length of the 'wing'            
                        

Note that the link to the Bifolium entry in MathWorld.Wolfram switches the sine and cosine functions. Since sine and cosine are related through a phase shift, the shapes are equivalent except for their rotation in the plane.

This shape was nicely-used in a novice design: Honey of a Bee.

TNTBifolium Features and Usage:
Primary Attributes:

5 Parameters:

  • center: TNTPoint
  • petalRadius: a real number
  • fillColor: TNTColor (can be null for a framework image)
  • borderStroke: a TNTStroke: to set the border color as well as the thickness of the sides
  • rotationDeg: a 'double' that rotates the image about its center.
    rotn > 0 ==> counter-clockwise; rotn < 0 ==> clockwise
To Create:

The example above was created by:

//designer color
var powderBlue = new TNTColor(126, 133, 234, "powderBlue");

blackStroke.setStrokeLineWidth(.5);
//easier than stmt above:
//blackStroke.lineWidth = .5;
var myBifolium = new TNTBifolium(origin, 15, powderBlue, blackStroke, 0);
myBifolium.drawTNTBifolium(context);
                                    
To Draw: myBifolium.drawTNTBifolium(context);