Coding Example: Minkowski-Bouligand Dimension
This problem is an extension of the previous case study. In this lesson, we'll learn how to find the fractal dimension of the Mandelbrot set.
We'll cover the following
Note: You should look at the ufunc.reduceat method that performs a (local) reduce with specified slices over a single axis.
Problem Description
We now want to measure the fractal dimension of the Mandelbrot set using the Minkowski–Bouligand dimension. To do that, we need to do box-counting with a decreasing box size (see figure below). As you can imagine, we cannot use pure Python because it would be way too slow. The goal of the exercise is to write a function using NumPy that takes a two-dimensional float array and returns the fractal dimension. We’ll consider values in the array to be normalized (i.e. all values are between 0 and 1).
Given below is the Minkowski-Bouligand dimension: