------------------------------------------------------------------------------ Mohamed G. Gouda Midterm 3 CS 356: Computer Networks Spring 2007 Solution ------------------------------------------------------------------------------ 1. (10 points) Process p[3] can only be sure about the link {3,4}. The net array shows that p[3] and p[4] are connected only to each other and disconnected from the rest of the network, which means information about rest of the processes is obsolete and updates from the rest of the network will not reach them. ------------------------------------------------------------------------------ 2. (10 points) RTMSG:: if i send data(x,y) to p[i+1, j] [] i>x -> send data(x,y) to p[i-1, j] [] j send data(x,y) to p[i, j+1] [] j>y -> send data(x,y) to p[i, j-1] [] i=x ^ j=y -> {arrived at destination} skip fi The solution above achieves load-balancing because the branches of the if statement that evaluate to true will be selected non-deterministically. Note: The up array is always true, so you don't need to check that. ------------------------------------------------------------------------------