CombinatoricsDifficulty 6.7National OlympiadProve itSouth Korea
Given an one-to-one correspondence f:{1,2,…,n}→{1,2,…,n} for some positive integer n, define four sets A, B, C, D as follows: A={i∣i>f(i)} B={(i,j)∣i<j≤f(j)<f(i) or f(j)<f(i)<i<j} C={(i,j)∣i<j≤f(i)<f(j) or f(i)<f(j)<i<j} D={(i,j)∣i<j and f(i)>f(j)} Prove that ∣A∣+2∣B∣+∣C∣=∣D∣, where ∣X∣ is the number of all elements in X.
Solution
We use an induction by the number ∣D∣: Firstly, if ∣D∣=0, f is identity and A=B=C=∅. So it holds for ∣D∣=0.
Next, assume that it holds that for all bijections with ∣D∣<k for some positive integer k. Given f with ∣Df∣=k>0, there exists i such that f(i)>f(i+1). Define the function g by g(j)=⎩⎨⎧f(i+1),f(i),f(j),if j=i,if j=i+1,otherwise. We are able to define four set (Ag,Bg,Cg,Dg) by the function g. Since ∣Dg∣=∣D∣−1=k−1<k, by the induction hypothesis, we have ∣Ag∣+2∣Bg∣+∣Cg∣=∣Dg∣.(5) Now, we divide five cases:
i. If f(i+1)>i and f(i)>i+1, then we have (∣Af∣,∣Bf∣,∣Cf∣,∣Df∣)=(∣Ag∣,∣Bg∣+1,∣Cg∣−1,∣Dg∣+1). ii. If f(i+1)=i and f(i)>i, then the property ∣{j∣j<i and i+1<f(j)}∣=∣{j∣f(j)<i and i+1<j}∣ yields (∣Af∣,∣Bf∣,∣Cf∣,∣Df∣)=(∣Ag∣+1,∣Bg∣,∣Cg∣,∣Dg∣+1). iii. If f(i+1)<i and f(i)>i, then we have (∣Af∣,∣Bf∣,∣Cf∣,∣Df∣)=(∣Ag∣,∣Bg∣,∣Cg∣+1,∣Dg∣+1) in the both of all cases f−1(i)<i and f−1(i)>i. iv. If f(i+1)<i and f(i)=i, then the property ∣{j∣j<i and i+1<f(j)}∣=∣{j∣f(j)<i and i+1<j}∣+1 yields (∣Af∣,∣Bf∣,∣Cf∣,∣Df∣)=(∣Ag∣−1,∣Bg∣+1,∣Cg∣,∣Dg∣+1). v. If f(i+1)<i and f(i)<i, then we have (∣Af∣,∣Bf∣,∣Cf∣,∣Df∣)=(∣Ag∣,∣Bg∣+1,∣Cg∣−1,∣Dg∣+1). Due to (5), the results above all cases complete the proof. □
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 reproduced verbatim; metadata (topic, difficulty) added by this project.