A continuous function that has flat regions. If the flat regions, which by definition have a derivative of zero, are connected by regions with a nonzero derivative, the function is called an incomplete devil's staircase. If the derivative of the function is zero almost everywhere, the function is called a complete devil's staircase (sometimes called a singular continuous function). If there are discontinuous jumps between the flat regions, the function is called a harmless staircase. A physical realization of a devil's staircase can occur in the Frenkel–Kontorowa model of atoms adsorbed on a periodic substrate.