Question

In: Computer Science

1. What is the average waiting time for Processes If the Operating System uses the Shortest-Job-First...

1. What is the average waiting time for Processes If the Operating System uses the Shortest-Job-First (SJF) Scheduling Algorithm?

(P1=5 ms, P2=10 ms, P3=15 ms)

2. How many page faults occur in the Optimum Page Replacement algorithm (OPR) with the following reference string for three-page frames?   

Reference String: 4,2,1,3,2,3,4,1

3. What is the average waiting time for Processes If the Operating System uses Shortest-Job-Remaining-First (SJRF) Scheduling Algorithm?

(P1=5 ms, P2=10 ms, P3=15 ms)

Arrival Time ( P1=0 ms, P2=5 ms, P3=10 ms)

4. What is the average waiting time for Processes If Operating System uses the First Come First Serve (FCFS) Scheduling Algorithm?

(P1=5 ms, P2=10 ms, P3=15 ms)

Process Order: P2, P1, P3

5. What is the average waiting time for Processes If the Operating System uses Round Robin (RR) Scheduling Algorithm?

(P1=5 ms, P2=10 ms, P3=15 ms)

Time slice/ quantum = 5 ms

6. What is the average waiting time for Processes If the Operating System uses the Priority Scheduling (PS) Scheduling Algorithm?

(P1=5 ms, P2=10 ms, P3=15 ms)

Priority Order: P3, P1, P2

7. How many page faults occur in the FIFO replacement algorithm with the following reference string for THREE-page frames?   

Reference String: 4,2,1,3,2,3,4,1

8. How many page faults occur in the Least Recently Used Algorithm (LRU) with the following reference string for three-page frames?   

Reference String: 4,2,1,3,2,3,4,1

Solutions

Expert Solution

SCHEDULING ALGORITHMS:

turn around time : it is interval between arrval time and completion time of the process

turn around time(TAT)=completion time(CT)- arrival time(AT)

waiting time:interval between TAT and burst time(BT) and the time it waits in the ready queue

waiting time:TAT-BT

burst time:time to run a process

arrival time:the time for process to more from new ready to new

Completion time:time to move from to terminate state(see in the gantt chart)

average waiting time(WT)=sum of all processes waiting time/number of process

FCFS(first come first serve):

Selection criteria:arrival time

mode of operation:non preemptive

conflict resolution:lower process id

SJF(shortest job first):

Selection criteria:burst time

mode of operation:non preemptive

conflict resolution:lower process id

SRJF(shortest remaining job first):

Selection criteria:burst time

mode of operation:preemptive

conflict resolution:lower process id

RR(round robin):

preemption of the running process is based on completing of time quantum allocated to a process.

Selection criteria:arrival time+time quantum

mode of operation:preemptive

Priority scheduling:

Selection criteria:priority

mode of operation:non preemptive

conflict resolution:lower process id

PAGE REPLACEMENT ALGORITHMS:

Optimal page replacement algo:

in the event of page fault,victimise that page which will not be used for the largest duration of time in future refrences.

FCFS(First come fisrt serve):

criteria:time of load

LRU(least recently used):

in the event of page fault,victimise that page which was not used recently.


Related Solutions

What is the average waiting time for Processes If Operating System uses the First Come First...
What is the average waiting time for Processes If Operating System uses the First Come First Serve (FCFS) Scheduling Algorithm? (P1=5 ms, P2=10 ms, P3=15 ms) Process Order: P2, P1, P3 Select one: a. 8.3 b. 11.7 c. 10 d. 6.7
Bus waiting time is uniformly distributed with the shortest and the longest waiting times being 7...
Bus waiting time is uniformly distributed with the shortest and the longest waiting times being 7 and 38 minutes respectively. What is the standard deviation of the average waiting time of 57 passenger
Operating Systems Question 1.What is the maximum number of processes in the system at any time...
Operating Systems Question 1.What is the maximum number of processes in the system at any time using the following code segment? extern char mypath[]; for ( int i = 0; i < 10; i++ ) { pid_t pid, pid_out; unsigned char status; if ( pid = fork() ) pid_out = wait ( &status ); else execl ( mypath, "child", "parameter", NULL ); } Assume that child performs some simple computation and returns the result, that is captured in status.
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
First-Come, First-Served (FCFS) Scheduling Shortest-Job-Next (SJN) Scheduling Priority Scheduling Shortest Remaining Time Round Robin(RR) Scheduling Multiple-Level...
First-Come, First-Served (FCFS) Scheduling Shortest-Job-Next (SJN) Scheduling Priority Scheduling Shortest Remaining Time Round Robin(RR) Scheduling Multiple-Level Queues Scheduling Provide a timing example of each of the algorithms above. List some processes (at least four) with the appropriate properties for creating a time diagram (such as Process ID, Arrival Time, Burst Time, and Execution Time). Walk through the timing diagram identifying the algorithm you’re using and state which process goes first, which process finishes first, etc.
List of six process scheduling algorithms (for operating systems): First-Come, First-Served (FCFS) Scheduling Shortest-Job-Next (SJN) Scheduling...
List of six process scheduling algorithms (for operating systems): First-Come, First-Served (FCFS) Scheduling Shortest-Job-Next (SJN) Scheduling Priority Scheduling Shortest Remaining Time Round Robin(RR) Scheduling Multiple-Level Queues Scheduling Compare and contrast the algorithms against one another here. You have at least six algorithms, so this should be an extensive part of the project, and all research based.
For Shortest Remaining Time, What is the arrival time, completion time, burst time, turnaround time, and...
For Shortest Remaining Time, 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 Shortest Remaining Time
Iowa Company uses a process costing system. Operating data for the first processing department for the...
Iowa Company uses a process costing system. Operating data for the first processing department for the month of June appear below: Units Percent Complete with Respect to Conversion Beginning work-in-process inventory 15,000 30% Started into production during June 75,000 Ending work-in-process inventory 20,000 70% According to the company's records, the conversion cost in beginning work-in-process inventory was $49,920 at the beginning of June. Additional conversion costs of $855,120 were incurred in the department during the month. 1. How many units...
Iowa Company uses a process costing system. Operating data for the first processing department for the...
Iowa Company uses a process costing system. Operating data for the first processing department for the month of June appear below: Units Percent Complete with Respect to Conversion Beginning work-in-process inventory 12,000 60% Started into production during June 80,000 Ending work-in-process inventory 18,000 40 % According to the company's records, the conversion cost in beginning work-in-process inventory was $44,530 at the beginning of June. Additional conversion costs of $832,150 were incurred in the department during the month. How many units...
An operating system uses the First-Come, First-Served (FCFS) CPU scheduling algorithm. Consider the following set of...
An operating system uses the First-Come, First-Served (FCFS) CPU scheduling algorithm. Consider the following set of processes in this OS, with the length of the CPU burst time given in milliseconds, and the shown priority. A larger priority number implies a higher priority. There is no pre-emption. The processes are assumed to have arrived in the order P1, P2, P3, P4, P5, all at time 0. Process Burst Time Priority P1 2 2 P2 1 5 P3 4 1 P4...
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT