A hybrid CHAOS-PSO algorithm for dimensional synthesis of a redundant manipulator based on tracking trajectories without or with singularities