Folding Polyominoes into (Poly)Cubes

12/26/2017 ∙ by Oswin Aichholzer, et al. ∙ Technische Universität Braunschweig University of California, Irvine MIT Linköping University Université Libre de Bruxelles Swarthmore College TU Graz 0

We study the problem of folding a polyomino P into a polycube Q, allowing faces of Q to be covered multiple times. First, we define a variety of folding models according to whether the folds (a) must be along grid lines of P or can divide squares in half (diagonally and/or orthogonally), (b) must be mountain or can be both mountain and valley, (c) can remain flat (forming an angle of 180^∘), and (d) must lie on just the polycube surface or can have interior faces as well. Second, we give all the inclusion relations among all models that fold on the grid lines of P. Third, we characterize all polyominoes that can fold into a unit cube, in some models. Fourth, we give a linear-time dynamic programming algorithm to fold a tree-shaped polyomino into a constant-size polycube, in some models. Finally, we consider the triangular version of the problem, characterizing which polyiamonds fold into a regular tetrahedron.

READ FULL TEXT VIEW PDF
POST COMMENT

Comments

There are no comments yet.

Authors

page 1

page 2

page 3

page 4

This week in AI

Get the week's most popular data science and artificial intelligence research sent straight to your inbox every Saturday.

1 Introduction

When can a polyomino be folded into a polycube ? The answer to this basic question depends on the precise model of folding allowed. At the top level, two main types of foldings have been considered in the literature: polyhedron folding (as in Part III of [9]) and origami folding (as in Part II of [9]).

Polyhedron folding perhaps originates with [11]. In this variant of the problem, the folding of must exactly cover the surface of , with a single layer everywhere. This requirement is motivated by sheet metal bending and other manufacturing applications with thick material, where it is desired to form a given shape with the material without creating layers of doubled thickness. If we make the additional assumption that at least one square of maps to a whole square of , an easy polynomial-time algorithm can determine whether folds into in this model: guess this mapping (among the choices), and then follow the forced folding to test whether is covered singly everywhere. Without this assumption, algorithms for edge-to-edge gluing of polygons into convex polyhedra [11], [9, ch. 25] can handle the case where the grid of does not match the grid of , but only when is convex. Specific to polyominoes and polycubes, there is extensive work in this model on finding polyominoes that fold into many different polycubes [3] and into multiple different boxes [1, 12, 13, 14, 15]

In origami folding, the folding of is allowed to multiply cover the surface of , as long every point of is covered by at least one layer of . This model is motivated by folding thinner material such as paper, where multiple layers of material are harmless, and is the model considered here. General origami folding results [8] show that every polycube, and indeed every polyhedron, can be folded from a polyomino of sufficiently large area. Two additional results consider the specific case of folding a polycube, with precise bounds on the required area of paper. First, every polycube can be folded from a sufficiently large square polyomino [6]. (This result also folds all the interior grid faces of .) Second, every polycube can be folded from a rectangular polyomino, with at most two layers at any point [5]. Both of these universality results place all creases on a fixed hinge pattern (typically a square grid plus some diagonals), so that the target polycube can be specified just by changing the fold angles in a polyomino whose shape depends only on the size  and not on the shape of .

Figure 1: Three polyominoes that fold along the grid lines into a unit cube, from puzzles by Nikolai Beluhov [4].

In this paper, we focus on the decision question of whether a given polyomino  can fold into a given polycube , in the origami folding model. In particular, we characterize the case when is a single cube, a problem motivated by three puzzles by Nikolai Beluhov [4]; see Figure 1. This seemingly simple problem already turns out to be surprisingly intricate.

We start in Section 2 by refining different folding models that allow or disallow various types of folds: (a) folds being just along grid lines of or also along diagonal/orthogonal bisectors of grid squares, (b) folds being all mountains or a combination of mountain and valley, (c) folds being strictly folded or can remain flat (forming an angle of ), and (d)  folds being restricted to lie on just the polycube surface or folds being allowed to have interior faces as well. Then, in Section 3, we characterize all grid-aligned models into a hierarchy of the models’ relative power.

Next, in Section 4, we characterize all the polyominoes that can be folded into a unit cube, in grid-based models. In particular, we show that all polyominoes of at least ten unit squares can fold into a unit cube using grid and diagonal folds, and list all smaller polyominoes that cannot fold into a unit cube in this model. Observe that the polyominoes of Figure 1 each consist of at least ten unit squares, though they furthermore fold into a cube using just grid-aligned folds. In this more strict model, we characterize which tree-shaped polyominoes lying in a and strip fold into a unit cube. This case matches the puzzles of Figure 1 except in the “tree-shaped” requirement; it remains open to characterize cyclic polyominoes that fold grid-aligned into a unit cube.

We also give some algorithmic results and consider the triangular grid. In Section 5, we give a linear-time dynamic programming algorithm to fold a tree-shaped polyomino into a constant-size polycube, in grid-based models. In Section 6, we consider the analogous problems on the triangular grid, characterizing (rather easily) which polyiamonds fold into a regular tetrahedron, in grid-based models. Finally, we present some open problems in Section 7.

2 Notation

A polyomino is a two-dimensional polygon formed by a union of unit squares on the square lattice connected edge-to-edge. We do not require all adjacent pairs of squares to be connected to each other; that is, we allow “cuts” along the edges of the lattice. A polyomino is a tree shape if the dual graph of its unit squares (the graph with a vertex per square and an edge for each connected pair of squares) is a tree. Analogously, in one dimension higher, a polycube is a connected three-dimensional polyhedron formed by a union of unit cubes on the cubic lattice connected face-to-face. If a polyomino or polycube is a rectangular box, we refer to it by its exterior dimensions, e.g., a 21 polyomino (domino) or a 221 polycube. We denote the special case of a single unit cube by .

We study the problem of folding a given polyomino to form a given polycube , allowing various different combinations of types of folds: axis-aligned and mountain folds, and valley folds, fold angles of any degree, diagonal folds through opposite corners of a square, and half-grid folds that bisect a unit square in an axis-parallel fashion.111We measure fold angles as dihedral angles between the two incident faces, signed positively for mountain (convex) and negatively for valley (reflex) folds.

((a))
((b))
Figure 4: Examples for interior faces shown in green. They connect to the red cube edges.

All faces of must be entirely covered by folded faces of , but in some cases we allow some faces of to lie inside without covering any face of . A face of is an interior face of if it is not folded onto any of the (boundary) faces of . For example, if we consider a chain of unit squares in a polyomino, two folds of along edges of two opposite edges of a unit square of result in a V-shape with two interior faces; see Figure ((a))(a) and LABEL:sub@fig:int-f-b for examples. A folding model specifies a subset of ,, , , any; grid; interior faces; diagonal; half-grid as allowable folds.

3 Folding hierarchy

We say that model is stronger than (denoting this relation by ) if, for all polyomino-polycube pairs such that folds into in , also folds into in . If there also exists a pair such that folds into in , but not in , then is strictly stronger than (). The relation ‘’ satisfies the properties of reflexivity, transitivity and antisymmetry, and therefore it defines a partial order on the set of folding models. Figure 5 shows the resulting hierarchy of the folding models that consist of combinations of the following folds: ,, , , any; interior faces; grid.

Figure 5: Hierarchy of fold operations. The nodes correspond to the following folding models: ; grid, grid, interior faces; grid, grid, interior faces; grid, grid, interior faces; grid, ; interior faces; grid, and interior faces; grid. A black arrow from to indicates that . Blue and green arrows indicate incomparable models. The labels on arrows correspond to the relations’ numbers from the proof of Theorem 3.
Figure 6: A 17 polyomino can be folded into a unit cube in model ; grid; diagonal. The mountain and valley folds are shown in red and blue, respectively.
((a))
((b))
Figure 9: In case we allow , half-grid folds, and diagonal folds only, shape does not fold to a unit cube . However, if we do not require faces of to be covered by full unit squares of , does fold into , the mountain (red) and valley folds (blue) are shown in LABEL:sub@fig:lb9-b.

Integrating diagonal and half-grid folds (which we omit from the hierarchy of Figure 5) can result in even stronger models. For instance, a 17 polyomino can be folded into a unit cube in model ; grid; diagonal (see Figure 6), but not in any (the strongest model shown in Figure 5). The example shown in Figure 9 shows that any; interior faces; grid; diagonal; half-grid is strictly stronger than any; interior faces; grid; diagonal.

We need the following lemma to prove the hierarchy of Figure 5.

Figure 10: The shape needs interior faces to be folded into a polycube.

(a)

(b)

(c)


(d)


(e)

(f)

(g)

(h)

Figure 11: Examples for Theorem. 3: polyominoes (a) , (b) , (c) , and (d) ; and polycubes (e) a unit cube , (f) a 211 polycube , (g) a 332 polycube with a 1-cube hole centered in a 33 face, and (h) a -cube cross .

Folding the tree shape shown in Figure 11(b) into the polycube shown in Figure 11(f) with requires interior faces. (Either of the faces or shown in Figure 10 can be the interior face.)

We label the faces of as shown in Figure 10. The case analysis below shows that a folding without interior faces does not exist, as in every case we are forced to fold away at least two faces. Since and has 10 faces, there will not be enough remaining faces to complete the folding.

First note that any folds will reduce the figure to at most squares, and it is easy to check that these cannot be folded to without an additional overlap. Furthermore, all of the folds between pairs of exterior faces of have the same orientation, so (in the absence of degree folds to reverse the orientation) any fold from to that avoids interior faces can only use one of the two angles or . Therefore, it is sufficient to check that cannot be folded to using only folds and only exterior faces.

If face covers one of the 11 faces of , faces and are forced to cover faces and , respectively, thus doubling two faces. If face covers part of a face of , then there are two subcases: If face or face covers the adjacent face of then faces and are forced to cover faces and , respectively, thus doubling two faces. If face or face covers the other half of the face of then faces , and are forced to collectively cover faces , and , thus doubling at least two faces. Therefore, it is not possible to fold into without interior faces.

The following establishes the relationships between models presented in Figure 5.

The folding models consisting of combinations of the following folds {, , , , any; interior faces; grid} have the mutual relations presented in Figure 5. In particular, these mutual relations hold for polyominoes without holes. First note that all containments are obvious: for any two models and corresponding to two nodes of the hierarchy given in Figure 5 such that there is an arrow from to , trivially . It remains to give examples to show that either two models are incomparable or that one is strictly stronger than the other, that is, to show that there exists a polyomino that folds into a given polycube under one folding model, but not under the other. All cases can be shown using the polyomino-polycube pairs shown in Figure 11. They fold with: (a) , folds, (b) and interior faces (see Lemma 3), (c) folds, (d) , and interior faces.

Example (a) establishes relations , , , , , , , .

Example (b) establishes relations , , , , , , , .

Example (c) establishes relations , , , , , , , .

Example (d) establishes relation .

Let , , , , , , , , and .

First we will give a detailed proof for Relation 25. We will then present the proofs for the other relations more briefly.

Relation 25: is strictly stronger than . Any polyomino that folds into polycube in  also folds into in . To prove a strict relation, we must show that there exists some polyomino that folds into some polycube in , but that does not fold into in . Let consist of five cubes forming a cross as in Figure 11(h) (), and let be as in Figure 11(d) (). Assume that can be folded into in the folding model . Polyomino consists of unit squares, while has square faces on its surface. Therefore, out of the squares of will be the faces of  when folded. Consider the 121 subpolyomino of . When folded, it has to form the “walls” of the cross , that is, the vertical faces of , otherwise this strip can form not more than eight faces of the cross (looping around one of the 311 subpolycubes). It is straightforward to see now, that in the two yellow squares prevent from folding into . However, in the two yellow squares can form interior faces with a interior fold. Therefore, .

Relation 1: We show that folds into in , but does not fold into in . , and has square faces on its surface. Hence, all squares of are faces of . Consider the subpolyomino, , of . When folded with only, there exist only two positions for this subpolyomino in . In both positions the center piece covers ’s face; the two positions differ only by a rotation of . But then the two flaps of size one and two, respectively, adjacent to need to fold into the 1-cube hole, using folds at the flap grid lines adjacent to . But a fold at the remaining grid line of the size two flap does not result in the outer square covering a separate face of . This contradicts the assumption that all squares of are faces of .

Relation 2: We show that folds into in , but does not fold into in . , while has square faces on its surface. Using folds the two subpolyominoes of fold to two rings of size four. Folding along both grid lines adjacent to the connecting square with those two rings overlap. This results in an overlap of four faces, making it impossible to constitute a shape of faces with the -square shape . In one grid line adjacent to the connecting square is folded with , the other with . Folding all other grid lines with  results in .

