Declutter layout algorithm
Hi all you algorithm gurus - I'm looking for ideas for an algorithm to solve the following problem. It's specifically meant to "spread out" or "declutter" the overlapping vertices in a graph visualization system, but I'll state it in more general terms.
In a rectangular area of the screen there are n rectangles. Each rectangle has a location (the (x,y) coordinate of upper-left corner) a width and a height. Some of the rectangles may overlap each other. The declutter layout algorithm should translate the vertices from their original locations, such that after translation no vertices overlap. The algorithm should also try to minimize the translation distance of each rectangle, so the user does not lose all context.
Any ideas? Sounds similar to a spring embedded layout algorithm, or some kind of repellent force algorithm, except we're not concerned about connectedness of vertices. Just need to spread out the overlapping ones.

