Harry Seldon's blog

Fractals, Chaos, and Control Systems on Rails

Read

Symposium : Tribute to Benoit Mandelbrot at the Ecole Polytechnique

Posted by Harry Seldon on February 28, 2011

Tribute to Mandelbrot

A symposium specific to a tribute to Benoit Mandelbrot will take place at the Ecole Polytechnique on the 17th and 18th of March 2011. Entrance is free but upon registration :

http://events.polytechnique.fr/accueil/hommage-a-benoit-mandelbrot/

Title of the event is “Universalities and fractals”. You can find the absolutely fascinating program at the previous address.
Here are just a few presentations :

  • Heinz-Otto Peitgen. University of Bremen and Florida Atlantic University « The Mandelbrot Set: Revitalizing Iteration Theory and Popularizing Mathematics »
  • Luciano Pietronero, Universita La Sapienza, Rome « Fractal Cosmology »
  • Laurent Calvet, HEC Paris et National Bureau of Economic Research (USA) « Risque extrême et régularité fractale en finance » (Extreme risk and fractal regularity in finance)
  • Jens Feder, Physics of Geological Process, Université d’Oslo, “Fractals flow and Fracture”
  • Peter Jones, Yale University « Product Formulas for Measures and Applications to Analysis »

By the way of this blog, I much thank the organizing committee as it seems to me that Mandelbrot was one of the greatest genius of the XXth century. I have been much awaiting this kind of tribute in France. That’s why I will deeply regret for a long time the fact that there is no way I can come on the Friday.

Here is a reminder of the few articles I wrote about Mandelbrot:

Posted in , | 1 comment | Tags , , , , | atom

Best videos about fractals chaos and Benoit Mandelbrot

Posted by Harry Seldon on October 19, 2010

Everything you have always wanted to know about fractals without daring to ask.

These two movies about fractals and chaos are amazing.

In French and in only one part here

Thank you Prof. Mandelbrot for teaching us how to describe nature !

Posted in | 1 comment | Tags , , , | atom

Tribute to Benoit Mandelbrot

Posted by Harry Seldon on October 18, 2010

Benoit Mandelbrot is, imho, the biggest genius of the XXth century and our time. His work has already technologically changed our world (CGI, cell phone antennas, processors shapes, unerstanding stock market krachs, etc.). But the day, the philosophy, the epistemology, behind his work is understood, the day, the “language of nature” that Mandelbrot taught us, is understood, this day, the world will be a lot more peaceful.

Back in February 2009, I wrote that the celebrity I would love most to meet was Benoit Mandelbrot. I could partially fullfill that dream almost exactly one year ago (on the Sunday 24th of October 2009). While he was in Paris to present the amazing movie Fractals: Hunting the hidden dimension I got the privilege to talk to Benoit Mandelbrot on the phone. I have never posted about that because the talk was quite personal but I guess I will someday. For now, I can say for sure that Benoit Mandelbrot was a great man with an amazing kindness and a very nice sense of humor. He was so kind to tell me to call him after I sent him an email. And on the phone, when I asked him why he was not giving more conferences, he answered me : “you know, I am old, most people think I am already dead.”

Well before that encounter I grew up reading Mandelbrot’s books, among them “The Fractal Geometry of Nature”. Prof. Mandelbrot, I already miss you.

About memories, here is a best of the posts I wrote about fractals, Benoit Mandelbrot, chaos and controls. The first article was a short portrait of Mandelbrot where I campaigned for him to have the Nobel Prize in ALL categories : economy, physics, medecine (biology), chemistry, and even litterature and peace.

If you wish to pay a tribute to Benoit Mandelbrot, please, feel free to do so in the comments.

tree_snow_battle
Children making a snow battle under a magnificient fractal tree.

Posted in | 3 comments | Tags , , , | atom

Benoit Mandelbrot, father of the fractal theory, has just died

Posted by Harry Seldon on October 17, 2010

Benoit Mandelbrot is leaving us way too soon, even at 86. There is still so much to do to educate people about fractals.

I got the incredible luck to speak to him on the phone almost exactly one year ago (on the Sunday 24th of October 2009). He was still in good shape and he had quite a lot of projects. Among them, he was preparing a book of his memories. I hope he had the time to finish it.

I am shocked by this news.
All my thoughts go to his familly.

In an interesting but sad coincidence that life can do, I met this current week Nassim Nicholas Taleb who is, in some sort, Mandelbrot’s disciple.

The king is dead. Long live the king.
Mandelbrot is dead. Long live Taleb.

For more information, see the links given by the message sent by the Finance and Mandelbrot Facebook group :

Philippe Herlin October 17 at 10:01am R.I.P. BENOIT MANDELBROT, 1924-2010


Finance & Mandelbrot
http://www.facebook.com/group.php?gid=53108760302

Posted in , | no comments | Tags , , , | atom

How did we get here? Chaos vs God

Posted by Harry Seldon on January 18, 2010

I love the description given by the BBC for their documentary “The Secret Life of Chaos” (which you can watch here).
As I have written a few articles about fractals, chaos and controls lately, I have added links internal to this blog to the text.

“Chaos theory has a bad name, conjuring up images of unpredictable weather, economic crashes and science gone wrong. But there is a fascinating and hidden side to Chaos, one that scientists are only now beginning to understand. It turns out that chaos theory answers a question that mankind has asked for millennia - how did we get here?

In this documentary, Professor Jim Al-Khalili sets out to uncover one of the great mysteries of science -

  • how does a universe that starts off as dust end up with intelligent life?
  • How does order emerge from disorder?

It’s a mindbending, counterintuitive and for many people a deeply troubling idea. But Professor Al-Khalili reveals the science behind much of beauty and structure in the natural world and discovers that far from it being magic or an act of God, it is in fact an intrinsic part of the laws of physics.

Amazingly, it turns out that the mathematics of chaos can explain how and why the universe creates exquisite order and pattern. The natural world is full of awe-inspiring examples of the way nature transforms simplicity into complexity. From trees to clouds to humans - after watching this film you’ll never be able to look at the world in the same way again.”

Notice that this introduction can be sum up by “Chaos vs God” or “Chaotical Design vs Intelligent Design”. However, anyway, one question remains: who created the laws of physics? Or how were created these laws of Physics, if you prefer ;-)

I have often privately said that James Gleick’s Chaos book gives clearer answers than the Bible about our world. Now is the time to say it publicly!

Enjoy the documentary!

Posted in | no comments | Tags , , , , | atom

The Secret Life of Chaos (BBC 2010)

Posted by Harry Seldon on January 18, 2010

The BBC aired on Thursday, January 14th an excellent documentary about Chaos, Fractals and Nature. You can watch it right here thanks to YouTube. If you are in UK you can also watch it on the BBC website at this address.

I am glad the BBC helps making these subjects popular and fashionnable more than 20 years after James Gleick’s Chaos book.

Part 1

All parts follow.

Part 2

Part 3

Part 4

Part 5

Part 6

Enjoy!

Posted in | no comments | Tags , , , , | atom

The fractal Google logo

Posted by Harry Seldon on January 14, 2010

Thx Pixgeeks for reminding me of this nice Google logo involving fractals.

fractal_google_logo

It was in memoriam to Gaston Julia’s Birthday.

In case I need to precise, the fractals you see on the logo are called Julia sets because the French mathematician Gaston Julia described them first. However, most of my readers already know that, right? ;-)

To say something only initiated people can understand: “The Mandelbrot set contains all Julia sets”. (That is why the fractal on the left is actually the Mandelbrot set.)

You can check all google logos here.

Posted in | 1 comment | Tags , , , , | atom

7 lifechanging books about fractals, chaos, nature, philosophy and even finance for the holidays

Posted by Harry Seldon on December 14, 2009

Mandelbulb
Mandelbulb by Daniel White

As we are still at the beginning of the holiday season, maybe you haven’t bought all your gifts yet. In that case, here are a few lifechanging books you can offer to your loved ones.
By lifechanging, I mean you will never look at the world in the same way after reading one of these books. There is even a good chance you will find the world a lot more simple after your reading because these books give you keys to the behaviour of nature and mankind.

If you don’t like too much specialized books, you will like these ones because each one of them will speak about several topics among geology, economy, biology, social sciences, and climate.

Moreover, you will find some element of answers for several popular questions of our days like:

fractals_nature_model

So, let’s go to the point, here are these absolutely marvellous books. Notice, they are somehow sorted by order of importance.

So, in case it was not clear, now you see why my Twitter name is @Fractalharry ;-)

You can propose other books in the comments.

Enjoy your reading.

PS I have linked to Amazon for your convenience but I don’t touch any commission!

Posted in | 7 comments | Tags , , , , , , , , , | atom

Simplexity: Things are a lot simpler than they seem and vice versa

Posted by Harry Seldon on October 20, 2009

Have you ever heard of simplexity ?

Some systems are a lot simpler than they look like. For instance, let’s consider the shape of a tree. It looks complex, especially if you compare it with a straight line. However, if you have read Mandelbrot or heard of fractals, you know that all you need to draw a tree is a 2 lines pattern, which you repeat a big number of times introducing at each step some light randomness. You can model pretty easily this tree shape. At least you can generate at your will tree shapes. That is typically the way used in computer graphics to generate natural virtual 3D scenes. However, this does not mean you can predict the accurate shape of a tree from its seed.

So, is the tree shape complex or simple? Thanks to Mandelbrot we know now that the shape is a lot simpler than it seems. Associating the notions of predictability and simplicity, the converse is also true: it is more complicated than you could think even if you have heard of fractals. Hence this notion of simplexity, contraction of simplicity and complexity.

Here are a few good books on the subject:

If you know about fractals and chaos, you must be already familiar with that fact that simplicity can bring complexity quickly and easily. But you might not know this term of simplexity.
More generally, each time you think “this thing is a lot simpler than I had imagined at first”, you experience simplexity: in fact, you changed your first impression of overall complexity by discovering the underlying simple principles.

While we are at it. There is a field where simplexity shows all its magnificence: it is in finance. International finance looks complex but there are a limited number of principles behind it. You can even fairly easily model a stock chart. (Even if this model has nothing to do with the actual models used by financial analysts). But even with a good model you cannot predict easily the stock chart of a determined company.
For more info, you can have a look at the Facebook group “Finance & Mandelbrot”.

And at last, because I cannot prevent from saying it again, If you want to keep things simple, then regulate them. Contrary to what you could think, you do not need very accurate models to control a system.

Posted in , | 1 comment | Tags , , , , | atom

How to draw Mandelbrot's fractal with Rails and Open Flash Chart?

Posted by Harry Seldon on April 18, 2009

Mandelbrot set

Let us draw the Mandelbrot set with OFC. The point is to make a new example of use of OFC and it is also to have some fun with the so interesting fractal theory. To see how fashionable it is, read this post: Good news from the combat against the crisis. This post is highly inspired from this nice French page about the Mandelbrot set. I am using the algorithm given there.

Definition of the Mandelbrot set
For each point of the complex plane we associate the sequence: zn+1=zn2+A with z0=0 and A=a+ib the point affix. Iff the sequence is bounded the point A belongs to the Mandelbrot”s set. Problem is, it is not easy for a computer to say if a sequence remains bounded. It would require an infinite number of calculations. For each point, we are simply going to make a ‘large’ number of calculation on the sequence. It can be shown analytically that if the module of zn is greater than 2 the sequence will diverge. So during nmax iterations, if the sequence goes above 2, the sequence diverges and it has diverged all the quicker as the number of iteration is low. If it is quick to diverge it is far from the set. A color will be associated to each point according to its distance from the set. If the algorithm reaches nmax the probability for the point to belong to the set is maximal with respect to our computation.

To code without complex numbers we will use the real coordinates, the sequence being written equivalently as:
xn+1=xn2-yn2+a
yn+1=2 xn yn+b

Code for Open Flash Chart
The implementation with Rails and OFC is explained hereafter. It is using a scatter chart.

in test_it_controller.rb

  def index_mandelbrot_fractal
    # from http://perso.numericable.fr/~haasjn/haasjn/AlgoMandel.txt 
    @graph = open_flash_chart_object(500,500,"/test_it/graph_code_Mandelbrot_fractal")     
  end

Also in test_it_controller.rb

  def graph_code_Mandelbrot_fractal
    #    Algorithm to draw Mandelbrot's fractal 
    #    
    #    variables a,b,x,y,xmin,ymax,cx,cy,width,step:real
    #              i,j,nx,ny,n:int
    #              r: table
    #        
    #    cx,cy    coordinates of the image center in the complex plane
    #    xmin     image left limit 
    #    ymax     image upper limit
    #    width    image width in the complex plane
    #    nx       image horizontal resolution 
    #    ny       image vertical resolution
    #    nmax     maximum number of loops to compute the convergence of the complex sequence
    #    step     step between 2 points 
    #    r        table containing the result for each point
    #
    #    in the loop 
    #    i,j  indices of the point 
    #    a,b  point coordinates
    #    x,y  values of the complex sequence
    #    x1   next value of x 
    #    n    indice of the complex sequence
    # 
    #    Algorithm beginning 
    #    cx,cy,width,nx,ny,nmax are given at start 
    cx = 0
    cy = 0
    width = 4.to_f
    nx = 100.to_f
    ny = 100.to_f
    nmax = 250.to_f

    xmin = cx-width/2
    ymax = cy+width/2*ny/nx
    step  = width/nx

    # Preparation of the chart
    chart = OpenFlashChart.new
    title = Title.new("Mandelbrot set")
    chart.set_title(title)
    r = Array.new # results 

    # The loop asks : does the point (a,b) belong to the Mandelbrot set ? 
    # The bigger n, the more probable the point belongs to  the set 
    for j in 0..ny-1
      b=ymax-j*step       
      for i in 0..nx-1
        a=i*step+xmin
        x=0
        y=0 
        n=0
        #  while x*x+y*y<4 and n<=nmax
        while x*x+y*y<4 && n<=nmax
          x1=x*x-y*y+a
          y=2*x*y+b
          x=x1
          n=n+1
        end

        # Adding the point to the chart
        # Needs to associate a color according to n 
        # that is according to the time needed to converge
        amplif = 1
        c = (16.0.+n/nmax*(255.0-16.0)*amplif).to_int
        c = [255,c].min
        col_gray = (255-c).to_int.to_s(16).to_s
        col =  "#"+col_gray+col_gray+col_gray
        scatter = Scatter.new(col, 2);
        scatter.set_values([ScatterValue.new(a,b)])
        chart.add_element( scatter )

        # if you want to store the result 
        r.push([a,b,n,c])
      end #i
    end #j

    x_axis = XAxis.new
    x_axis.set_range(xmin,-xmin)
    chart.x_axis = x_axis

    y_axis = YAxis.new
    y_axis.set_range( -ymax, ymax )
    chart.y_axis = y_axis
    render :text => chart.to_s      
  end

in index_mandelbrot_fractal.html.erb

<script type="text/javascript" src="/javascripts/swfobject.js"></script>
<%= @graph %>

Notice the code for the computation and the graph are made together in the controller code. This is just for simplicity to write this post. Technically, the computation is more a work for your model. Preparing the graph is also a work for the model. With a DRY code you would have one model method to prepare the data, one to prepare the chart. Then in the controller you call the method that prepares the chart and you sends the data to the view.

Result
Here is the Mandelbrot set chart. Beware it takes about 10 seconds to load. Indeed the algorithm is computationally intensive. The code is available in the OFC test app on github. Here is the controller code.

Thanks for having read this world first: drawing the Mandelbrot set with Ruby on Rails and OFC.

Posted in , | 2 comments | Tags , , , , , | atom

Search

Navigate


Recent Comments

Recent Posts

Tags

actuators aircraft atc blog chaos chaos_theory charts control controllers controls crisis economy finance flight fractals git gnc gs guidance linux mandelbrot marketing navigation ns ofc on pilot rails ruby sas scs sensors statistics systems techcrunch thinkosphere tutorial typo ubuntu wifi

Categories

Archives

Syndicate


Sponsor