Relation 3: We show that folds into in , but does not fold into in . , while has square faces on its surface. Hence, only one square of can either overlap with another square or constitute an interior face of . does not allow interior faces; hence, Lemma 3 shows that does not fold into in .

Relation 4: We show that folds into in (see proof of Relation 2), but does not fold into in . , while has square faces on its surface. To cover at least one of the subpolyominoes of must be folded into a ring of size four using either folds only or folds only; without loss of generality we assume that the fold uses only folds. If we fold the grid line of the connecting square adjacent to this ring with , the connecting square does not cover a face of , thus we need to use a fold. The same holds true for the other grid line adjacent to the connecting square, and for the remaining grid lines. Then the proof of Relation 2 shows that we cannot fold into using folds only.

Relation 5: We show that folds into in (see proof of Relation 1), but does not fold into in . , and has square faces on its surface. Hence, all squares of are faces of . Again, there only exist two positions for . The two flaps of size one and two adjacent to again need to constitute faces of the 1-cube hole. The flap grid lines adjacent to need to be folded with folds, but then neither a fold, nor a fold at the remaining grid line of the size two flap, result in the outer square covering a separate face of .

Relation 6: We show that folds into in (see proof of Relation 3), but does not fold into in . No interior faces are allowed in ; hence, Lemma 3 shows that does not fold into in .

Relation 7: We show that folds into in (see proof of Relation 2), but does not fold into in . , while has square faces on its surface. The proof of Relation 2 showed that using only folds is insufficient to fold into . That is, we would have to use interior faces to fold into in . As  is a unit cube, we need two folds of , an infeasible grid fold in .

Relation 8: We show that folds into in (see proof of Relation 1), but does not fold into in . , and has square faces on its surface. Hence, all squares of are faces of . In the proof of Relation 1 we showed that does not fold into in . As we need to use interior faces to fold into . But any such interior face would be a square of that is not a face of .

Relation 9: We show that folds into in (see proof of Relation 3), but does not fold into in . No interior faces are allowed in ; hence, Lemma 3 shows that does not fold into in .

Relation 10: We show that folds into in , but does not fold into in  (see proof of Relation 9). In the proof of Relation 3 we showed that folds into  in . As this holds true for .

Relation 11: We show that folds into in , but does not fold into in (see proof of Relation 8). In the proof of Relation 5 we showed that folds into in . As this holds true for .

Relation 12: We show that folds into in , but does not fold into in (see proof of Relation 7). In the proof of Relation 7 we showed that folds into in . As this holds true for .

Relation 13: We show that folds into in , but does not fold into in  (see proof of Relation 6). In the proof of Relation 6 we showed that folds into  in . As this holds true for .

Relation 14: We show that folds into in , but does not fold into  in  (see proof of Relation 5). In the proof of Relation 5 we showed that folds into  in . As this holds true for .

Relation 15: We show that folds into in , but does not fold into in  (see proof of Relation 4). In the proof of Relation 2 we showed that folds into  in . As this holds true for .

Relation 16: We show that folds into in , but does not fold into in . No interior faces are allowed in ; hence, Lemma 3 shows that does not fold into in . In the proof of Relation 9 we showed that folds into in . As this holds true for .

Relation 17: We show that folds into in , but does not fold into in . , and has square faces on its surface. Hence, all squares of are faces of . In the proof of Relation 8 we showed that does not fold into in . As we need to use folds to fold into . But any such fold would cover a face of twice, a contradiction to all squares of being faces of . In the proof of Relation 8 we showed that folds into in . As this holds true for .

Relation 18: We show that folds into in , but does not fold into in (see proof of Relation 17). In the proof of Relation 8 we showed that folds into in . As this holds true for .

Relation 19: We show that folds into in (see proof of Relation 12), but does not fold into in . In the proof of Relation 8 we showed that does not fold into in . As we need to use interior faces. As is a unit cube, we need two folds of , an infeasible grid fold in .

Relation 20: folds into in (see proof of Relation 15), but does not fold into in (see proof of Relation 19).

Relation 21: folds into in (see proof of Relation 10), but does not fold into in (see proof of Relation 16).

Relation 22: We show that folds into in , but does not fold into in (see proof of Relation 16). In the proof of Relation 3 we showed that folds into in . As this holds true for .

Relation 23: We show that folds into in , but does not fold into in (see proof of Relation 19). In the proof of Relation 2 we showed that does not fold into in . As this holds true for .

Relation 24: We show that folds into in , but does not fold into in (see proof of Relation 17). In the proof of Relation 1 we showed that folds into in . As this holds true for .

All but one of the polyominoes used in the proof of Theorem 3 (Figure 11(a)-(d)) are tree shapes, that is, polyominoes whose dual graph of unit squares is a tree. We conjecture the following:

Conjecture 1

The hierarchy in Theorem 3 also holds for tree shapes.

(a)

(b)

Figure 12: (a) Shape that needs both mountain and valley folds to cover a unit cube . (b) The mountain and valley folds are shown in red and blue, respectively.

There exist tree shapes that need both mountain and valley folds to cover a unit cube .

The shape shown in Figure 12(a) does not fold into a unit cube with only valley folds: the four unit squares in the left column (gray) fold to a ring of size four, and the two flaps can only cover one of the two remaining cube faces. But with both mountain and valley folds, can be folded into , by using a fold between the first column and the longer flap, see Figure 12(b).

We used example (d) in Theorem 3 to show that some polyominoes require the use of interior faces in order to fold to a given polycube. The following theorem shows that , with size , is a minimal example of a polycube such that folding it with a tree shape may require interior faces.

Let any; interior faces; grid. Any tree shape that folds into a unit cube with interior faces also folds into a unit cube without interior faces.

We use induction on the size of . Therefore, consider a that folds into a unit cube with interior faces such that any smaller tree that folds into a unit cube with interior faces also folds into a unit cube without interior faces. If folds into a unit cube with interior faces in multiple ways, fix one of them with as few interior faces as possible; if the number of interior faces is 0, then the induction is complete. In the rest of this proof, “the folding of ” refers to that folding.

