I have an array of points in two dimensional plane. The closed-loop formed by these points (by joining each point with two neighboring points, and first point to the last point, always lies on both sides of the Y-axis (x>0 and x<0). I am trying to find the area of a section of this domain lying on the x > 0 side of the Y axis. Use of WindingPolygon function to determine the domain is giving “disconnected polygon with holes”. Due to this, discretization of this domain is giving an area completely different from the original area. Attached is the file having the data.
It worked for most of the cases, but the problem of “disconnected polygon with holes” persisted. When I try to determine the area of the bound region, a new error message “BoundaryMeshRegion::holm: Unable to find points not in the region for all of the inner boundaries.” pops up in the message window. I tried to search, but could not find any reference for this error message. Not sure if the two messages “disconnected polygon with holes” and “BoundaryMeshRegion::holm: Unable to find points not in the region for all of the inner boundaries.” are connected to each other. Attached file has an example. Will be thankful for any further suggestion.
PS- If I run a large number of sets of “points” to determine the bound areas, this error message coincides with the hanging of the Mathematica…
Try generating a BSplineFunction or BezierFunction from the points to smooth them out and eliminate holes. There may be a better way to identify and remove holes, try asking on MSE.