Example of a Continuous Function Differentiable on [a,b)
At a glance
- 1. Choose a function
Let f(x) = sqrt(b − x) on the closed interval [a,b].
- 2. Check continuity
The square-root function is continuous, including at x = b, where f(b) = 0.
- 3. Check differentiability
For x in [a,b), the derivative exists; at a, use the right-hand derivative.
- 4. Check the endpoint
At b, the difference quotient is unbounded, so there is no finite left derivative.
A standard example is a function that stays continuous at the right endpoint while its slope becomes unbounded as it approaches that endpoint. For any real numbers a < b, set
This function is continuous on [a,b] and differentiable throughout [a,b), including at a if differentiability at the left endpoint is interpreted as a right-hand derivative. It is not differentiable at b in the usual finite-derivative sense.
Differentiability on a half-closed interval
The phrase “semi-differentiable” is not used uniformly across mathematics. In this context, the usual intended meaning is that the function is differentiable at the points of [a,b), with a one-sided derivative at the included endpoint a. The endpoint b is excluded from the differentiability requirement, even though the function must still be continuous there.
For an interior point x, differentiability uses the ordinary two-sided limit. At the left endpoint a, the derivative from within the interval is
If “semi-differentiable” is being used with a different definition in your course or text, check that convention; the example below satisfies this common half-interval interpretation.
Verify the example
Since the square-root function is continuous on the nonnegative reals and b − x ≥ 0 throughout [a,b], the composition is continuous on [a,b]. In particular, , and values of f(x) approach 0 as x approaches b from the left.
For every x in (a,b), the chain rule gives
This is a finite real number for each such x. At a, take the right-hand derivative:
The limit is finite because a < b. Thus the function is differentiable at every point of [a,b) under the stated endpoint convention.
At b, however, the left-hand difference quotient is, for h < 0,
As h approaches 0 from below, this tends to , not to a finite real number. So f has no finite left derivative at b. That does not conflict with continuity at b: continuity requires the function values to approach f(b), not the difference quotients to have a finite limit.
A concrete case
On [0,1], take . Then , and for its derivative is
where the value at 0 is understood as the right-hand derivative, . As x approaches 1 from below, the derivative becomes arbitrarily large in magnitude, but the function itself approaches 0. The left difference quotient at 1 is , which has no finite limit.
Common mistakes
- Confusing continuity with differentiability: A function can be continuous at b even when it has no finite derivative there.
- Ignoring the endpoint convention: On [a,b), a is included and b is not. If differentiability at a is required, it is normally defined using a right-hand limit.
- Saying the derivative is infinite: An infinite limiting slope is not a finite derivative. It indicates that the derivative does not exist as a real number.
- Forgetting a < b: The interval must have positive length for the example and endpoint calculation to apply.
If the goal is only to find a function continuous on [a,b] and differentiable on [a,b), the example works. If instead differentiability is required at both endpoints, this function does not meet that stronger condition.
Spotted an error? Send a correction. Read how we write and check articles in our editorial policy.