Skip to main content
OlympiadHQ

Browse · MathNet

Print

Baltic Way 2019

Baltic Way 2019 counting and probability

Problem

Determine all integers which can be expressed in the form where are positive integers whose sum equals .
Solution
First, easy induction shows that .

Base case : . Assuming the inequality holds for a certain and adding the obvious , we get the claim for .

Given the conditions of the problem, this shows that (for a given ) the quadratic form in question takes values ; and the minimum is attained e.g. for and all .

Now to the upper bound. The fine point is that is variable. So, let be a -string of positive integers with , and with ; and let be the generated value . If , we merge with ; and if , we merge with , thus creating the following -string (with entries summing to ): . If is the new value of the quantity under consideration then, in the first case ; and in the second case After several steps comes down to and we arrive at a -string (with ) producing the value The product of two integers with a given sum has a maximum To show that all integer values between and are attained, we focus on strings ending in . We claim that these alone are enough to generate all those values. Induction again. Base : obvious. Fix and assume that positive-integer strings with sum , ending in a , yield all values from to . At the end of each of these strings (next to the terminal ) we attach another ; the value of the quadratic form grows by . So we already have strings with sum and with last entry , producing all values from to .

Now, if is even, , the triples (3-strings) and produce the values and ; and the quadruples (4-strings) with give values from down to (which is below ). If is odd, , the value comes from the triples ; and now the quadruples with yield the values from down to (below ). In each case, as ranges from to , the generated values of the quadratic form sweep (with slight excess) the entire missing interval. Induction is completed and the claim results.

The answer follows: the values of are all integers from to (inclusive).
Final answer
All integers from 2018 to 1019090 inclusive.

Techniques

Invariants / monovariantsColoring schemes, extremal argumentsQM-AM-GM-HM / Power MeanCombinatorial optimizationSums and products