A basic principle in tame geometry is that there are no pathological definable functions in o-minimal structures. One precise sense in which this principle is true is given by the Monotonicity Theorem.
Monotonicity Theorem : Let $f: R \to R$ be a definable function in some o-minimal structure $\mathfrak{R}$. Then $f$ is piecewise continuous and is piecewise constant or strictly monotone. That is, we can find $-\infty = a_0 < a_1 < \ldots < a_m = \infty$ so that for $0 \leq i < m$ the function $f \upharpoonright (a_i,a_{i+1})$ is continuous and constant, strictly increasing, or strictly decreasing.