9

Has the following problem been studied before? If yes, what approaches/algorithms were developed to solve it?

Problem ("Maximum Stacking Height Problem")

Given $n$ polygons, find their stable, non-overlapping arrangement that maximizes their stacking height on a fixed floor under the influence of gravity.


Example

Three polygons:

enter image description here

and three of their infinitely many stable, non-overlapping arrangements, with different stacking heights:

enter image description here


Clarifications

  • All polygons have uniform mass and equal density
  • Friction is zero
  • Gravity is acting on every point into the downwards direction (i.e. the force vectors are all parallel)
  • A configuration is not considered stable if it rests on an unstable equilibrium point (for example, the green triangle in the pictures can not balance on any of its vertices, even if the mass to the left and the right of the balance point is equal)
  • To further clarify the above point: A polygon is considered unstable ("toppling") unless it rests on at least one point strictly to the left and at least one point strictly to the right of its center of gravity (this definition greatly simplifies simulation and in particular makes position integration etc. unnecessary for the purpose of evaluating whether or not an arrangement is stable.
  • The problem in its "physical" form is a continuous problem that can only be solved approximately for most cases. To obtain a discrete problem that can be tackled algorithmically, constrain both the polygon vertices and their placement in the arrangement to suitable lattices.


Notes

  • Brute force approaches of any kind are clearly infeasible. Even with strict constraints on the placement of polygons inside the lattice (such as providing a limited region "lattice space") the complexity simply explodes for more than a few polygons.
  • Iterative algorithms must bring some very clever heuristics since it is easy to construct arrangements where removing any single polygon results in the configuration becoming unstable and such arrangements are unreachable by algorithms relying on every intermediate step being stable.
  • Since the problem smells at least NP- but more likely EXPTIME-complete in the total number of vertices, even heuristics would be of considerable interest. One thing that gives hope is the fact that most humans will recognize that the third arrangement in the example is optimal.

2 Answers2

1

The following algorithm may not be optimal, but should give a good approximation. We will use Simulated Annealing. Each configuration can be represented by the following parameters:

  1. Order of shapes from ground to top
  2. Rotation of each shape
  3. Horizontal displacement of each shape

To evaluate a configuration, we place shapes one at a time in the order given in 1 with the rotation from 2 and horizontal displacement from 3. Wait until the configuration settles into a stable position and then measure its height. A configuration can be "mutated" by changing one of the 3 attributes. Run standard Simulated Annealing procedure to find good configurations. To make this more efficient, we can limit the number of rotations in 2 to $k$ bins. Similarly we can limit the number of possible horizontal displacements. With the right parameters, each of the configurations in the original post can be achieved. For me the hardest part in implementing this is finding a good physics simulator that would allow realistic placement of these shapes.

1

While I don't know of any specific algorithms for this problem, you could approach this in a pretty efficient method by breaking it down into separate parts.

I would start by finding the rotation for each individual shape that provides a maximum height while maintaining a valid balancing orientation (is: not on a point like with the triangle). If a shape has multiple equal heights, i would go with the configuration that gives the greatest surface area on top of it. Once you have this, you can then figure out how to best stack each object in a manor that is able to be balanced.

GEMISIS
  • 156
  • 4