07-14-2024, 03:42 PM
yeah I thought you @TerryRitchie were that far already???
Google: How to calculate the Centroid:
thats why I said compare that to your idea of mid(x, y) (xmax-xmin)/2, (ymax-ymin)/2
They might be kinda close, the same in certain cases like a circle but not always correct.
Google: How to calculate the Centroid:
Quote:How do I compute the centroid in a polygon?
Write down the coordinates of each polygon vertex.
Count the vertices and denote their number by n .
Add all the x values from the vertices and divide the sum by n .
Add all the y values from the vertices and divide the sum by n .
That's it!
thats why I said compare that to your idea of mid(x, y) (xmax-xmin)/2, (ymax-ymin)/2
They might be kinda close, the same in certain cases like a circle but not always correct.
724 855 599 923 575 468 400 206 147 564 878 823 652 556 bxor cross forever

