Pushing Blocks by Sweeping Lines

02/24/2022
by   Hugo A. Akitaya, et al.
0

We investigate the reconfiguration of n blocks, or "tokens", in the square grid using "line pushes". A line push is performed from one of the four cardinal directions and pushes all tokens that are maximum in that direction to the opposite direction. Tokens that are in the way of other tokens are displaced in the same direction, as well. Similar models of manipulating objects using uniform external forces match the mechanics of existing games and puzzles, such as Mega Maze, 2048 and Labyrinth, and have also been investigated in the context of self-assembly, programmable matter and robotic motion planning. The problem of obtaining a given shape from a starting configuration is know to be NP-complete. We show that, for every n, there are "sparse" initial configurations of n tokens (i.e., where no two tokens are in the same row or column) that can be compacted into any a× b box such that ab=n. However, only 1× k, 2× k and 3× 3 boxes are obtainable from any arbitrary sparse configuration with a matching number of tokens. We also study the problem of rearranging labeled tokens into a configuration of the same shape, but with permuted tokens. For every initial configuration of the tokens, we provide a complete characterization of what other configurations can be obtained by means of line pushes.

READ FULL TEXT

Please sign up or login with your details

Forgot password? Click here to reset