Correlation Dimension

The correlation dimension can be calculated using the Grassberger-Procaccia algorithm [1]. This involves calculation of the correlation sum defined as

[latex] C_m\left( r  \right) = \mathop {\lim }\limits_{N \to \infty } \frac{2}{{N\left( {N – 1} \right)}}\sum\limits_{i = 1}^N {\sum\limits_{j = i + 1}^N {\Theta \left( {r  – \left\| {y_i  – y_j } \right\|} \right)} } [/latex]   (1)

where [latex]|| y_i – y_j ||[/latex] is the distance between pairs of points in the phase space and [latex]\Theta(x)[/latex]  is the Heaviside function: [latex]\Theta = 1[/latex] if [latex]x \geq 0[/latex] and [latex]\Theta = 0 [/latex] if [latex]x \leq 0[/latex].  The value [latex]r[/latex] is the radius of a hypersphere in an [latex]m[/latex]-dimensional space, and [latex]N[/latex] is the number of points in the space.

In theory the density of the points will scale as a power law with the radius

[latex] \mathop {\lim }\limits_{r \to 0} \mathop {\lim }\limits_{N \to \infty } C_m\left( r  \right) = r^D [/latex]   (2)

The correlation dimension is then given by

[latex] D = \mathop {\lim }\limits_{r \to 0} \mathop {\lim }\limits_{N \to \infty } \frac{{\log C_m\left( {r} \right)}}{{\log r }} [/latex]   (3)

So the gradient of a graph of [latex]{\log C_m\left({r} \right)}[/latex] versus [latex]\log r[/latex] should approach a finite value [latex]D[/latex] in the limit as [latex]r \rightarrow 0[/latex]. For data that has finite sampling, the slope of this graph for very small [latex]r[/latex] is very inaccurate so instead a ‘scaling’ region of [latex]r[/latex] is taken over which the slope is relatively stable. A plot of the gradient, [latex]D_m (r) = \partial \log C_m (r) / \partial \log (r) [/latex], as a function of [latex]r[/latex] makes observing this region much clearer. The value of the slope [latex]D_m (r)[/latex] within the scaling region is the correlation dimension.

A great free program for efficient calculation of this measure is the TISEAN package [2]. It contains a range of other very useful tools for time series analysis.


[1] P. Grassberger, and I. Procaccia, “Measuring the strangeness of strange attractors”, Physica D 9, 189-208 (1983).
[2] R. Hegger, H. Kantz and T. Schreiber, “Practical implementation of nonlinear time series methods: The TISEAN package”, CHAOS 9, 413 (1999).