ArticleslgStudy

science

Single-machine scheduling

Single-machine scheduling is a science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand Single-machine scheduling rather than just read about it. In short: Single-machine scheduling or single-resource scheduling is an optimization problem in computer science and operations research. We are given n jobs J1,…,Jn of varying processing times, which need to be scheduled on a single machine, in a way that optimizes a certain objective, such as the throughput.

Key takeaways

  • Single-machine scheduling belongs to science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect Single-machine scheduling to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of Single-machine scheduling from memory before moving on to harder problems.

Reference excerpt

Single-machine scheduling or single-resource scheduling is an optimization problem in computer science and operations research. We are given n jobs J1,…,Jn of varying processing times, which need to be scheduled on a single machine, in a way that optimizes a certain objective, such as the throughput. Single-machine scheduling is a special case of identical-machines scheduling, which is itself a special case of optimal job scheduling. Many problems, which are NP-hard in general, can be solved in polynomial time in the single-machine case. In the standard three-field notation for optimal job scheduling problems, the single-machine variant is denoted by 1 in the first field. For example, " 1||∑Cj" is a single-machine scheduling problem with no constraints, where the goal is to minimize the sum of completion times. The makespan-minimization problem 1||Cmax, which is a common objective with multiple machines, is trivial with a single machine, since the makespan is always identical. Therefore, other objectives have been studied. There are also problems where precedence constraints arise to ensure that some jobs occur before some other jobs. The precedence constraints form a partial order (J,≺), where J is the set of all jobs, ordered by ≺. Alternatively, one can consider precedence constraints as a directed acyclic graph, G=(J,A), where A is the set of precedence arcs. Whenever, J1≺J2 for two jobs J1,J2∈J then job J2 can only be started once job J1 has finished processing. In the graph version, if (J1,J2)∈A then job J1must precede J2 in any feasible schedule.

Minimizing the sum of completion times The problem 1||∑Cj aims to minimize the sum of completion times. It can be solved optimally by the Shortest Processing Time First rule (SPT): the jobs are scheduled by ascending order of their processing time pj. The problem 1||∑wjCj aims to minimize the weighted sum of completion times. It can be solved optimally by the Weighted Shortest Processing Time First rule (WSPT): the jobs are scheduled by ascending order of the ratio pj/wj. The problem 1|chains|∑wjCj is a generalization of the above problem for jobs with dependencies in the form of chains. It can also be solved optimally by a suitable generalization of WSPT. The problem 1|prec|∑wjCj is the precedence-constrained version of the original problem. This problem is strongly NP-hard. There are several approximation algorithms with an approximation factor of 2.

Minimizing the cost of lateness The problem 1||Lmax aims to minimize the maximum lateness. For each job j, there is a due date dj. If it is completed after its due date, it suffers lateness defined as Lj:=Cj−dj. 1||Lmax can be solved optimally by the Earliest Due Date First rule (EDD): the jobs are scheduled by ascending order of their deadline dj. The problem 1|prec|hmax generalizes the 1||Lmax in two ways: first, it allows arbitrary precedence constraints on the jobs; second, it allows each job to have an arbitrary cost function hj, which is a function of its completion time (lateness is a special case of a cost function). The maximum cost can be minimized by a greedy algorithm known as Lawler's algorithm. The problem 1|rj|Lmax generalizes 1||Lmax by allowing each job to have a different release time by which it becomes available for processing. The presence of release times means that, in some cases, it may be optimal to leave the machine idle, in order to wait for an important job that is not released yet. Minimizing maximum lateness in this setting is NP-hard. But in practice, it can be solved using a branch-and-bound algorithm.

Maximizing the profit of earliness In settings with deadlines, it is possible that, if the job is completed by the deadline, there is a profit pj. Otherwise, there is no profit. The goal is to maximize the profit. Single-machine scheduling with deadlines is NP-hard; Sahni presents both exact exponential-time algorithms and a polynomial-time approximation algorithm.

Maximizing the throughput The problem 1||∑Uj aims to minimize the number of late jobs, regardless of the amount of lateness. It can be solved optimally by the Hodgson-Moore algorithm. It can also be interpreted as maximizing the number of jobs that complete on time; this number is called the throughput. The problem 1||∑wjUj aims to minimize the weight of late jobs. It is NP-hard, since the special case in which all jobs have the same deadline (denoted by 1|dj=d|∑wjUj ) is equivalent to the Knapsack problem. The problem 1|rj|∑Uj generalizes 1||∑Uj by allowing different jobs to have different release times. The problem is NP-hard. However, when all job lengths are equal, the problem can be solved in polynomial time. It has several variants:

The weighted optimization variant, 1|rj,pj=p|∑wjUj, can be solved in time O(n7). The unweighted optimization variant, maximizing the number of jobs that finish on time, denoted 1|rj,pj=p|∑Uj, can be solved in time O(n5) using dynamic programming, when all release times and deadlines are integers. The decision variant - deciding whether it is possible that all given jobs complete on time - can be solved by several algorithms, the fastest of them runs in time O(nlog⁡n). Jobs can have execution intervals. For each job j, there is a processing time tj and a start-time sj, so it must be executed in the interval [sj, sj+tj]. Since some of the intervals overlap, not all jobs can be completed. The goal is to maximize the number of completed jobs, that is, the throughput. More generally, each job may have several possible intervals, and each interval may be associated with a different profit. The goal is to choose at most one interval for each job, such that the total profit is maximized. For more details, see the page on interval scheduling. More generally, jobs can have time-windows, with both start-times and deadlines, which may be larger than the job length. Each job can be scheduled anywhere within its time-window. Bar-Noy, Bar-Yehuda, Freund, Naor and Schieber present a (1-ε)/2 approximation.

… excerpt ends here. Continue reading the full article.

Worked examples

Example 1 — a first encounter with Single-machine scheduling

Start with the simplest possible case. Write down what Single-machine scheduling claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to Single-machine scheduling before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about Single-machine scheduling ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of Single-machine scheduling

In research
Single-machine scheduling appears in science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses Single-machine scheduling in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
Single-machine scheduling is common in secondary-school and first-year university syllabi. It links to neighbouring topics NP-complete problems, Optimal scheduling, so understanding it makes those chapters shorter.
In everyday life
Look for Single-machine scheduling outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “Single-machine scheduling” →

How to study Single-machine scheduling in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what Single-machine scheduling means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain Single-machine scheduling out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is Single-machine scheduling in simple terms?

Single-machine scheduling or single-resource scheduling is an optimization problem in computer science and operations research. We are given n jobs J1,…,Jn of varying processing times, which need to be scheduled on a single machine, in a way that optimizes a certain objective, such as the throughpu…

Why does Single-machine scheduling matter?

Because it connects several science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study Single-machine scheduling?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on Single-machine scheduling.

Tags

  • NP-complete problems
  • Optimal scheduling

Keep exploring