Skip to main content

2022 AIME I Problem 12

Problem 12 of 15HarderCombinatorics

For any finite set X,X, let ∣X∣|X| denote the number of elements in X.X. Define Sn=∑∣A∩B∣,S_n = \sum |A \cap B|, where the sum is taken over all ordered pairs (A,B)(A, B) such that AA and BB are subsets of {1,2,3,…,n}\{1, 2, 3, \ldots, n\} with ∣A∣=∣B∣.|A| = |B|. For example, S2=4S_2 = 4 because the sum is taken over the pairs of subsets (A,B)∈{(∅,∅),({1},{1}),({1},{2}),({2},{1}),({2},{2}),({1,2},{1,2})}, \begin{aligned} &(A, B) \in {}\\ &\quad \small\left\{\begin{gathered} (\emptyset, \emptyset), (\{1\}, \{1\}), \\ (\{1\}, \{2\}), (\{2\}, \{1\}), \\ (\{2\}, \{2\}), (\{1, 2\}, \{1, 2\}) \end{gathered}\right\}, \end{aligned} giving S2=0+1+0+0+1+2=4.S_2 = 0 + 1 + 0 + 0 + 1 + 2 = 4. Let S2022S2021=pq,\frac{S_{2022}}{S_{2021}} = \frac{p}{q}, where pp and qq are relatively prime positive integers. Find the remainder when p+qp + q is divided by 1000.1000.

Your answer

Integer from 0 to 999
Show solution

Solution

Count element by element: SnS_n equals the number of triples (x,A,B)(x, A, B) with ∣A∣=∣B∣|A| = |B| and x∈A∩B.x \in A \cap B. For a fixed xx and size k,k, there are (n−1k−1)\binom{n-1}{k-1} choices for each of AA and BB containing x,x, so by the Vandermonde identity Sn=n∑k=1n(n−1k−1)2=n(2n−2n−1). \begin{aligned} S_n &= n \sum_{k=1}^{n} \binom{n-1}{k-1}^2 \\ &= n\binom{2n-2}{n-1}. \end{aligned} Therefore S2022S2021=2022(40422021)2021(40402020)=20222021⋅4042⋅404120212=2⋅2022⋅404120212. \begin{aligned} \frac{S_{2022}}{S_{2021}} &= \frac{2022\binom{4042}{2021}}{2021\binom{4040}{2020}} \\ &= \frac{2022}{2021} \cdot \frac{4042 \cdot 4041}{2021^2} \\ &= \frac{2 \cdot 2022 \cdot 4041}{2021^2}. \end{aligned} Since 2021=43⋅472021 = 43 \cdot 47 divides neither 2022,2022, 4041=32⋅449,4041 = 3^2 \cdot 449, nor 2,2, this fraction is in lowest terms: p=2⋅2022⋅4041=16341804p = 2 \cdot 2022 \cdot 4041 = 16341804 and q=20212=4084441.q = 2021^2 = 4084441. Then p+q=20426245,p + q = 20426245, whose remainder modulo 10001000 is 245.245.
AoPS wiki

Tagged: subsets · combinations · double counting · Vandermonde’s Convolution

More practice