implemented pos2angles()