## March 11, 2015

### A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

#### Posted by Simon Willerton Consider the following shape that we are zooming into and out of. What dimension would you say it was? At small scales (or when it is very far away) it appears as a point, so seems zero-dimensional. At bigger scales it appears to be a line, so seems one-dimensional. At even bigger scales it appears to have breadth as well as length, so seems two-dimensional. Then, finally, at very large scales it appears to be made from many widely separated points, so seems zero-dimensional again.

We arrive at an important observation:

The perceived dimension varies with the scale at which the shape is viewed.

Here is a graph of my attempt to capture this perceived notion of dimension mathematically. Hopefully you can see that, moving from the left, you start off at zero, then move into a region where the function takes value around one, then briefly moves up to two then drops down to zero again.

The ‘shape’ that we are zooming into above is actually a grid of $3000\times 16$ points as that’s all my computer could handle easily in making the above picture. If I’d had a much bigger computer and used say $10^{7}\times 10^{2}$ points then I would have got something that more obviously had both a one-dimensional and two-dimensional regime.

In this post I want to explain how this idea of dimension comes about. It relies on a notion of ‘size’ of metric spaces, for instance, you could use Tom’s notion of magnitude, but the above picture uses my notion of $2$-spread.

I have mentioned this idea before at the Café in the post on my spread paper, but I wanted to expand on it somewhat.

## What do we mean by dimension?

First we should try to understand how we think of dimension. We are used to thinking of it in terms of ‘degrees of freedom’, or the number of different directions you can go in, so a line is one dimensional and a square is two dimensional. This will always give us an integer dimension.

It was realised that there were spaces that could be given meaningful non-integer dimensions by using a different approach to what dimension is. Let’s follow one train of thought. If we think about the square and the line again, we can see that they have different scaling properties. If we scale up a line by a factor of two, then we can fit exactly two copies of the original line in. If we scale up a square by a factor of two then we can fit four copies of the original square in. More generally if we scale up the line by a factor of $n$ then we can fit $n=n^{1}$ copies of the original line in and if we similarly scale up the square by a factor of $n$ we can fit $n^{2}$ copies of the original square. The indices $1$ and $2$ coincide with the dimensions of the spaces.

Let’s take that as the basis of a different notion of dimension and see what happens when we scale up some fractally shapes.

## A first attempt at defining dimension

Let’s take a not well defined notion of scale dimension to be the following. Say that the scale dimension is $D$ if when we scale up by a factor of $n$ (for suitable $n$) we get $n^{D}$ copies of our original space back.

We see that the Koch curve is scaled by a factor of $3$ we can fit four copies of the original in, or more generally when scaled by a factor of $n=3^{k}$ we can fit $4^{k}=(3^{\log _{3}(4)})^{k}= n^{\log _{3}(4)}$ copies in. So this says that the scale dimension is $\log _{3}(4)$. Similarly for the Cantor set. If you scale it by a factor of three you can fit two copies of the original in, more generally if we scale it by a factor of $n=3^{k}$ we can fit $2^{k}=(3^{\log _{3}(2)})^{k}= n^{\log _{3}(2)}$ copies in. So this says that the scale dimension is $\log _{3}(2)$. The above idea, although appealing, has several flaws. One flaw is that it is not clear what is meant by having $n$-copies of our original shape: for instance, when we scale up the square and decompose into smaller squares the boundaries overlap, so we get a bit less than four copies. Another flaw is that the above idea only works for certain special shapes: for instance, if we scale up a disk by a factor of two we don’t get a shape we can decompose into four of our original shapes. Indeed, there is no $n\gt 1$ such that when we scale up a disk by a factor of $n$ we get a shape that can be decomposed into $n^{2}$ copies of our original disk.

## A second attempt

We could address these two flaws by observing that when we scale up a plane shape such as a square or a disk by a factor of two we get a shape which is four times the area of the original shape. Similarly, when we scale all lengths by a factor of $n$ we get a shape which has $n^{2}$ the area. More generally, for a shape in $D$-dimensional Euclidean space, when we scale all lengths by a factor of $n$ we get a shape which has $n^{D}$ times the volume.

