viernes, 15 de octubre de 2010

ubigraph: an interactive 3D graph creator

A few days ago I read a funny post on HN. A guy was presenting some clojure code that used ubigraphto produce 3d navigable graphs.

To make ubigraph portable and interoperable with many languages, they present the app as an independent window (embedable, I hope) with its own process that acts as a XML-RPC server, so if you don't have an specific API for your language, you can use plain XML-RPC calls.

I've written a simple fibonacci function with a callback that draws the flow of the calculations.
Here's the code, and a (static) image of the graph.





To See how memoizing works, I've modified the code a bit using Memoize and a normalizer function and now we see how the number of steps is O(n).