Alaa Zaitoon
Skip to content
Spring Boot & Modern Web UI

CPU Scheduling Simulator

A fully interactive, real-time CPU Scheduling Simulator designed to visualize and analyze operating system scheduling processes. The simulator enables users to run 5 classic CPU scheduling algorithms, view color-coded dynamic Gantt charts, and analyze overall performance metrics dynamically.

Problem Statement

Visualization of Operating Systems processes execution is complex. Understanding preemption, CPU idle slices, and ready-queue ordering requires a clear, interactive visual Gantt timeline showing exactly when process switches occur.

System Architecture

Client-side state machine using React hooks. The simulation runs on pure JavaScript arrays, managing ready queues, sorting execution slices, and exporting performance statistics (TAT, WT). CSS transitions and Framer Motion handle animation.

Engineering Challenges & Solutions

Modeling textbook preemption schedules correctly when processes arrive during a running time slice (such as in Round Robin queue ordering), and avoiding viewport scroll clipping on mobile screens.

App Interface Preview

CPU Scheduling Simulator preview

Technologies Used

Java 17+Spring Boot 3.xMavenHTML5Vanilla CSSJavaScript ES6JUnit 5Docker

Core Features

  • Interactive color-coded Gantt Charts displaying idle CPU cycles
  • Supports 5 algorithms: FCFS, SJF, Priority (Preemptive/Non-Preemptive), RR
  • Calculates Completion Time, Turnaround Time, and Waiting Time
  • Pre-loaded sample datasets for one-click testing and comparison