Question: You will solve another scheduling problem. Say you run a workshop and you get a set of n tasks that your clients give you. Task
You will solve another scheduling problem. Say you run a workshop and you get a set of n tasks that your clients give you. Task i takes ti time. In addition, each task has a priority pi You can only do these tasks one at a time.
The completion time fi of a task i is the time at which it completes therefore, if you do the tasks in order then the completion time of task is f t the completion time of task is f t tsince it has to wait until task is done before it can start and completion time of task isfttt
Your goal is to minimize the cost function
n
C Xpifi
i
where fi is the completion time of task i That is you are minimizing the weighed sum of com pletion times. You will design, prove the correctness of and analyze a greedy algorithm for this problem.
a points Consider some simple greedy strategies. a Schedule the shortest job first. b Schedule the job with the biggest priority first. Give counterexamples for both these strategies.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
