f(x)=\frac{(x+2)x^3}{(x+1)^2}

Asymptote

Restquotient

g(x) = ((x + 2) * x^(3))
h(x) = (x + 1)^(2)
f(x) = g(x) / h(x)
L_1 = Division(g, h)
q(x) = ((2 * x) + 1) / (x + 1)^(2)
asy(x) = x^(2) - 1
i: x = -1
t = 1.53
Q: (t, 0)
T: (t, q(t))
A: (t, asy(t))
P: (t, f(t))
j = Segment(P, A)
k = Segment(T, Q)
O = (0, 0)
l = Segment(O, Q)
G: (t, g(t))
H: (t, h(t))
m = Segment(G, Q)
n = Segment(H, Q)
p: y = 1
r: x = -2
s: x = 0
b = Segment(Q, P)
u = Vector(Q, T)
v = Vector(A, P)
Text2: "g(x)=" + (LaTeX[g]) + ""
Text3: "h(x)=" + (LaTeX[h]) + ""
Text4: "f(x)=" + (LaTeX[asy]) + "+" + (LaTeX[q]) + ""
Text6: "asy(x)=" + (LaTeX[asy]) + ""
Text8: "q(x)=" + (LaTeX[q]) + ""