question compute the difference quotient $\frac{f(x + h)-f(x)}{h}$ for the function given below…

question compute the difference quotient $\frac{f(x + h)-f(x)}{h}$ for the function given below. $f(x)=-x^{2}+2x + 1$ select the correct answer below. -2x - h + 2 -x - h + 2 -2x+2h + 1 -2x - 2h + 1 -2x - h - 2 -2x - h + 1
Answer
Explanation:
Step1: Find (f(x + h))
Substitute (x+h) into (f(x)=-x^{2}+2x + 1). [ \begin{align*} f(x + h)&=-(x + h)^{2}+2(x + h)+1\ &=-(x^{2}+2xh+h^{2})+2x + 2h+1\ &=-x^{2}-2xh - h^{2}+2x + 2h+1 \end{align*} ]
Step2: Calculate (f(x + h)-f(x))
[ \begin{align*} f(x + h)-f(x)&=(-x^{2}-2xh - h^{2}+2x + 2h+1)-(-x^{2}+2x + 1)\ &=-x^{2}-2xh - h^{2}+2x + 2h+1 + x^{2}-2x - 1\ &=-2xh - h^{2}+2h \end{align*} ]
Step3: Calculate (\frac{f(x + h)-f(x)}{h})
[ \begin{align*} \frac{f(x + h)-f(x)}{h}&=\frac{-2xh - h^{2}+2h}{h}\ &=\frac{h(-2x - h + 2)}{h}\ &=-2x - h+2 \end{align*} ]
Answer:
(-2x - h + 2)