Explainer: The Differentiability of a Function

In this explainer, we will learn how to determine whether a function is differentiable and identify the relation between a functionโ€™s differentiability and its continuity.

Differentiation is hugely important, and being able to determine whether a given function is differentiable is a skill of great importance. When we learn about derivatives, we learn two important facts: firstly, that the derivative is the slope of the tangent to a curve at any given point and, secondly, that the derivative is defined by a limit and, therefore, only exists if the given limit exists. Using these two important ideas about derivatives, we can determine whether certain derivatives exist. We begin by recapping the definition of the derivative.

Definition of the Derivative

The derivative of a function at a point ๐‘ฅ๏Šฆ is defined as lim๏‚โ†’๏Šฆ๐‘“(๐‘ฅ+โ„Ž)โˆ’๐‘“(๐‘ฅ)โ„Ž.

An alternative but equivalent definition of the derivative is lim๏—โ†’๏—๏Šง๏Šง๏Ž ๐‘“(๐‘ฅ)โˆ’๐‘“(๐‘ฅ)๐‘ฅโˆ’๐‘ฅ.

There are two common ways we denote derivatives: Leibnizโ€™s notation and prime notation (sometimes referred to as Lagrangeโ€™s notation). For a function ๐‘ฆ=๐‘“(๐‘ฅ), Leibnizโ€™s notation for the derivative is written using the infinitesimals d๐‘ฆ and d๐‘ฅ as dd๐‘ฆ๐‘ฅ, which we read as โ€œthe derivative of ๐‘ฆ with respect to ๐‘ฅโ€ or โ€œd๐‘ฆ by d๐‘ฅ.โ€

Using prime notation, the derivative of ๐‘“(๐‘ฅ) with respect to ๐‘ฅ is denoted ๐‘“(๐‘ฅ)๏Ž˜, which we read as โ€œ๐‘“ prime of ๐‘ฅ.โ€

In the definition above, we mentioned that the derivative is defined as a limit, if the limit exists, which indicates that it is possible that the limit does not exist. In such cases, we say that the function is not differentiable at this point. In this explainer, we will explore the relationship between the continuity of a function and the differentiability and consider different ways in which a function can fail to be differentiable.

Since the derivative at a point represents the slope of the tangent to the curve at that point, this tells us that if we are unable to define a tangent to a curve, the derivative will not exist. The first case we will consider is the case where the function is discontinuous. If the function has a jump discontinuity, we will not be able to define a tangent to the curve at that point. We would therefore expect that the derivative will not be defined at such a point.

Example 1: Differentiability of a Function with a Jump Discontinuity

Suppose ๐‘“(๐‘ฅ)=๏ญโˆ’6๐‘ฅโˆ’4๐‘ฅโ‰คโˆ’1,3๐‘ฅ๐‘ฅ>โˆ’1.ifif๏Šจ

What can be said of the differentiability of ๐‘“ at ๐‘ฅ=โˆ’1?

Answer

Here, we have been given a piecewise defined function composed of two smooth functions. Generally, in situations like this, the derivative of the function is composed of the derivative of the functions defining each part. However, we also need to consider whether the functions agree at the points where the functions are joined together. If we apply this approach, we can differentiate each part of this function using the power rule as follows: ๐‘“(๐‘ฅ)=๏ญโˆ’6๐‘ฅ<โˆ’1,6๐‘ฅ๐‘ฅ>โˆ’1.๏Ž˜ifif

We can then consider the points where these two functions join and find that the derivative on either side of ๐‘ฅ=โˆ’1 is โˆ’6. At this point, we might naively conclude that the function is differentiable. However, this is not the correct answer. To see this, we will use the definition of the derivative, lim๏‚โ†’๏Šฆ๏Šฆ๏Šฆ๐‘“(๐‘ฅ+โ„Ž)โˆ’๐‘“(๐‘ฅ)โ„Ž, and demonstrate that this limit does not exist at ๐‘ฅ=โˆ’1. Since the function is defined differently on each side of the point ๐‘ฅ=โˆ’1, we will consider the left and right limits. Beginning with the left limit, we have lim๏‚โ†’๏Šฆ๏Žช๐‘“(โˆ’1+โ„Ž)โˆ’๐‘“(โˆ’1)โ„Ž.

Using the definition of the function ๐‘“, we have ๐‘“(โˆ’1)=2 and can rewrite the limit as limlimlim๏‚โ†’๏Šฆ๏‚โ†’๏Šฆ๏‚โ†’๏Šฆ๏Žช๏Žช๏Žช๐‘“(โˆ’1+โ„Ž)โˆ’๐‘“(โˆ’1)โ„Ž=โˆ’6(โˆ’1+โ„Ž)โˆ’4โˆ’2โ„Ž=โˆ’6โ„Žโ„Ž.

Since โ„Žโ‰ 0, we can cancel this common factor from the numerator and denominator to get limlim๏‚โ†’๏Šฆ๏‚โ†’๏Šฆ๏Žช๏Žช๐‘“(โˆ’1+โ„Ž)โˆ’๐‘“(โˆ’1)โ„Ž=โˆ’6=โˆ’6.

We can now consider the right limit, lim๏‚โ†’๏Šฆ๏Žฉ๐‘“(โˆ’1+โ„Ž)โˆ’๐‘“(โˆ’1)โ„Ž.

Using the definition of the function we have been given, we have limlimlimlim๏‚โ†’๏Šฆ๏‚โ†’๏Šฆ๏Šจ๏‚โ†’๏Šฆ๏Šจ๏‚โ†’๏Šฆ๏Šจ๏Žฉ๏Žฉ๏Žฉ๏Žฉ๐‘“(โˆ’1+โ„Ž)โˆ’๐‘“(โˆ’1)โ„Ž=3(โˆ’1+โ„Ž)โˆ’2โ„Ž=3๏€น1โˆ’2โ„Ž+โ„Ž๏…โˆ’2โ„Ž=1โˆ’6โ„Ž+3โ„Žโ„Ž.

We can split this fraction and rewrite this as limlim๏‚โ†’๏Šฆ๏‚โ†’๏Šฆ๏Žฉ๏Žฉ๐‘“(โˆ’1+โ„Ž)โˆ’๐‘“(โˆ’1)โ„Ž=๏€ผ1โ„Žโˆ’6+3โ„Ž๏ˆ.

In this case, since lim๏‚โ†’๏Šฆ๏Žฉ1โ„Ž=โˆž, the limit does not exist. The reason the limit does not exist is the fact that the function is actually discontinuous at this point as we can see from its graph.

Since the limit does not exist, the derivative is not defined. Hence, we can say that the function ๐‘“ is not differentiable at ๐‘ฅ=โˆ’1.

The last example showed that the function was not differentiable at the point of discontinuity. This is actually a general result, that at the points where a function is discontinuous it is not differentiable. Hence, in the last example, the most efficient solution is to first confirm that the function is not continuous and therefore not differentiable.

There are other ways that a function might not be differentiable. For example, if the graph of a function has a corner, in this case, the limit that defines the derivative will not exist since its left and right limits will be different.

Example 2: Assessing the Differentiability of a Function from Its Graph

The figure shows the graph of ๐‘“. What can be said of the differentiability of ๐‘“ at ๐‘ฅ=โˆ’4?

Answer

The graph of the function ๐‘“ has a corner at the point where ๐‘ฅ=โˆ’4. This means that the slope of the tangent to the left of ๐‘ฅ=โˆ’4 is not equal to the slope of the tangent to the right of ๐‘ฅ=โˆ’4. Hence, the derivative will have a jump discontinuity and will not be defined at this point since its right and left limits will not agree. Hence, The function is not differentiable at ๐‘ฅ=โˆ’4 because the functionโ€™s rate of change is different on both sides of that point.

There are many examples of functions whose graphs have corners. Two common types of functions that can have corners are functions defined piecewise or functions defined in terms of the absolute value. In the next example, we will consider another case where the derivative is not defined.

Example 3: The Existence of a Derivative at a Cusp

The figure shows the graph of ๐‘“. At which points is the derivative of the function not defined?

Answer

The graph shows a function with two cusps, one at ๐‘ฅ=โˆ’1 and one at ๐‘ฅ=1. At these cusps, the tangent to the curve is vertical. When the tangent is vertical, its slope is infinite, which will also imply that the limit lim๏‚โ†’๏Šฆ๏Šฆ๏Šฆ๐‘“(๐‘ฅ+โ„Ž)โˆ’๐‘“(๐‘ฅ)โ„Ž does not exist. Hence, the derivative of this function is not defined at the points ๐‘ฅ=โˆ’1 and ๐‘ฅ=1.

The last example showed us that the derivative is not defined at a cusp of a real-valued function. More generally, if the tangent to a curve is vertical, the derivative is not defined. The next example will highlight one such function.

Example 4: Domain of the Derivative