The proof progresses as follows: first, we argue that we can fold away extraneous branches of the folded tree shape interior to the cube, leaving only topologically necessary interior faces. Then, we show that the interior faces must be connected to form long “interior paths”. Finally, by restricting the ways these interior paths can turn and connect to the cube faces, we show by case analysis that the interior faces can be refolded to lie on the cube faces.

Claim 1: No interior face of the folding of is a leaf of the dual of .

If the folding of has some interior face that is a leaf of the tree, then the restriction of the folding of to also folds into a cube (possibly with interior faces), so it folds into a cube without interior faces. But if we fold onto its parent in the tree and identify the two faces, we get exactly the restriction of the folding of  to , so we can use that folding to fold all of into a cube without interior faces.

Since no interior face is a leaf, every interior face is part of some path joining two cube faces in the folding of . Call such a path (including the two cube faces at its ends) an “interior path”. When convenient, we may refer to the unfolded state of such a path by the sequence of directions from each square to the next, using N(orth) for positive y, S(outh) for negative y, W(est) for negative x, and E(ast) for positive x; for instance, the path of the three squares at the grid positions (0,0), (0,1), and (1,1) could be written NE or WS.

Claim 2: Every interior path has length at least 4.

Any single square which joins to two cube edges is one of the cube faces. So there are at least two interior faces in any such path, plus one face at each end, for a total of at least 4.

Claim 3: Some interior path has at least one turn in the unfolded state.

Suppose to the contrary that every interior path has no turns in the unfolded state; that is, that all such paths are rectangles in the unfolded state. We will eliminate such paths one by one. After eliminating each path, we will have a folding of into a cube with possibly-intersecting interior faces, but after all interior paths are eliminated, there can be no more interior faces that could intersect, and we will have a proper folding of (defined by fold angles at the edges) into a cube without interior faces. This folding can always be done without interference between cube face squares. The interior path splits the polyomino into two pieces, each of which can be folded independently of each other just as they were in the original folding. So we are left with two partial cubes, connected by the interior path. If we invert every mountain and valley fold in the folding of one of them, we get a folding with inverted orientation (that is, with the innermost layer outermost and vice versa). Then we can nest the folding of one part inside the folding of the other part.

If we have an extended interior path that is a rectangle consisting of squares , , , , …, (where and are cube faces), note that all the edges between squares on the path are parallel, and the edge between and is a cube edge, so all of them are parallel to the same cube edge. Without loss of generality, let that cube edge be vertical. We will leave every square in the component of containing  in place, unfold the path so that it goes around the faces of the cube other than the top and bottom (and, since it has at least 4 faces by Claim 2, it covers all four such faces), and rotate the rest of the unfolding of around the vertical axis of the cube so that it still connects to . The top and bottom faces are still covered because they were covered in the folding of , and every existing cube face has either been left in place or rotated around the vertical axis of the cube, both of which take the top face to the top face and the bottom face to the bottom face.

After eliminating all such paths that way, we get a folding of into a cube with no interior faces, as desired.

Claim 4: In every interior path, there is at least one interior square between each cube face to which the path connects and the first square at which the path turns.

Suppose there is an interior path that turns at its first interior square . Let the orientation of the cube edge to which connects be , let the orientation of the edge on which connects to the next square of the path be , and let the orientation of the other edge of be . has one vertex at a vertex of the cube, since it shares an edge of adjacent (as an edge of ) to the edge on which connects to a cube face. Without loss of generality let the cube be axis-aligned and let be the vertex with the least value in every coordinate. Then any edge inside the cube with an endpoint at goes in a nonnegative direction in every coordinate. In particular, and are two such directions, and they are perpendicular, so their dot product is 0, so in every coordinate at least one of them is 0. Since there are only three coordinates, one of them is nonzero in at most one coordinate, that is, one of and is the orientation of a cube edge. If is the orientation of a cube edge, then has sides of orientations and and is therefore a cube face, contradicting the definition of . If is the orientation of a cube edge and isn’t , then is perpendicular to two cube edge orientations and and is therefore a cube edge orientation. Finally, if , then and are in the same place in the folding, so if in the unfolded state we first fold onto , we get a tree which folds into a cube with interior faces and which therefore by induction folds into a cube without interior faces.

Claim 5: If a square of an interior path is parallel to one of the cube faces, then there are at least two interior squares between it and any cube face to which the path connects.

Let be an interior square parallel to a cube face, and suppose that exactly one interior face connects an edge of it to a cube edge . Then would either be a vertical translation of by a distance strictly between 0 and 1 or a horizontal translation of such by exactly 1, and in both cases the distance from to is not exactly 1.

Claim 6: No interior path with exactly one turn connects to cube faces at edges of the same orientation.

Suppose to the contrary there is an interior path with exactly one turn that connects to edges of the same orientation. Let be the square at which that path turns. divides the path into two rectangles whose intersection is . In each such rectangle, the two edges of length 1 are parallel, since in each square of the rectangle, the two opposite edges are parallel. Since connects to edges of the same orientation, all four edges of length 1 in those rectangles are parallel; in particular, two consecutive edges of are parallel. But they are consecutive edges of the square, so they are perpendicular, a contradiction.

Claim 7: No interior path with exactly one turn connects to cube faces at edges of different orientations.

Suppose to the contrary that such a path exists. Let be the square at which the path turns. Consider the orientations of the internal (folded) edges of that path: the first one is parallel to one cube edge, and every folded edge before the turn is parallel to it, and the last one is parallel to a differently oriented cube edge, and every folded edge after the turn is parallel to it, so the two folded edges at the turn are each parallel to one of the cube edges, so is parallel to a cube face, without loss of generality the top one. Since is contained in the cube, it is a vertical translation of the top face.

There are at least two interior faces between and each end of the path by Claim 5. Then the interior path and the two cube faces to which it connects form an shape with side length 4 squares. In this case we could fold away every other square of (starting with the leaves) and ignore them; an of side length 4 already folds into a cube.

Claim 8: No interior path with exactly two turns connects to cube faces at edges of different orientations.

Suppose to the contrary that there is an interior path with exactly two turns that connects to edges of different orientations and , and let the orientations of the folded edges in the path be , , and . Then is perpendicular to both and (since the first turn square has edges oriented and and the other has edges oriented and ), so is also an orientation of a cube edge. Then is interior to the cube and parallel to the cube faces and is interior to the cube and parallel to the cube faces, so they intersect, contradiction.

