Daily

Random

Practice set

Baltic Way 2010 · Problem 7

Combinatorics

There are some cities in a country; one of them is the capital. For any two cities AA and BB there is a direct flight from AA to BB and a direct flight from BB to AA, both having the same price. Suppose that all round trips with exactly one landing in every city have the same total cost. Prove that all round trips that miss the capital and with exactly one landing in every remaining city cost the same.

Change pool

When you’re ready

Review material becomes available with the next Daily.

Review

Topics

Counting and enumeration · Invariants and monovariants

Solutions

Solution

Let CC be the capital and C1,C2,…,CnC_1, C_2, \dots, C_n be the remaining cities. Denote by d(x,y)d(x, y) the price of the connection between the cities xx and yy, and let σ\sigma be the total price of a round trip going exactly once through each city.

Now consider a round trip missing the capital and visiting every other city exactly once; let ss be the total price of that trip. Suppose CiC_i and CjC_j are two consecutive cities on the route. Replacing the flight Ci→CjC_i \to C_j by two flights: from CiC_i to the capital and from the capital to CjC_j, we get a round trip through all cities, with total price σ\sigma. It follows that

σ=s+d(C,Ci)+d(C,Cj)−d(Ci,Cj),\sigma = s + d(C, C_i) + d(C, C_j) - d(C_i, C_j),

so it remains to show that the quantity α(i,j)=d(C,Ci)+d(C,Cj)−d(Ci,Cj)\alpha(i, j) = d(C, C_i) + d(C, C_j) - d(C_i, C_j) is the same for all 2-element subsets {i,j}⊂{1,2,…,n}\{i, j\} \subset \{1, 2, \dots, n\}.

For this purpose, note that α(i,j)=α(i,k)\alpha(i, j) = \alpha(i, k) whenever i,j,ki, j, k are three distinct indices; indeed, this equality is equivalent to

d(Cj,C)+d(C,Ci)+d(Ci,Ck)=d(Cj,Ci)+d(C,C)+d(C,Ck),d(C_j, C) + d(C, C_i) + d(C_i, C_k) = d(C_j, C_i) + d(C, C) + d(C, C_k),

which is true by considering any trip from CkC_k to CjC_j going through all cities except CC and CiC_i exactly once and completing this trip to a round trip in two ways: Cj→C→Ci→CkC_j \to C \to C_i \to C_k and Cj→Ci→C→CkC_j \to C_i \to C \to C_k. Therefore the values of α\alpha coincide on any pair of 2-element sets sharing a common element. But then clearly α(i,j)=α(i,j′)=α(i′,j′)\alpha(i, j) = \alpha(i, j') = \alpha(i', j') for all indices i,j,i′,j′i, j, i', j' with i≠j,i′≠j′i \neq j, i' \neq j', and the solution is complete.

Contest context

Results from Baltic Way 2010

10 teams

Mean score
1.9 / 5
Scores of 4 or 5
3 / 10
Estonia
0 / 5

Score distribution

05
11
20
31
40
53
All team scores
TeamScore
Poland0 / 5
Lithuania5 / 5
Germany1 / 5
Latvia5 / 5
Denmark0 / 5
Sweden3 / 5
Estonia0 / 5
Norway5 / 5
Finland0 / 5
Iceland0 / 5