simple particle simulator in javascript