private function _theta(PointInterface $a, PointInterface $b)
    {
        list($x1, $y1) = $a->getCoordinates();
        list($x2, $y2) = $b->getCoordinates();
        return atan2($y2-$y1, $x2 - $x1) + 2 * M_PI;
    }