A Metaheuristic Optimization Approach for Trajectory Tracking of Robot Manipulators