r/Python • • Mar 26 '15

Exploring and visualizing Chaos Theory with Python and matplotlib

http://geoffboeing.com/2015/03/chaos-theory-logistic-map/
86 Upvotes

18 comments sorted by

4

u/huopak Mar 26 '15

This was awesome

1

u/gboeing Mar 26 '15

Thanks!

2

u/hharison Mar 26 '15

Really cool stuff. Interesting that you're coming at this from Urban Planning. I learned all this stuff in my studies for a Ph.D. in Psychology. I guess that's the whole point, right, that it's domain-independent, scale-invariant, etc. Good stuff.

You should do a section on Arnold Tongues. Also makes for good visualizations.

2

u/gboeing Mar 26 '15

Interesting. How is chaos usually applied in Psychology? I think you're right... there's something fundamentally appealing about chaos and complexity across tons of domains. Arnold Tongues would be cool to work on... I have an old IPython notebook visualizing Lorenz attractors that came out quite beautifully. I'll need to write that up when I have time.

5

u/hharison Mar 26 '15 edited Mar 26 '15

All sorts of ways. In my view, in the end it usually comes back to self-organization, and different ways to understand self-organizing systems. Check out this special issue for an approach to understanding intelligence as an inexorable product of self-organization, rooted in physics rather than biology.

There's a lot of work of work using dynamical systems to model behavior (you may have encountered similar models in e.g. traffic models. Some psychologists are concerned with locomotion and steering, there's a lot of crossover between models of vehicular "locomotion" and bipedal locomotion). Related to the dynamics is of course catastrophe theory and bifurcation theory. While it doesn't go deep in to choas, this paper explains the application of dynamics to behavior.

In the last few years multifractality has really taken off. Here's the leading article describing the application of mutlifractal measures to behavioral data.

Personally, I'm in a Psych. department and my advisor is a physicist. My first publication was on multifractal analysis of pole-balancing (subjects balancing a pole on their fingertip, recording movements with motion-capture equipment). It's looking like my thesis might be on the dynamics of behavioral transitions (e.g., walk to run).

1

u/gboeing Mar 27 '15

Great stuff! Thanks for sharing.

2

u/autowikibot Mar 26 '15

Multifractal system:


A multifractal system is a generalization of a fractal system in which a single exponent (the fractal dimension) is not enough to describe its dynamics; instead, a continuous spectrum of exponents (the so-called singularity spectrum) is needed.

Multifractal systems are common in nature, especially geophysics. They include fully developed turbulence, stock market time series, real world scenes, the Sun’s magnetic field time series, heartbeat dynamics, human gait, and natural luminosity time series. Models have been proposed in various contexts ranging from turbulence in fluid dynamics to internet traffic, finance, image modeling, texture synthesis, meteorology, geophysics and more. The origin of multifractality in sequential (time series) data has been attributed to mathematical convergence effects related to the central limit theorem that have as foci of convergence the family of statistical distributions known as the Tweedie exponential dispersion models as well as the geometric Tweedie models. The first convergence effect yields monofractal sequences and the second convergence effect is responsible for variation in the fractal dimension of the monofractal sequences.

From a practical perspective, multifractal analysis uses the mathematical basis of multifractal theory to investigate datasets, often in conjunction with other methods of fractal analysis and lacunarity analysis. The technique entails distorting datasets extracted from patterns to generate multifractal spectra that illustrate how scaling varies over the dataset. The techniques of multifractal analysis have been applied in a variety of practical situations such as predicting earthquakes and interpreting medical images.

====

Image i - A Strange Attractor that exhibits multifractal scaling


Interesting: ^Mandelbox | Fractal ^cosmology | Fractal ^derivative

Parent commenter can toggle ^NSFW or ^delete. Will also delete on comment score of -1 or less. | FAQs | ^Mods | Magic ^Words

2

u/frozenbobo Mar 27 '15 edited Mar 27 '15

For anyone interested in this topic, I can recommend two sources for newcomers.

Conversational, largely non-technical: Chaos: Making a New Science by James Gleick

Technical (requires knowledge of ordinary differential equations, but highly readable): Nonlinear Dynamics and Chaos by Steven H. Strogatz

1

u/gboeing Mar 27 '15

Yes, I'd definitely concur that Gleick and Strogatz are the best sources for newcomers. Someone else mentioned Mitchell's Complexity: A Guided Tour which shows the shift from Chaos to Complexity over the past two decades, and is very readable. Waldorp's Complexity is another good one - basically a Gleick knock-off for the Santa Fe Inst and complexity.

A couple other recommendations: Strogatz's Sync, and Kiel & Elliott's Chaos Theory in the Social Sciences (if you're interested in that branch of application).

Technically-minded folks might check out some of the early scholarly journal articles in the field for some of the simple, early math and the joy of seeing the light turn on in the minds of some very, very smart people:

2

u/PriceZombie Price tracking robot Mar 27 '15

Chaos: Making a New Science

Current $12.25 
   High $14.69 
    Low $10.31 

Price History Chart and Sales Rank | GIF

Nonlinear Dynamics and Chaos: With Applications to Physics, Biology, C...

Current $50.52 
   High $56.93 
    Low $50.52 

Price History Chart and Sales Rank | GIF | FAQ

1

u/nullmove Mar 27 '15

I have really liked Complexity: A Guided Tour. It has a chapter covering the exact material of this article, among other things. Very newcomer friendly too.

1

u/hharison Mar 27 '15

Technical (requires knowledge of ordinary differential equations, but highly readable): Nonlinear Dynamics and Chaos by Steven H. Strogatz[2]

Yep. The only textbook I've recommended people buy for fun.

A couple years ago I was catching up with my brother and he was like "I did a weird thing, you'll make fun of me, I ordered a textbook on Amazon. For pleasure reading."

I was like, "Strogatz?" I just knew; what else could it be?

3

u/pymatek Mar 27 '15

Nice writeup, but one important correction. To say that a system exhibits sensitive dependence on initial conditions requires that that you show that for fixed parameter values, two points that start arbitrarily close end up sufficiently far apart. You don't want to take the same initial condition and use it for two different parameter values.

2

u/gboeing Mar 27 '15 edited Jul 16 '15

Good catch

2

u/GrantNexus Mar 27 '15

I have so much to learn.