Consider the function ๐‘“(๐‘ฅ)=โˆš๐‘ฅ๏Žข.

  1. What is the domain of ๐‘“?
  2. Find an expression for the derivative of ๐‘“.
  3. What is the domain of the derivative ๐‘“๏Ž˜?

Answer

Part 1

The real cube root of any real number is well defined. Therefore, the domain of ๐‘“ is all the real numbers โ„.

Part 2

We can find an expression for the derivative of ๐‘“ by using the power rule which states that dd๐‘ฅ(๐‘ฅ)=๐‘›๐‘ฅ.๏Š๏Š๏Šฑ๏Šง

Hence, ๐‘“(๐‘ฅ)=๐‘ฅ๏€ฝ๐‘ฅ๏‰=13๐‘ฅ=13โˆš๐‘ฅ.๏Ž˜๏Šฑ๏Šจdd๏Ž ๏Žข๏Žก๏Žข๏Žข

Part 3

To find the domain of the derivative, we need to consider the points ๐‘ฅ for which ๐‘“(๐‘ฅ)=13โˆš๐‘ฅ๏Ž˜๏Šจ๏Žข is not defined. The only point where this is not defined is when the denominator is zero. This occurs when ๐‘ฅ=0. Therefore, the domain of ๐‘“๏Ž˜ is all real ๐‘ฅโ‰ 0 which we can write as โ„โงต0.

The previous example shows that the derivative of a continuous function might fail to exist at certain points in the domain. In particular, if the tangent line of a function is vertical, the derivative will not exist at this point.

Another way in which a function might fail to have a derivative is as a result of infinitesimal oscillations.

Example 5: Oscillatory Functions and Derivatives

Is the function ๐‘“(๐‘ฅ)=๏ฑ๐‘ฅ๏€ผ1๐‘ฅ๏ˆ๐‘ฅโ‰ 0,0๐‘ฅ=0sinifif differentiable at ๐‘ฅ=0?

Answer

To assess the differentiability of this function at ๐‘ฅ=0, we will consider the existence of the following limit: lim๏‚โ†’๏Šฆ๐‘“(0+โ„Ž)โˆ’๐‘“(0)โ„Ž.

Using the definition of the function ๐‘“, we have limlimsinlimsin๏‚โ†’๏Šฆ๏‚โ†’๏Šฆ๏Šง๏‚๏‚โ†’๏Šฆ๏Šง๏‚๐‘“(0+โ„Ž)โˆ’๐‘“(0)โ„Ž=โ„Ž๏€ป๏‡โˆ’0โ„Ž=โ„Ž๏€ป๏‡โ„Ž.

Since โ„Žโ‰ 0, we can cancel it from the numerator and denominator to get limlimsin๏‚โ†’๏Šฆ๏‚โ†’๏Šฆ๐‘“(0+โ„Ž)โˆ’๐‘“(0)โ„Ž=๏€ผ1โ„Ž๏ˆ.

This is an example of a limit that does not exist due to the oscillatory behavior of the function. Therefore, the limit does not exist. Hence, ๐‘“ is not differentiable at ๐‘ฅ=0. A graph of ๐‘“ demonstrates that the function displays a high level of oscillatory behavior near the origin, which is the reason why the derivative does not exist.

We have looked at many examples of how functions can fail to be differentiable. In many cases, these were continuous functions. Hence, we have seen that we can have continuous functions that are not differentiable. In fact, it is possible to have functions that are continuous everywhere but nowhere differentiable. The first known example of such a function was the Weierstrass function. Although functions such as the Weierstrass function seem unusual, it can be shown mathematically that the vast majority of continuous functions are actually nowhere differentiable!

Even though it is possible (and, rather intuitively, very common) to have continuous functions which are not differentiable, the converse is not true; all differentiable functions are continuous as we will demonstrate below.

Let ๐‘“ be a function that is differentiable at a point ๐‘ฅ=๐‘ฅ๏Šฆ. Then, by definition,

๐‘“(๐‘ฅ)=๐‘“(๐‘ฅ)โˆ’๐‘“(๐‘ฅ)๐‘ฅโˆ’๐‘ฅ.๏Ž˜๏Šฆ๏—โ†’๏—๏Šฆ๏Šฆlim๏ŽŸ(1)

We will show that ๐‘“ is continuous by demonstrating that lim๏—โ†’๏—๏Šฆ๏ŽŸ๐‘“(๐‘ฅ)=๐‘“(๐‘ฅ).

We begin by considering the limit lim๏—โ†’๏—๏Šฆ๏ŽŸ(๐‘“(๐‘ฅ)โˆ’๐‘“(๐‘ฅ)).

