# VII Problems with Measuring

The box-counting method is the most frequently used method for calculating the fractal dimension of images and plans throughout this paper - see chapter "4.2.3 Box-Counting Dimension 'Db'". Hence it is necessary to sum up the various problems that may arise by using it - e.g. caused by the dependence of fractal dimension upon the quality and preparation of the image, the sizes of the biggest and smallest boxes used - that is the definition of the upper and lower scale for measurement - and the starting position of the boxes in relation to the image.

## 7.1 The Size and the Quality of an Image

First of all it is necessary to remember that the image or the plan of which the fractal dimension is finally calculated only represents a simplification of the real object, e.g. of the front of a building. In this connection plans of smaller scales generally display more details of the building than those of bigger ones. This is quite similar to the distance of the observer to the real object: if one stands far away, something can be hardly recognized, except one uses a pair of glasses - compare picture 28. Getting closer, which means increasing the scale of the plan, the details become visible - certain details can only be identified from a certain distance or scale on. Thus translating an object into a plan first of all means to define the distance- or the scale-range - with the aid of the biggest and smallest recognizable detail. Using box-sizes beyond this range, in connection with the measurement of the fractal dimension by the box-counting method, this leads to falsified results - no additional details of the real object, the building, are included into the calculation because the plan does not contain them.

Looking at the Koch curve and other mathematical fractals this would mean that, depending upon the distance they are observed from, the number of iterations can be defined. E.g. from far away maybe only the first three iterations will be distinguishable, and all iterations from then on do not seem to change the image any more. Up to a certain scale the calculated box-counting dimension will give some conclusion on the fractal dimension of the real object. But then, if too small boxes are used for measurement, that is the scale-range of observation remains too low, the image will quickly turn out to be a one-dimensional line. From then on no additional details can be picked up because the image does not contain them - the length of this curve is limited in contrast to the real Koch curve.

Some other influences represent the quality of the image itself, which may be translated into the language of the computer by the number of pixels per inch - high or low definition. "Quality" also means how many details are getting lost only because of the preparation of the plan - by scanning and after-treatment - and not because of the distance, that is scale. Then the interpretation of the wall of floor plans, whether they are painted black, white or grey, influences the results of the measurement. But also the contents of the plan changes the fractal dimension: elevations may also display the environment - natural or built one -, floor plans may contain tiles on terraces and/or sanitary fixtures and other equipment - some closer look at this theme can be found at picture 81. Such differentiations are taken into consideration when analyzing house types in chapter "9Statistics". In general images that represent elevations and floor plans of buildings have to be similar in the way they pick up details, in their quality and in their scale if they should be compared with each other.

picture 81: Comparison of different starting parameters

The box-counting dimension of ground plans used in the following, taken from "Edoardo Gellner, Alte Bauernhäuser in den Dolomiten" by Edoardo Gellner, are measured with the computer-program "Fractal Dimension Calculator" written by Paul Bourke - these results can be compared with the measurement "by hand", which means that a grid is drawn on the image and the boxes are counted by hand, as presented in pictures 83 and 84. The graph below compares the fractal dimension of six different ground plans with different starting parameters. The graph is divided into two lines, a chain dotted and a broken one, which stands for two different types of plans. The first one contains the fractal dimension of the floor plans for images that are scanned with "300 ppi", which means that they mostly offer the "original", total information. The second type, the broken line, represents the same floor plans but with a definition factor of "72 ppi". As the graph shows, the second line is in general lower than the chain dotted one. Finally the three points indicate the fractal dimension of the ground plans with the walls being painted black.

There are some typical problems when computing the fractal dimensions of ground plans:
1. Definition factor of scanning: With a scanning definition factor of "72 ppi" the image loses very much of its original information. The resulting dimensions are much lower than the measured dimensions of the same house with a scanning definition factor of "300 ppi". In the case of the house-parts in Fornesighe - examples 1 and 5 - and Foppa - example 3 - the fractal dimensions range from 1.08 to 1.15 - broken line, columns 1, 3 and 5 -, while those of a definition factor of "300ppi" range between 1.32 and 1.41 - chain dotted line of the same columns. Looking at the results of the complete ground plans of three farmhouses in Fornesighe - examples 2 and 6 - and Foppa - example4 - the same phenomenon can be identified: the dimensions of the "72 ppi" images range from 1.38 and 1.42 - broken line, columns 2, 4 and 6 -, while those of the "300 ppi"-image can be found between 1.53 and 1.57. If I maintain that a "72 ppi"-image offers less information than a "300 ppi"-image, I proceed from the same total sizes in centimeters with different definition factors.

2. Information: The plans of the house parts in Foppa and Fornesighe offer less information, which means that they are much smoother than the complete plans of the farmhouses. Therefore the fractal dimensions are lower than those of the more complex total plans. Looking at the complete floor plans, example 2 in Fornesighe has the lowest dimension - 1.53 at "300 ppi". The fractal dimension of example 4 in Foppa is 1.56 and that of example 6 in Fornesighe 1.57, which is not much higher. Though the plans are different in their characteristics they offer some similarities: they are not rectangular, they are somehow irregular and they seem to have grown "naturally" - not planned at once -, which is mainly true for the last example.

3. Different qualities: Whether or not the walls are defined as additional information, they remain white or they are painted black. If walls are interpreted as hidden parts of the house, they are excluded from measuring, which means that they are kept white, empty areas: that may be interpreted that way that because of their invisibility they cannot offer additional information. Otherwise they may be seen as important parts of the house and therefore not only the surface is included in measurement, but the whole mass - black, filled walls. In case of room plans there is a greater difference between white and black walls: the walls painted black result in a dimension of 1.40 to 1.47 - the dimensions of the white ones lying between 1.32 to 1.40. But there is less influence on the complete plans, that is because of the complexity of the whole image: "Db" of the 6th example of the "300 ppi"-image = 1.57 and "Db" of "black wall" = 1.59.

a single room of the farmhouse "FO5" in Fornesighe:
Db for "72 ppi"-image=1.08; Db for "300 ppi"-image=1.32; Db for "walls black"-image=1.45

farmhouse "FO5" in Fornesighe:
Db for "72 ppi"-image=1.42; Db for "300 ppi"-image=1.53

a single room of the farmhouse "FZ10" in Foppa:
Db for "72 ppi"-image=1.137; Db for "300 ppi"-image=1.40

farmhouse "FZ10" in Foppa:
Db for "72 ppi"= 1.38; Db for "300 ppi" = 1.56

a single room of the farmhouse "FO6" in Fornesighe:
Db for "72 ppi"-image=1.15; Db for "300 ppi"-image=1.408; Db for "walls black"-image=1.47

farmhouse 4 in Fornesighe "FO6"
Db for "72 ppi"-image=1.42; Db for "300 ppi"-image=1.57; Db for "walls black"-image=1.59

## 7.2 The Range of Box-Size

The absolute smallest possible box-size that can be used for calculating programs represents one pixel, as a resolution limit of the computer and of the digital image respectively. But in general too small box-sizes would mean that every difference caused by the preparation for the computer is also taken into consideration. In consequence the thickness of a line of the image should represent the absolute lowest limit size for the box-counting method. That means if the scale range we are looking at is between one and two pixels and the line is three pixels wide, the dimension of this line on the lower scale increases approaching two, though a line is one dimensional in Euclidean sense. This and the fact that below this scale no more details can be picked up, are the reason why the lowest box-size should be bigger than the thickness of the lines - see pictures 82.

picture 82: Measurement problems – rectangles and squares

The box-counting dimension of a square: At every stage of the box counting method all boxes are turned black, because all boxes contain a part of the figure. Therefore the square turns out to be a two-dimensional object no matter from what distance that is scale we are looking at it.

 square - 100X100 units stage unity size 1/s log 1/s "N" pieces log(N) dimension 1 s(1)= 2 0.301 N(1)= 4 0.602 D 2 s(2)= 4 0.602 N(2)= 16 1.204 D(s1-s2)= 2.000 3 s(3)= 8 0.903 N(3)= 64 1.806 D(s2-s3)= 2.000 4 s(4)= 16 1.204 N(4)= 256 2.408 D(s3-s4)= 2.000 5 s(5)= 32 1.505 N(5)= 1024 3.010 D(s4-s5)= 2.000 6 s(6)= 64 1.806 N(5)= 4096 3.612 D(s5-s6)= 2.000 D(slope without first stage)= 2.000

The box-counting dimension of a rectangle and a "line" respectively: The border of the object - square or rectangle - is identical with the borders of the boxes of the box counting method. That means in other words that the size of the object is a multiple of the size of the boxes, which is the reason why the results are unequivocal to such a high degree - the fractal dimensions are given in the graphs below.

 rectangle - 100X50 units stage unity size 1/s log 1/s "N" pieces log(N) dimension 1 s(1)= 2 0.301 N(1)= 4 0.602 D 2 s(2)= 4 0.602 N(2)= 8 0.903 D(s1-s2)= 1.000 3 s(3)= 8 0.903 N(3)= 32 1.505 D(s2-s3)= 2.000 4 s(4)= 16 1.204 N(4)= 128 2.107 D(s3-s4)= 2.000 5 s(5)= 32 1.505 N(5)= 512 2.709 D(s4-s5)= 2.000 6 s(6)= 64 1.806 N(5)= 2048 3.311 D(s5-s6)= 2.000 D(slope without first stage)= 2.000
 rectangle - 100X25 units stage unity size 1/s log 1/s "N" pieces log(N) dimension 1 s(1)= 2 0.301 N(1)= 4 0.602 D 2 s(2)= 4 0.602 N(2)= 8 0.903 D(s1-s2)= 1.000 3 s(3)= 8 0.903 N(3)= 16 1.204 D(s2-s3)= 1.000 4 s(4)= 16 1.204 N(4)= 32 1.505 D(s3-s4)= 1.000 5 s(5)= 32 1.505 N(5)= 128 2.107 D(s4-s5)= 2.000 6 s(6)= 64 1.806 N(5)= 512 2.709 D(s5-s6)= 2.000 D(slope without first stage)= 1.500

The box-counting dimension of a square - with a different starting position: At the 3rd stage the square has a low fractal dimension of about 1.81 and only then in the smaller box-sizes this dimension increases again approaching the value two - e.g. at the 6th stage Db=2.00. In other words, only for the smaller box-sizes, i.e. for bigger scales, the results of the measurement correspond with the assumption that a square is a two-dimensional object.

 square - 100X100 units - different starting points stage unity size 1/s log 1/s "N" pieces log(N) dimension 1 s(1)= 2 0.301 N(1)= 4 0.602 D 2 s(2)= 4 0.602 N(2)= 16 1.204 D(s1-s2)= 2.000 3 s(3)= 8 0.903 N(3)= 56 1.748 D(s2-s3)= 1.807 4 s(4)= 16 1.204 N(4)= 211 2.324 D(s3-s4)= 1.911 5 s(5)= 32 1.505 N(5)= 756 2.879 D(s4-s5)= 1.811 6 s(6)= 64 1.806 N(5)= 3022 3.480 D(s5-s6)= 1.999 D(slope without first stage)= 1.888

