Dining Philosophers Problem: Difference between revisions
Jump to navigation
Jump to search
(Created page with "{{DISPLAYTITLE:Dining Philosophers Problem (Deadlock Avoidance)}} == Description == There are $n$ philosophers numbered 0 through $n-1$, seated around a circle table. Their only problem--besides philosophy--is that the dish served is a very difficult kind of spaghetti, that has to be eaten with two forks. There are two forks next to each plate, so that presents no difficulty: as a consequence, however, no two neighbors may be eating simultaneously. The philosophers' li...") |
No edit summary |
||
(One intermediate revision by the same user not shown) | |||
Line 10: | Line 10: | ||
== Parameters == | == Parameters == | ||
$n$: number of philosophers | |||
== Table of Algorithms == | == Table of Algorithms == |
Latest revision as of 07:53, 10 April 2023
Description
There are $n$ philosophers numbered 0 through $n-1$, seated around a circle table. Their only problem--besides philosophy--is that the dish served is a very difficult kind of spaghetti, that has to be eaten with two forks. There are two forks next to each plate, so that presents no difficulty: as a consequence, however, no two neighbors may be eating simultaneously. The philosophers' lives consist of an alternation between eating and thinking. The goal is to devise a strategy such that no philosopher is stuck thinking forever and each philosopher may eat at reasonable intervals.
Related Problems
Generalizations: Deadlock Avoidance
Parameters
$n$: number of philosophers
Table of Algorithms
Name | Year | Time | Space | Approximation Factor | Model | Reference |
---|---|---|---|---|---|---|
Resource hierarchy solution | 1965 | $O({2}^n)$ | $O(n)$ | Exact | Deterministic | Time |
Arbitrator solution | 1965 | $O({2}^n)$ | $O({1})$ | Exact | Deterministic | Time |