A curve that has no slope, anywhere
Before 1872, most working mathematicians took for granted that a continuous curve — one you could draw without lifting your pen — must be smooth almost everywhere, with a well-defined tangent line at all but a handful of sharp corners. André-Marie Ampère even attempted a general proof of this in 1806. Karl Weierstrass shattered that intuition with a single explicit formula: a function that is provably continuous at every point of the real line, yet has a derivative at none of them.
The construction is an infinite sum of cosine waves at geometrically growing frequency and shrinking amplitude — an early example of what today would be called a fractal, decades before Mandelbrot gave that word meaning:
The formula and the condition on a, b
W(x) = sum_{n=0}^{infinity} a^n * cos(b^n * pi * x)
conditions (Weierstrass's original 1872 statement):
0 < a < 1
b is a positive odd integer
a*b > 1 + 3*pi/2 ≈ 5.712...
then W is continuous everywhere, differentiable nowhere.
Each individual term a^n·cos(b^nπx) is a perfectly smooth cosine wave, just a very wiggly one for large n — b^n grows the frequency exponentially while a^n shrinks the amplitude, and because a < 1 the sum converges uniformly, which is exactly what guarantees the limit function W is continuous. The subtlety is that "uniformly convergent sum of smooth functions" does not imply "smooth limit" — differentiation and infinite summation don't automatically commute, and Weierstrass's ab > 1 + 3π/2 condition is precisely the threshold at which the high-frequency terms overwhelm any candidate tangent line at every single point, no matter how you zoom in.
Why differentiability fails everywhere
Intuitively: to have a derivative at a point, the function's difference quotient (f(x+h)−f(x))/h must settle down to a finite limit as h shrinks. But at every scale of h, some term in the Weierstrass sum is oscillating on exactly that scale — because the frequencies b^n span every order of magnitude — and that term's slope refuses to vanish or stabilize relative to the others. Zoom in on the graph at any point and any magnification, and you keep finding fresh jagged wiggles instead of the curve flattening out into an approximate straight line, which is the geometric signature of "no tangent exists here."
Self-affine structure and fractal dimension
The graph of W is self-affine: rescale the x-axis by a factor of b and the y-axis by a factor of 1/a simultaneously, and the graph maps back onto (a shifted copy of) itself, because that's exactly what shifting the summation index by one does to the formula. This self-similarity across scales is why the curve looks statistically the same whether you view it at normal scale or zoomed in a thousandfold — the defining visual signature of a fractal — and its graph has a box-counting (fractal) dimension of 2 + log(a)/log(b), strictly between the dimension 1 of a smooth curve and the dimension 2 of a filled region.
A turning point for rigor in analysis
Weierstrass's example landed at exactly the moment mathematicians were trying to place calculus on rigorous epsilon-delta foundations rather than intuitive geometric reasoning, and it proved the intuitive reasoning could be flatly wrong. It's often cited as the decisive push that turned real analysis into the careful, proof-driven discipline taught today — a reminder that "obviously true" geometric statements about continuity and smoothness needed actual proofs, because pathological counterexamples like this one were lurking in the gaps.
Frequently asked questions
How can a function be continuous but have no derivative anywhere?
By summing infinitely many wiggles at ever-finer scales whose amplitude shrinks slower than their frequency grows. Each individual term is smooth, but no finite truncation captures the limit's fine structure, and the limiting sum has a jagged detail at every scale, so no tangent line can be defined at any point.
Why did 19th-century mathematicians find this so shocking?
Because the prevailing intuition, going back to Newton, Leibniz and Ampere, held that a continuous curve should be differentiable except perhaps at a few isolated bad points. Weierstrass's 1872 construction showed continuity and differentiability are far more independent than anyone believed, forcing a rebuild of analysis on fully rigorous epsilon-delta foundations.
Is the Weierstrass function a fractal?
Its graph has fractal properties: it is self-affine, meaning zooming in by a factor of b horizontally while stretching by a in amplitude reproduces a graph statistically indistinguishable from the original, and its graph has a well-defined fractal (box-counting) dimension strictly between 1 and 2.
Try it live
Everything above runs in your browser — open Weierstrass Nowhere-Differentiable Function and change the parameters while it is running. Nothing is installed, nothing is uploaded, the whole model lives in one tab.
▶ Open Weierstrass Nowhere-Differentiable Function simulation