PathSim: Block Diagram Simulation in Pure Python

Milan Rother

PyData & Scientific Libraries Stack
Python Skill Novice
Domain Expertise Intermediate

Talk Overview

This talk presents PathSim through its development journey: why it was created, what technical challenges it solves, and how it fits into the scientific Python ecosystem. Rather than just another simulation tool, PathSim addresses a specific gap between low-level ODE solvers and expensive proprietary environments.

Target Audience

  • Engineers and researchers simulating physical systems
  • Python developers curious about simulation frameworks
  • Anyone who's hit limitations with scipy.integrate for complex systems
  • Those interested in the journey of building scientific software

No simulation background required - concepts explained from first principles.

Talk Structure (30 minutes)

The Origin Story (4 min)

  • Why build PathSim? Real problems that motivated development
  • The gap between scipy.integrate and full simulation environments
  • Design decisions: decentralized architecture, pure Python, minimal dependencies

What Makes Block Diagram Simulation Different? (8 min)

  • Live comparison: same system with scipy.integrate vs PathSim
  • Signal routing and interconnections
  • The block diagram mental model for complex systems
  • When you need structure beyond "write a function, call solve_ivp"

Core Features Through Examples (12 min)

Example 1: Event Handling

  • Bouncing ball with zero-crossing detection
  • Why this is hard with basic ODE solvers
  • PathSim's event system in action

Example 2: Stiff Systems

  • Van der Pol oscillator demonstration
  • Implicit solver integration (ESDIRK, BDF methods)
  • Adaptive timestepping visualization

Example 3: Hierarchical Modeling

  • Building subsystems and nesting them
  • Modularity for large-scale simulations

Integration & Ecosystem (4 min)

  • Co-simulation capabilities and FMI support
  • Hardware-in-the-loop applications
  • Custom block development and extensibility
  • Integration with other Python tools (control libraries, ML frameworks)

Getting Started (2 min)

  • Installation and documentation
  • Example gallery walkthrough
  • Where PathSim fits in your workflow
  • Contributing and community

Key Takeaways

  • Understand when block diagram simulation adds value over basic ODE solving
  • See practical examples of stiff systems and event handling
  • Learn about PathSim's architecture and extensibility
  • Know how to integrate simulation into broader Python workflows

Why This Talk Matters

Many Python users face the "scipy.integrate isn't enough, but I don't want MATLAB" problem. This talk shows there's a middle ground: structured simulation that's open source, Pythonic, and extensible. The development story provides insights into building scientific software, while practical demos show immediate applicability.

The talk emphasizes technical substance over credentials - showing what problems PathSim solves and how, rather than where it's being used.

Milan Rother

Milan is a freelance developer specializing in numerical simulation and scientific computing tools. Based in Braunschweig with a master's degree in EE from TU Braunschweig, he builds open-source frameworks that bridge engineering practice and Python scientific computing.

As the creator of PathSim, Milan has worked on a range of projects including modeling for biomedical sensors, design automation for integrated circuits, microwave imaging, and most recently nuclear fusion systems. Beyond PathSim, he maintains several scientific computing tools including vectorfitting algorithms, harmonic balance frameworks, and RFIC design tools.