Fixes segfaults (at the cost of some threading performance), and adds a cooler equation demo