Abstract-We describe the design, implementation, and programming of a set of robots that, starting from an amorphous arrangement, can be assembled into arbitrary shapes and then commanded to self-disassemble in an organized manner, to obtain a goal shape. We present custom hardware, distributed algorithms, and experimental results from hundreds of trails which show the system successfully forming complex threedimensional shapes. Each of the 28 modules in the system is implemented as a 1.8-inch autonomous cube-shaped robot able to connect to and communicate with its immediate neighbors. Embedded microprocessors control each module's magnetic connection mechanisms and infrared communication interfaces. When assembled into a structure, the modules form a system that can be virtually sculpted using a computer interface and a distributed process. The group of modules collectively decide who is on the final shape and who is not using algorithms that minimize information transmission and storage. Finally, the modules not in the structure disengage their magnetic couplings and fall away under the influence of an external force, in this case, gravity.