### 11.14.6 The area of a polygon: area

The area command takes as argument a circle or polygon which is star-shaped with respect to its first vertex (i.e., the line segment from the first vertex to any point in the polygon lies within the polygon).

area returns the area of the object.
Input:

area(triangle(0,1,i))

Output:

1/2

Input:

area(square(0,2))

Output:

4

The area command has areaat and areaatraw versions (see section 11.14.1).