The box-counting dimension of a rectangle and a "line" respectively - with a different starting position: The borders of the objects - square or rectangle - are not identical with the lines of the grid of the box counting method. When the grid becomes more detailed the fractal dimension of the square increases again approaching two. Though the figures are identical with those from the page before, there are differences in measurement only because of the relative position of the boxes.

 rectangle - 100X50 units - different starting points stage unity size 1/s log 1/s "N" pieces log(N) dimension 1 s(1)= 2 0.301 N(1)= 4 0.602 D 2 s(2)= 4 0.602 N(2)= 12 1.079 D(s1-s2)= 1.585 3 s(3)= 8 0.903 N(3)= 35 1.544 D(s2-s3)= 1.544 4 s(4)= 16 1.204 N(4)= 112 2.049 D(s3-s4)= 1.678 5 s(5)= 32 1.505 N(5)= 378 2.577 D(s4-s5)= 1.755 6 s(6)= 64 1.806 N(5)= 1512 3.180 D(s5-s6)= 2.000 D(slope without first stage)= 1.739
 rectangle - 100X25 units - different starting points stage unity size 1/s log 1/s "N" pieces log(N) dimension 1 s(1)= 2 0.301 N(1)= 4 0.602 D 2 s(2)= 4 0.602 N(2)= 8 0.903 D(s1-s2)= 1.000 3 s(3)= 8 0.903 N(3)= 21 1.322 D(s2-s3)= 1.392 4 s(4)= 16 1.204 N(4)= 56 1.748 D(s3-s4)= 1.415 5 s(5)= 32 1.505 N(5)= 216 2.334 D(s4-s5)= 1.948 6 s(6)= 64 1.806 N(5)= 810 2.908 D(s5-s6)= 1.907 D(slope without first stage)= 1.669

The box-counting dimension of the border of a square and a rectangle respectively: In this case the examples are the same images and boxes as before, but this time we are only looking at the outlines of the squares and the rectangles. The results show us that this time the dimensions decrease and come close to the value of one. This means that the figure is close to a one-dimensional object. In the Euclidean sense this is true because the outline of a square is a line.

 square - 100X100 units - outlines stage unity size 1/s log 1/s "N" pieces log(N) dimension 1 s(1)= 2 0.301 N(1)= 4 0.602 D 2 s(2)= 4 0.602 N(2)= 12 1.204 D(s1-s2)= 1.585 3 s(3)= 8 0.903 N(3)= 24 1.806 D(s2-s3)= 1.000 4 s(4)= 16 1.204 N(4)= 60 2.408 D(s3-s4)= 1.322 5 s(5)= 32 1.505 N(5)= 124 3.010 D(s4-s5)= 1.047 6 s(6)= 64 1.806 N(5)= 252 3.612 D(s5-s6)= 1.023 D(slope without first stage)= 1.115 rectangle - 100X50 units - outlines stage unity size 1/s log 1/s "N" pieces log(N) dimension 1 s(1)= 2 0.301 N(1)= 4 0.602 D 2 s(2)= 4 0.602 N(2)= 8 0.903 D(s1-s2)= 1.000 3 s(3)= 8 0.903 N(3)= 20 1.301 D(s2-s3)= 1.322 4 s(4)= 16 1.204 N(4)= 44 1.643 D(s3-s4)= 1.138 5 s(5)= 32 1.505 N(5)= 92 1.964 D(s4-s5)= 1.064 6 s(6)= 64 1.806 N(5)= 188 2.274 D(s5-s6)= 1.031 D(slope without first stage)= 1.131 rectangle - 100X50 units - outlines stage unity size 1/s log 1/s "N" pieces log(N) dimension 1 s(1)= 2 0.301 N(1)= 4 0.602 D 2 s(2)= 4 0.602 N(2)= 8 0.903 D(s1-s2)= 1.000 3 s(3)= 8 0.903 N(3)= 16 1.204 D(s2-s3)= 1.000 4 s(4)= 16 1.204 N(4)= 32 1.505 D(s3-s4)= 1.000 5 s(5)= 32 1.505 N(5)= 68 1.833 D(s4-s5)= 1.087 6 s(6)= 64 1.806 N(5)= 140 2.146 D(s5-s6)= 1.042 D(slope without first stage)= 1.035

