Production scheduling rules, also called dispatching rules or priority rules, decide which job a machine runs next when several are waiting. The common ones are first come, first served (FCFS), shortest processing time (SPT), earliest due date (EDD), critical ratio (CR) and least slack (LS).
On a single machine with all jobs waiting at the start, two results are proven: SPT gives the lowest average flow time, and EDD gives the lowest maximum lateness. No rule is best on every measure, so the right one depends on what you are trying to protect.
The rules at a glance
| Rule | Runs next | Good at | Watch out for |
|---|---|---|---|
| First come, first served (FCFS) | The job that arrived first | Simple, and seen as fair | Ignores due dates and job length |
| Shortest processing time (SPT) | The shortest job | Lowest average flow time on one machine; less work in process | Long jobs keep waiting and can end up very late |
| Earliest due date (EDD) | The job due first | Lowest maximum lateness on one machine | Ignores job length; does not minimize the number of late jobs |
| Critical ratio (CR) | The job with the lowest ratio of time left to work left | Weighs urgency against the work still to do | Must be recalculated as time passes; needs good estimates of work left |
| Least slack (LS) | The job with the least slack: time left minus work left | Like EDD, but counts how much work is left | Ignores how many operations are left |
Two more you will meet:
- Longest processing time (LPT) runs the longest job first. On one machine it gives the worst average flow time of any sequence, the mirror image of SPT.
- Priority classes sort jobs into groups first, for example a customer whose line is down, then normal orders, then stock replenishment, and apply one of the rules above inside each group.
The measures and formulas
Flow time = completion time − time the job arrived
Lateness = completion time − due date (negative if early)
Tardiness = lateness if it is positive, otherwise 0
Critical ratio = time remaining until due ÷ work remaining
Slack = time remaining until due − work remaining
Averages are over all jobs, with on-time jobs counting as 0 tardiness. Maximum tardiness is the worst single job. A critical ratio below 1 means the job is behind, 1 means it is on schedule, above 1 means it has time to spare, and below 0 means it is already past due.
Worked example: five jobs at one machine
Example inputs, not real data. Five jobs are waiting at a CNC machining center on the morning of day 0. They arrived in the order A, B, C, D, E. Times are in working days. All five are there at the start, so each job’s flow time equals its completion day.
| Job | Arrived | Processing time (days) | Due (day) |
|---|---|---|---|
| A | 1st | 6 | 24 |
| B | 2nd | 8 | 9 |
| C | 3rd | 4 | 6 |
| D | 4th | 3 | 15 |
| E | 5th | 9 | 28 |
First come, first served: A, B, C, D, E
| Job | Processing (days) | Completion (flow time) | Due | Lateness | Tardiness |
|---|---|---|---|---|---|
| A | 6 | 6 | 24 | −18 | 0 |
| B | 8 | 14 | 9 | 5 | 5 |
| C | 4 | 18 | 6 | 12 | 12 |
| D | 3 | 21 | 15 | 6 | 6 |
| E | 9 | 30 | 28 | 2 | 2 |
Shortest processing time: D, C, A, B, E
| Job | Processing (days) | Completion (flow time) | Due | Lateness | Tardiness |
|---|---|---|---|---|---|
| D | 3 | 3 | 15 | −12 | 0 |
| C | 4 | 7 | 6 | 1 | 1 |
| A | 6 | 13 | 24 | −11 | 0 |
| B | 8 | 21 | 9 | 12 | 12 |
| E | 9 | 30 | 28 | 2 | 2 |
Earliest due date: C, B, D, A, E
| Job | Processing (days) | Completion (flow time) | Due | Lateness | Tardiness |
|---|---|---|---|---|---|
| C | 4 | 4 | 6 | −2 | 0 |
| B | 8 | 12 | 9 | 3 | 3 |
| D | 3 | 15 | 15 | 0 | 0 |
| A | 6 | 21 | 24 | −3 | 0 |
| E | 9 | 30 | 28 | 2 | 2 |
Critical ratio: B, C, D, E, A
Critical ratio is recalculated every time the machine finishes a job and picks the next one. The job with the lowest ratio runs next (in bold):
| Job | Day 0 | Day 8 | Day 12 | Day 15 | Day 24 |
|---|---|---|---|---|---|
| A | 24 ÷ 6 = 4.00 | 16 ÷ 6 = 2.67 | 12 ÷ 6 = 2.00 | 9 ÷ 6 = 1.50 | 0 ÷ 6 = 0.00 |
| B | 9 ÷ 8 = 1.13 | — | — | — | — |
| C | 6 ÷ 4 = 1.50 | −2 ÷ 4 = −0.50 | — | — | — |
| D | 15 ÷ 3 = 5.00 | 7 ÷ 3 = 2.33 | 3 ÷ 3 = 1.00 | — | — |
| E | 28 ÷ 9 = 3.11 | 20 ÷ 9 = 2.22 | 16 ÷ 9 = 1.78 | 13 ÷ 9 = 1.44 | — |
| Job | Processing (days) | Completion (flow time) | Due | Lateness | Tardiness |
|---|---|---|---|---|---|
| B | 8 | 8 | 9 | −1 | 0 |
| C | 4 | 12 | 6 | 6 | 6 |
| D | 3 | 15 | 15 | 0 | 0 |
| E | 9 | 24 | 28 | −4 | 0 |
| A | 6 | 30 | 24 | 6 | 6 |
Look at job D. On day 0 it has the most comfortable ratio of all, 5.00. By day 12 its ratio is 1.00, the tightest, and it runs next. Had you worked out the ratios once on day 0 and kept that order (B, C, E, A, D), D would finish on day 30, 15 days late, and the average flow time would be 19.6 days.
Least slack: B, C, D, A, E
Slack on day 0 is the due day minus the processing time: A 18, B 1, C 2, D 12, E 19. On one machine every waiting job loses one day of slack per day, so the order never changes as time passes.
| Job | Processing (days) | Completion (flow time) | Due | Lateness | Tardiness |
|---|---|---|---|---|---|
| B | 8 | 8 | 9 | −1 | 0 |
| C | 4 | 12 | 6 | 6 | 6 |
| D | 3 | 15 | 15 | 0 | 0 |
| A | 6 | 21 | 24 | −3 | 0 |
| E | 9 | 30 | 28 | 2 | 2 |
Results compared
| Rule | Sequence | Average flow time (days) | Average tardiness (days) | Late jobs | Maximum tardiness (days) |
|---|---|---|---|---|---|
| First come, first served | A, B, C, D, E | 17.8 | 5.0 | 4 | 12 |
| Shortest processing time | D, C, A, B, E | 14.8 | 3.0 | 3 | 12 |
| Earliest due date | C, B, D, A, E | 16.4 | 1.0 | 2 | 3 |
| Critical ratio | B, C, D, E, A | 17.8 | 2.4 | 2 | 6 |
| Least slack | B, C, D, A, E | 17.2 | 1.6 | 2 | 6 |
| Longest processing time | E, B, A, C, D | 21.2 | 8.8 | 3 | 21 |
- SPT has the lowest average flow time, 14.8 days. On one machine with all jobs present that always holds: no other sequence of these five jobs does better.
- EDD has the lowest maximum tardiness, 3 days. That also always holds on one machine: EDD minimizes the maximum lateness, and with it the maximum tardiness.
- In this example EDD also has the lowest average tardiness of the rules and ties for the fewest late jobs. That is this example, not a general result.
- None of the rules finds the fewest late jobs possible. The sequence B, D, A, E, C has only one late job, but that job, C, is 24 days late. Fewer late jobs and a smaller worst case pull in opposite directions.
- The machine needs 30 days for all five jobs whatever the order. The rules only change who waits.
What changes with many machines and setups
In a real shop a job visits several work centers, each with its own queue, and a rule applied at one machine cannot see what it does at the next. Three things change.
- Work remaining means the whole routing. For critical ratio and slack, count every operation still to do, and often the expected waiting time between them, not just this machine.
- The guarantees go away. SPT and EDD are proven best on one machine for the measures above. With several machines and jobs arriving over time, they are still sensible rules, but no longer proven best.
- Setups change the arithmetic. When a changeover depends on what ran before, running jobs of the same changeover family back to back can save hours, even if it breaks the due-date order. The trade is setup hours against lateness. Shorter setups make the trade easier; see setup time reduction.
This is why schedulers try several rules and keep the best. Production Planning in the Statadventure Lab does this when you choose Automatic sequencing. It builds a finite capacity schedule with four rules (priority then due date, earliest due date, critical ratio and least slack), keeps the one with the best score, then swaps neighboring orders and moves late orders forward while the score improves. The score counts priority-weighted late days first, then changeover hours. It is a heuristic: it finds a good sequence in milliseconds, not a proven best one.
How to pick a rule for your shop
- Pick the measure first. If customers judge you on on-time delivery (see fill rate vs OTIF), start with EDD, least slack or critical ratio. If long lead times and work in process are the problem, look at SPT. If material ages in the queue, or customers expect to be served in turn, FCFS may be the right choice.
- Start at the bottleneck. The sequence at the machine that limits output sets the dates for everything after it. Elsewhere, a simple rule is usually enough.
- Test on your own orders. Take last month’s jobs at the bottleneck, apply three or four rules in a spreadsheet, and compare average flow time, late jobs and the worst lateness, as in the table above.
- Write the rule down. Put it on the dispatch list so every shift sequences the same way.
Common mistakes
- Sorting once by critical ratio. The ratio changes as days pass. Recalculate it each time the machine picks a job.
- Letting SPT starve long jobs. Move any job that has waited more than a set number of days to the front.
- Judging a rule on one number. A rule can win on average flow time and still leave one customer weeks late. Compare the measures together.
If you would rather not run the comparison by hand each week, production scheduling software can do it on every order and machine at once. In the Lab it comes with Production Planning, at $99 a month on its own or as an add-on.
Want to compare rules on your own orders?
The live demo sequences a sample pumps and valves plant and shows the Gantt chart and dispatch list. No sign-up.
Frequently asked questions
Which production scheduling rule is best?
None is best on every measure. On one machine, SPT gives the lowest average flow time and EDD the lowest maximum lateness. For on-time delivery, start with a due-date rule such as EDD, least slack or critical ratio, and compare several on your own orders.
How do you calculate critical ratio?
Divide the time remaining until the due date by the work remaining. A job due in 12 days with 8 days of work left has a critical ratio of 12 ÷ 8 = 1.5. Recalculate it every time the machine picks its next job.
What is the difference between slack and critical ratio?
Slack subtracts: time remaining minus work remaining, in days. Critical ratio divides the same two numbers. Two jobs with 2 days of slack look the same to the slack rule, but a job with 1 day of work left (ratio 3.0) is safer than one with 10 days left (ratio 1.2), and critical ratio sees that.
Does SPT make long jobs late?
It can. SPT keeps putting long jobs behind shorter ones. In the example, SPT left job B, the second-longest, 12 days late. You can cap how long a job may wait, or switch to a due-date rule as jobs get close to their due date.
Sources: Dorit S. Hochbaum, scheduling algorithms notes, UC Berkeley IEOR (RIOT), for SPT minimizing mean flow time and EDD minimizing maximum lateness and maximum tardiness on a single machine with all jobs ready at time 0.
Try the Statadventure live tools
Inventory tools for US manufacturers: reorder point, safety stock, EOQ and landed cost, with the inputs and assumptions shown.
Open the live tools