%% Number of Polygon Sides
% Create a polygon and determine its number of sides.

t = 0:0.5:2*pi;
P = [cos(t)' sin(t)'];
polyin = polyshape(P);
plot(polyin)
N = numsides(polyin)

% Copyright 2012 The MathWorks, Inc.