public function angleBetween(self $b)
    {
        $denominator = $this->length() * $b->length();
        if ($denominator == 0) {
            throw new Exception('Cannot divide by zero');
        }

        return acos($this->dotProduct($b) / $denominator);
    }