a 2D version is also available by by Andrew Duffy
http://physics.bu.edu/~duffy/HTML5/cyclotron.html