Question

In: Computer Science

Given the following mix of job, job lengths, and arrival times, assume a time slice of...

Given the following mix of job, job lengths, and arrival times, assume a time slice of 10 and compute the completion for each job and average response time for the FCFS, SJN, SRT, and Round Robin Scheduling Algorithm.

jobs arrival time CPU cycle(ms)

A 0 16

B 3 2

C 5 11

D 9 6

E 10 1

F 12 9

G 14 4

H 16 14

I 17 1

J 19 8

Solutions

Expert Solution

1.FCFS

A B C D E F G H I J

0-------16----------18---------29---------35---------36--------45---------49----------63----64-----72

completion time

A - 16, B - 18, C- 29 , D- 35, E - 36, F - 45, G - 49 , H - 63 , I - 64 , J - 72

Average Response Time = (0+16+18+29+35+36+45+49+63+64)/10 = 35.5

2. SJN

A E I B G D J C F H

0---------16--------17----18-------20-----------24---------30------38---------49--------58---------72

completion time

A - 16, B - 20, C- 49 , D- 30, E - 17, F - 58, G - 24 , H - 72 , I - 18 , J - 38

Average Response Time = (0+18+38+24+16+49+20+58+17+30)/10 = 27

3.SRT

A B C D E D G I C J F A H

0-----3--------5--------9------10-------11------16-------20--21------28---36-------45-----58------72

completion time

A - 58, B - 5, C- 28 , D- 16, E - 11, F - 45, G - 20 , H - 72 , I - 21 , J - 36

Average Response Time = (0+3+5+9+10+36+16+58+20+28)/10 = 18.5

4.RR

A B C D E F G H I J A C H

0-----10------12------22------28------29------38-----42-------52---53---61-----67-------68-----72

completion time

A - 67, B - 12, C- 68 , D- 28, E - 29, F -38, G - 42 , H - 72 , I - 53 , J - 61

Average Response Time = (0+10+12+22+28+29+28+42+52+53)/10 = 27.6

Do ask if any doubt. Please upvote.


Related Solutions

Assume, you are trying to execute the following jobs with execution times and their varying arrival...
Assume, you are trying to execute the following jobs with execution times and their varying arrival times are given. These jobs are run on a single processor using pre-emptive SJF algorithm. If the average waiting time of the processes is 4 millisecond, then the value of X is________. Show the equation with values that helps you to find the value of X. Process No: J1 J2 J3 J4 J5 J6 Arrival time: 0 1 2 3 4 5 Burst Time:...
Consider the following information on job times and due dates (in hours). Job Job Time Due...
Consider the following information on job times and due dates (in hours). Job Job Time Due Date A 4.00 8.00 B 1.50 5.00 C 4.50 9.00 D 4.25 17.00 E 2.25 6.00 You are asked to determine the processing sequence using Shortest Processing Time (SPT) and Earliest Due Date (EDD) rule; and to decide which sequence is better for average job flow time and the average job tardiness performance measures. FORMAT FOR ENTRIES: • Sequence should be entered in the...
You are given the following processes with CPU-burst time, arrival time and priority (lower # means...
You are given the following processes with CPU-burst time, arrival time and priority (lower # means higher priority) Process CPU-burst Arrival time Priority P1 12 0 5 P2 6 6 2 P3 9 1 2 P4 14 3 1 P5 7 5 4 For each of the following scheduling algorithm, show (using the diagram as in the slides), how the process are being executed. Also calculate the average wait time. Shortest job first (non-preemptive) Shortest remaining job first (preemptive) Priority-based...
For Shortest-Job-Next (SJN) Scheduling, -What is the arrival time, completion time, burst time, turnaround time, and...
For Shortest-Job-Next (SJN) Scheduling, -What is the arrival time, completion time, burst time, turnaround time, and the waiting time? -discuss these terms further as they pertain to the efficiency of the algorithm as well as properties such as starvation. -Pros and Cons of SJN
Data on the following slide are the vehicle arrival times at a stop sign. The total time span of the recording was T = 240 minutes.
Data on the following slide are the vehicle arrival times at a stop sign. The total time span of the recording was T = 240 minutes. - What is the average rate l? - Calculate the interarrival times. - Provide visual matches of the data vs. Poisson and data vs. Expo. Use 1-min intervals for the Expo interarrival times Use 10-min intervals for the Poisson [use Excel or any software you like or you can also do it manually] 7.0...
The following data yields the arrival and service times that each customer will require, for the...
The following data yields the arrival and service times that each customer will require, for the first 13 customers at a single server queue system (M/M/1). Upon arrival, a customer either enters service if the server is idle or joins the waiting line. When the server completes the work on a certain customer, the next one in line (i.e. the one who has been waiting the longest) enters the service. The studied period ends until the last customer leaves the...
Assume you have the following jobs to execute with one processor: i t(pi) Arrival Time 0...
Assume you have the following jobs to execute with one processor: i t(pi) Arrival Time 0 75 0 1 40 10 2 25 10 3 20 80 4 45 85 Using the table, assume the context switch time is five time units with RR scheduling. Create a Gantt chart illustrating the execution of these processes. What is the turnaround time for process p3? What is the average wait time for the processes?
Consider the following processes that came at time zero with the following order of arrival with...
Consider the following processes that came at time zero with the following order of arrival with the given CPU burst time. Draw the chart for average turnaround time, average wait time, and average response time versus the time quantum 1,2,3,4,5,6 and 7 using a round-robin CPU scheduling algorithm. Processes CPU Burst Time P1 6 P2 3 P3 1 P4 7
A time study was conducted on a job that contains four elements. The observed times and...
A time study was conducted on a job that contains four elements. The observed times and performance ratings for six cycles are shown in the following table. OBSERVATIONS (minutes per cycle) Element Performance Rating 1 2 3 4 5 6 1 90 % 0.44 0.50 0.43 0.45 0.44 0.46 2 85 1.50 1.56 1.47 1.51 1.49 1.52 3 110 0.84 0.89 0.77 0.83 0.86 0.80 4 100 1.10 1.14 1.08 1.16 1.16 1.26 a. Determine the average cycle time for...
Given the operation times provided: JOB TIMES (minutes) A B C D E F Center 1...
Given the operation times provided: JOB TIMES (minutes) A B C D E F Center 1 20 16 43 60 35 42 Center 2 27 30 51 12 28 24 a. Develop a job sequence that minimizes idle time at the two work centers. The sequence is             (Click to select)  A-B-C-D-E-F  B-A-C-E-F-D  C-A-B-D-E-F  F-E-D-A-B-C  E-F-D-B-C-A  D-C-B-A-E-F  . b. Determine idle time of center 2, assuming no other activities are involved. Idle time             minutes
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT