Skip to content

jalmitul12/OS-Process-Scheduling-Simulator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 

Repository files navigation

⚙️ CPU Scheduling Simulator

An advanced and interactive CPU Scheduling Simulator built using HTML, CSS, and JavaScript to visualize how operating systems schedule processes.

This project provides a real-time simulation environment with Gantt charts, step-by-step execution, and performance analysis.


📌 Key Highlights

  • 🎯 Interactive CPU scheduling simulation
  • 📊 Dynamic Gantt Chart visualization
  • ⏯️ Step-by-step execution player
  • 📈 Real-time performance metrics
  • ⚡ Supports preemptive & non-preemptive algorithms
  • 🧠 Smart insights like starvation and convoy effect detection

🧠 Supported Algorithms

Algorithm Type Description
FCFS Non-Preemptive Executes processes in order of arrival
SJF Non-Preemptive Selects process with shortest burst time
SRTF Preemptive Runs process with shortest remaining time
Round Robin Preemptive Uses time quantum for fair scheduling
Priority (NP) Non-Preemptive Executes based on priority
Priority (P) Preemptive Preempts for higher priority
HRRN Non-Preemptive Avoids starvation using response ratio

🎮 Features

🔹 Process Management

  • Add processes with arrival time, burst time, and priority
  • Automatic ID generation and color coding
  • Load sample data

🔹 Simulation Engine

  • Real-time scheduling execution
  • Handles preemption and context switching
  • Supports time quantum for Round Robin

🔹 Gantt Chart Visualization

  • Displays execution timeline
  • Shows process execution and idle time

🔹 Step-by-Step Execution

  • Play, pause, next, previous controls
  • Displays:
    • Current time
    • Active process
    • Ready queue

🔹 Performance Metrics

Per Process:

  • Completion Time (CT)
  • Turnaround Time (TAT)
  • Waiting Time (WT)
  • Response Time (RT)

Overall:

  • Average Turnaround Time
  • Average Waiting Time
  • Average Response Time
  • CPU Utilization
  • Throughput

🛠️ Tech Stack

  • HTML5
  • CSS3 (Glassmorphism UI)
  • JavaScript



⚙️ Installation & Setup

1. Clone the Repository

git clone https://github.com/your-username/cpu-scheduling-simulator.git

2. Navigate to Project Folder

cd cpu-scheduling-simulator

3. Run the Project

Open scheduling.html in your browser


About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors