Takagi–Landsberg curve: Difference between revisions

From JSXGraph Wiki
(New page: The blancmange function is defined on the unit interval by :<math> {\rm blanc}(x) = \sum_{n=0}^\infty {s(2^{n}x)\over 2^n},</math> where <math>s(x)</math> is defined by <math>s(x)=\mi...)
 
No edit summary
 
(13 intermediate revisions by one other user not shown)
Line 9: Line 9:
:<math>    T_w(x) = \sum_{n=0}^\infty w^n s(2^{n}x)</math>
:<math>    T_w(x) = \sum_{n=0}^\infty w^n s(2^{n}x)</math>


for a parameter w; thus the blancmange curve is the case <math>w = 1 / 2</math>. The value <math>H = − \log2w</math> is known as the Hurst parameter. For <math>w = 1 / 4</math>, one obtains the parabola: the construction of the parabola by midpoint subdivision was described by Archimedes.
for a parameter w; thus the blancmange curve is the case <math>w = 1 / 2</math>. For <math>w = 1 / 4</math>, one obtains the parabola: the construction of the parabola by midpoint subdivision was described by Archimedes.




<jsxgraph width="500" height="500" box="box">
<jsxgraph width="500" height="500" box="box">
  var bd = JXG.JSXGraph.initBoard('box', {axis:true,originX: 250, originY: 250, unitX: 25, unitY: 25});
  var bd = JXG.JSXGraph.initBoard('box', {axis:true,boundingbox: [-0.05, 16, 1.27, -4]});
  var f = bd.createElement('slider', [[1,8],[5,8],[0,4,8]]);
  var w = bd.create('slider', [[0,8],[0.8,8],[0,0.25,1.5]], {name:'w'});
  var len = bd.createElement('slider', [[1,7],[5,7],[0,2,2]]);  
  var N = bd.create('slider', [[0,7],[0.8,7],[0,5,40]], {name:'N'});  
  var k = bd.createElement('slider', [[1,6],[5,6],[0,2,10]]);
  var s = function(x){ return Math.abs(x-Math.round(x)); };
  var c = bd.createElement('curve', [function(phi){return f.Value()*Math.cos(Math.floor(k.Value())*phi); }, [0, 0],0, function(){return len.Value()*Math.PI;}],
  var c = bd.create('functiongraph', [
            {curveType:'polar', strokewidth:2});       
    function(x){
        var n, su, wval;
        su = 0.0;
        wval = w.Value();
        for (n=0;n<N.Value();n++) {
          su += Math.pow(wval,n)*s(Math.pow(2,n)*x);
        }
        return su;
    },0,1],{strokeColor:'red'});       
</jsxgraph>
</jsxgraph>
===The JavaScript code to produce this picture===
<source lang="javascript">
var bd = JXG.JSXGraph.initBoard('box', {axis:true,boundingbox: [-0.05, 16, 1.27, -4]});
var w = bd.create('slider', [[0,8],[0.8,8],[0,0.25,1.5]], {name:'w'});
var N = bd.create('slider', [[0,7],[0.8,7],[0,5,40]], {name:'N'});
var s = function(x){ return Math.abs(x-Math.round(x)); };
var c = bd.create('functiongraph', [
    function(x){
        var n, su, wval;
        su = 0.0;
        wval = w.Value();
        for (n=0;n<N.Value();n++) {
          su += Math.pow(wval,n)*s(Math.pow(2,n)*x);
        }
        return su;
    },0,1],{strokeColor:'red'});     
</source>
===References===
* Teiji Takagi, "A Simple Example of a Continuous Function without Derivative", Proc. Phys. Math. Japan, (1903) Vol. 1, pp. 176-177.
===External links===
* [http://en.wikipedia.org/wiki/Blancmange_curve http://en.wikipedia.org/wiki/Blancmange_curve]
[[Category:Examples]]
[[Category:Curves]]

Latest revision as of 07:26, 9 June 2011

The blancmange function is defined on the unit interval by

[math]\displaystyle{ {\rm blanc}(x) = \sum_{n=0}^\infty {s(2^{n}x)\over 2^n}, }[/math]

where [math]\displaystyle{ s(x) }[/math] is defined by [math]\displaystyle{ s(x)=\min_{n\in{\bold Z}}|x-n| }[/math], that is, [math]\displaystyle{ s(x) }[/math] is the distance from x to the nearest integer. The infinite sum defining [math]\displaystyle{ blanc(x) }[/math] converges absolutely for all x, but the resulting curve is a fractal. The blancmange function is continuous but nowhere differentiable.

The Takagi–Landsberg curve is a slight generalization, given by

[math]\displaystyle{ T_w(x) = \sum_{n=0}^\infty w^n s(2^{n}x) }[/math]

for a parameter w; thus the blancmange curve is the case [math]\displaystyle{ w = 1 / 2 }[/math]. For [math]\displaystyle{ w = 1 / 4 }[/math], one obtains the parabola: the construction of the parabola by midpoint subdivision was described by Archimedes.


The JavaScript code to produce this picture

 var bd = JXG.JSXGraph.initBoard('box', {axis:true,boundingbox: [-0.05, 16, 1.27, -4]});
 var w = bd.create('slider', [[0,8],[0.8,8],[0,0.25,1.5]], {name:'w'});
 var N = bd.create('slider', [[0,7],[0.8,7],[0,5,40]], {name:'N'}); 
 var s = function(x){ return Math.abs(x-Math.round(x)); };
 var c = bd.create('functiongraph', [
     function(x){
        var n, su, wval;
        su = 0.0;
        wval = w.Value();
        for (n=0;n<N.Value();n++) {
           su += Math.pow(wval,n)*s(Math.pow(2,n)*x);
        }
        return su;
     },0,1],{strokeColor:'red'});

References

  • Teiji Takagi, "A Simple Example of a Continuous Function without Derivative", Proc. Phys. Math. Japan, (1903) Vol. 1, pp. 176-177.

External links