Disk Scheduling: Difference between revisions

From Algorithm Wiki
Jump to navigation Jump to search
(Created page with "== Problem Description== File systems must be accessed in an efficient manner, especially with hard drives, which are the slowest part of a computer. As a computer deals with multiple processes over a period of time, a list of requests to access the disk builds up. For efficiency purposes, all requests (from all processes) are aggregated together. The technique that the operating system uses to determine which requests to satisfy first is called disk scheduling. == Bou...")
 
No edit summary
Line 1: Line 1:
== Problem Description==
{{DISPLAYTITLE:Disk Scheduling (Disk Scheduling)}}
File systems must be accessed in an efficient manner, especially with hard drives, which are the slowest part of a computer.
== Description ==  
As a computer deals with multiple processes over a period of time, a list of requests to access the disk builds up. For efficiency purposes, all requests (from all processes) are aggregated together.


The technique that the operating system uses to determine which requests to satisfy first is called disk scheduling.
When disk requests arrive at the disk device, they are queued for service and a disk scheduling algorithm is used to decide which of a waiting queue of disk requests to serve next.  


== Bounds Chart ==
== Parameters ==  
[[File:Disk_SchedulingBoundsChart.png|1050px]]


== Step Chart ==
<pre>n: number of requests</pre>
[[File:Disk_SchedulingStepChart.png|1050px]]


== Improvement Table ==
== Table of Algorithms ==  
{| class="wikitable" style="text-align:center;" width="100%"  
 
!width="20%" | Complexity Classes !! width="40%" | Algorithm Paper Links !! width="40%" | Lower Bounds Paper Links
{| class="wikitable sortable" style="text-align:center;" width="100%"
|-
 
| rowspan="1" | Exp/Factorial
! Name !! Year !! Time !! Space !! Approximation Factor !! Model !! Reference
|
 
|
|-
 
| [[FCFS (Disk Scheduling Disk Scheduling)|FCFS]] || 1979 || $O(n)$ || $O({1})$ auxiliary || Exact || Deterministic ||
|-
| [[SSTF (Disk Scheduling Disk Scheduling)|SSTF]] || 1979 || $O(n*log n)$ with binary tree || $O(n)$ auxiliary || Exact || Deterministic || [https://www.geeksforgeeks.org/program-for-sstf-disk-scheduling-algorithm/?ref=lbp Space]
|-
|-
| rowspan="1" | Polynomial > 3
| [[SCAN (Disk Scheduling Disk Scheduling)|SCAN]] || 1979 || $O(n*log n)$ || $O(n)$ auxiliary || Exact || Deterministic || [https://www.geeksforgeeks.org/scan-elevator-disk-scheduling-algorithms/?ref=lbp Space]
|
|
|-
|-
| rowspan="1" | Cubic
| [[LOOK (Disk Scheduling Disk Scheduling)|LOOK]] || 1979 || $O(n*log n)$ || $O(n)$ auxiliary || Exact || Deterministic || 
|
|
|-
|-
| rowspan="1" | Quadratic
| [[C-SCAN (Disk Scheduling Disk Scheduling)|C-SCAN]] || 1979 || $O(n*log n)$ || $O(n)$ auxiliary || Exact || Deterministic || 
|
|
|-
|-
| rowspan="1" | nlogn
| [[C-LOOK (Disk Scheduling Disk Scheduling)|C-LOOK]] || 1979 || $O(n*log n)$ || $O(n)$ auxiliary || Exact || Deterministic || 
|
|
|-
|-
| rowspan="1" | Linear
|}
| [FCFS (1979)]
 
== Time Complexity graph ==  


[SSTF (1979)]
[[File:Disk Scheduling - Time.png|1000px]]


[SCAN (1979)]
== Space Complexity graph ==


[LOOK (1979)]
[[File:Disk Scheduling - Space.png|1000px]]


[C-SCAN (1979)]
== Pareto Decades graph ==


[C-LOOK (1979)]
[[File:Disk Scheduling - Pareto Frontier.png|1000px]]
|
|-
| rowspan="1" | logn
|
|
|-|}

Revision as of 10:23, 15 February 2023

Description

When disk requests arrive at the disk device, they are queued for service and a disk scheduling algorithm is used to decide which of a waiting queue of disk requests to serve next.

Parameters

n: number of requests

Table of Algorithms

Name Year Time Space Approximation Factor Model Reference
FCFS 1979 $O(n)$ $O({1})$ auxiliary Exact Deterministic
SSTF 1979 $O(n*log n)$ with binary tree $O(n)$ auxiliary Exact Deterministic Space
SCAN 1979 $O(n*log n)$ $O(n)$ auxiliary Exact Deterministic Space
LOOK 1979 $O(n*log n)$ $O(n)$ auxiliary Exact Deterministic
C-SCAN 1979 $O(n*log n)$ $O(n)$ auxiliary Exact Deterministic
C-LOOK 1979 $O(n*log n)$ $O(n)$ auxiliary Exact Deterministic

Time Complexity graph

Error creating thumbnail: Unable to save thumbnail to destination

Space Complexity graph

Error creating thumbnail: Unable to save thumbnail to destination

Pareto Decades graph

Error creating thumbnail: Unable to save thumbnail to destination