Skip to main content

Derivatives

The Derivative As a Limit​

The derivative of the function ff at the point xx is defined as:

lim⁡h→0f(x+h)−f(x)h\lim_{h \to 0} \displaystyle\frac{f(x+h) - f(x)}{h}

if this limit exists.

Details​

Definition

The derivative of the function ff at the point xx is defined as

lim⁡h→0f(x+h)−f(x)h\lim_{h \to 0} \displaystyle\frac{f(x+h) -f(x)}{h}

if this limit exists.

When we write y=f(x)y = f(x), we commonly use the notation dydx\displaystyle\frac{dy}{dx} or f′(x)f'(x) to denote the derivative.

The Derivative of f(x)=a+bxf(x)=a+bx​

If

$f(x)=a+bxf(x) = a + bx

then

f(x+h)=a+b(x+h)=a+bx+bhf(x + h) = a + b(x + h) = a + bx + bh

and thus

lim⁡h→0f(x+h)−f(x)h=lim⁡h→0bhh=b\lim_{h \to 0} \displaystyle\frac{f(x+h)-f(x)}{h} = \lim_{h \to 0} \displaystyle\frac{bh}{h}=b

Fig. 27

Details​

If

f(x)=a+bxf(x) = a + bx

then

f(x+h)=a+b(x+h)=a+bx+bhf(x + h) = a + b(x + h) = a + bx + bh

and thus

lim⁡h→0f(x+h)−f(x)h=lim⁡h→0bhh=b\lim_{h \to 0} \displaystyle\frac{f(x+h)-f(x)}{h} = \lim_{h \to 0} \displaystyle\frac{bh}{h}=b

Thus

f′(x)=bf'(x)=b

The Derivative of f(x)=xnf(x)=x^n​

If

f(x)=xnf(x)=x^n

then

f′(x)=nxn−1f'(x)=nx^{n-1}

Details​

Let f(x)=xnf(x)=x^n, where nn is a positive integer. To calculate f′f' we use the binomial theorem in the third step:

f(x+h)−f(x)h=(x+h)n−xnh=∑q=0n−1(nq)xqhn−qh=∑q=0n−1(nq)xqhn−q−1=(nn−1)xn−1=nxn−1\begin{aligned} \displaystyle\frac{f(x+h)-f(x)}{h} &= \displaystyle\frac{(x+h)^n-x^n}{h} \\ & = \displaystyle\frac{\displaystyle\sum_{q=0}^{n-1}\displaystyle\binom{n}{q}x^qh^{n-q}}{h} \\ & = \displaystyle\sum_{q=0}^{n-1}\displaystyle\binom{n}{q}x^qh^{n-q-1} \\ & = \displaystyle\binom{n}{n-1}x^{n-1} \\ & = nx^{n-1} \end{aligned}

Thus, we obtain f′(x)=nxn−1f'(x)=nx^{n-1}.

The Derivative of Ln and Exp​

If

f(x)=exf(x) = e^x

then

f′(x)=exf'(x) = e^x

If

g(x)=ln⁡(x)g(x) = \ln(x)

then

g′(x)=1xg'(x) = \displaystyle\frac{1}{x}

Details​

The derivatives of the exponential function is the exponential function itself. That is, if

f(x)=exf(x) = e^x

then

f′(x)=exf'(x) = e^x

The derivatives of the natural logarithm, ln⁡(x)\ln(x), is 1x\displaystyle\frac{1}{x}. That is, if

g(x)=ln⁡(x)g(x) = \ln(x)

then

g′(x)=1xg'(x) = \displaystyle\frac{1}{x}

The Derivative of a Sum and Linear Combination​

If ff and gg are functions then the derivative of f+gf+g is given by f′+g′f' + g'.

Details​

Similarly, the derivative of a linear combination is the linear combination of the derivatives. If ff and gg are functions and k(x)=af(x)+bg(x)k(x)=af(x) + bg(x) then k′(x)=af′(x)+bg′(x)k'(x)=af'(x)+ bg'(x).

Examples​

Example

If

f(x)=2+3x,g(x)+x3f(x) = 2+3x, g(x)+x^3

then we know that

f′(x)=3,g(x)=3x2f'(x)=3, g(x)=3x^2

