This code was developed for this YouTube video from Veritasium
This is not a library, but rather a collection of standalone scripts! As such, there is a bit of code duplication between scripts.
python -m pip install --upgrade pippip install numpypip install numbagit clone https://github.com/jonnyhyman/Chaos.gitcd ~/route/to/your/folderpython logistic_interactive.pypython logistic_interactive.py

This visualization creates a cobweb plot, time series graph, and bifurcation plot for visualizing the logistic map. The font pictured is "Avenir Next" which is licensed as part of macOS. Other OSes will see their default font.
python logistic_mandelbrot.py

Here we see the Mandelbrot set on the x-y plane, and iterations of the Mandelbrot set in the z axis. This reveals the bifurcation plot beneath the Mandelbrot set!
Final visualization is accomplished by a volume rendering of 1000x1000x1000 voxels, oversampled by 16 to reduce aliasing. At that resolution the visual does not run in realtime.
python logistic_zoom.py

$ claude mcp add Chaos \
-- python -m otcore.mcp_server <graph>