So we could try to say that a shape has volume dimension $D$ if when you scale it up by a factor of $n$ the volume changes by a factor of $n^{D}$. Unfortunately, that doesn’t work for various reasons. Firstly, you have to specify the kind of volume you need for each shape, so you need length for lines and area for squares, so you’re presupposing the dimension when you pick the volume to use! Secondly, this is not going to work for fractals as none of these volumes make sense for a fractal. The Koch curve does not have a meaningfully non-trivial length or area. (To define fractal dimensions such as the Hausdorff or Minkowski dimension you’d take a different turn at this point, but we’ll carry on the way we’re going.)

## Defining dimension using a notion of size

An alternative would be if we had a single notion of size which we could use for all shapes simultaneously. For a given shape we could then see how this size changes under scaling and use that to define a notion of dimension. This is the approach I used as I know of several appropriate notions of size.

• Tom Leinster introduced ‘magnitude’ $|\cdot |$ which is a notion of size which is defined for every compact subset of a Euclidean space — and more generally, for every compact, positive definite metric space. I’ll not give the definition here.

• Tom also introduced ‘maximum diversity’ which is based on magnitude, is a bit more complicated to define but is somewhat better behaved on all metric spaces. He gives the definition in this post if you are interested.

• I introduced a one-parameter family $\{ E_{q}\} _{q\ge 0}$ of notions of size which are defined for every finite metric space — and I suspect for every compact subset of Euclidean space as well. These are easier to define and calculate, but I’ll just give the definitions for $E_{0}$ and $E_{2}$, which are particularly nice to write down. If $(X,d)$ is a finite metric space with $N$ points then the $0$-spread and $2$-spread are defined as follows: $E_{0}(X)\coloneqq \sum _{x\in X}\frac{1}{\displaystyle\sum _{y\in X}e^{-d(x,y)}}; \qquad E_{2}(X)\coloneqq \frac{N^{2}}{\displaystyle\sum _{x,y\in X}e^{-d(x,y)}}.$

Once we have a notion of size $S$, we want to use this to define a notion of dimension which tells us how the size alters under scaling. Typically we can’t do anything as naive as finding a $D$ such that if we scale by a factor of $n$ then the size scales by a factor of $n^{D}$, the sizes described above are generally more interesting than that!

For a shape $X$ and $t\gt 0$ we define $t X$ to be the shape $X$ scaled up by a factor of $t$. We then have the size $S(t X)$ being a function of $t$ and we define the dimension of $X$ to be the growth rate of this function at $t=1$. By growth rate I mean some number associated to a function such that the growth rate of $t^{D}$ is $D$. Recalling from school that the way to calculate the growth rate of a function is to plot the function on log-log paper and measure the gradient, we take the instantaneous growth rate of a function to be the logarithmic derivative, $\frac{d (\ln (f(t)))}{d \ln (t)}$. A couple of applications of the chain rule tell us that this is just $\frac{d f(t)}{dt}\frac{t}{f(t)}$.

For a notion of size $S$, this leads us to define the S-dimension of a shape $X$ by $\dim _{S}(X)\coloneqq \frac{d \ln (S(t X))}{d \ln (t)}\bigg | _{t=1}=\frac{d S(t X)}{dt}\frac{t}{S(t X)}\bigg |_{t=1}.$

The graph in the introduction is the $E_2$-dimension of the $3000\times 16$ lattice of points in the animation plotted as we scale the set of points, i.e. it’s the graph of $dim_S(t X)$ as we vary $t$.

In practice, it seems that the magnitude, $E_{0}$ and $E_{2}$ dimensions of a given shape look very similar. They have different advantages over each over: for instance, we know, or have conjectured, closed forms for magnitudes of several shapes; but in the case of things that we don’t have a closed form for it is quicker to calculate the $0$- or $2$-spread dimension.

## Next time…

Next time I’ll give more examples. I’ll also say something about connections with Minkowski dimension, although I don’t understand the full story there.

Posted at March 11, 2015 3:25 PM UTC

TrackBack URL for this Entry:   https://golem.ph.utexas.edu/cgi-bin/MT-3.0/dxy-tb.fcgi/2813

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

If your growth rate graph width was scaled from 400 to 380, HTML layout wouldn’t create all that blank space and position it after the right side bar ends.

Posted by: RodMcGuire on March 11, 2015 4:52 PM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

