I have grids as polygons where the grids are overlapping. I want list of grids covering a separate polygon. The image below demonstrate the problem. The red lines are the edges of the grids and the black polygon is polygon of our interest.
Since the grids are overlapping simple intersect will generate a list where some grids add to spatial redundancy. I want to optimize size this list by removing the grids which only contribute to the spatial redundancy. For example, in the following image the skyblue polygon will intersect with four surrounding grids, but the expected output is a single grid (any one of the four intersecting grid).
As mentioned, solution in this case may not be unique, what is expected here any of the all possible solution where count of grids in the solution is minimized.