Motion of charge in a magnetic field