It is similar to the SCAN disk scheduling algorithm except for the difference that the disk arm in spite of going to the end of the disk goes only to the last request to be serviced in front of the head and then reverses its direction from there only. Thus it prevents the extra delay which occurred due to unnecessary traversal to the end of the disk.
Given an array of disk track numbers and initial head position, our task is to find the total number of seek operations done to access all the requested tracks if LOOK disk scheduling algorithm is used. Also, write a program to find the seek sequence using LOOK disk scheduling algorithm.
The following chart shows the sequence in which requested tracks are serviced using LOOK.
Therefore, the total seek count is calculated as:
= (60-50)+(79-60)+(92-79) +(114-92)+(176-114) +(176-41)+(41-34)+(34-11)