Activity or Task Scheduling ProblemThis is the dispute of optimally scheduling unittime tasks on a single processor, where each job has a deadline and a penalty that necessary be paid if the deadline is missed. A unittime task is a job, such as a program to be rush on a computer that needed precisely one unit of time to complete. Given a finite set S of unittime tasks, a schedule for S is a permutation of S specifying the order in which to perform these tasks. The first task in the schedule starts at time 0 and ends at time 1; the second task begins at time 1 and finishes at time 2, and so on. The dispute of scheduling unittime tasks with deadlines and penalties for each processor has the following inputs:
Here we find a schedule for S that minimizes the total penalty incurred for missed deadlines. A task is late in this schedule if it finished after its deadline. Otherwise, the task is early in the schedule. An arbitrary schedule can consistently be put into earlyfirst form, in which the first tasks precede the late tasks, i.e., if some new task x follows some late task y, then we can switch the position of x and y without affecting x being early or y being late. An arbitrary schedule can always be put into a canonical form in which first tasks precede the late tasks, and first tasks are scheduled in order of nondecreasing deadlines. A set A of tasks is independent if there exists a schedule for the particular tasks such that no tasks are late. So the set of first tasks for a schedule forms an independent set of tasks 'l' denote the set of all independent set of tasks. For any set of tasks A, A is independent if for t = 0, 1, 2.....n we have N_{t}(A) ≤ t where N_{t}(A) denotes the number of tasks in A whose deadline is t or prior, i.e. if the tasks in A are expected in order of monotonically growing deadlines, then no task is late. Example: Find the optimal schedule for the following task with given weight (penalties) and deadlines.
Solution: According to the Greedy algorithm we sort the jobs in decreasing order of their penalties so that minimum of penalties will be charged. In this problem, we can see that the maximum time for which uniprocessor machine will run in 6 units because it is the maximum deadline. Let T_{i} represents the tasks where i = 1 to 7 T_{5} and T_{6} cannot be accepted after T_{7} so penalty is w_{5} + w_{6} = 30 + 20 = 50 (2 3 4 1 7 5 6) Other schedule is (2 4 1 3 7 5 6) There can be many other schedules but (2 4 1 3 7 5 6) is optimal.
Next TopicTravelling Sales Person Problem

PLC
Illustrator
Postman
IoT
GraphQL
Xampp
Kivy
A. Anywhere
Ext.js
UiPath
Arduino
Digital E.
Adwords
MySQL