Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

1. Build a model of the problem if such a model is not provided. 2. Decide which

ID: 3827526 • Letter: 1

Question

1. Build a model of the problem if such a model is not provided. 2. Decide which class it belongs to: P, NP, NP-Complete, PSPACE. 3. If possible: Propose a practical (polynomial-time or pseudo polynomial) algorithm to solve it, optimally or approximately. 4. Analyze its time complexity. 5. If your algorithm is approximate algorithm, identify its approximation ratio. • Otherwise: State the complexity class of this problem. o Explain why it belongs to this complexity class. Given k network routes from one source to one destination, and n files to be transfer from the source to the destination; each file fi has length li, the transfer speed along all k paths are identical. Find out how to assign files to each of the k routes so that to finish the transfer of all n files in the shortest time. For example, given 10 files, their lengths are: 5, 6, 7, 3, 2, 10, 9, 8, 6, 4, and 3 paths, the optimal solution is to transfer them in 20/speed time unit.

Explanation / Answer

1)
This problem is about dead lock avoidance problem.
So if any pair is busy ..
wait() //until new pair is available
processPair() //if available..start process

--------------------------------------------------------------------
2)
This class is NP-complete
we can solve this is in polynomial and non-polynomial time..

-------------------------------------------------------------------------------
3)
This problem is about dead lock avoidance problem.
So if any pair is busy ..
wait() //until new pair is available
processPair() //if available..start process

------------------------------------------------------------------------------
4)
Time complexity will be O(nm)
-------------------------------------------------
5)
Time complexity will be O(mn)
because we have m process and we have to wait n waits ... So O(nm)