Does finding slope of the tangent line to $y=x^2 +2x$ constitute division by zero when differentiating from first principles

calculusderivativesfunctionslimitstangent line

When we consider a limit as $h \rightarrow 0$ when finding the slope of the tangent to a function at a particular point, we sometimes find ourselves in a form where the function may lead to a division by $0$ error. However, since this is a limit, I'm unsure whether or not this actually does lead to this particular problem.

To illustrate the above problem, let's say that one wishes to find the slope of the tangent line at the point $(-1,-1)$ in the function $y=x^2 +2x$

We are told that $y=x^2 +2x$ and so we look for the slope at $(-1,-1)$.

We consider $f(-1+h)=(-1+h)^2+2(-1+h)=h^2 -1$ where $h \rightarrow 0$; so the closest point is $((-1+h),(h^2-1))$.

Finding the slope, we have $\frac{h^{2}-1-(-1)}{h-1-(-1)}=\frac{h^2}{h}=h$. When $h$ approches $0$, the slope is $0$.

I am wondering if when $h^2/h$ is simplified to $h$, this would preclude us from taking the limit as $h$ approaches zero, as the expression has been divided by $h$ at one point. To take the limit when $h$ approaches zero, we plug in zero for $h$– doesn't this constitute a zero division error? Thanks for any clarification.

Best Answer

No, there is no division by $\bf0$ error here. One of the main advantages of taking limits as variables approach $0$ is that we avoid this particular error and can describe the behaviour of the function when the input(s) are close to $0$ but not actually equal to it.

When we take the limit of a function as a variable approaches $0$, what we are doing is considering what happens when that variable becomes arbitrarily close to $0$. The fact that this variable is not actually equal to $0$ is an important distinction.

You are correct that if $\frac{h^2}{h}$ is evaluated when $h=0$, then this fraction is undefined (and cannot be simplified to $h$). However, we are taking a limit. Therefore, what we are actually considering is $\frac{h^2}{h}$ when $h$ is close to $0$. Since $h$ is not actually equal to $0$, we are able to simplify to fraction (as you have done in the question) down to $h$. Now, we can evaluate the limit as $h$ approaches $0$ which is equal to $0$. Therefore, the slope (derivative) of this function at $(x,y)=(-1,-1)$ is $0$.

Note that you can verify the above result by considering the derivative at the point $x=-1$. Since $y=x^2 +2x$, we have $\frac{dy}{dx} = 2x+2$ which is a function for the gradient of the function at $x$. We are interested in the case where $x = -1$, so we substitute this in and see that this matches up with our above answer of $0$ from the above paragraph. More explicitly, we have that $ 2(-1)+2 = 0$ as the slope of the tangent line at the point of the curve where $x = -1$.