Calculates the area of a closed polygon. The polygon points are given in points.
The result is positive if, in a Cartesian coordinate system with x to the right and y to the top, the polygon points are circulating counterclockwise around the enclosed area.
Otherwise, the result is negative.
Namespace: Altaxo.GeometryAssembly: AltaxoCore (in AltaxoCore.dll) Version: 4.8.3448.0 (4.8.3448.0)
Syntaxpublic static double PolygonArea(
IEnumerable<PointD2D> points
)
Parameters
- points IEnumerablePointD2D
- The polygon points. There is no need to repeat the first point at the end of the enumeration.
Return Value
DoubleThe polygon area (positive for a counterclockwise oriented polygon, negative for a clockwise oriented polygon).
See Also