Pattern generation with removing overlapping ones

I am generating rectangular random pattern with populate tools. Thus a high number of overlapping rectangles are created which is unwanted. I am trying to remove them with the collision (many-many) widget. Unfortunately if I use this it removes all the overlapping curves. If there is two overlapping curves it gives true for both curves, despite it would desirable to remove only one of them. Is there any solution for this?

DUPLICATE THREAD!!! Please delete this one.