# Modulus of Continuity

I originally posted this question on math.stackexchange (http://math.stackexchange.com/questions/83182/modulus-of-continuity-take-2), but it's been a few days and I haven't received any correct answers.

Let $\rho: \mathbb{R}^+ \to \mathbb{R}^+$ be a continuous nondecreasing function such that $\rho(t) = 0$ if and only of $t = 0$. If you can answer my question in the special case $\rho(t) = Ct$ where $C$ is a constant then it will probably be possible to adapt your construction to the general case.

Say that a function $f: X \to \mathbb{R}$ on a metric space has modulus of continuity $\rho$ at a point $x_0 \in X$ if $|f(x) - f(x_0)| \leq \rho(d(x,x_0))$ for every $x \in X$. For example, a function has modulus of continuity $Ct$ at $x_0$ if and only if it is Lipschitz with Lipschitz constant $C$ at $x_0$.

Question If $X$ is a compact metric space without isolated points, is it true that the set $S$ of all continuous functions on $X$ which have modulus of continuity $\rho$ at some point of $X$ is nowhere dense in $C(X)$ equipped with the supremum norm?

Note that the "some point" that I am referring to is not fixed and may depend on the function. The complement of $S$ is the set of all functions which do not have modulus of continuity $\rho$ at any point.

To prove that the answer is affirmative for a given $X$ one must be able to construct functions of arbitrarily small norm which oscillate arbitrarily rapidly. For example, if $\rho(t) = Ct$ and $X = [0,1]$ then one can use a piecewise linear function such that the slope of each linear piece is larger than $C$ in absolute value. However, I don't see how to generalize this idea to an arbitrary compact metric space without isolated points.

-
Take a finite $\delta$-net $A\subset X$ in $X$. Take a finite $\delta$-net $B\subset X\setminus A$ in $X\setminus A$. Since there are no isolated points, $B$ is still a $2\delta$-net in $X$. Put $f=0$ on $A$, $f=3\rho(2\delta)$ on $B$. Extend arbitrarily to a continuous function. –  fedja Nov 21 '11 at 22:00
Paul, I can't say for sure without knowing exactly what your motivation for the question is, but in light of fedja's comment, which looks correct but which doesn't feel to me like the kind of counterexample I expected you to be looking for, is it possible that you mean to use a slightly different definition for modulus of continuity, namely that $|f(x)-f(x_0)| \leq \rho(d(x,x_0))$ holds for all $x$ sufficiently close to $x_0$? Of course there are two possibilities even here, depending on whether or not you allow the meaning of sufficiently close'' to depend on $x_0$... –  Vaughn Climenhaga Nov 22 '11 at 3:18
@Vaughn. You can iterate Fedja's construction for $\delta_n\to0+$ to get a continuous function such that any ball of radius $\delta_n$ contains points $x,y$ with $f(x)-f(y)>10\cdot\rho(2\cdot\delta_n)$. –  Anton Petrunin Nov 22 '11 at 5:35
@Anton: perhaps I'm just being dense, but I'm not convinced the iteration gives you a non-trivial continuous function. As I understand it the iterative procedure should consist of taking finite sets $A_n$ and $B_n$ that are disjoint and $\delta_n$ (or $2\delta_n$)-dense, then setting $f(x) = a_n$ for $x\in A_n$ and $b_n$ for $x\in B_n$, where $a_n,b_n$ are appropriate chosen. But then every point $x\in X$ is the limit of points $x_n\in A_n$, and hence continuity requires $f(x) = \lim f(x_n) = \lim a_n$, which implies $f$ constant. Am I missing something? –  Vaughn Climenhaga Nov 22 '11 at 19:22
@Vaughn: I guess, in view of this discussion, I'll have to expand my short comment into a full answer. I'll certainly address all the questions you raised so far (that is easy) but is anything else unclear? –  fedja Nov 25 '11 at 20:24

All right, I don't think that anything I'll say below will be new to Paul. However it'll address Vaughn's concerns (to the extent he expressed them in the comments by the moment of this writing).

Of course, the ultimate purpose is to show that for a given modulus of continuity $\rho$, the set $U$ of continuous functions $f$ that have that modulus of continuity at at least one point $x$ in the sense that there exists $\delta>0$ (depending on $x$) such that $|f(x)-f(y)|\le\rho(d(x,y))$ for all $y$ satisfying $d(x,y)\le \delta$ is small.

However, there is no chance to show that it is nowhere dense because you can take any function and flatten it a bit near any value $v$ it takes, i.e., to consider $g(x)=\min(f(x)+\varepsilon,v)+\max(f(x)-\varepsilon,v)-v$. This function will be constant near the point where $f=v$ and differ from $f$ by at most $\varepsilon$. So, every open set contains a "bad" function.

The right words to use instead of "nowhere dense" are "of the first category". Note that if $f$ has modulus of continuity $\rho$ at some point locally, then it has modulus of continuity $A\rho$ at the same point globally for some large integer constant $A$. Now fix $A$ and consider the set $F_A$ of functions $f$ such that there exists a point $x\in X$ at which $f$ has global modulus of continuity $A\rho$. Note that the union of $F_A$ contains $U$.

Note that each $F_A$ is closed: if $f_n\in F_A$ converge to $f$ uniformly and $x_n\in X$ are the corresponding bad points, then any accumulation point $x$ of the sequence $x_n$ is bad for $f$.

It remains to show that $F_A$ contains no open set. Let $f$ be any function in $C(X)$. Let $\lambda>0$. Choose $\delta>0$ so small that $|f(x)-f(y)|\le\lambda$ whenever $d(x,y)\le 4\delta$ and $A\rho(2\delta)<\lambda$ as well. Now run the construction in my remark only denote the resulting function $g$ and put $g=0$ on $A$ and $g=4\lambda$ on $B$.

Consider $h=f+g$. On one hand, it differs from $f$ by $4\lambda$ or less. On the other hand, for each point $x\in X$, the ball of radius $2\delta$ centered at $x$ contains a point $a\in A$ and a point $b\in B$. If $h$ had global modulus of continuity at $x$, we would have $|h(a)-h(b)|\le 2A\rho(2\delta))<2\lambda$. On the other hand, this difference is at least $4\lambda-|f(a)-f(b)|\ge 3\lambda$. Thus, every open ball in $C(X)$ intersects the complement of $F_A$.

-
Thanks for the clarification. The step that I was missing was the observation that local modulus of continuity implies global up to some constant, so that the construction in your comment can deal with local considerations and not just global. This answer clears everything up. (It seems to me that Anton's comments were suggesting a different way of completing the solution, which I still don't thoroughly understand, but that's a different matter.) –  Vaughn Climenhaga Nov 27 '11 at 0:26
You are welcome! :). I still wonder what you really wanted in your other question (conditional geometric distribution) though. –  fedja Nov 27 '11 at 0:49
That's a fair thing to wonder. I added a couple comments to that question, trying to explain... –  Vaughn Climenhaga Nov 28 '11 at 5:49
Sorry I neglected this question for so long, but this argument does seem to do the trick. Thanks! –  Paul Siegel Dec 2 '11 at 17:14