Mr. Dlanod, the notorious developer, has not given up yet on his plans to build some hotels in the wilderness, despite earlier setbacks . This time around, the plan calls for six hotels, and a network of roads needs to be build to connect any hotel to any other. His thinking has evolved, and he is now looking at this issue from a different point of view.
Since we are among (aspiring) mathematicians, I will explain the issue in graph-theoretical terms: We are constructing an (undirected) graph with the hotels as its vertices and the road segments as its edges. To facilitate traffic flow, the graph should not be at tree, but it is required to contain at least one cycle (of any length).
Again, there is a budget constraint, of course: In a simple model, on a weekly schedule, the profit from each hotel is projected to be the square of the number of patrons (in Rubles), but road maintenance in the wilderness is expensive, and the cost for each road segment (i.e., each edge of the graph) is expected to be the product of the number of patrons in the two hotels it connects. For example, if there were only two hotels, with 3 and 4 patrons, respectively, and a road connecting them, the profit from the hotels would be 3 2 + 4 2 and road maintenance would cost 3 × 4 Rubles, for an overall profit of 13 Rubles.
It is required that, regardless of the number of patrons in each hotel , there will never be a weekly loss overall (profit from hotels minus cost of road maintenance), although Dlanod grudgingly accepts to merely break even in some weeks.
How many choices does Dlanod have to realise his project, if any? To be more precise: How many such graphs are there, up to isomorphism.
Bonus 1: What if trees are allowed?
Bonus 2: What if greedy Dlanod would once again decide to build more than six hotels?
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
If G is a connected graph on six hotels/vertices that fits Dlanod's requirements, we can find a nonempty subcollection U of the vertices of G such that, if G 0 is the graph obtained from the vertices U and all the edges of G that connect two vertices of U , then
The fact that U exists follows since Dlanod requires a cycle in his network of roads.
If x v guests stay at vertex v , forming the vector x , let D ( x ) be Dlanod's profit.
We can restrict attention to G 0 by considering situations where x v = 0 for v ∈ U . If L is the Laplacian matrix of G 0 , and if x ^ is the vector of guests at the vertices in U only, then x ^ T L x ^ = 2 D ( x ) + u ∈ U ∑ ( d e g ( u ) − 2 ) x u 2 If we consider the particular case where z u = 1 for all u ∈ U (and z v = 0 for v ∈ U still), then z ^ T L z ^ = 0 , and hence D ( z ) < 0 if there are any u ∈ U with d e g ( u ) > 2 . Thus all vertices in G 0 must have degree 2 .
Suppose that U is not the full set of vertices of G . There must be some vertex v of G which does not belong to U , but which is directly connected by a single edge of G to G 0 (if there were two or more such edges, then v could have been included in U ). Consider putting 2 guests in each of the vertices of U , 1 guest in v , and 0 guests everywhere else. Then Dlanod's profit is 0 from the subgraph G 0 plus 1 2 from the hotel v , minus 2 for the road connecting v to G 0 , and 0 from everything else. In other words, Dlanod makes a loss. Thus U must be the full set of vertices, so that G = G 0 .
Thus all vertices must have degree 2 , and hence D ( x ) = 2 1 x T L x ≥ 0 for all x . Since the graph is connected, this means that it must be a 6 -cycle. Thus there is only 1 option to within isomorphism
From this argument, there is nothing special about 6 that I can see, and the same argument should work for n hotels. There is at least one profitable tree configuration (a simple chain), so Dlanod has more choices if he allows himself trees.
Your solution is a lot more formal than mine, as usual, but is it fair to say that they are equivalent in content? It is certainly good for the readers to have a choice between our very different styles, "succinct" vs "explicit."
Did you count how many isomorphism classes there are if trees are allowed? I counted five, but I would have to double check my work.
Log in to reply
In essence, perhaps. My proof showed that G 0 had to be a loop, by excluding all vertices of degree 3 . Your proof considers what happens if you add one vertex to a loop, but does not quite seem to account for the possibility of that point being connected to the loop in more than one way (in other words, being a vertex in G 0 ).
Overall, I found five as well. There are 6 trees to within isomorphism. The only two that don't work are the one with a degree 5 vertex (2 guests at the degree 5 vertex and 1 at the other 5) and the one with a degree 4 vertex (4 guests at the degree 4 vertex, 2 guests at its 4 neighbours and 1 and the final vertex). That makes 1 + 4 = 5 isomorphism classes of graph.
Log in to reply
My solution does (explicitly) account for the possibility that the outlier is connected to more than one point on the loop. In that case, Dlanod will gain 1 Ruble from the outlier but lose 2 Rubles for each connection to the loop, for an "overall loss of at least 1 Ruble," as I state. I try to be "suaviter in modo, fortiter in re," covering all the essential points, but not more. In other words: making things as simple as possible, but not simpler. I certainly don't claim that I always succeed...
I agree with your count of the trees on six vertices. In my latest problem I invite "the Brilliant community" to think about the general case.
Log in to reply
@Otto Bretscher – What about more complex graphs than cycles? You proof now shows that the cycle has to be a 6 -cycle. If you tack an extra road to a loop, joining two other vertices on that loop, your argument needs to be modified a tad. You could either argue that the "all vertices equal to 1 " option gives 0 profit for the loop (and so overall loss − 1 for the loop with additional edge), or else you need to consider the smaller loop created by the new edge and part of the old loop, and see that we have an outlier tacked on to that. Then you can reuse your argument. Once we know you cannot tack on an extra edge, there is even less merit in tacking on more than one.
Log in to reply
@Mark Hennings – Since adding any additional edges would create extra cost but no extra revenue, that is clearly "verboten." We just break even as it is if the number of patrons in all the hotels along the loop is the same, as I mention. I took that point as selfevident.
Are you saying my solution is "too brief"? It's always a tough call how much to write, and it depends on the audience, of course.
Can we establish the following principle? If a connected graph G 0 has a break-even distribution, then any connected graph G with G 0 as a proper subgraph has a losing distribution.
Log in to reply
@Otto Bretscher – A modification of your argument can easily deal with the principle by constructing a counter-example. Say G 0 has x vertices, and each hotel in G 0 has p customers. Let G ′ be the graph formed by the vertices not in G 0 and with edges in G , and each hotel in G ′ have q customers.
The profit by G 0 is 0 . The profit by G ′ is q 2 ( n − x − E ′ ) where E ′ is the number of edges of G ′ , since Q ′ has n − x vertices.
G 0 and G ′ has to be connected by C number of edges, increasing the cost by C p q .
The total profit is hence 0 + q 2 ( n − x − E ′ ) − C p q < q 2 ( n − x − ( n − x − 1 ) ) − p q < q 2 − p q < q ( q − p ) . The case where E ′ = n − x − 1 is possible as the mimimum number of edges a graph with k edges can have is k − 1 (e.g. star graph). The case where C = 1 is possibly by connecting G 0 and G ′ with only 1 edge. As such, the maximum profit for such a partition of G is q ( q − p ) , which can be negative by chosing p > q .
Log in to reply
@Julian Poon – I don't quite understand your argument. Are you assuming that G 0 is a cycle? I meant the "principle" to apply to any connected graph G 0 with a break-even distribution; in this case we cannot assume that all the hotels in G 0 have the same number of customers, of course.
Also, I don't understand in what sense your construction provides a counter-example. You are constructing a losing distribution on G , after all, which my "principle" claims exists.
Log in to reply
@Otto Bretscher – Oh yes, I realised the circular argument. Though I think a fix could be having q be snaller than any element in G 0 , with the elements in G 0 be break-even. I'll modify the argument and make it clearer when I have the time today.
@Otto Bretscher – I am quite happy with your principle if G 0 contains all the vertices there are. Please clarify how it is going to work if we (say) attach a new vertex to a connected graph G 0 (which has a break-even distribution). The obvious way to find a losing distribution for the new graph is to assign a number of guests to the new vertex which is strictly less than the number of guests at the vertex in G 0 (in the break-even distribution) to which it is to be attached. What if the break-even distribution for G 0 has no guests at that particular vertex?
Since we are building on a 6 -cycle, it is OK to assume that we have all the vertices, I guess!
Log in to reply
@Mark Hennings – If G 0 has no guests at some hotels, then we pick an empty hotel in G 0 next to an occupied one and populate the empty one with one guest.
Log in to reply
@Otto Bretscher – Yup, that works! Break-even with some zeros can become break-even or losing with no zeros, and that can be extended to even more losing on a larger graph. The principle would make a good lemma at the start of the proof.
Log in to reply
@Mark Hennings – Thanks! I breathe a sigh of relief. When I first read Julian's post and yours, I was wondering whether I had overlooked something. I plan to rely on this "lemma" heavily in my solution to "the Dlanod saga continues."
Problem Loading...
Note Loading...
Set Loading...
First we need to convince ourselves that a cycle by itself satisfies the budget constraint; otherwise there would be no solution. Consider a cycle 1 → 2 → 3 → . . . → n → 1 , and assume that there are x k patrons at hotel k in a given week. If we let x n + 1 = x 1 , then the overall profit will be ∑ k x k 2 − ∑ k x k x k + 1 = 2 1 ∑ k ( x k − x k + 1 ) 2 ≥ 0 , showing that a cycle "works." (We merely break even if and only if the number of patrons happens to be the same at all the hotels.)
Thus one possible option is to run a loop road past all the six hotels. We claim that this is the only solution. Indeed, if a loop would run past fewer than six hotels, then there would be at least one "outlier" connected to at least one of the hotels on the loop. If all the hotels on the loop get 2 patrons but the outlier gets only 1 (with all the other hotels, if any, getting no customers that week), then Dlanod would suffer an overall loss of at least 1 Ruble, which is verboten.
Thus there is 1 isomorphism class of graphs with the required properties.