# Finding the maximum number of disconnected fragments

In a plane, we have a convex polygon with n sides. What would be the maximum number of disconnected pieces / fragments if this polygon is clipped against a square?

• Can the pieces be of arbitrary shape, or do you require concave pieces to be decomposed into convex pieces? Commented May 1, 2016 at 8:26
• When you say "clipped", can we assume that the inside of the square is discarded, and we are counting the number of disconnected pieces left outside the square? Commented May 1, 2016 at 8:28

A convex polygon has the property:

• A line drawn through a convex polygon will intersect the polygon exactly twice.

From this follows that any line trough splits the convex polygon in 2 pieces.

Image 1: convex polygon split by a line.

Using this, and assuming the inner piece is discarded we can craw the conclusion that there are five cases:

1. When the lines of the square do not exit the polygon. You now have a piece with a hole or the entire polygon is contained and theres no hole and no piece.
2. When the lines exit 2 times you have one fragment*
3. when the lines exit 4 times you have two fragments*
4. when the exits are 6 times you have three fragments*
5. when the exits are 8 times you have four fragments *

Image 2: the five cases, clipping rectangle and remaining shards in black. Even a squares has same cases if the polygons vary, just easier to draw this way.

The last case is the maximum so answer is four or five if you count the clipped part as one piece.

* Since we haven't tackled the cases very rigorously we know that this is the highest possible answer, there could be less for each case. There shouldn't be but I so far haven't given evidence for that. But thats okay it wasn't asked.

• What about the case where one corner of the square is inside the polygon and all others are outside? Commented May 8, 2016 at 14:08
• @RichieSams its the same case as splits into one shard, it exits 2 times and results in one concave shard. Commented May 8, 2016 at 14:56
• @trichoplax right i can add that. There shouldn't be less, but see i added the or less for your comment. I am not sure i have proven there isn't a smaller case (i could), there shouldn't be but i haven't laid out the proof very well for that case, not rigorous enough. I have however proven that there are no more cases than 4 and since i can find a 4 it proves that is maximum which is enough to answer the question at hand. Commented May 8, 2016 at 20:11
• @joojaa fair point. Commented May 8, 2016 at 20:24