Claim 9: No interior path with exactly three turns connects to cube faces at edges of the same orientation.

Suppose to the contrary that such a path exists. Let the orientations of the folded edges be , , , and again. Then and are perpendicular, and are perpendicular, and and are perpendicular, so the square with edges oriented and is perpendicular to one cube edge (and hence parallel to a cube face) and contained inside the cube, so it is a translation of a cube face, that is, and are the other two orientations of cube edges. Then the square at which the path first turns has edges and , so it is a translation of the cube face, and the square at which the path turns second has edges and , so it is a translation of the cube face. Both of those squares are inside the cube, so they intersect, a contradiction.

Claim 10: No interior path with exactly three turns connects to cube faces of different orientations.

Suppose to the contrary that such a path exists. Let the orientations of the folded edges be , , , and . Then and are perpendicular, and are perpendicular, and are perpendicular, and and are perpendicular (since they are two distinct cube edge orientations), so each of and is perpendicular to each of and . But we’re working in 3 dimensions, so the span of and and the span of and cannot both be two-dimensional, that is, either or . Without loss of generality , and the orientations of the folded edges of the path are , , , and . By Claim 5, there are at least 4 squares in a line up to the square spanned by and , and by Claim 4, there are at least three squares in a line starting from the last square spanned by and . That is, the unfolded state contains, after folding away any extra squares in those lines, either NNNENWW or NNNENEE or NNNESEE or NNNESWW, up to rotation and reflection. One fold takes the middle two to NNNEEE, which folds into a cube; one fold takes the other two to a line of four with one square on either side, which folds into a cube.

Claim 11: No interior path has an even number of turns that is greater than or equal to .

Suppose to the contrary that such a path exists. By Claim 4, there are at least three squares in a line up to and including the first square at which there is a turn and three squares in a line from the last square at which there is a turn. Also, there are at least two squares on the path between those two lines of length 3, since there are at least two more squares at which the path turns. Let the lines of length 3 be oriented east-west in the unfolded state. If they are separated by at least two spaces north-south, then we can fold over any north-south folds (between squares adjacent east or west) to get a north-south line of length 4 with two lines extending by two to the east or west; by folding one of those over if necessary, we get a line of length 4 with a square on either side, which folds into a cube. If there are two lines of length 3 that cover at least 5 spaces east-west, then by folding east-west folds in the middle we get EENEE, which folds into a cube. Otherwise, we have two lines of length 3 separated by at most one space north-south and covering at most 4 spaces east-west. By folding any east-west folds north of the north line or south of the south line, we get, up to rotation or reflection, either EESWSEE or EESWSWW or EESWWSEE(E). The first two fold into WSWSW, which folds into a cube; the last folds into WSWWS, which folds into a cube.

Claim 12:

No interior path has an odd number of turns that is greater than or equal to 

.

Suppose to the contrary that such a path exists. First, if there are any squares in the interior of the path at which turns don’t occur, fold them over. Without loss of generality, let the interior path start at (0,0) and go EES to (1,0), (2,0), (2,-1). If the path ever extends two spaces farther E in the unfolded state, folding over all north-south folds past that EES that gives at least EESEE, which folds into a cube. If the path ever again extends farther W than it started in the unfolded state, then folding over all north-south folds past that EES gives at least EESWWW, which folds into EESEE, which folds into a cube. So, if the unfolded state ever extends farther N than 1, it does so via the spaces (3,-1) and (3,0). Also, if the unfolded state extends as far N as 2, then all three spaces (3,-1), (3,0), (3,1) are used and in a straight line, so by folding all east-west folds after (3,-1) and all north-south folds before it, we get EEENNN, which folds into a cube. If the unfolded state extends farther N than 0, then, since the unfolded state ends with a N-S line of three squares (since there are an odd number of turns), can’t go back below N=0 once it is gone above it, and doesn’t have room for a N-S line of length three ending anywhere but (3,1), the unfolded state ends at (3,1). Since the path has length at least 9, (2,-1) doesn’t connect directly to (3,-1), so all four spaces (3,-2), (3,-1), (3,0), and (3,1) are used and in a straight line, and by folding all east-west folds after (3,-1) and all north-south folds before it, we get EEENNN, which folds into a cube. If the path extends both as far E as 3 and as far S as -3, then by folding anyway anything W of 2 by north-south folds, we get (E)ESSSE, which folds into a cube. If the path extends as far E as 3, then it fits in a bounding box and has at least 5 turns, and the only two remaining paths are EESWWSEEENN and EESWSEENN. The first can be folded into the second, which can be folded into EESSENN, which can be folded into EESSES, which can be folded into ESSES, which folds into a cube. In the only case left, the unfolded state is only three squares wide east-west. If any of the other cases apply starting from the other end of the path, we also fold into a cube; otherwise, the unfolded state fits in a square, but it is at least 9 long and starts and ends with perpendicular paths of length 3, which don’t fit in a square, contradiction. Hence any such path can be folded into a cube.

Claim 13: No interior path with exactly two turns connects to cube faces at edges of the same orientation.

If there is such a path , say it connects to cube faces at edges of the same orientation . Let the orientations of the folded edges be x, y, and x, let and be the squares at which the turns occur (whose edges are oriented and ), and let and be the cube faces at the ends of the paths. Then by Claim 4. Without loss of generality, let the first turn in the unfolded state be a right turn.

If the second turn is a left turn, then fold away everything but the path, and fold away the portion of the path between and to get a path of length 6 that goes NNENN, which folds into a cube.

If both turns are right turns and either or , then we can fold away the portion of the path between and and fold the other edge adjacent to either or to get a path of length 6 that goes NNENN, which folds into a cube.

If both turns are right turns and , then by folding everything else away and folding the edge between and we get a path that goes SEEES, which folds into a cube.

If both turns are right turns, , and either end of the path (without loss of generality the end of the path) connects to more than one square (besides or ), then the path contains either N, N, E, S*, S, S or N, N*, E, S, S, E, and making 180 folds over the starred edges gives a shape that folds into a cube.

