Distributed positioning algorithm for ad-hoc networks.