By multiplying and dividing by ๐‘ฅโˆ’๐‘ฅ๏Šฆ, we have limlim๏—โ†’๏—๏Šฆ๏—โ†’๏—๏Šฆ๏Šฆ๏Šฆ๏ŽŸ๏ŽŸ(๐‘“(๐‘ฅ)โˆ’๐‘“(๐‘ฅ))=๏€ฝ(๐‘ฅโˆ’๐‘ฅ)๐‘“(๐‘ฅ)โˆ’๐‘“(๐‘ฅ)๐‘ฅโˆ’๐‘ฅ๏‰.

Using the rules of finite limits, we can rewrite this as limlimlim๏—โ†’๏—๏Šฆ๏—โ†’๏—๏Šฆ๏—โ†’๏—๏Šฆ๏Šฆ๏ŽŸ๏ŽŸ๏ŽŸ(๐‘“(๐‘ฅ)โˆ’๐‘“(๐‘ฅ))=(๐‘ฅโˆ’๐‘ฅ)๏€ฝ๐‘“(๐‘ฅ)โˆ’๐‘“(๐‘ฅ)๐‘ฅโˆ’๐‘ฅ๏‰.

Using equation (1), we have limlim๏—โ†’๏—๏Šฆ๏Ž˜๏Šฆ๏—โ†’๏—๏Šฆ๏ŽŸ๏ŽŸ(๐‘“(๐‘ฅ)โˆ’๐‘“(๐‘ฅ))=๐‘“(๐‘ฅ)(๐‘ฅโˆ’๐‘ฅ).

Furthermore, we know that lim๏—โ†’๏—๏Šฆ๏ŽŸ(๐‘ฅโˆ’๐‘ฅ)=0. Therefore, lim๏—โ†’๏—๏Šฆ๏ŽŸ(๐‘“(๐‘ฅ)โˆ’๐‘“(๐‘ฅ))=0.

Once again, we can use the rules of finite limits to get limlim๏—โ†’๏—๏—โ†’๏—๏Šฆ๏ŽŸ๏ŽŸ๐‘“(๐‘ฅ)โˆ’๐‘“(๐‘ฅ)=0.

Therefore, limlim๏—โ†’๏—๏—โ†’๏—๏Šฆ๏ŽŸ๏ŽŸ๐‘“(๐‘ฅ)=๐‘“(๐‘ฅ) as required. Hence, we have shown that a function is continuous at all points where it is differentiable.

In our final few examples, we will apply what we have learned about the existence of derivatives and the connection between differentiability and continuity.

Example 6: Functions and Derivatives

Consider a function with ๐‘“(โˆ’8)=3 and ๐‘“(โˆ’8)=7๏Ž˜. What is lim๏—โ†’๏Šฑ๏Šฎ๐‘“(๐‘ฅ)?

Answer

We have been told that ๐‘“(โˆ’8)=7๏Ž˜; therefore, we know that ๐‘“ is differentiable at ๐‘ฅ=โˆ’8. Since differentiability implies continuity, we know that lim๏—โ†’๏—๏Šฆ๏ŽŸ๐‘“(๐‘ฅ)=๐‘“(๐‘ฅ).

Hence, lim๏—โ†’๏Šฑ๏Šฎ๐‘“(๐‘ฅ)=3.

In the final two examples, we will consider functions defined piecewise. When dealing with such functions, it is important to check for continuity, and then we can differentiate each part separately and consider the points where parts meet.

Example 7: Assessing the Differentiability of a Function

Suppose ๐‘“(๐‘ฅ)=๏ฑโˆ’1+3๐‘ฅ๐‘ฅโ‰ค1,โˆ’๐‘ฅ+3๐‘ฅ>1.ifif๏Šฉ

What can be said of the differentiability of ๐‘“ at ๐‘ฅ=1?

Answer

We will begin by ensuring that the function is continuous at ๐‘ฅ=1. From the definition, we can see that ๐‘“(1)=2; furthermore, we can see that limlim๏—โ†’๏Šง๏—โ†’๏Šง๏Žช๏Žฉ๐‘“(๐‘ฅ)=2,๐‘“(๐‘ฅ)=2.

Therefore, the function is continuous at ๐‘ฅ=1. We can now apply the power rule to differentiate each part of the function as follows: ๐‘“(๐‘ฅ)=๏ฑโˆ’3๐‘ฅ๐‘ฅ<1,โˆ’3๐‘ฅ๐‘ฅ>1.๏Ž˜๏Šจ๏Šจifif

