General method for the calculation of particle trajectories in any sector field in a third order approximation