Find Jobs
Hire Freelancers

to write a program in Java that simulates the behavior of the multiprogramming operating system

$90-275 USD

Ολοκληρώθηκε
Αναρτήθηκε περίπου 9 χρόνια πριν

$90-275 USD

Πληρωμή κατά την παράδοση
Introduction: It is required in this assignment, to write a program in Java that simulates the behavior of the multiprogramming operating system. At the end of the simulation, you are expected to output some statistics regarding the behavior of the system. In the following sections, we will introduce the hardware specification, the multiprogramming OS features and the jobs requirements. Hardware: The computer hardware is assumed to have: 1. A hard disk of size of 10 GB where 1/5 of this size is used to store the user programs. 2. A RAM of size 192MB, where 32MB is used to store the OS. 3. A CPU that executes one instruction each unit of time. 4. An IO device for input and output operations. 5. An internal clock that ticks every unit of time. Operating System: The operating system is the multiprogramming OS. We would be interested in only 2 features in this simulation: The Job and CPU scheduling. 1. Job Scheduling: The program with the smallest size is first selected to be loaded in the main memory. We call this technique by SSPF. 2. CPU scheduling: The CPU is allocated to the program with the smallest expected running time. We call this technique by SETF. Program specifications: Each program has 2 main requirements: A program size in KB and an expected execution time. Of course, the expected execution time is greater or equal to the exact execution time. In addition, each program should have an Id and state. The student should specify any extra information that is required by the simulation. 1. The memory sizes are uniformly distributed between 16KB and 16384KB 2. The expected execution time is also distributed between 16 ut and 512 ut. Initialization phase: You should perform the following steps before running the simulation: 1. Generate enough programs with random memory size and random expected execution time so to fill the hard disk. (Σ Program sizes ≤ 2 GB) 2. Load the RAM with the maximum number of user programs. 3. Start the simulation run which consists of a simulation of the Machine Execution Cycle. The Machine Execution Cycle: The following algorithm simulates the machine Execution Cycle: MEC algorithm: While true do { Increments the simulated clock by one unit of time (* This assumes that one instruction is executed *) If there are interrupts Then Interrupts the current program and calls the ISRi endif } Interrupts are also randomly generated: 1. The possibility that there are interrupts is 10% 2. The possibility that there is an IO request is 20% 3. The possibility that the busy IO device will terminate is 20% 4. The possibility that the program terminates normally is 5% 5. The possibility that the program terminates abnormally is 1% The main simulator program is like this: Initialize the simulation While there are jobs in the H-Disk do { Run the Machine Execution Cycle } Print the required statistics Output from the simulation: At the end of the simulation, you should print the following results: The number of initially generated jobs stored on the H-disk. The average program size of all jobs. The average number of jobs that have completed their execution normally. The average number of jobs that have completed their execution abnormally. The number of CPU bound jobs.
Ταυτότητα εργασίας: 7606149

Σχετικά με την εργασία

2 προτάσεις
Απομακρυσμένη Εργασία
Ενεργός/ή 9 χρόνια πριν

Ψάχνεις τρόπο για να κερδίσεις μερικά χρήματα;

Πλεονεκτήματα πλειοδοσίας στο Freelancer

Καθόρισε τον προϋπολογισμό σου και το χρονοδιάγραμμα
Πληρώσου για τη δουλειά σου
Περίγραψε την πρόταση σου
Η εγγραφή και η πλειοδοσία σε εργασίες είναι δωρεάν
Βραβεύτηκε στον/στην:
Avatar Χρήστη
I have 5 years of programming experience. I can help you solve this problem. When you work with me you will feel very comfortable.
$100 USD σε 1 ημέρα
4,8 (31 αξιολογήσεις)
4,4
4,4
2 freelancers δίνουν μια μέση προσφορά $150 USD για αυτή τη δουλειά
Avatar Χρήστη
Hi. I can help you on this program. Thank you. .
$200 USD σε 3 ημέρες
5,0 (12 αξιολογήσεις)
4,3
4,3

Σχετικά με τον πελάτη

Σημαία της SAUDI ARABIA
riyadh, Saudi Arabia
5,0
2
Επαληθευμένη μέθοδος πληρωμής
Μέλος από Μαΐ 4, 2015

Επαλήθευση Πελάτη

Ευχαριστούμε! Σου έχουμε στείλει ένα email με ένα σύνδεσμο για να διεκδικήσεις τη δωρεάν πίστωση σου.
Κάτι πήγε στραβά κατά την προσπάθεια αποστολής του email σου. Παρακαλούμε δοκίμασε ξανά.
Εγγεγραμμένοι Χρήστες Συνολικές Αναρτημένες Δουλειές
Freelancer ® is a registered Trademark of Freelancer Technology Pty Limited (ACN 142 189 759)
Copyright © 2024 Freelancer Technology Pty Limited (ACN 142 189 759)
Φόρτωση προεπισκόπησης
Δόθηκε πρόσβαση για Geolocation.
Η σύνδεση σου έχει λήξει και τώρα έχεις αποσυνδεθεί. Παρακαλούμε συνδέσου ξανά.