Home > Differentiation > Differentiating Polynomials from first principles

## Differentiating Polynomials from first principles

The gradient of a curve is always changing.  To calculate the gradient at a point we can consider the gradient of a chord going through that point and gradually make the length of the chord shorter.  As the length gets closer to zero the gradient of the chord should get closer to the gradient of the tangent at the point.

When we are finding the gradient function we are differentiating

Consider the diagram

You can see from the graph that as $\delta x$ gets smaller so does $\delta y$ and that the gradient of the chord gets closer to that of the tangent.

So as $\delta x \rightarrow 0$, $\frac{\delta y}{\delta x} \rightarrow$ the gradient at x

We refer to the gradient at x as $\frac{dy}{dx}$

### Finding the gradient function of $x^2$

Let $y=x^2$

The point that is $\delta x$ across from $x$ has the coordinates  $(x+\delta x, y+\delta y)$

Substituting into $y=x^2$ gives $y+\delta y=(x+\delta x)^2 \Rightarrow y+\delta y=x^2+2x(\delta x)+(\delta x)^2$

Since  $y=x^2$ we get $x^2+\delta y=x^2+2x(\delta x)+(\delta x)^2 \Rightarrow \delta y=2x(\delta x)+(\delta x)^2$

If we now divide  through by $\delta x$ we get $\frac{\delta y}{\delta x} = 2x+\delta x$

Now if we let $\delta x \rightarrow 0$ we get $\frac{dy}{dx}=2x$

### Finding the gradient function of $x^n$

Note that $(x+a)^n = x^n + nax^{n-1} + \frac{n(n-1)}{2!}a^2x^{n-2} + \frac{n(n-1)(n-2)}{3!}a^3x^{n-3} + ...$

Let $y = x^n$

The point that is $\delta x$ across from $x$ has the coordinates  $(x+\delta x, y+\delta y)$

Substituting into $y=x^n$ gives $y+\delta y=(x+\delta x)^n$

So $y+\delta y = x^n + n\delta x x^{n-1} + \frac{n(n-1)}{2!}(\delta x)^2x^{n-2} + \frac{n(n-1)(n-2)}{3!}(\delta x)^3x^{n-3} + ...$

Since  $y=x^n$

we get $x^n+\delta y = x^n + n\delta x x^{n-1} + \frac{n(n-1)}{2!}(\delta x)^2x^{n-2} + \frac{n(n-1)(n-2)}{3!}(\delta x)^3x^{n-3} + ...$

If we now divide  through by $\delta x$

we get $\frac{\delta y}{\delta x} = n x^{n-1} + \frac{n(n-1)}{2!}\delta xx^{n-2} + \frac{n(n-1)(n-2)}{3!}(\delta x)^2x^{n-3} + ...$

Now if we let $\delta x \rightarrow 0$ we get $\frac{dy}{dx}=n x^{n-1}$

You should be able to see that when we differentiate that we multiply by the power and then subtract one from the power.

Examples

 $y$ $\frac{dy}{dx}$ $x^5$ $5x^4$ $3x^7$ $21x^6$ $5x^{-3}$ $-15x^{-4}$

Questions