If both turns are right turns, , and neither end of the path connects to more than one square in the folded state, then there are more squares in the unfolded state than the six squares of the path , , , , , , because those only cover 2 cube faces. By the previous paragraph, the rest of the unfolding doesn’t connect at or , and by Claim 4, nothing connects at or . Suppose some path leading to another cube face connects to . If the next square on is , then the path , , , , is an interior path with at least two turns and its first two turns in different directions, but we’ve already eliminated all such cases. Otherwise, the next square of is . If the following square is , then the path , , , , is an interior path with at least two turns and its first two turns in different directions, but we’ve already eliminated all such cases. If the following square is , then the path , , , , is an interior path with at least one turn and at least three spaces in a line after its first turn, but we’ve already eliminated all such cases. So the following square is . That accounts for both turns on the path, so the next square is . If that is not a cube face, then the path , , , , has two right turns and either or , an already-eliminated case. Similarly, if there is more than one cube face there, then the path , , , is a path with two right turns, , and an end of the path connecting to more than one square, an excluded case. So we’ve only accounted for three cube faces and need at least three more, but there is nowhere left that a path to a cube face can attach, contradiction.

If both turns are right turns, , and both ends of the path connect to more than one square (besides or ): in the unfolded state, and have exactly one square between them, and that square isn’t the extra square for both ends of the path because the unfolded state is a tree, so some end of the path (without loss of generality the end of the path) connects to a different other square, that is, the path contains either N, N, E, E*, S*, S, S or N, N*, E*, E, S, S, E, and making 180 folds over the starred edges gives a shape that folds into a cube.

If both turns are right turns, , and one end of the path (without loss of generality the end) connects to no cube faces except its end () in the folded state, then nothing else connects to the interior of the path, because we’ve already eliminated all cases for interior paths except this one and straight interior paths, but there is nowhere we can connect an interior path to this one without creating at least one non-straight interior path. We will refold the squares of the interior path to leave fixed and nevertheless cover the cube face that covered; this doesn’t affect any other cube faces. In fact, starting from , a path N, N, E, E, S, S along the cube covers four of its faces, and folding the first E and the first S 180 to get a path N, N, W, N covers the remaining two. So we can cover the whole cube without that interior path, as desired.

4 Polyominoes that fold into a cube

In this section we characterize all polyominoes that can be folded into a unit cube and all tree-shaped polyominoes that are a subset of a 2 or 3 strip and can be folded into a unit cube using arbitrary grid folds. In Section 4.1 we present exhaustive results for all polyominoes of constant size obtained by computer search.

Consider a polyomino of size and a unit cube under a folding model any; grid; diagonal; half-grid, such that each face of has to be covered by a full unit square of . Then there is a polyomino of size that cannot be folded into , while all polyominoes with can be folded.

((a))
((b))
((c))
((d)) connectivity transformation
((e)) number transformation
((f)) corner transformation
((g)) width/height transformation
Figure 20: Proof details for Theorem 4. The mountain and valley folds are shown in red and blue, respectively. Unit squares marked with “x” can be located at an arbitrary height and light gray squares fold away. For the two adjacent corner transformations in the left of LABEL:sub@fig:ub10a-f, fold away the upper shaded corner before folding away the lower one.

For the lower bound see Figure 9. The polyomino in Figure ((a))(a) cannot be folded into a unit cube under our model. Note that if we allow half-grid folds without requiring faces of to be covered by full unit squares of , we can turn this shape into a unit cube; see Figure ((b))(b).

For the upper bound , we start by identifying several target polyominoes, examples of which are shown in Figure ((a))(a)LABEL:sub@fig:ub10a-c. Each target polyomino can be folded into a cube using only grid folds. We denote them by listing the numbers of squares in each column, using + or – to signify the cases where the columns may be attached in arbitrary arrangements or a specific arrangement is required, respectively. The target polyominoes are:

  1. A 1+4+1 polyomino, composed of one contiguous column of four unit squares, with one more unit square on either side, at an arbitrary height.

  2. A 2–2–2 polyomino, composed of three (vertical) pairs attached in the specific manner shown.

  3. A 2–3+1 polyomino, composed of a (vertical) pair and triple attached in the specific manner shown, with one more unit square at an arbitrary height.

((h))
((i))
((j))
((k))
Figure 25: Proof details for Theorem 4. The mountain and valley folds are shown in red and blue, respectively. Regions shaded in light gray are folded away.

We next describe some transformations that can be used to convert any polyomino of sufficient size to one of the target polyominoes. See Figure ((d))(d)LABEL:sub@fig:ub10a-g for examples of the following. If is the maximum number of unit squares in any column (say, in ), we can apply a connectivity transformation LABEL:sub@fig:ub10a-d by using (horizontal) half-grid folds to convert into a polyomino in which these unit squares form a contiguous set, while leaving at least one unit square in each previously occupied column. A number transformation LABEL:sub@fig:ub10a-e lets us fold away extra unit squares for . Corner transformations LABEL:sub@fig:ub10a-f fold away unnecessary unit squares (or half-squares) in target shapes by using diagonal folds when turning them into a unit cube. Finally, width and height transformations LABEL:sub@fig:ub10a-g fold over whole columns or rows of onto each other, producing a connected polyomino with a smaller total number of columns or rows.

We consider a bounding box of of size , with . The unit squares are arranged in columns and rows, indexed and , with unit squares  in column , and unit squares in row .

Now consider a case distinction over ; see Figure ((h))(h)–Figure ((s))(s). For , the claim is obvious, as we can reduce to a 1+4+1 target; see, for example, Figure ((h))(h). For , note that and assume that . If , a width transformation yields the case , so assume , and therefore . By a number transformation, we can assume . If is a polyomino, we can make use of a 1+4+1 polyomino with corner transformations; see Figure ((i))(i). If , we have . Because is connected, any two units squares in column 1 must be connected via column 2, requiring at least three unit squares; because , we conclude that column 1 contains at most two connected components of unit squares. Thus, at most one connectivity transformation makes column 1 connected, with unit squares in column 2. Possibly using height transformation, we get a connected polyomino with vertical size six, six unit squares in column 1, and unit squares in column 2. For , there is a transformation to target shape 1+4+1 even if the squares in column 2 form a single connected component; for example see Figure ((j))(j). For , a similar transformation exists; see, for example, Figure ((k))(k). This leaves , and thus , without being a polyomino. This maps to a 1+4+1 target shape, as shown for example in Figure ((l))(l) by folding a unit square from column 2 that extends beyond the vertical range of the unit squares in column 1 over to column 0.

((l))
((m))
((n))
((o))
((p))
((q))
((r))
((s))
Figure 34: Proof details for Theorem 4. The mountain and valley folds are shown in red and blue, respectively. Regions shaded in light gray are folded away and the hatched region denote holes.

For and , we can use connectivity, height and width transformations to obtain a new polyomino that has height four, a connected set of unit squares in column 2 and , as well as unit squares in columns 1 and 3. Note that at least one square must remain in each of column 1 and column 3 throughout these transformations. This easily converts to a 1+4+1 shape, possibly with corner transformations; as in Figure ((m))(m) for example. Therefore, assume  and (without loss of generality) , implying . If and column 2 is connected, then contains a 2–3+1 target shape, see Figure ((n))(n) for an example; if column 2 is disconnected, we can use a vertical fold to flip one unit square from column 3 to column 0, obtaining a 1+4+1 target shape, similar to Figure ((o))(o). If , , and then a diagonal fold of the square in column 2, along with a corner transformation maps to a 1+4+1 target shape. As a consequence, we are left with , , , where . If , the unit squares in columns 1 and 3 must be connected. For this it is straightforward to check that we can convert into a 2–2–2 target polyomino; see Figure ((p))(p) for example. Therefore, consider , . This implies that column 1 contains at most two connected sets of unit squares. If there are two, then the unit squares in column 2 must be connected, implying that we can convert into a 2–3+1 target shape; as in Figure ((q))(q) for example. Thus, the four unit squares in column 1 must be connected. If the three unit squares in column 2 are connected, we get a 2–3+1 target shape; see for example Figure ((q))(q). If the unit squares in column 2 are disconnected, but connected by the three unit squares in column 3, we convert this to a 2–3+1 target shape; see Figure ((r))(r). This leaves the scenario in which there is a single unit square in column 1 whose removal disconnects the shape; for this we can flip one unit square from column 3 to column 0 in order to create a 1+4+1 target shape; see Figure ((s))(s) for an example.

For , we proceed along similar lines. If there is a row or column that contains four unit squares, we can create a 1+4+1; otherwise, a row or column with three unit squares allows generating a 2–3+1. If there is no such row or column, we immediately get a 2–2–2.

In order to classify which tree shapes

fold to a unit cube, we define two infinite families of polyominoes. First, the family given by a strip, with any number of added tabs consisting of squares adjacent to the same side of the strip and potentially including their left and/or right neighbors (see Figure 37). The second family consists of a strip with a single tab of height , also potentially with their left and/or right neighbors (Figure 38).

Given a tree shape , a unit cube and any; grid.

  • If is a subset of a strip, then only the infinite family defined by Figure 37 cannot fold into .

  • If is a subset of a strip, then only the infinite family defined by Figure 38 cannot fold into .

Figure 35: A vertical edge in a subset of a strip with possible adjacent vertices for subtrees.

For the subset of a strip consider one vertical edge, as shown in Figure 35, and the possible subtrees attached at , , and . One such vertical edge has to exist, otherwise the strip is a strip and never folds to a cube. We consider the length of subtrees attached at , , and when folded to the same row as this “docking” unit square to the vertical edge. With slight abuse of notation we refer to these lengths by , , and again.

(a)

(b)

(c)

(d)

(e)

Figure 36: In any; grid only the shapes in (a) and (d) folds into a unit cube , the shapes in (b), (c) and (e) do not fold into .

The first observation is that, if , then folds to a cube. In this case we can fold all other squares away to end up with the shape in Figure 36(a). Not included in this categorization are the four shapes shown in Figure 36(b)–(e). Of those only (d) folds into a cube.

Figure 37: An example polyomino from an infinite family that cannot fold into a unit cube.
Figure 38: Infinite family that cannot fold into a unit cube, with at least a height 2 red subset (others are optional).

Thus, if we characterize more precisely which cases yield the shapes from Figure 36(a) and (d), we obtain a cube for:

Figure 37 shows an example of a polyomino that does not satisfy the above conditions and thus does not fold to a unit cube.

For the subset of a strip, we denote the rows of the height strip by row 1, row 2 and row 3. In case we have more than three unit squares in two different rows, we can fold over squares to obtain the shape from Figure 36(a), which folds into a unit cube. Otherwise, only one row spans the length of the strip. If there are vertical edges adjacent to a strip to two different sides (above and below), that is, the strip is located in row 2, this folds to a cube. Consequently, if we have height three and cannot fold the shape into a unit cube, a long strip cannot be located in the center row, row 2, of the shape. Without loss of generality, let the strip be located in the lowest row, row 1. As we have height three, there is at least a height two part which is a subset of the red part in Figure 38 connected to the strip. That is, there are unit squares in row 2 and row 3, occupying a connected subset of the red part in Figure 38. Let these unit squares be denoted by . If there exists another vertical edge of length at least one, that is only adjacent to the strip (but not directly to ) we can fold over and obtain a case from above which can easily be folded to a unit cube. Consequently, only a single vertical subset of length two can be attached, as shown in red in Figure 38.

4.1 Enumeration of cube-foldable polyominoes

In this section we present results on folding polyominoes of constant size into a cube. We consider polyominoes of up to 14 unit squares. Our results have been obtained by exhaustive computer search. The second column of Table 1 shows the number of different free polynominoes with a given number of squares. Here, “free” means that elements which can be transformed into each other by translation, rotation and/or reflection are counted only once. For polyominoes whose dual (c.f. Section 2) is not a tree, that is, their connecting graph contains cycles, we considered all possible dual trees. Thus, we first generated all such dual trees for polyominoes of size up to 14. The third column of Table 1 shows their number, compared to the number of different free polyominoes. While the number of different free polyominoes is currently known for shapes of size up to 28 (http://oeis.org/A000105), the number of different dual trees was known only for up to 10 elements (http://oeis.org/A056841).

free dual foldable not
polyominoes trees with and and diagonal
2 1 1
3 2 2
4 5 5
5 12 15
6 35 54 11 0 0 43
7 108 212 90 24 39 59
8 369 908 571 175 126 36
9 1285 4011 3071 697 233 10
10 4655 18260 15645 2230 385 0
11 17073 84320 77029 6673 618 0
12 63600 394462 374066 19337 1059 0
13 238591 1860872 1803568 55477 1827 0
14 901971 8843896 8682390 158208 3298 0
Table 1: Different ways of folding small polyominoes into a cube.

We checked for each of the generated dual trees of a polyomino (of size six or more) whether it can be folded into a unit cube. We did this in three different steps. In the first step, we only allowed folds. Column 4 of Table 1 shows how many (dual trees of) polyominoes can be folded to a cube with this restriction. It is interesting to observe that while for only 11 polyominoes can be folded to a cube, for over of all shapes can be folded to a cube.

In the second step we tried and folds for the remaining dual trees. Table 1 gives in column 5 how many additional cube foldings can be obtained this way. For the dual trees for which this step found a folding, we never needed to use more than two folds. For and there are each only one example which needs two folds, and we found no such examples for : for those values of all foldable examples could be folded with just one fold.

In the last step we allowed also diagonal folds for the remaining dual trees. Column 6 of Table 1 shows how many additional dual trees can be folded in this case, and the last column gives the number of remaining (non-foldable) dual trees. The most interesting result here is that for all polyominoes, regardless of which dual tree we select for them, can be folded in this way. This is similar to Theorem 4, except that here we do not allow half-grid folds, but instead allow covering a cube face with triangles from diagonal folds. Moreover, all such foldings need at most one diagonal fold, with the exception of the strip, the only example we found that needs two diagonal folds.

Figure 39: Polyominoes of size 6 that cannot be folded to a cube (for any dual tree).
Figure 40: Polyominoes of size 7 to 9 that have dual trees which cannot be folded to a cube.

Figures 39 and 40 show all polyominoes of size for which dual trees exist (for for any existing dual tree), such that they cannot be folded to the unit cube using , , and diagonal folds. There are such polyominoes with a total of different dual trees for , polyominoes with dual trees for , polyominoes with dual trees for , and one polyomino with dual trees for . Note, however, that for many of them there are cuts (i.e., dual trees) such that they can be folded to the cube. For example, the square has dual trees that can fold to a cube (Figure 41).

Figure 41: Puzzle333Solution: The top row needs two folds, and the second and third row need one fold. The last two rows cannot be folded, even with diagonal folds. Note, however, that some of these cuttings can be folded if we allow half-grid folds, cf. Figure 9.: which cuttings of a square fold to a cube?

5 Dynamic programming algorithm for trees

Let be a tree shape, be a polycube with cubes, no four squares meeting at an edge, and . Then it is possible in linear time (in the size of ) to determine whether can fold to in folding model .

We choose an arbitrary root of . For each square of  define the subtree of  to be the tree shape consisting of all squares whose shortest path in  to the root passes through . For a square of , define a placement of  to be an identification of  with a surface square of  together with the subset of the squares of  covered by squares in the subtree of . We use a dynamic program that computes, for each square of , and each placement of , whether there is a folding of the subtree of that places in the correct position and correctly covers the specified subset. Each square has placements, and we can test whether a placement has a valid folding in constant time given the same information for the children of . Therefore, the algorithm takes linear time.

We have been unable to extend this result to folding models that allow folds, nor to folds with interior faces, nor to polycubes for which four or more squares meet at an edge. The difficulty is that the dynamic program constructs a mapping from the polyomino to the polycube surface (topologically, an immersion) but what we actually want to construct is a three-dimensional embedding of the polyomino without self-intersections, and in general testing whether an immersion can be lifted to a three-dimensional embedding is NP-complete [10]. For folds, a three-dimensional lifting always exists, as can be seen by induction on the number of squares in the tree shape: given a folding of all but one square of the tree shape, there can be nothing blocking the addition of the one remaining square to its neighbor in the tree shape. However, in the presence of folds, the addition of a square to an edge of a tree shape can be blocked by a fold surrounding that edge.

It is tempting to attempt to extend our dynamic program to a fixed-parameter algorithm for non-trees (parameterized by feedback vertex number in the dual graph of the polyomino), by finding an approximate minimum feedback vertex set, trying all placements of the squares in this set, and using dynamic programming on the remaining tree components of the graph. However, the problem of parts of the fold blocking other parts of the fold becomes even more severe in this case, even for folds. Additionally, we must avoid knots and twists in the three-dimensional embedding. These issues make it difficult to extend the dynamic program to the non-tree case.

6 Triangular Grid

In this section we discuss folding polyiamonds into polytetrahedra. A polyiamond is a 2D polygon that is a connected union of a collection of equilateral triangles on an equilateral triangular lattice. That is, polyiamonds are the analog to polyominoes with equilateral triangles instead of unit squares. We use the same notation as with polyominoes, so the number of triangles comprising a polyiamond is called the size of the polyiamond, and we say a polyiamond is a tree-polyiamond if its dual graph is a tree. A polytetrahedron extends the notion of a polycube, simply replacing unit cubes with regular tetrahedra. (Note, however, that the shapes of polytetrahedra are limited by the fact that regular tetrahedra do not tile space.)

We begin by noting that there are exactly polyiamonds that are tree shapes but do not fold into a tetrahedron.

In the folding model any; grid, a tree-polyiamond folds into a tetrahedron if and only if it is not one of the following shapes:

The tetrahedron has two nets: one whose dual has a vertex of degree , and one whose dual is a path of length and whose triangles do not all share a vertex. If a polyiamond contains either of the two nets, those four triangles may be folded into a tetrahedron with all of the other triangles of the polyiamond folded flat against the faces of the tetrahedron.

Therefore, we need to show that the above polyiamonds are the only polyiamonds that do not contain a net of a tetrahedron, and that none of the six can be folded into a tetrahedron in some other way. If the dual tree of the polyiamond contains a vertex of degree , the polyiamond contains a net of the tetrahedron and can therefore be folded into a tetrahedron. Therefore, it is sufficient to consider polyiamonds whose dual trees are paths. If we examine a polyiamond whose dual is a path that does not contain the second tetrahedral net, either the polyiamond contains fewer than triangles, or each of its triangles share a single vertex. The only possibilities are the six mentioned above. None can cover a tetrahedron, because they cannot reach the tetrahedron face that is opposite the shared vertex.

7 Conclusion

Various open problems remain.

First, we gave an example of a tree shape that does fold into a polycube for any; interior faces; grid, but not in weaker models. In particular, has no folding into that avoids using interior faces. consists of 5 unit cubes—is it minimal?

Second, we characterized tree shapes that are a subset of a strip and fold into a unit cube in the