Question

In: Computer Science

Question 1: On a disk with 1000 cylinders, number 0 to 999, compute the number of...

Question 1:

On a disk with 1000 cylinders, number 0 to 999, compute the number of tracks the disk arm must move to satisfy all the requests in the disk queue. Assume the last request serviced was at track 345 and the head is moving toward track 0. The queue in FIFO order contains requests for the following tracks: 123, 847, 692, 475, 105, 376.

Perform the computations for the following disk scheduling algorithms:

a)       FCFS                                                                                                       

b)       SSTF                                                                                                        

c)       SCAN - Increasing Track                                                                          

d)       C-SCAN - increasing Track                                                                       

e)       LOOK - increasing Track                                                                           

Question 2:

Considering a system with five processes P0 through P4 and three resources of type A, B, C. Resource type A has 10 instances, B has 5 instances and type C has 7 instances. Suppose at time t0 following snapshot of the system has been taken:

a)       What will be the content of the Need matrix?                                             

b)       Is the system in a safe state? If Yes, then what is the safe sequence?   

Solutions

Expert Solution

Q1

Please verify that the request order is valid or not. Since the question is a well known one, it must be 123, 874, 692, 475, 105, 376. The track number which might be different is underlined. Moreover, please let me know that the meaning of "increasing track" is same as I have given in the solution. If it is something else then please let me know in the comments, I will change the solution. Also, if there is any part for which the answer does not match please let me know in the comments, I will try to provide you a new solution for that part.  

Q2

Your question was incomplete but since you have given the total number of resources I got hint what the question might be since the question is well known. If the question is something else please let me know.


Related Solutions

Suppose that a disk drive has 6,000 cylinders, numbered 0 to 5999. The drive is currently...
Suppose that a disk drive has 6,000 cylinders, numbered 0 to 5999. The drive is currently serving a request at cylinder 3150, and the previous request was at cylinder 1805 (Hint: this indicates the reading head's moving direction). The queue of pending requests, in FIFO order, is: 3511, 2332, 2800, 3192, 658, 1296, 1918, 1356, 5936, 2527 Starting from the current head position, what is the total distance in cylinders) that the disk arm moves to satisfy all the pending requests for...
Suppose that a disk drive has 5,000 cylinders, numbered 0 to 4,999. The drive is currently...
Suppose that a disk drive has 5,000 cylinders, numbered 0 to 4,999. The drive is currently serving a request at cylinder 2,150, and the previous request was at cylinder 1,805. The queue of pending requests, in FIFO order, is: 2,069, 1,212, 2,296, 2,800, 544, 1,618, 356, 1,523, 4,965, 3681 Starting from the current head position, what is the total distance (in cylinders) that the disk arm moves to satisfy all the pending requests for each of the following disk-scheduling algorithms?...
The question asks to allow the user to integer ranging from 1 to 999 using JOPtionpane...
The question asks to allow the user to integer ranging from 1 to 999 using JOPtionpane in JAVA; and display those integers in words. For example, if the user enters 13 the program should display " Thirteen" and loop to ask the user to enter another integers. If the user enters 0, the program should quit. If the user enters an integer greater than 999, the program should display an error message and ask the user to enter an integer...
i need code in javascript or htmlt convert 0 to 999 numbers into word
i need code in javascript or htmlt convert 0 to 999 numbers into word
Compute the determinant of A, where A= a 4x4 matrix [1 -3 0 0; 2 1...
Compute the determinant of A, where A= a 4x4 matrix [1 -3 0 0; 2 1 0 0; 0 0 1 2; 0 0 2 1] a 4x4 matrix [2 5 4 2; 0 0 0 2; 0 -3 0 -4; 1 0 -1 1] and a 4x4 matrix [1 -3 0 0; 2 1 0 0; 0 0 1 2; 0 0 2 1]^-1. a) det(A)= -36 b) det(A)= 5 c) det(A)= 0 d) det(A)= -13 e)det(A)= 36
Project C0 C1 C2 C3 C4 A -5000 +1000 +1000 +3000 0 B -1000 0 +1000...
Project C0 C1 C2 C3 C4 A -5000 +1000 +1000 +3000 0 B -1000 0 +1000 +2000 +3000 C -5000 +1000 +1000 +3000 +5000 If the opportunity cost of capital is 11%, and you have unlimited access to the capital, which one(s) would you accept? What would be your action if the cost of capital is 16%? Suppose that you have limited access to the capital and you need to choose only one project. Which one would you choose? The...
Days 1 to 120: Number of New Cases 0 1 0 0 2 0 3 0...
Days 1 to 120: Number of New Cases 0 1 0 0 2 0 3 0 0 0 0 14 2 1 0 27 80 51 18 26 216 81 37 117 167 108 151 178 111 414 337 195 706 214 300 68 118 160 190 209 154 193 170 154 166 68 119 152 146 101 98 159 175 195 195 157 130 129 161 116 133 217 209 75 298 240 205 196 233 76 339 170...
0-499 22 500-999 201 1000-1499 1,645 1500-1999 9,365 2000-2499 92,191 2500-2999 569,319 3000-3499 1,387,335 3500-3999 988,011...
0-499 22 500-999 201 1000-1499 1,645 1500-1999 9,365 2000-2499 92,191 2500-2999 569,319 3000-3499 1,387,335 3500-3999 988,011 4000-4499 255,700 4500-4999 36,766 5000-5499 3,994 0-499 22 500-999 201 1000-1499 1,645 1500-1999 9,365 2000-2499 92,191 2500-2999 569,319 3000-3499 1,387,335 3500-3999 988,011 4000-4499 255,700 4500-4999 36,766 5000-5499 3,994 D) Use the normal model to determine the proportion of babies in each class How do I manually determine the normal mode? Please provide step by step manually (excel is what I am using, however I...
(Using C++) Sample array: 100, 45, 33, 55, 356, 11, 1000, 999, 987 You need to...
(Using C++) Sample array: 100, 45, 33, 55, 356, 11, 1000, 999, 987 You need to perform the following steps to evaluate the algorithm’s time complexity: Pick any two sorting algorithms (e.g., merge sort, bubble sort). Find the algorithm implementation. Create the array, and store all of the elements described above. Pass the array into the first sorting algorithm. Pass the array into the second sorting algorithm. Calculate the execution time for the first sorting algorithm’s execution. Calculate the execution...
Suppose: 1) 1 year futures price=$1000, 2) interest rate = 0%, and 3)for K=$1000, the premium...
Suppose: 1) 1 year futures price=$1000, 2) interest rate = 0%, and 3)for K=$1000, the premium on a 1 year call (C) is $100 and on a 1year put (P) $150. a. Does put-call parity hold? If not, relative to each other which option is overpriced and which underpriced? b. Describe a profitable and risk free arbitrage, that is, what would you long today and what would you short? c. For your arbitrage described in question b. what are your...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT