{"id":557,"date":"2019-06-29T22:25:02","date_gmt":"2019-06-29T22:25:02","guid":{"rendered":"http:\/\/funfacts.104.42.120.246.xip.io\/?page_id=557"},"modified":"2019-11-18T23:42:36","modified_gmt":"2019-11-18T23:42:36","slug":"devils-staircase","status":"publish","type":"page","link":"https:\/\/math.hmc.edu\/funfacts\/devils-staircase\/","title":{"rendered":"Devil&#8217;s Staircase"},"content":{"rendered":"\n<div class=\"wp-block-image\"><figure class=\"alignright\"><img loading=\"lazy\" decoding=\"async\" width=\"200\" height=\"201\" data-attachment-id=\"1398\" data-permalink=\"https:\/\/math.hmc.edu\/funfacts\/devils-staircase\/30003-3-1\/\" data-orig-file=\"https:\/\/math.hmc.edu\/funfacts\/wp-content\/uploads\/sites\/4\/2019\/11\/30003.3.1.gif\" data-orig-size=\"200,201\" data-comments-opened=\"1\" data-image-meta=\"{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}\" data-image-title=\"30003.3.1\" data-image-description=\"\" data-image-caption=\"\" data-large-file=\"https:\/\/math.hmc.edu\/funfacts\/wp-content\/uploads\/sites\/4\/2019\/11\/30003.3.1.gif\" src=\"https:\/\/math.hmc.edu\/funfacts\/wp-content\/uploads\/sites\/4\/2019\/11\/30003.3.1.gif\" alt=\"\" class=\"wp-image-1398\"\/><\/figure><\/div>\n\n\n\n<p>Here is a strange continuous function on the unit interval, whose derivative is 0 almost everywhere, but it somehow magically rises from 0 to 1!<\/p>\n\n\n\n<p>Take any number X in the unit interval, and express it in base 3. Chop off the base 3 expansion right after the first 1. Next change all 2&#8217;s in the expansion to 1&#8217;s. This number now has only 0&#8217;s or 1&#8217;s in its expansion, so we can interpret it as a base 2 number! Call this new number f(x).<\/p>\n\n\n\n<p>If you plot this function, you get something called the&nbsp;<em>Devil&#8217;s Staircase<\/em>. It is related to the&nbsp;standard Cantor set&nbsp;in the following way. This function is constant at all the removed intervals from the standard Cantor set. For instance if x is in [1\/3, 2\/3], then f(x)=1\/2. If x is in [1\/9, 2\/9], then f(x)=1\/4; if x is in [7\/9, 8\/9], then f(x)=3\/4.<\/p>\n\n\n\n<p>If you plot this you will see that this function is not differentiable at the Cantor set points, but has zero derivative everywhere else! But since a Cantor set has&nbsp;measure zero, this function is has zero derivative practically everywhere, and only &#8220;rises&#8221; on Cantor set points!<\/p>\n\n\n\n<p><strong>Presentation&nbsp;Suggestions:<\/strong><br>Draw a good approximation to the devil&#8217;s staircase.<\/p>\n\n\n\n<p><strong>The&nbsp;Math&nbsp;Behind&nbsp;the&nbsp;Fact:<\/strong><br>Pathological functions such as this one are important and fun examples that are studied in a real analysis course. Another fun pathology is a&nbsp;Continuous but Nowhere Differentiable&nbsp;function.<\/p>\n\n\n\n<p><strong>How to Cite this Page:<\/strong>\u00a0<br>Su, Francis E., et al. &#8220;Devil&#8217;s Staircase.&#8221;\u00a0<em>Math Fun Facts<\/em>. &lt;http:\/\/www.math.hmc.edu\/funfacts>.<\/p>\n\n\n\n<p><strong>Fun Fact suggested by:<\/strong><br>Lesley Ward<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Here is a strange continuous function on the unit interval, whose derivative is 0 almost everywhere, but it somehow magically&#46;&#46;&#46;<\/p>\n","protected":false},"author":7,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"tags":[57,20,7,130,86,60],"class_list":["post-557","page","type-page","status-publish","hentry","tag-advanced","tag-analysis","tag-calculus","tag-functions","tag-measure-0","tag-real-analysis"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/math.hmc.edu\/funfacts\/wp-json\/wp\/v2\/pages\/557","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/math.hmc.edu\/funfacts\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/math.hmc.edu\/funfacts\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/math.hmc.edu\/funfacts\/wp-json\/wp\/v2\/users\/7"}],"replies":[{"embeddable":true,"href":"https:\/\/math.hmc.edu\/funfacts\/wp-json\/wp\/v2\/comments?post=557"}],"version-history":[{"count":3,"href":"https:\/\/math.hmc.edu\/funfacts\/wp-json\/wp\/v2\/pages\/557\/revisions"}],"predecessor-version":[{"id":1399,"href":"https:\/\/math.hmc.edu\/funfacts\/wp-json\/wp\/v2\/pages\/557\/revisions\/1399"}],"wp:attachment":[{"href":"https:\/\/math.hmc.edu\/funfacts\/wp-json\/wp\/v2\/media?parent=557"}],"wp:term":[{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/math.hmc.edu\/funfacts\/wp-json\/wp\/v2\/tags?post=557"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}