Skip to main content
OlympiadHQ

Browse · MathNet

Print

2024 CGMO

China 2024 counting and probability

Problem

There are 100 students in a summer camp, with exactly 2024 pairs of mutual friends. We need to divide them into 50 groups of 2 students each. Prove that: 1. It's possible to group them such that at most 20 groups contain mutual friends; 2. It's possible to group them such that at least 23 groups contain mutual friends; 3. It's possible to group them such that exactly 22 groups contain mutual friends.
Solution
Proof. Using the language of graph theory to describe this problem, we represent each student as a vertex and connect two vertices with an edge if the corresponding students are friends, forming a simple graph of order . By the given condition, has exactly edges.

Pair the vertices into pairs, called a "pairing." The problem requires proving the existence of a pairing where the number of adjacent vertex pairs satisfies certain conditions.

(1) It is well-known that the edge set of a complete graph of order can be partitioned into perfect matchings. Thus, there exist pairing methods such that each pair of vertices appears in exactly one of these pairings. Therefore, the total number of adjacent vertex pairs across these pairings is .

By the pigeonhole principle, there exists a pairing where the number of adjacent vertex pairs does not exceed .

(2) Assume the conclusion does not hold. Then, the maximum matching in has at most edges. We can add some edges to such that the maximum matching has exactly edges. We now prove that the number of edges in is less than .

Take a maximum matching, denoted as (), and let be the set of remaining vertices, where . By the maximality of the matching, there are no edges within . If a vertex or is adjacent to at least two vertices in , we call it a "good vertex."

Note that if one of or is a good vertex, the other cannot be adjacent to any vertex in ; otherwise, we could adjust to two other edges, resulting in a larger matching.

Suppose there are good vertices among (), where . Without loss of generality, assume are good vertices. For , and cannot be adjacent; otherwise, we could adjust and to three other edges, obtaining a larger matching.

Thus, the number of edges among is at most . For , there are at most edges between and . For , there are at most edges between and . Therefore,



which is a contradiction. This proves the conclusion.

(3) From the conclusions of (1) and (2), there exist two pairings: the first contains at most edges of , and the second contains at least edges of .

We now adjust the first pairing step-by-step to the second pairing as follows: Select a pair from the second pairing that is not in the first pairing. Suppose the first pairing contains and . Replace and with and .

After each adjustment, the number of pairs shared with the second pairing increases by at least one. Thus, after finitely many steps, the first pairing becomes the second pairing. Since each adjustment changes two pairs, the number of edges of in the pairing changes by at most . Starting from at most and ending with at least , if is not achieved at any intermediate step, there must exist a pairing with exactly edges of , which after one adjustment becomes with exactly edges of .

Let be , where is an edge if and only if .

Without loss of generality, assume adjusts and to and , and neither nor is an edge.

Note that in the following cases, we can adjust to obtain a pairing with exactly edges of :

Case 1: There exist such that among , there is a pairing with exactly one edge of . Replace and in with this pairing.

Case 2: There exist such that among , there is a pairing with exactly one edge of . Replace and in with this pairing, and then replace and with and . The resulting pairing has exactly edges of .

Case 3: There exist and such that among , there is a pairing with or edges of . Replace and in with this pairing. If the number of edges increases by one, also replace and with and . In any case, we obtain a pairing with exactly edges of .

Now assume none of the above cases occur. Note that the number of edges in is even, while the number of edges of the form is (odd). Thus, there exist such that among , , , , exactly an odd number are edges in . These four pairs can be split into two pairings: one with exactly edge of and the other with or edges.

Since Cases 1, 2, and 3 do not occur, we must have and . Without loss of generality, let , , and suppose and are either both edges or both non-edges (by swapping and if necessary). If neither is an edge, then in , replace and with and , resulting in a pairing with exactly edges of .

Now assume and are both edges of .

Since Case 3 does not occur, for any and , exactly two of , , , are edges of . Thus, the number of edges between and is exactly .

It follows that the number of edges among is at most . Thus, there exists a non-adjacent pair in . Without loss of generality, assume is not an edge of . Since Case 1 does not occur, is also not an edge.

In , replace , , , with , , , , resulting in a pairing with exactly edges of . This completes the proof. □

Techniques

Matchings, Marriage Lemma, Tutte's theoremPigeonhole principleCounting two ways