I was requested in another thread to talk a bit about continuous functions that are nowhere differentiable. This is not a simple topic, but it was an important one historically because it shows how our intuitions can diverge quite a bit from what is actually provable.
We first start with some definitions:
A real valued function f:R->R is said to be continuous if for each x in R and each e>0, there is a d>0 such that whenever y is in R with |x-y|<d, we get |f(x)-f(y)|<e.
In this, the d can depend on both x and e. This was discussed above and is a typical hurdle for math students.
Similarly, we say that f:R->R is differentiable at the point x if for there is a real number f'(x) such that for each e>0 there is a d>0 such that whenever |h|<d, we have
| ( f(x+h) -f(x))/h -f'(x) |<e
This is just a restatement of the limit definition of the derivative in terms of the epsilon-delta definition of limit. So, we have f'(x)=lim_{h->0} (f(x+h) -f(x) )/h. To say that f is differentiable at x is to say that this limit on h exists and is finite. To say that f is NOT differentiable means this limit does NOT exist.
Now, most 'typical' functions that are continuous are differentiable at 'most' points. Intuitively (danger!), a lack of differentiability at a point of continuity means there is a 'corner' at that point or a vertical tangent line. We are going to stretch that intuition to the breaking point.
We start out with a 'saw tooth' function g(x), which is defined to be periodic of period 4 (for convenience) and such that g(x)=x for 0<=x<=2 and g(x)=4-x for 2<=x<=4.
This function graphs something like /\/\/\/\/\/\/\/\/\/\ with a base for the slopes all 1 or -1 and the baseline of a triangle of length 4. This function fails to be differentiable (corner!) at every even integer.
Next, let g_n (x) =g( 4^n x)/4^n.
In this, the 4^n inside the parentheses make the function have a smaller period (it goes through things faster by a factor of 4^n) and the division by 4^n makes the total 'size' mush smaller. Again, though, g_n (x) is a sawtooth function /\/\/\/\/\/\, but now with a smaller height and a faster back-and-forth. A crucial aspect: the slopes of the lines re still 1 or -1.
Notice that all of these g_n are continuous.
Now let f(x) be the infinite sum of the g_n (x) (n from 1 to infinity).
A few crucial points:
1. This sum always converges. In fact, we can do a comparison test with with sum of 1/4^n which is a geometric series.
2. The function f(x) is still continuous. This is trickier. The point is that given an e>0, we can get some tail of the series to be smaller than e/2 since the sum of 1/4^n converges. Then, the finitely many g_n left over are all continuous, so we can pick the d>0 show that their total change is smaller than e/2 also. So, in the function f, we can get |f(x)-f(y)|<e by controlling finitely many of the g_n (the rest add up to be small automatically).
3. This function is differentiable nowhere.
And this is trickier still. The point is that for h=1/4^n, the difference quotient for the derivative adds up the slopes of the g's up to stage n. This is a sum of 1 or -1 for n terms. ALL the rest of the g's are periodic so contribute nothing to the difference quotient. In particular, for h=1/4^n, the difference quotient is even when n is even and odd when n is odd. But this means the limit as n->infinity cannot exist! Hence, the limit as h->0 does not exist!
The result of adding up all of these smaller and smaller, but faster, sawtooth functions is a limit that is continuous (since all the g's are and they are controlled nicely in size), but has 'corners everywhere'.
This, by the way, was NOT the first such continuous nowhere differentiable function. The first given was the sum of sin(3^n x)/2^n. The proof is harder for this example, though, but the idea is the same: control size by using a convergent sequence to keep heights low and make the slopes go wild by increasing periods. In the second case, the derivative 'should be' the sum of 3^n cos(3^n x)/2^n and the 3^n/2^n diverges badly when added up.
Even more dramatic, in the study of Brownian motion (molecules bouncing off of each other), the functions representing the motion of the particle are *usually* continuous and nowhere differentiable! The idea is that many small jolts make the velocity undefined.
We first start with some definitions:
A real valued function f:R->R is said to be continuous if for each x in R and each e>0, there is a d>0 such that whenever y is in R with |x-y|<d, we get |f(x)-f(y)|<e.
In this, the d can depend on both x and e. This was discussed above and is a typical hurdle for math students.
Similarly, we say that f:R->R is differentiable at the point x if for there is a real number f'(x) such that for each e>0 there is a d>0 such that whenever |h|<d, we have
| ( f(x+h) -f(x))/h -f'(x) |<e
This is just a restatement of the limit definition of the derivative in terms of the epsilon-delta definition of limit. So, we have f'(x)=lim_{h->0} (f(x+h) -f(x) )/h. To say that f is differentiable at x is to say that this limit on h exists and is finite. To say that f is NOT differentiable means this limit does NOT exist.
Now, most 'typical' functions that are continuous are differentiable at 'most' points. Intuitively (danger!), a lack of differentiability at a point of continuity means there is a 'corner' at that point or a vertical tangent line. We are going to stretch that intuition to the breaking point.
We start out with a 'saw tooth' function g(x), which is defined to be periodic of period 4 (for convenience) and such that g(x)=x for 0<=x<=2 and g(x)=4-x for 2<=x<=4.
This function graphs something like /\/\/\/\/\/\/\/\/\/\ with a base for the slopes all 1 or -1 and the baseline of a triangle of length 4. This function fails to be differentiable (corner!) at every even integer.
Next, let g_n (x) =g( 4^n x)/4^n.
In this, the 4^n inside the parentheses make the function have a smaller period (it goes through things faster by a factor of 4^n) and the division by 4^n makes the total 'size' mush smaller. Again, though, g_n (x) is a sawtooth function /\/\/\/\/\/\, but now with a smaller height and a faster back-and-forth. A crucial aspect: the slopes of the lines re still 1 or -1.
Notice that all of these g_n are continuous.
Now let f(x) be the infinite sum of the g_n (x) (n from 1 to infinity).
A few crucial points:
1. This sum always converges. In fact, we can do a comparison test with with sum of 1/4^n which is a geometric series.
2. The function f(x) is still continuous. This is trickier. The point is that given an e>0, we can get some tail of the series to be smaller than e/2 since the sum of 1/4^n converges. Then, the finitely many g_n left over are all continuous, so we can pick the d>0 show that their total change is smaller than e/2 also. So, in the function f, we can get |f(x)-f(y)|<e by controlling finitely many of the g_n (the rest add up to be small automatically).
3. This function is differentiable nowhere.
And this is trickier still. The point is that for h=1/4^n, the difference quotient for the derivative adds up the slopes of the g's up to stage n. This is a sum of 1 or -1 for n terms. ALL the rest of the g's are periodic so contribute nothing to the difference quotient. In particular, for h=1/4^n, the difference quotient is even when n is even and odd when n is odd. But this means the limit as n->infinity cannot exist! Hence, the limit as h->0 does not exist!
The result of adding up all of these smaller and smaller, but faster, sawtooth functions is a limit that is continuous (since all the g's are and they are controlled nicely in size), but has 'corners everywhere'.
This, by the way, was NOT the first such continuous nowhere differentiable function. The first given was the sum of sin(3^n x)/2^n. The proof is harder for this example, though, but the idea is the same: control size by using a convergent sequence to keep heights low and make the slopes go wild by increasing periods. In the second case, the derivative 'should be' the sum of 3^n cos(3^n x)/2^n and the 3^n/2^n diverges badly when added up.
Even more dramatic, in the study of Brownian motion (molecules bouncing off of each other), the functions representing the motion of the particle are *usually* continuous and nowhere differentiable! The idea is that many small jolts make the velocity undefined.