An easy-to-use, modular and extendable Julia package for Dynamical Billiard systems in two dimensions.


DynamicalBilliards Logo: The Julia billiard

A Julia package for dynamical billiard systems in two dimensions. The goals of the package is to provide a flexible and intuitive framework for fast implementation of billiard systems of arbitrary construction.

Documentation Package Evaluator Travis AppVeyor
Build Status Build status

The core of DynamicalBilliards.jl is separated in simple and cohesive modular structures:

  • Straight propagation : The standard billiard dynamical system. A particle is propagating in a straight line, until a specular reflection is performed at a boundary.
  • Magnetic propagation : Instead of a straight line, the orbit of the particle is a circle, like electrons in a perpendicular magnetic field. The particle still undergoes specular reflections at the boundaries of the billiard.
  • Ray-splitting billiards : A semiclassical implementation of the dynamical billiard. After a collision of a particle with a boundary, the particle may propagate through the boundary given some arbitrary probability and transmission law.
  • Standard billiards : A library of pre-constructed billiard systems that have already been used in Physics/Mathematics (e.g. Sinai, periodic Sinai, Buminovich etc.)
  • Visualization : functions for plotting and visualizing aspects of a billiard system, such as obstacles, orbits and more. Also includes animation related content.

NOTICE: This package does not support collision between particles (currently). All particles are considered point-particles for all simulations offered by DynamicalBilliards.jl.


This package is registered, simply use Pkg.add("DynamicalBilliards") to install it.

The master branch of DynamicalBilliards is used for development purposes. It is not advised to use Pkg.checkout("DynamicalBilliards"), unless you want to contribute to the development of the package.


Plotting in DynamicalBilliards is done through a sister package, DynamicalBilliardsPlotting. This enables the core package to not have any dependency on plotting packages.

If you want to use the plotting features of DynamicalBilliards, simply run Pkg.add("DynamicalBilliardsPlotting"). Notice that you must be able to install PyPlot for plotting to work. If you are having trouble installing PyPlot you can always use the minimal Python installation through miniconda by running these lines in your Julia terminal:

ENV["PYTHON"]=""; Pkg.add("PyCall"); Pkg.build("PyCall");
Pkg.add("PyPlot"); using PyPlot;

First Commit


Last Touched

30 days ago


265 commits