Trying to write a sub or function to verify if a point is included whitin the shape defined by several 2D points

hhxman

New Member
Joined
Jun 7, 2011
Messages
1
What I am trying to do is to define a formula, or even a function that can be able to answer if a certain point (Xp, Yp) is or not included within a shape defined by several points (not always the same number of points).
Graphically is simple to answer if You can easily plot the shape.
In a cartesian chart i can represent the shape which is delimited by the perimeter defined from the position of the several points (X1, Y1), (X2, Y2) ... (Xn, Yn). Does the point P = (Xp, Yp) belong to the area of the above defined polygon? Does the point P eventually belong to the edge?

Thanks in advance,

hhxman
 

Excel Facts

When did Power Query debut in Excel?
Although it was an add-in in Excel 2010 & Excel 2013, Power Query became a part of Excel in 2016, in Data, Get & Transform Data.
google on
determine if point is within polygon

you will get loads of answers
 
Upvote 0

Forum statistics

Threads
1,224,566
Messages
6,179,555
Members
452,928
Latest member
101blockchains

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top