1

You are given an undirected graph (social network) in which each edge $e = (v, v')$ has an interval $I_e = [l_e, u_e]$ on it. The meaning is that you know that $v$ and $v'$ met at some point during the interval $I_e$, but have no idea when exactly. You also know that some source node $s$ started with some infectious disease, and that a set $P \subseteq V$ ended up with the disease, while a disjoint set $N \subseteq V$ definitely did not catch the disease. (There may be nodes that are neither in P nor in N.) The disease has the property that when two nodes $v, v'$ meet, one of whom has the disease, it is instantaneously transmitted to the other, who is also immediately infectious. I want a polynomial-time algorithm which when given $G, P, N$ and the $I_e$, either outputs meeting times $t_e ∈ I_e$ for each edge that explain the observations, or correctly concludes that it is impossible that all of $P$ got the disease while no one in $N$ did.

I feel like a way to approach this problem is to start with the subset of P, and check the edges with the latest times in the intervals greedily and relax the time intervals if we need to reach other vertices in P. We then try to tighten the constraints if we are about to hit vertices not in P. What would be an algorithm to tackle this problem?

Source: last problem https://david-kempe.com/CS670/HW1.pdf

  • Where did you encounter this task? Please credit the original source of all copied material. See https://cs.stackexchange.com/help/referencing – D.W. Oct 06 '21 at 06:55
  • What are your thoughts? You propose a greedy algorithm - a good next step would be to try to prove it correct and try to find a counterexample. We have guides on that at https://cs.stackexchange.com/q/59964/755. I suggest you spend some time on that, then update your question to show your progress or where you got stuck. – D.W. Oct 06 '21 at 06:56
  • I'm getting the idea of creating an elevation map for this problem. Basically for nodes in P, if u transmitted to v at some time, there will be an upward slope defined as the edge. However for nodes in N, the slope will be reversed. So then the idea is to pour water at the very top of P and see how it rolls down the elevation map. The trouble I am having is with the nuances of overlapping time intervals and the small details. – IUissopretty Oct 06 '21 at 20:05

0 Answers0