f(x) = e^{-x}·(x + 1)^2
g(x) = 2·e^{-x}·(x + 1)
----------------------------------------------------------------------------------------------------
g(x) - f(x)
= 2·e^{-x}·(x + 1) - e^{-x}·(x + 1)^2
= e^{-x}·(2·x + 2) - e^{-x}·(x^2 + 2·x + 1)
= e^{-x}·((2·x + 2) - (x^2 + 2·x + 1))
= e^{-x}·(2·x + 2 - x^2 - 2·x - 1)
= e^{-x}·(1 - x^2)
= f'(x)