<s>[INST] What is the inverse for: $x^2+4x+5,x\ge-2$ What is the inverse for: $x^2+4x+5,x\ge-2$

I have tried to solve it using the quadratic formula:
$x^2+4x+5=y$
$x^2+4x+5-y=0$
$x=-2\pm\sqrt{y-1}$
$y\ge1$
The inverse should be: $x=-2+\sqrt{y-1}$
I don't understand why it sould be $+\sqrt{y-1}$ and not $-\sqrt{y-1}$
Can someone explain why it is positive and not negative?
 [/INST] Try plugging in a number. Since we assume $x\geq -2$, plugging in $x=3$ gives us $f(3)=26$. We want $f^{-1}(26)=3$. This only happens when $f^{-1}(y)=-2+\sqrt{y-1}$. In case we were to take $x<-2$, the inverse would have been $-2-\sqrt{y-1}$. This phenomena occours since $x^2+4x+5$ is not globally invertible, and hence has two inverses depending on the region.
</s>