How can we generalise to find the gradient for any tangent line to a function \(y=x^n\), where \(n\) is a positive integer?
We could adapt what we did for the quadratic and cubic curves in order to generalise: how can we find the gradient of the line through the points with coordinates \((x,x^n)\) and \((x+h,(x+h)^n)\)? Where \(h\) is a very very small positive number.
We can then calculate the gradient of the line going through the points \((x,x^n)\) and \((x+h,(x+h)^n)\),
\[ \frac{y_2-y_1}{x_2-x_1}=\frac{(x+h)^n-x^n}{x+h-x}=\frac{(x+h)^n-x^n}{h}.\]
We would like to expand and simplify this expression, but \((x+h)^n\) is not so simple to expand when we don’t have a specific value for \(n\).
However, \(x+h\) is a binomial. We have a way to expand \((x+h)^n\), The Binomial Theorem, for \(n\) a positive integer:
\[(x+h)^n={\binom n 0}x^nh^0+{\binom n 1}x^{n-1}h+{\binom n 2}x^{n-1}h^2+ \dots + {\binom n {n-1}}xh^{n-1}+{\binom n n}x^{0}h^n.\]
The binomial coefficients \({\dbinom n k}\) are given by \(\dfrac{n!}{k!(n-k)!}\).
We can now think about how to expand,
\[\frac{(x+h)^n-x^n}{h}.\]
The numerator is,
\[{\binom n 0}x^nh^0+{\binom n 1}x^{n-1}h+{\binom n 2}x^{n-1}h^2+ \dots + {\binom n {n-1}}xh^{n-1}+{\binom n n}x^{0}h^n-x^n\]
which simplifies to,
\[{\binom n 1}x^{n-1}h+{\binom n 2}x^{n-1}h^2+ \dots + {\binom n {n-1}}xh^{n-1}+{\binom n n}x^{0}h^n.\]
The denominator simplifies to \(h\).
So, the gradient of the line through the points \((x,x^n)\) and \((x+h,(x+h)^n)\) is
\[{\binom n 1}x^{n-1}+{\binom n 2}x^{n-1}h+ \dots + {\binom n {n-1}}xh^{n-2}+{\binom n n}h^{n-1}.\]
As we move the point \((x+h,(x+h)^n)\) closer and closer to \((x,x^n)\), we are making \(h\) smaller and smaller, finally making \(h\) zero. This gives the gradient of the line that touches the curve \(y=x^n\) at the point \((x,x^n)\) as \({\binom n 1}x^{n-1}\), for \(n\) a positive integer.
The binomial coefficient \(\dbinom{n}{1}\) is given by \(\dfrac{n!}{1!(n-1)!}=\dfrac{n\times (n-1) \times \dots \times 1}{(n-1)\times (n-2) \times \dots \times 1}=n\).
This gives the gradient of the line that touches the curve \(y=x^n\) at the point \((x,x^n)\) as \(nx^{n-1}\), for \(n\) a positive integer.