Maths Olympiad Prep

Library / /356 of 397

Combinatorics Difficulty 7.0 National Olympiad Prove it Taiwan

Let T={1,2,,n}T = \{1, 2, \dots, n\}. For a subset S={s1,s2,,sk}TS = \{s_1, s_2, \dots, s_k\} \subseteq T where s1>s2>>sks_1 > s_2 > \dots > s_k, define
f(S)=s1s2+s3s4+; f(S) = s_1 - s_2 + s_3 - s_4 + \dots;
g(S)=s1s3+s5s7+, g(S) = s_1 - s_3 + s_5 - s_7 + \dots,
that is, gg is the weighted sum obtained by giving weights 1,0,1,01, 0, -1, 0 in order and cyclically, while ff is the weighted sum obtained by giving weights 1,11, -1 in order and cyclically; clearly, f()=g()=0f(\emptyset) = g(\emptyset) = 0.

a. Find a formula for STf(S)\sum_{S \subseteq T} f(S), that is, the sum of f(S)f(S) over all subsets STS \subseteq T.

b. Find a formula for STg(S)\sum_{S \subseteq T} g(S).

c. If you cannot solve (b), then likewise find STg(S)\sum_{S \subseteq T} g(S), but this time let T={1,2,,8}T = \{1, 2, \dots, 8\}.

Solution

(a) (2 points) Let Fn=STf(S)F_n = \sum_{S \subseteq T} f(S) for n=0,1,2,n = 0, 1, 2, \dots. Considering whether the number nn is "in" or "not in" the subset SS, we obtain the following equality:
Fn=ST{n}(nf(S))+Fn1=n×2n1Fn1+Fn1=n×2n1. \begin{aligned} F_n &= \sum_{S \subseteq T - \{n\}} (n - f(S)) + F_{n-1} \\ &= n \times 2^{n-1} - F_{n-1} + F_{n-1} \\ &= n \times 2^{n-1}. \end{aligned}

(b) (5 points) Let Gn=STg(S)G_n = \sum_{S \subseteq T} g(S) for n=0,1,2,n = 0, 1, 2, \dots. Clearly G0=0G_0 = 0, G1=1G_1 = 1, G2=5G_2 = 5, G3=16G_3 = 16. Below assume n3n \ge 3. Consider whether the subset SS contains nn or not; when it contains nn and there is a second-largest element, let the second-largest element be designated as kk, so we obtain

Gn=Gn1+n×2n1k=1n1Gk1=Gn1+n×2n1Gn2k=1n2Gk1=Gn1+n×2n1Gn3(n2)×2n3+k=1n3Gk1k=1n2Gk1=Gn12Gn3+(3n+2)×2n3, \begin{align*} G_n &= G_{n-1} + n \times 2^{n-1} - \sum_{k=1}^{n-1} G_{k-1} \\ &= G_{n-1} + n \times 2^{n-1} - G_{n-2} - \sum_{k=1}^{n-2} G_{k-1} \\ &= G_{n-1} + n \times 2^{n-1} - G_{n-3} - (n-2) \times 2^{n-3} + \sum_{k=1}^{n-3} G_{k-1} - \sum_{k=1}^{n-2} G_{k-1} \\ &= G_{n-1} - 2G_{n-3} + (3n+2) \times 2^{n-3}, \end{align*}
or
GnGn1+2Gn3=(3n+2)×2n3. G_n - G_{n-1} + 2G_{n-3} = (3n + 2) \times 2^{n-3}.
The above recurrence is non-homogeneous. Suppose G^n=(α+βn)2n\hat{G}_n = (\alpha + \beta n)2^n is a particular solution; substituting into the recurrence gives
(α+βn)2n(α+β(n1))2n1+2(α+β(n3))2n3=(3n+2)×2n3(8α4α+4β+2α6β)+(8β4β+2β)n=2+3nα=β=12G^n=(1+n)2n1. \begin{align*} & (\alpha + \beta n)2^n - (\alpha + \beta(n-1))2^{n-1} + 2(\alpha + \beta(n-3))2^{n-3} = (3n + 2) \times 2^{n-3} \\ \Rightarrow \quad & (8\alpha - 4\alpha + 4\beta + 2\alpha - 6\beta) + (8\beta - 4\beta + 2\beta)n = 2 + 3n \\ \Rightarrow \quad & \alpha = \beta = \frac{1}{2} \\ \Rightarrow \quad & \hat{G}_n = (1 + n)2^{n-1}. \end{align*}
After homogenizing the recurrence: GnGn1+2Gn3=0G_n - G_{n-1} + 2G_{n-3} = 0, whose characteristic polynomial is x3x2+2x^3 - x^2 + 2, and the roots of the polynomial are 1,1+i-1, 1+i and 1i1-i. So the general solution of the non-homogeneous recurrence will be:
Gn=A(1)n+B(1+i)n+C(1i)n+(1+n)2n1. G_n = A(-1)^n + B(1+i)^n + C(1-i)^n + (1+n)2^{n-1}.

Checking the boundary conditions:
G0=0=A+B+C+12; G_0 = 0 = A + B + C + \frac{1}{2};
G1=1=A+(1+i)B+(1i)C+2; G_1 = 1 = -A + (1+i)B + (1-i)C + 2;
G2=5=A+2iB2iC+6. G_2 = 5 = A + 2iB - 2iC + 6.
From this we obtain A=0,B=1+i4A = 0, B = \frac{-1+i}{4} and C=1i4C = \frac{-1-i}{4}, that is
Gn=1+i4(1+i)n+1i4(1i)n+(n+1)2n1, G_n = \frac{-1+i}{4}(1+i)^n + \frac{-1-i}{4}(1-i)^n + (n+1)2^{n-1},
or
Gn=14((1+i)n+(1i)n)+i4((1+i)n(1i)n)+(n+1)2n1, G_n = \frac{-1}{4}((1+i)^n + (1-i)^n) + \frac{i}{4}((1+i)^n - (1-i)^n) + (n+1)2^{n-1},
or
Gn=12((n0)(n2)+(n4))+12((n1)(n3)+(n5))+(n+1)2n1 G_n = \frac{-1}{2} \left( \binom{n}{0} - \binom{n}{2} + \binom{n}{4} - \cdots \right) \\ \qquad + \frac{-1}{2} \left( \binom{n}{1} - \binom{n}{3} + \binom{n}{5} - \cdots \right) + (n+1)2^{n-1}

Want a route through all this instead of an archive? The track puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.

Source: MathNet, licensed CC-BY-4.0. Statement translated into English from zh; metadata (topic, difficulty) added by this project.