Maslov index and Morse theory for the relativistic Lorentz force equation