The image of the function is the set of elements f(x), where the values of x belong to the domain of the function.
Let y = 2(x+1)/(x^2+2x+5)
y*(x^2+2x+5) = 2x + 2
y*x^2 + 2y*x + 5y - 2x - 2 = 0
We'll consider y as a coefficients and we'll combine like terms in x:
y*x^2 + x*(2y - 2) + 5y - 2 = 0 (1)
Since the values of x are considered as being real numbers, we'll impose the constraint that the discriminant of the equation (1) to be positive or, at least, zero.
delta = (2y-2)^2 - 4y*(5y-2)>=0
delta = 4y^2 - 8y + 4 - 20y^2 + 8y
We'll combine and eliminate like terms:
delta = -16y^2 + 4 >= 0
We'll divide by -16:
y^2 - 4/16 =< 0
We'll recognize the difference of 2 squares:
(y - 2/4)(y+2/4) =< 0
(y - 1/2)(y + 1/2) =< 0
Since the expression y^2 - 4/16 is negative over the range [-1/2 ; 1/2], then the image of the function f(x) is the set [-1/2 ; 1/2].