We now need to consider the left and right limits to ensure they agree. From the definition of ๐‘“๏Ž˜, we can see limlim๏—โ†’๏Šง๏Ž˜๏—โ†’๏Šง๏Ž˜๏Žช๏Žฉ๐‘“(๐‘ฅ)=โˆ’3,๐‘“(๐‘ฅ)=โˆ’3.

Therefore, we can conclude that the limit exists and ๐‘“(1)=โˆ’3๏Ž˜. Hence, the function ๐‘“(๐‘ฅ) is differentiable at ๐‘ฅ=1.

Example 8: Assessing the Differentiability of a Function

Find the values of ๐‘Ž and ๐‘ and discuss the differentiability of the function ๐‘“ at ๐‘ฅ=โˆ’1 given that ๐‘“ is continuous and ๐‘“(๐‘ฅ)=๏ณ9๐‘ฅ+๐‘Ž๐‘ฅ+4๐‘ฅ<โˆ’1,11๐‘ฅ=โˆ’1,๐‘Ž+๐‘๐‘ฅ๐‘ฅ>โˆ’1.๏Šจififif

Answer

Since ๐‘“ is continuous, it is continuous at ๐‘ฅ=โˆ’1; therefore, limlim๏—โ†’๏Šฑ๏Šง๏—โ†’๏Šฑ๏Šง๏Žช๏Žฉ๐‘“(๐‘ฅ)=๐‘“(๐‘ฅ)=๐‘“(โˆ’1)=11.

Therefore, 11=9๐‘ฅ+๐‘Ž๐‘ฅ+4=13โˆ’๐‘Ž.lim๏—โ†’๏Šฑ๏Šง๏Šจ๏Žช

Hence, ๐‘Ž=2. Furthermore, 11=๐‘Ž+๐‘๐‘ฅ=2โˆ’๐‘.lim๏—โ†’๏Šฑ๏Šง๏Žฉ

Therefore, ๐‘=โˆ’9. Hence, ๐‘“(๐‘ฅ)=๏ณ9๐‘ฅ+2๐‘ฅ+4๐‘ฅ<โˆ’1,11๐‘ฅ=โˆ’1,2โˆ’9๐‘ฅ๐‘ฅ>โˆ’1.๏Šจififif

We can now consider the derivative on each side of ๐‘ฅ=โˆ’1 using the power rule as follows: ๐‘“(๐‘ฅ)=๏ญ18๐‘ฅ+2๐‘ฅ<โˆ’1,โˆ’9๐‘ฅ>โˆ’1.๏Ž˜ifif

We now need to consider the left and right limits at ๐‘ฅ=โˆ’1. From the definition of ๐‘“๏Ž˜, we can see limlim๏—โ†’๏Šฑ๏Šง๏Ž˜๏—โ†’๏Šฑ๏Šง๏Ž˜๐‘“(๐‘ฅ)=โˆ’16,๐‘“(๐‘ฅ)=โˆ’9.

Therefore, the left and right limits do not agree and the function is not differentiable at ๐‘ฅ=โˆ’1.

Key Points

  • The derivative of a function at a point ๐‘ฅ๏Šฆ is defined as lim๏‚โ†’๏Šฆ๐‘“(๐‘ฅ+โ„Ž)โˆ’๐‘“(๐‘ฅ)โ„Ž. An alternative but equivalent definition of the derivative is lim๏—โ†’๏—๏Šง๏Šง๏Ž ๐‘“(๐‘ฅ)โˆ’๐‘“(๐‘ฅ)๐‘ฅโˆ’๐‘ฅ. There are two common ways we denote derivatives: Leibnizโ€™s notation and prime notation (sometimes referred to as Lagrangeโ€™s notation). For a function ๐‘ฆ=๐‘“(๐‘ฅ), Leibnizโ€™s notation for the derivative is written using the infinitesimals d๐‘ฆ and d๐‘ฅ as dd๐‘ฆ๐‘ฅ, which we read as โ€œthe derivative of ๐‘ฆ with respect to ๐‘ฅโ€ or โ€œd๐‘ฆ by d๐‘ฅ.โ€
    Using prime notation, the derivative of ๐‘“(๐‘ฅ) with respect to ๐‘ฅ is denoted ๐‘“(๐‘ฅ)๏Ž˜, which we read as โ€œ๐‘“ prime of ๐‘ฅ.โ€
  • A function is not differentiable when this limit does not exist. This can happen in a number of different ways including the following.