Thanks Rod, I don’t actually see the problem, which is why I hadn’t fixed it!

I do usually make graphics 300pt in the introductory part because I know the problem exists – I did it for the animation but not for the graph. Hopefully it’s now fixed.

Posted by: Simon Willerton on March 11, 2015 5:30 PM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

Can one make scale dimension precise like this: for a metric space $X$ and $t\gt 0$, let $tX$ be the scaled space as in your post. Then let $C(t)$ be the smallest natural number for which there exists a short surjection from the $C(t)$-fold coproduct of $X$ to $tX$. So $C(t)$ measures how many copies of $X$ one needs in order to cover $tX$. Then if $C(t)$ grows like a power in $t$, we can define the scale dimension to be this exponent. Does this give anything reasonable? (In order for the coproduct to exist, we need to allow the metrics to assume the value $\infty$.)

On a different note, I recall having heard of scale-dependent dimensions before: as you might already know, physicists study them in the context of quantum gravity! Figure 3 on page 16 in the link shows plots of the “spectral dimension” and “walk dimension” as a function of a parameter $t$, where the direction of increasing $t$ corresponds to an exponential decrease in length scale. So roughly, their $t$ is the logarithm of yours, while your $t$ is their $k$ ;)

Posted by: Tobias Fritz on March 11, 2015 4:56 PM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

Posted by: Mark Meckes on March 11, 2015 7:27 PM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

Haha, those don’t even look so different from how some people depict quantum gravity: Posted by: Tobias Fritz on March 11, 2015 9:11 PM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

Tobias, can you calculate your candidate scale dimension for a disk?

I wasn’t familiar with quantum gravity scaling, thanks.

Posted by: Simon Willerton on March 12, 2015 10:19 AM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

Here’s a sketch of an argument showing that my candidate scale dimension is $2$ for the unit disc $D^2$. Maybe somebody knows how to make it rigorous?

Let $C(t)$ be the smallest number of unit discs needed to cover $t D^2$, where “cover” is in the sense of my definition in terms of a surjective short map. First, I claim that $C(t)$ is upper bounded by some multiple of $t^2$. To see this, we can first cover $tD^2$ by something like $\pi t^2$ unit squares aligned with the grid; at the boundary of the disc, they need to be squashed a bit in order for them to fit into $tD^2$. Second, we can cover each square by $4$ copies of $D^2$ or less. Taken together, this should give something like $C(t)\leq 4\pi t^2$ for large enough $t$.

On the other hand, I believe that the area of the image of a short map $D^2\to t D^2$ cannot exceed the area of $D^2$ itself. This should give a lower bound $C(t)\geq t^2$. Together with the upper bound, this suggests that $C(t)$ grows quadratically in $t$, so that the scale dimension of the disc is $2$.

Other examples for which it is easier to find a rigorous argument include finite metric spaces and the unit interval. For finite $X$, the dimension is zero, since any $t X$ can be covered by $|X|$ many copies of $X$: just map every copy of $X$ to a single point. Hence the corresponding $C(t)$ is bounded by $|X|$ as $t$ grows, and the dimension is zero. For the unit interval, one can make a similar argument as for the disc, but it’s much easier to make rigorous: $C(t)\leq t$ for integer $t$ follows from covering $t[0,1]=[0,t]$ by $t$ copies of $[0,1]$ in the obvious way; and $C(t)\geq t$ is also clear since the image of $[0,1]$ under a short map is again an interval of length $\leq 1$, and therefore one cannot do better than with the previous covering. In conclusion, we have $C(t)=t$ for the unit interval and integer $t$, and the interval’s scale dimension is $1$.

Posted by: Tobias Fritz on March 12, 2015 2:51 PM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

I’m confused: your definition of the $S$-dimension looks like it is defining a number, but then you say that the $E_2$ dimension of some shape is a graph or function. Do you mean that the graph is the function $t \mapsto dim_S(t X)$?

Posted by: Mike Shulman on March 11, 2015 8:46 PM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

Posted by: Simon Willerton on March 12, 2015 10:13 AM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

This is a little bit like persistent homology, c.f. Robert Ghrist’s stuff.

Posted by: Jake on March 11, 2015 9:41 PM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

It is a little like that, indeed. But what it is not clear is if there is any tangible connection.

