# Strange real functions

I know there are a lot of strange functions $f~:~\mathbb R \to \mathbb R$.

I'm looking for an "elementary but complete" exposition of a result discovered by W. Sierpi\'nski and A. Zygmund in "Sur une fonction qui est discontinue sur tout ensemble de puissance du continu." Fund. Math., vol. 4, pp.316–318, 1923 stating (in simple form) that there exist a function $f~:~\mathbb R \to \mathbb R$ such that for every non empty open interval $I$, $f(I)=\mathbb R$ .

And also, a probably well-known fact for experts in real analysis: If an arbitrary continuous function $f~:~ [0,1] \to \mathbb R$ is given, is it true that $f_{|D}$ is monotonic on some dense set $D\subset [0,1]$ or some set $D$ of positive measure?

It seems to be true if I replace "dense set" by "perfect subset" (according to Jack Brown). If this is not true an example is highly appreciated.

-
The restriction of the absolute value function to $[-1,1]$ does not seem to be monotonous on any dense subset of $[-1,1]$. – Mariano Suárez-Alvarez Dec 11 '10 at 13:50
The first question is a duplicate of mathoverflow.net/questions/32126/…. – Joel David Hamkins Dec 11 '10 at 13:55
@Mariano, indeed it is obvious so I slightly changed the question. – Portland Dec 11 '10 at 14:14
Not sure what the change was but Mariano's answer remains valid: $|x-c|$ is a counterexample where $c$ is any inner point of the domain. – fedja Dec 11 '10 at 15:14
@fedja: Portland added the option that the set is not dense, but has positive measure. – Willie Wong Dec 11 '10 at 18:07

Although you asked about continuous functions, here is an example of a discontinuous function $f:[0,1]\to\mathbb{R}$ which is not monotone on any measurable set with positive measure.

Let $V\subset [0,1]$ be the usual Vitali set, selecting one element from each equivalence class under translation by the rationals. Thus, $V$ is not measurable, and the translates $V+q$ (working modulo 1) for rational $q$ are disjoint and cover $[0,1]$. It follows that none of the translates $V+q$ contains a measurable set of positive measure. Enumerate the rationals $\mathbb{Q}=\{ q_n \mid n\in\mathbb{N}\}$, and let $f(x)=n$ for $x\in V+q_n$. Thus, $f$ is constant on each $V+q$, and the range of $f$ involves only natural number values. Suppose that $f$ is monotone on a measurable set $A\subset [0,1]$. If $f|A$ is constant or has only finitely many values, then $A$ will be contained in the union of finitely many $V+q$, and hence not have positive measure. Otherwise, $A$ must contain points from infinitely many $V+q$, and since the range is contained in $\mathbb{N}$, it must be that $f$ is nondecreasing on $A$. For any $a\in A$, note that if $f(a)=n$, then $A\cap [0,a]$ is contained in the union of $V+q_m$ for $m\leq n$, a finite number of translations of $V$. Thus $A\cap [0,a]$ has measure $0$ for any $a\in A$, and it follows that $A$ has measure $0$ altogether.

-
I seem to recall that a discontinuous additive function $f:\mathbb R\to\mathbb R$ can't be bounded (let alone monotone) on any measurable set with positive measure. But maybe I remember wrong? – bof Jun 5 '14 at 10:54

Every continuous function is monotone on a perfect set:

Let $I=[0,1]$ and let $f:I\to\mathbb R$ be continuous (actually, Borel-measurable is enough for what follows). Let $[I]^2$ be the set of 2-element subsets of $I$.
For all $\{a,b\}\in[I]^2$ with $a\lt b$ let $c(a,b)=0$ if $f(a)\lt f(b)$ and $c(a,b)=1$, otherwise.
Since $f$ is continuous, the set $$\{(a,b)\in I^2:a\lt b\wedge c(a,b)=0\}$$ is Borel in $I^2$. By a theorem of Galvin, there is a perfect set $P\subseteq I$ such that $c$ is constant on $[P]^2$.
From the definition of $c$ is follows that $f$ is monotone on $P$.

A source for Galvin's theorem is Kechris' book on Classical Descriptive Set Theory. If you want to avoid the use of Galvin's theorem, you can use the full strength of continuity:

Since every nonempty open subset of $I$ contains a perfect set, we may assume $f$ is not monotone on any nonempty open subset of $I$.
Now every nonempty open subset of $I$ has a two-element subset on which $f$ is strictly increasing.

A straight-forward perfect set construction now gives you a perfect set on which $f$ is strictly increasing.

-
Hi Stefan. I edited what you wrote a bit so the brackets and $\lt$ signs show. – Andrés Caicedo Dec 11 '10 at 19:17
Thanks, Andres. I was just in the process of editing my answer when you edited it. For some reason, my strict-inequality characters don't show properly. – Stefan Geschke Dec 11 '10 at 19:32
Yeah, they don't. I use \lt instead. – Andrés Caicedo Dec 11 '10 at 19:39
@stefan, thanks, here is another proof ams.org/journals/proc/1990-108-02/S0002-9939-1990-0987607-1/… BTW my question is about dense subset or subset with positive measure – Portland Dec 11 '10 at 22:06
@Portland: Thanks for the reference. Apparently I have reproved Theorem 1.2 of the paper you mention. The article also says that you cannot necessarily get a set of positive measure on which the function is differentiable and monotone. Concerning density: I read your question, but it sounded like you where not absolutely sure even about the existence of a perfect set. – Stefan Geschke Dec 12 '10 at 9:38

Enumerate all rational intervals, let them be $\Delta_1$, $\Delta_2$ and so on. Let $K_i\subset \Delta_i$ be a perfect nowhere dense set (of cardinality continuum, of course) so that $K_i$ are mutually disjoint. It is easy to construct such sets one by one. Then map each $K_i$ to $\mathbb{R}$ bijectively and define $f$ in other points (not belonging to $\cup K_i$) arbitrarily.

-