Mathematica 9 is now available
THIS IS DOCUMENTATION FOR AN OBSOLETE PRODUCT.
SEE THE DOCUMENTATION CENTER FOR THE LATEST INFORMATION.
Polytopes Package >

Polytopes Package

This package contains functions that give geometrical characteristics of regular polygons. Polygons are identified by name (Digon, Decagon, etc.) in function arguments and in results.
NumberOfVertices[p]number of vertices in polygon p
NumberOfEdges[p]number of edges in polygon p
NumberOfFaces[p]number of faces in polygon p
Vertices[p]list of vertex coordinates for polygon p
Area[p]area of polygon p when edges have unit length
InscribedRadius[p]radius of the inscribed circle of polygon p when edges have unit length
CircumscribedRadius[p]radius of the circumscribed circle of polygon p when edges have unit length
Faces[p]list of faces from vertex numbers for polygon p

Geometrical characteristics of polygons.

Digonpolygon with 2 edges
Trianglepolygon with 3 edges
Squarepolygon with 4 edges
Pentagonpolygon with 5 edges
Hexagonpolygon with 6 edges
Heptagonpolygon with 7 edges
Octagonpolygon with 8 edges
Nonagonpolygon with 9 edges
Decagonpolygon with 10 edges
Undecagonpolygon with 11 edges
Dodecagonpolygon with 12 edges

Names of polygons.

The functions Area, InscribedRadius, and CircumscribedRadius give information for a polygon with edges of length 1. The list of coordinates returned by Vertices is conventional for the specified polygon and does not necessarily correspond to a polygon with unit edge length.
This loads the package.
In[1]:=
Click for copyable input
An octagon has 8 edges.
In[2]:=
Click for copyable input
Out[2]=
This is the area of an octagon when the length of each edge is 1.
In[3]:=
Click for copyable input
Out[3]=
These points represent the coordinates of the vertices of an octagon.
In[4]:=
Click for copyable input
Out[4]=
Here is a plot of the vertices of an octagon.
In[5]:=
Click for copyable input
Out[5]=
Ask a question about this page  |  Suggest an improvement  |  Leave a message for the team
Format:   HTML  |  CDF