Maths Olympiad Prep

Library / /346 of 377

Combinatorics Difficulty 5.7 AIME, harder Prove it United States

Problem:
For a string of PP 's and QQ 's, the value is defined to be the product of the positions of the PP 's. For example, the string PPQPQQP P Q P Q Q has value 124=81 \cdot 2 \cdot 4=8.

Also, a string is called antipalindromic if writing it backwards, then turning all the PP 's into QQ 's and vice versa, produces the original string. For example, PPQPQQP P Q P Q Q is antipalindromic.

There are 210022^{1002} antipalindromic strings of length 20042004. Find the sum of the reciprocals of their values.

Solution

Solution:
20051002/20042005^{1002} / 2004 !
Consider the product
(11+12004)(12+12003)(13+12002)(11002+11003). \left(\frac{1}{1}+\frac{1}{2004}\right)\left(\frac{1}{2}+\frac{1}{2003}\right)\left(\frac{1}{3}+\frac{1}{2002}\right) \cdots\left(\frac{1}{1002}+\frac{1}{1003}\right) .
This product expands to 210022^{1002} terms, and each term gives the reciprocal of the value of a corresponding antipalindromic string of PP 's and QQ 's as follows: if we choose the term 1/n1 / n for the nnth factor, then our string has a PP in position nn and QQ in position 2005n2005-n; if we choose the term 1/(2005n)1 /(2005-n), then we get a QQ in position nn and PP in position 2005n2005-n. Conversely, each antipalindromic string has its value represented by exactly one of our 210022^{1002} terms. So the value of the product is the number we are looking for. But when we simplify this product, the nnth factor becomes 1/n+1/(2005n)=2005/n(2005n)1 / n+1 /(2005-n)=2005 / n(2005-n). Multiplying these together, we get 1002 factors of 2005 in the numerator and each integer from 1 to 2004 exactly once in the denominator, for a total of 200510022005^{1002} / 2004!2004!.

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.