Prioritizing linear equality and inequality systems: Application to local motion planning for redundant robots