Posted by: Simon Willerton on March 12, 2015 10:12 AM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

Jake: You should also mention Gunnar Carlsson. I also had had a thought along the same lines. It also relates to shape theory a la Borsuk (1970s) where features are studied at a range of scales. The insight from Persistant homology might be related to the change in ‘dimension’ as the scale changes, i.e. some sort of generalised ‘bar graph’ as you get in papers on Persistence. (I know Simon has thought about this.)

Posted by: Tim Porter on March 13, 2015 7:33 AM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

Hi, that’s a very compact and nice definition.

Do I understand right that in order to define size S(tX) in your 0-spread and 2-spread you simply rescale the distance function by t?

I am confused about how you apply this to fractals though… you motivated your definitions also by saying that “the Koch curve does not have a meaningfully non-trivial length”, but for your definition you need a notion of distance… is this distance not the same as a length along the curve? or you use the distance in an embedding space?

Do you know anything about a possible relation between your spreads and the spectral dimension? After all the exponential of a distance does appear also in the heat kernel. I ask because the spectral dimension is much used in quantum gravity these days…as somebody already pointed out (see for example also this one http://arxiv.org/abs/hep-th/0505113 ).

Posted by: Dario Benedetti on March 12, 2015 8:19 PM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

Dario, a quick reply for now.

You said

Do I understand right that in order to define size S(tX) in your 0-spread and 2-spread you simply rescale the distance function by t?

Yes the size $S(t X)$ is just the rescaling the distance by $t$, so for the $2$-spread we have

$E_{2}(t X)\coloneqq \frac{N^{2}}{\displaystyle\sum _{x,y\in X}e^{-t d(x,y)}}.$

is this distance not the same as a length along the curve?

The Koch curve is not rectifiable – you can’t measure the length along the curve. However, it does sit naturally in $\mathbb{R}^2$ as a compact subset and you can equip it with the subset metric where $\mathbb{R}^2$ has the usual Euclidean metric.

Finally you said

the exponential of a distance does appear also in the heat kernel

It’s actually the exponential of the square of the metric that appears in the heat kernel. This seems to make quite a difference. However, you can look at the asymptotics of the spread of a Riemannian manifold as you scale the metric and the terms in the asymptotic expansion are the same sort of curvature terms that appear in the asymptotic expansion of the heat kernel. This is mentioned in my post on spread in the section on “Non-finite metric spaces”

Posted by: Simon Willerton on March 13, 2015 11:55 AM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

Could you make a looped gif where a point expands into a line which turns out to be made of a grid of points which expand leaving just a single point…

which expands into a line hich turns out to be made of a grid of points which expand leaving just a single point…

This would be a nice illustration of a set whose dimension keeps looping from 0 to 1 to 2 as we keep zooming in. I think some people would find this exciting.

Posted by: John Baez on March 14, 2015 1:43 AM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1) One thing that seems right up your street is the formula for the $E_2$-dimension of a metric space:

$dim_{E_2}(X)=\frac{\sum_{x,y\in X} d(x,y) e^{-d(x,y)}} {\sum_{x,y\in X} e^{-d(x,y)}}.$

It looks like some sort of expected value of energy.

Posted by: Simon Willerton on March 16, 2015 10:52 AM | Permalink | Reply to this

### Re: A Scale-Dependent Notion of Dimension for Metric Spaces (Part 1)

Nice—thanks! I may post this to G+ with a link to your article here.

Yes, that formula is analogous to the expected value of a Hamiltonian, except that the analogy would be better if you had

$\frac{\sum_{x,y\in X} d(x,y) e^{-\beta d(x,y)}} {\sum_{x,y\in X} e^{-\beta d(x,y)}}.$

where $\beta$ is an adjustable parameter. In the analogy, $\beta$ would be $1/ k T$ where $T$ is temperature and $k$ is Boltzmann’s constant. $k T$ has units of energy, and this serves to make $\beta d(x,y)$ dimensionless, as you want for something that you’re taking the exponential of.

But in your actual problem, $\beta$ would be an adjustable parameter with units of inverse length. I believe a quantity of this nature appears in your work, since you’re talking about ‘scale-dependent’ quantities: $\beta$ sets the scale.

Posted by: John Baez on March 20, 2015 2:48 AM | Permalink | Reply to this