The other extreme, the biggest box-size, can be as large as the image itself. But this extreme can be eliminated, because when counting the number of occupied boxes at this stage, it does not make any difference whether there is only one black pixel or many, the result is always one. Only some stages later, decreasing the box sizes, the difference between one pixel and many will be recognized by a low fractal dimension for the first and a higher one for the latter case. So often the first, biggest, box-sizes are excluded from the measurement.

The box-sizes in between the two extremes, the smallest and largest box-size, should generally decrease by the factor two from scale to scale. So the outer borders of the measurement-grid remains the same, and by that the relative position from one box-size to the previous one.

## 7.3 Starting Points

There is more than one possible starting-position for the boxes to be laid over the image. E.g. the left bottom corner of the box may be identical with the left bottom corner of the image. But it is also possible to start three pixels left and two pixels down of the corner of the image. In this connection pixels are used because most measurements of this paper were made with the computer and so the lower limit of resolution is one pixel. Thus if the box-size is only one pixel then the starting point has only one possible position on the bottom left side and each box of this grid is exactly one dot of the image. Whereas if the box-size is 2 by 2 pixels, four possible random origins are possible: first all four pixels are situated on the image - the left lower pixel of the box is identical with the left lower pixel of the image -, secondly only one pixel is located on the image - the origin of the box is one pixel below and one left of the image -, thirdly the lower half of the box is outside the image and fourthly the left half sticks out. If the box-sizes increase, there are of course even more possibilities for the position of the starting point of the box - see picture 83.

picture 83: Starting position of the boxes

The relative position of the starting box to the image has some influence on the results of the fractal dimension. The same is true for the size of the first box. On the following two pages I have changed these starting values for two of the previous examples.

A single room of the farmhouse "FO6" in Fornesighe: If the relative position of the boxes and their size do not change, the number of boxes at the basis is not important, that means that the "white" area around the image can be small or big - the results are the same.

 a single room of "FO6" - 300dpi stage unity size 1/s log 1/s "N" pieces log(N) dimension 1 s(1)= 3 0.477 N(1)= 9 0.954 D 2 s(2)= 6 0.778 N(2)= 18 1.255 D(s1-s2)= 1.000 3 s(3)= 12 1.079 N(3)= 53 1.724 D(s2-s3)= 1.558 4 s(4)= 24 1.380 N(4)= 140 2.146 D(s3-s4)= 1.401 5 s(5)= 48 1.681 N(5)= 325 2.512 D(s4-s5)= 1.215 D(slope)= 1.331

farmhouse "FO6" in Fornesighe: In the picture below the position of the building and boxes respectively have changed in relation to the measurement of the "300 ppi"-image, shown at the bottom. In both cases the fractal dimensions from the 3rd stage onwards are nevertheless quite similar.

 the ground plan of "FO6" - 300dpi stage unity size 1/s log 1/s "N" pieces log(N) dimension 1 s(1)= 4 0.602 N(1)= 20 1.301 D 2 s(2)= 8 0.903 N(2)= 72 1.857 D(s1-s2)= 1.848 3 s(3)= 16 1.204 N(3)= 234 2.369 D(s2-s3)= 1.700 4 s(4)= 32 1.505 N(4)= 737 2.867 D(s3-s4)= 1.655 5 s(5)= 64 1.806 N(5)= 1985 3.298 D(s4-s5)= 1.429 D(slope)= 1.662
 the ground plan of "FO6" - 300dpi; changed grid size stage unity size 1/s log 1/s "N" pieces log(N) dimension 1 s(1)= 6 0.778 N(1)= 30 1.477 D 2 s(2)= 12 1.079 N(2)= 88 1.944 D(s1-s2)= 1.553 3 s(3)= 24 1.380 N(3)= 282 2.450 D(s2-s3)= 1.680 4 s(4)= 48 1.681 N(4)= 869 2.939 D(s3-s4)= 1.624 5 s(5)= 96 1.982 N(5)= 2260 3.354 D(s4-s5)= 1.379 D(slope)= 1.577

How do computer-programs manage such problems - see picture 84? E.g. the computer program "Benoit" starts with a defined side-length of the largest box. The user can change this starting size, but usually this is given by one-fourth of the width or height of the image. Beside that he can also define the decreasing coefficient of the box-size. To minimize the error deriving from the box-sizes and starting positions, the program defines a certain increment of grid rotation - the grid rotates with a certain angle. For each grid-position - rotation - the occupied boxes are counted. The computer-program then calculates the minimum number of boxes occupied by the image for each box-size - following from that it does not matter whether the boxes exceed the image or not.

picture 84: Measurement programs

For better comparison, it is important to use the same measuring-program, because different programs may lead to different values of fractal dimensions - the differences mainly derive from the starting positions of the boxes. I have measured some of the floor plans of picture 81 by hand and then with the computer program "Benoit" - the results are given in the chart below.

a single room of the farmhouse "FO5" in Fornesighe
"300 ppi"-image; "72 ppi"-image; "black wall"-image

results: farmhouses.pdf

## 7.4 The Slope of the log-log Graph

The slope of the log(N(s))-log(1/s) graph defines the fractal dimension of the object, which is getting more exact, the more results - N(s) versus 1/s - are available. Points of the graph that are situated beside this slope - line - may indicate that first the image of observation is not a fractal, secondly the box-sizes are defined as too big or too small, thirdly the image-quality is bad or fourthly as mentioned in the previous chapter the image is multifractal. In the analysis of house-types of chapter "9 Statistics" this circumstance is brought in by the position of the points of the graph in relation to the slope: the results are called "very smooth" - the points are congruent with the slope -, "smooth" - indicating minimal deviation -, "diverging" or "strongly diverging". The last two cases are excluded from measurement because it is not clear whether elevations are multifractal or if the deviation results from the influences as described before, like bad quality, wrong preparation and so on.

## 7.5 Programs

The measurement of the fractal dimension of one and the same image with different computer-programs may lead to different results - if the same image with the same quality and size is run through different programs, this will offer the differences in computing-adjustments. Some of the differences of the programs are given in picture 84 where I have used different computer-programs - "Fractal Dimension Calculator" and "Benoit" - for the same calculations. In comparison and for better understanding I have also measured the box-counting dimensions of some images by hand.
The instruction of the "Fractal Dimension Calculator" by Paul Bourke compares some images of known fractals with the results of the dimensions calculated by his program. Thus the Koch Island has a measured fractal dimension of 1.5, while the box-counting dimension is 1.53 - the difference between these two results is 1.8%. The Koch "Coastline" has a measured fractal dimension of 1.262 and a box-counting dimension of 1.22, the difference being 3.6%. In the first case of the Koch Island the slope and the curve of the points of the log-log graph are quite congruent, while the curve of the Koch "Coastline" differs a little bit from the straight unit-line. For a Euclidean line the measured dimension is 0.994 instead of 1, so there is a deviation of only 0.6%.

## Footnotes

 "Benoit version 1.2" TruSoft Int'l, Inc. - Copyright (C) 1997, 1999; User manual.
 http://www.mhri.edu.au/~pdb/fractals/fractdim (15.04.1999); User manual for a mac program.

### FLÄVIZ

Studie zur Visualisierung von Planänderungen des Flächenwidmungs- und Bebauungsplanes: Änderungen im Flächenwidmungs- und Bebauungsplan sind für die Betroffenen, d.h. die Anrainer, aber auch für die Entscheidungsträger oft schwer zu lesen. [...]

### FRACAM

This is a non commercial web application created by Wolfgang E. Lorenz and Gabriel Wurzer. It is used for education and research purposes only! The application can be used and is provided "as is" without warranty of any kind! [...]

### Halloween pumpkin

Some Pumpkin Carving Ideas for Halloween (2014-2020) [...]

M-DAB - Towards re-using material resources of the city
Talk and Proceeding: eCAADe 2020 - Anthropologic – Architecture and Fabrication in the cognitive age (Berlin, Germany, 2020 | virtual conference)
presentation (video)