Given a continuous function $f:[a,b]\mapsto \mathbb{R}$, are there known additional conditions that ensure $f$ is piecewise monotone?
Like this question, my motivation is to decompose the interval $[a,b]$ as disjoint union of countable subintervals such that $f$ is monotone over each of these subintervals. However, I want to understand what condition on $f$, in addition to given continuity, is required for piecewise monotonicity.
So far I understand that continuity is not enough since it does not exclude the possibility of nowhere differentiable functions such as this. Also, requiring $f$ to be differentiable is not enough as it can be everywhere differentiable but nowhere monotonic. What, then, is required to make a continuous function piecewise monotonic?