areaintersection.m
No License
Function gives the approximate area of intersection of two polygons
whose vertices are given by set1 and set2.
Note that implementation of this function requires the standard Matlab
function "inpolygon"
STANDARD CALL
area = areaintersection(set1, set2, resolution)
INPUTS
set1 : an N x 2 matrix of the form (x1, y1; x1, y2; ...) giving the
vertices of a polygon
set2 : an M x 2 matrix of the form (x1, y1; x1, y2; ...) giving the
vertices of a second polygon
resolution : a positive scalar that determines the accuracy of the
approximation. The larger the value the greater the accuracy and the
longer the evaluation time. The matlab function "inpolygon" is the
real limiting factor in terms of execution time
OUTPUT
area : a scalar value that represents the area of intersection of the two
polynomials in standard units squared
Paul Koprowski 2007
paulkoprowski@hotmail.com
Cite As
paul (2026). areaintersection.m (https://www.mathworks.com/matlabcentral/fileexchange/15557-areaintersection-m), MATLAB Central File Exchange. Retrieved .
MATLAB Release Compatibility
Platform Compatibility
Windows macOS LinuxCategories
Tags
Discover Live Editor
Create scripts with code, output, and formatted text in a single executable document.
| Version | Published | Release Notes | |
|---|---|---|---|
| 1.0.0.0 | fixed a bug in error mesages |
