QuantEcon’s Smit Lunagariya delivered a four-hour tutorial on Computational Methods for Simulation using JAX and NumPy at SciPy 2026, held at the University of Minnesota in Minneapolis, on July 14, 2026.

The tutorial uses Thomas Schelling’s segregation model as its running example — a classic demonstration of how mild individual preferences can lead to extreme aggregate outcomes — and works through how to turn readable but slow Python code into a high-performance simulation:

  1. The basic model — the dynamics of segregation implemented with Python classes
  2. NumPy implementation — rewriting the model with arrays and functions for clarity and speed
  3. JAX implementation — translating the model to JAX syntax and concepts
  4. Further parallelization — exploiting modern parallel hardware such as GPUs

The techniques carry over to other settings that rely on large-scale simulation, including urban planning and epidemiology.

The materials were prepared by John Stachurski, Thomas J. Sargent, Smit Lunagariya, and Matt McKay.

All tutorial materials are freely available online and on GitHub, including notebooks that can be run on Google Colab with no local setup.