The Barnes-Hut algorithm, implemented in a number of languages