simpy

Create process-based discrete-event simulations in Python with shared resources and timed events.

6|Updated Dec 30, 2025
One-click install
npx skills add https://github.com/pur3v4d3r/pur3-pkb-codebase --skill simpy-pur3v4d3r
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: simpy
Source: https://github.com/pur3v4d3r/pur3-pkb-codebase/tree/main/.claude/skills/__scientific-skills/simpy
Command: npx skills add https://github.com/pur3v4d3r/pur3-pkb-codebase --skill simpy-pur3v4d3r

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires simpy, and includes scripts (resource) and references (resource) components.

What problem does it solve?

SimPy provides a process-based discrete-event simulation framework for Python, enabling you to model systems where entities interact with each other and contend for shared resources (servers, machines, bandwidth) over time.

Core Features & Use Cases

  • Process modeling using Python generator functions
  • Shared resource management (Resource, Container, Store)
  • Event-driven scheduling and synchronization
  • Real-time simulations synchronized with wall-clock time
  • Comprehensive monitoring and data collection

Use Cases

  • Manufacturing
  • Healthcare
  • Telecommunications
  • Transportation
  • Service operations
  • Computer systems

Quick Start

Create a simple environment, define a couple of processes, start them, and run until a specified simulation time.

Frequently Asked Questions about simpy

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
What is discrete-event simulation in Python and when should I use it?

Discrete-event simulation models systems where entities interact and contend for shared resources over time. Use it for manufacturing, healthcare, telecommunications, transportation, and service operations requiring queueing and event-driven dynamics.

How do I model shared resources and queues in a Python simulation?

Model shared resources and queues using process-based Python generator functions. The framework provides Resource, Container, and Store components to manage entity contention, event scheduling, and synchronization within the simulation environment.

Can I run real-time simulations synchronized with wall-clock time in Python?

Yes, real-time simulations synchronized with wall-clock time are supported. This allows you to model and monitor systems where process execution and event-driven scheduling must match actual elapsed time rather than simulated time.

Does SimPy work for modeling network traffic and server contention?

SimPy works for modeling network traffic and server contention through its resource management and event-driven scheduling. It handles bandwidth and server allocation by modeling entities competing for limited resources over time.

How do I monitor and collect data from a discrete-event simulation?

Monitor and collect data by utilizing the framework's comprehensive monitoring capabilities during simulation execution. Track resource utilization, entity wait times, and process interactions as the environment advances through scheduled events.

What are the limitations of using Python generator functions for process-based simulation?

Python generator functions model process-based simulation but may face performance limitations with extremely large-scale systems. The framework is suited for modeling queueing, resource contention, and event-driven dynamics rather than continuous mathematical simulation.