A Real Time Distributed Approach to Collision Avoidance for Industrial Manipulators