improve particles, refactor to create math module, experiment with foreground drawing