1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
maria [59]
3 years ago
6

Disk requests come in to the disk driver for cylinders 10, 22, 20, 2, 40, 6, and 38, in that order. A seek takes 6 msec per cyli

nder moved. The arm is initially at cylinder 20.
How much seek time is needed if


a) FCFS


b) SSTF


c) SCAN (elevator)


algorithm is employed?
Computers and Technology
1 answer:
oksano4ka [1.4K]3 years ago
6 0

Answer:

For  FCFS = 876msec For SSTF = 360msec For SCAN(elevator) = 348msec

Explanation:

Considering FCFS algorithm.

In FCFS, the requests are addressed in the order they arrive in the disk queue, this means that the number of cylinders traveled becomes equal to the total of disk requests. With the arm initially at 20, the first request is to read cylinder 10.

Therefore the cylinders traversed for the first request = 20 – 10 = 10  

For the second request i.e. a movement from cylinder 10 to cylinder 22, the number of cylinders traversed is = 22 - 10 = 12.

Similarly, for the third request seek arm will return to 20 from 22 so, cylinders traversed through would be = 22-20 = 2.    

Also for the fourth request, cylinders traversed would be = 20 – 2 = 18.

For the fifth request, cylinders traversed = 40 – 2 = 38.

Now for the sixth request cylinders traversed = 40 – 6 = 34.

For the seventh and last request, cylinders traversed = 38 – 6 = 32.

So now to get the how much seek time is required for Disk scheduling algorithm  

First we would add the total cylinders traversed = 10 + 12 + 2+ 18+ 38 + 34 + 32

     = 146 cylinders  

So therefore the total seek time = number of cylinders traversed X seek time per cylinder

               = 146 X 6

   = 876msec

Considering SSTF algorithm.

In SSTF (Shortest Seek Time First), requests having shortest seek time are executed first. So, the seek time of every request is calculated in advance in the queue and then they are scheduled according to their calculated seek time. What this means is that the closest disk (cylinder) next to the position of the seek arm is attended to first. With   the arm at 20 initially, the first request is to read cylinder 22 (i.e. the closest cylinder to the seek arm)

Therefore the cylinders traversed for the first request = 22-20 = 2

For the second request, the disk to focus on is disk 20 and the cylinders traversed = 22-20 = 2

Similarly for the third request the seek arm will move to 10 from 20 so, cylinder traversed = 20-10 =10

For fourth request, cylinder traversed = 10 – 6 = 4

For the fifth request, cylinder traversed = 6 – 2 = 4

For sixth request, since all other disk request closer to it has been attended to the seek arm will move to disk 38 to attend to that disk request So, the cylinder traversed = 38 – 2 = 36

For the last request, cylinder traversed = 40 -38 = 2

So now to get the how much seek time is required for Disk scheduling algorithm  

First we would add the total cylinders traversed = 2 + 2 +10 + 4 + 4 + 36 + 2  

     = 60 cylinders

So therefore the total seek time = number of cylinders traversed X seek time per cylinder

     = 60 X 6 = 360msec

From Here we see that SSTF is better or an improvement to FCFS as it decrease the average response time (Average Response time is the response time of the all requests).

Considering SCAN (elevator) algorithm  

In SCAN algorithm the disk arm moves into a particular direction and services the requests coming in its path and after reaching the end of disk, it reverses its direction and again services the request arriving in its path. So, this algorithm works as an elevator and hence also known as elevator algorithm. Therefore the number of cylinder traveled becomes equal to the total of disk request. With the arm at 20 initially

The first request is to read cylinder 22 i.e. the first cylinder on the upward movement  

Therefore the cylinders traversed would be  =   20 – 22 = 2

For the second request is to read cylinder 38, and the cylinders traversed would be   = 38 – 22 =16

For the third request, seek arm will move to 40 So, the cylinders traversed would be = 40 – 38 = 2

For the fourth request, seek arm will return to 20 since from 40 since 40 is the highest in this upward elevator movement So, cylinders traversed would be = 40 -20 = 20  

For the fifth request, cylinder traversed would be = 20 – 10 = 10

For the sixth request, cylinder traversed would be   = 10 – 6 = 4

For the seventh and last request, cylinder traversed = 6 – 2 = 4

So now to get the how much seek time is required for Disk scheduling algorithm  

First we would add the total cylinders traversed = 2 + 16 + 2 + 20 +10+ 4 + 4 = 58 cylinders

So therefore the total seek time = number of cylinders traversed X seek time per cylinder

   = 58 X 6

          = 348msec

From Here we see that SCAN is better or an improvement to FCFS and SSTF as it decrease the average response time (Average Response time is the response time of the all requests).

You might be interested in
Danielle is analyzing logs and baselines of the systems and services that she is responsible for in her organization. She wants
GalinKa [24]

Answer:

b. Machine learning

Explanation:

The technique that is being described in this situation is known as Machine Learning. This is a fairly new technology that has become popular over the last decade. Machine learning uses artificial intelligence to analyze data and learn from it. Every time the system analyzes the data it learns something new, saves it, and implements it to its processes. Therefore, the more times it repeats the more it learns. These systems are continuously getting better and learning more, which makes them incredibly efficient.

5 0
2 years ago
Can you get shocked from a breaker box?
Mashcka [7]
I dont think it would, but maybe you should Google it just in case.
4 0
3 years ago
Bruce needs to have a drive to rerecord data on the used DVD
Dahasolnce [82]

Answer:

DVD- RW

Explanation:

4 0
3 years ago
What is the first thing you should do when troubleshooting a computer problem?
hichkok12 [17]

Answer:

A. Identify and locate the problem.

Explanation:

A problem-solving process can be defined as the systematic approach to used to identify and determine the solution to a particular problem.

The first thing you should do when troubleshooting a computer problem is to identify and locate the problem.

Basically, when an administrator or network engineer is trying to proffer a solution to a computer or network-related problem, it is very important and essential for he or she to first identify what the problem is. This is necessary because it will help to ensure that his or her energy is channeled in the right direction.

Hence, once the problem is identified, then a theory of probable cause can be established.

6 0
3 years ago
Read 2 more answers
Which of the following statements are true regarding Steve Jobs and Steve Wozniak? Select 3 options.
Furkat [3]

Answer:

1. Both Steve Jobs and Steve Wozniak raised $1000 by selling personal items, so that they could start Apple.

2. Steve Wozniak worked for Hewlett Packard designing calculators before starting Apple.

4. Steve Jobs never learned to code and primarily focused on design.

Explanation:

I just took the test.

8 0
3 years ago
Read 2 more answers
Other questions:
  • In databases and database-related software, which choice is not a Boolean operator?
    7·2 answers
  • CHANGE POSITION OF SONG Enter song's current position: Enter new position for song: "Peg" moved to position 3 JAMZ PLAYLIST MENU
    9·1 answer
  • What is Software? Write the functions of Software?​
    11·1 answer
  • The security manager assigned a new security administrator the task of implementing secure protocols on all wireless access poin
    9·1 answer
  • c++ 2.30 LAB: Phone number breakdown Given a long long integer representing a 10-digit phone number, output the area code, prefi
    10·1 answer
  • Information flows:
    11·1 answer
  • Each computer on a network requires a unique way to identify itself and to refer to other computers. This is accomplished by usi
    8·1 answer
  • Enna always says thank you when people give her gifts. She even writes thank-you cards. On holidays, Enna remembers
    9·1 answer
  • SOLVE IN C:
    10·1 answer
  • Jack was drinking a glass of water near his computer when his dog bumped his arm, spilling water on his keyboard. What is the fi
    6·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!