Skip to content

Latest commit

 

History

History
23 lines (16 loc) · 1005 Bytes

README.md

File metadata and controls

23 lines (16 loc) · 1005 Bytes

Page Faults by Page Replacement Algorithms using Scilab

This is the Scilab Code solution to Problem 9.8, Chapter 9 - Virtual Memory, Operating System Concepts (Book) by Abraham Silberschatz.

Problem 9.8:

Consider the following page reference string:

    1, 2, 3, 4, 2, 1, 5, 6, 2, 1, 2, 3, 7, 6, 3, 2, 1, 2, 3, 6.

How many page faults would occur for the following replacement algorithms, assuming one, two, three, four, five, six, and seven frames? Remember that all frames are initially empty, so your first unique pages will cost one fault each

  1. LRU replacement
  2. FIFO replacement
  3. Optimal replacement

Solution:

Steps of Code Execution:

  1. Clone / Download this repository
  2. Open Scilab and Run the main file - Ex_9_8.sce