18. a) Into how many parts can a plane be divided by two closed curves, one of which is a circle and the other is the boundary of a square?

b) $* *$ Into how many parts can space be divided by two closed surfaces, one of which is a sphere and the other is the surface of a cube?
18. a) The boundary of a square and a circle can divide the plane into parts of the following types:
1) the part located outside the square and outside the circle; such a part is always one;
2) the part located inside the square and inside the circle; if the square does not intersect the circle, then there are no such parts; otherwise, there is one such part;
3) the part located outside the circle but inside the square; such a part always contains at least one corner of the square, and for brevity, we will call it a "corner"; the number of "corners" does not exceed the number of corners of the square, i.e., four;
4) the part located outside the square but inside the circle; if the circle and the square intersect, then the boundary of such a part (a "segment") includes a segment of at least one of the four sides of the square; therefore, the total number of "segments" cannot exceed the number of sides of the square, i.e., four.

Thus, the maximum number of parts into which a square and a circle can divide the plane is

$$
1+1+4+4=10
$$

(Fig. 56, a). The minimum number of parts into which a square and a circle can divide the plane is, obviously, three: each line already divides the plane into 2 parts, and since they are different, the second line increases the number of parts by at least 1 (Fig. 56, b, c). It is easy to see that the number of parts into which a square and a circle divide the plane can be any number \( N \), where \( 3 \leqslant N \leqslant 10 \) (Fig. 56, a-u; the number of "corners" \( U \) and the number of "segments" \( C \) are indicated in parentheses).

b) A sphere and the surface of a cube can divide space into parts of four types:

1) outside the sphere and the cube (there is always 1 such part);
2) inside the sphere and the cube (there can be 0 or 1 such part);
3) outside the sphere but inside the cube (such a part must include at least one three-dimensional corner of the cube; for brevity, we will call such a part a "corner"; the number of them does not exceed the number of vertices of the cube, i.e., 8;
4) outside the cube but inside the sphere (if the sphere and the cube intersect, then the boundary of such a part must include at least one flat face; we will call such a part a "cap"; the number of them does not exceed the number of faces of the cube, i.e., 6).

Thus, the total number of parts cannot exceed

$$
1+1+8+6=16
$$

In Fig. 57, a case of the mutual position of the sphere and the cube is shown, where the number of parts into which both surfaces divide the space is maximal, i.e., 16 (the sphere touches all the edges of the cube).

The minimum number of parts into which a sphere and a cube can divide space is, obviously, 3 (compare the solution of part a)). Therefore, the total number of parts lies between 3 and 16.
![](https://cdn.mathpix.com/cropped/2024_05_21_15011fcc7946713185f0g-086.jpg?height=926&width=762&top_left_y=62&top_left_x=139)

Fig. 56.

![](https://cdn.mathpix.com/cropped/2024_05_21_15011fcc7946713185f0g-086.jpg?height=440&width=479&top_left_y=1101&top_left_x=289)

Fig. 57.
space, is maximal, i.e., 16 (the sphere touches all the edges of the cube).

In Fig. 57a, examples are given where the number of parts is 3, 4, 5, 6, 7, 8, 9, 10, 11, 12 (in parentheses—the number of "corners" \( U \) and the number of "caps" \( Ш \)). We will now prove that the sphere and the surface of the cube cannot divide space into 13, 14, or 15 parts.

The division of space into 13, 14, or 15 parts can only be achieved with the following values of \( (U, Ш): (8,3), (8,4), (8,5), (7,4), (7,5), (7,6), (6,5), (6,6) \), and \( (5,6) \); we will prove that none of these values can be taken by the pair \( (U, Ш) \). Leaving aside the "extreme" values \( (8,3) \) and \( (5,6) \), note that in all other cases \( Ш \geqslant 4 \) and \( U \geqslant 6 \). But if an edge \( AB \) of the cube lies entirely inside the sphere, then the planes of the four faces of the cube converging at vertices \( A \) and \( B \) cut off four spherical segments from the sphere, which together form one part of space inside the sphere and outside the cube; therefore, the number of \( Ш \) "caps," which can be at most 6, cannot exceed 3 in this case. Therefore, when \( Ш \geqslant 4 \), all 12 edges of the cube must intersect the sphere, touch it, or lie outside it, i.e., the mutual position of the sphere and the cube must be covered by the following table:

| Number of edges | Number of "caps" | 5 | 5 |  |
| :--- | :---: | :---: | :---: | :---: | :---: | :---: |
| intersecting the sphere | 0 | 1 | 2 | 3 |
| touching the sphere or lying outside it | 12 | 11 | 10 | 9 |

(The number of "caps," which can be at most 6, can decrease only due to the presence of edges of the cube that intersect the sphere or lie inside it.)

The number of edges touching the sphere cannot exceed 6. Indeed, if there were 7 or more, then at least 3 of them would belong to one face of the cube: since if among the four edges bounding each face of the cube, the sphere touched no more than two, the total number of edges of the cube touching the sphere could not exceed \( \frac{1}{2}(2 \cdot 6) = 6 \). (The product \( 2 \cdot 6 \) is divided by 2 because when counting edges "by faces," each edge is counted twice.) But if the sphere touches three edges belonging to one face \( \alpha \) of the cube, then the sphere intersects the plane \( \alpha \) along an inscribed circle in the face \( \alpha \), and the center of the sphere lies on the axis of symmetry of the cube perpendicular to the face \( \alpha \). Moving the center of the sphere along the line \( a \), we see that in this case the pair \( (U, Ш) \) can take the following values: \( (1,1), (1,5), (1,6) \), and \( (8,6) \) (the value \( (8,6) \), corresponding to the maximum number of 16 parts of space, is achieved when the sphere intersects two faces \( \alpha \) and \( \beta \) along inscribed circles in these faces); but none of these values \( (U, Ш) \) coincide with the ones we are interested in. Thus, the values \( (8,4), (8,5), (7,4), (7,5), (7,6), (6,5) \), and \( (6,6) \) of the pair \( (U, Ш) \) are impossible.

The value \( (5,6) \) of the pair \( (U, Ш) \) is impossible because when \( Ш = 6 \), all 12 edges of the cube touch the sphere or lie outside it (see the table above); but in this case, at least 6 edges of the cube lie outside the sphere, and therefore the number \( U \) of "corners" cannot equal 5 (it cannot exceed 2).

Finally, consider the value \( (8,3) \) of the pair \( (U, Ш) \). From \( U = 8 \), it follows that all 12 edges of the cube intersect the sphere or touch it; but since we have established that the number of edges touching the sphere cannot exceed 6, at least 6 edges intersect the sphere. But (we have already used this fact above) the presence of an edge \( AB \) of the cube intersecting the sphere leads to a decrease by one in the total number of \( Ш \) "caps," because in this case, the planes of the adjacent faces \( \alpha \) and \( \beta \) of the cube cut off segments from the sphere, which together form one part of space inside the sphere and outside the cube; therefore, when \( U = 8 \), \( Ш \) must be 2, which proves the impossibility of the case \( (U, Ш) = (8,3) \).

[Note that in part a), in the case of the maximum possible number \( N = 10 \) of parts of the plane, we can, by specifying a square, place the circle in different ways so that \( N \) equals 10. The nature of the case of the maximum possible number