and if we write

h(x)=f(x)+g(x)=2+3x+x3h(x)=f(x)+g(x)=2+3x+x^3

then

h′(x)=3+3x2h'(x)=3+3x^2

The Derivative of a Polynomial​

The derivative of a polynomial is the sum of the derivatives of the terms of the polynomial.

Details​

If

p(x)=a0+a1x+⋯+anxnp(x) = a_0+a_1x+\dots +a_n x^n

then

p′(x)=a1+2a2x+3a3x2+4a4x3+⋯+nanx(n−1)p'(x) = a_1+2a_2x+3a_3x^2+4a_4x^3+\dots +na_n x^{(n-1)}

Examples​

Example

If

p(x)=2x4+x3p(x)=2x^4+x^3

then

p′(x)=2dx4dx+dx3dx=2⋅4x3+3x2=8x3+3x2p'(x)=2\displaystyle\frac{dx^4}{dx}+\displaystyle\frac{dx^3}{dx}=2 \cdot 4x^3 +3x^2 = 8x^3 +3x^2

The Derivative of a Product​

If

h(x)=f(x)⋅g(x)h(x)=f(x)\cdot g(x)

then

h′(x)=f′(x)⋅g(x)+f(x)⋅g′(x)h'(x)=f'(x)\cdot g(x)+f(x)\cdot g'(x)

Details​

Consider two functions, ff and gg and their product, hh :

h(x)=f(x)⋅g(x)h(x)=f(x)\cdot g(x)

The derivative of the product is given by

h′(x)=f′(x)⋅g(x)+f(x)⋅g′(x)h'(x)=f'(x)\cdot g(x)+f(x)\cdot g'(x)

Examples​

Example

Suppose the function ff is given by

f(x)=xex+x2ln⁡xf(x)=xe^x+x^2\ln x

Then the derivative can be computed step by step as

f(x)=dxdxex+xdexdx+dx2dxln⁡x+x2dln⁡xdx=1⋅ex+x⋅ex+2x⋅ln⁡x+x2⋅1x=ex(1+x)+2xln⁡x+x\begin{aligned} f(x) &= \displaystyle\frac{dx}{dx}e^x+x\displaystyle\frac{de^x}{dx}+\displaystyle\frac{dx^2}{dx}\ln x +x^2\displaystyle\frac{d \ln x}{dx} \\ & = 1\cdot e^x + x \cdot e^x + 2x \cdot \ln x + x^2 \cdot \displaystyle\frac{1}{x} \\ & = e^x \left ( 1+x \right ) + 2x \ln x + x \end{aligned}

Derivatives of Composite Functions​

If ff and gg are functions and h=f∘gh=f \circ g so that\ h(x)=f(g(x))h(x) = f(g(x)) then h′(x)=dh(x)dx=f′(g(x))g′(x)h'(x) = \displaystyle\frac{dh(x)}{dx} = f'(g(x)) g'(x)

Examples​

Example

For fixed xx consider:

f(p)=ln⁡(px(1−p)n−x)=ln⁡px+ln⁡(1−p)n−x=xln⁡p+(n−x)ln⁡(1−p)\begin{aligned} f(p) &= \ln(p^{x} (1-p)^{n-x}) \\ &= \ln p^{x} + \ln(1-p)^{n-x} \\ &= x \ln p + (n-x) \ln (1-p) \end{aligned}

Then the derivative is computed as follows:

f′(p)=x1p+n−x1−p(−1)=xp−n−x1−p\begin{aligned} f'(p) &= x \displaystyle\frac{1}{p} + \displaystyle\frac{n-x}{1-p}(-1) \\ &= \displaystyle\frac{x}{p} - \displaystyle\frac{n-x}{1-p} \end{aligned}
Example

For fixed xx and yy consider

f(b)=(y−bx)2f(b) = (y-bx)^2

Then the derivative is computed as follows:

f′(b)=2(y−bx)(−x)=−2x(y−bx)=(−2xy)+(2x2)b\begin{aligned} f'(b) &= 2 (y-bx) (-x) \\ &= -2x (y-bx) \\ &= (-2xy) + (2x^2)b \end{aligned}