Keywords

1 Parameters of Spatial Complexity of Binary Maps

“Difference is of two kinds… the first is called a difference of number the other of kind”

(David Hume, “A treatise of human nature”, 1740)

Besides entropy class, additional parameters (not measures) of a map’s spatial complexity (aside of entropy/diversity) are its “patchiness” (P), “adjacency” (A) and “clumpiness” (B). The role of these parameters in spatial complexity has been identified earlier (Papadimitriou 2002; Papadimitriou 2009; Papadimitriou 2012).

Patchiness (P) is the number of non-adjacent (disjoint) patches of the same color dispersed over the dominant cover of the binary map (which, in the language of landscape ecology is called “the matrix”).

Adjacency (Ad) is the number of edges shared by cells of the same patch type (it refers to patches only; not to the dominant color). It is defined as the number of edges between cells of the same cover type Vi in the map:

$$A_{d} = \sum\limits_{i = 1}^{n} {\partial_{i} V_{i} }$$
(11.1)

and refers only to the cells that are defined as “colored” (not belonging to the dominant population of cells).

A typical assumption is that the more patchy a map, the more complex it is expected to be. Spatial complexity is expected to decrease if patches of the same color are clumped together and at this point enters the parameter “clumpiness”.

Clumpiness (B) is defined here to be the maximum size of the largest edge-continuous block (aggregate) of cells of the same patch type: B = max{patch size of the same color} and it is examined because clustering plays a central role in self-organization and complexity (Bormashenko et al. 2020).

As an example, consider the calculation of r, P, B, CP1 and CP2 for the three flag-like example binary maps of the same size (5 × 5), resembling the flags of three European countries, shown in Fig. 11.1. The results of the calculations are given in Table 11.1.

Fig. 11.1
figure 1

Calculating the spatial complexity on three simplified flag-like example binary 5 × 5 maps resembling the flags of three southern European countries

Table 11.1 Results of the calculations of the metrics and parameters of spatial complexity of three simplified flag-like example binary 5 × 5 maps shown in Fig. 11.1

2 The Spatial Complexity of 3 × 3 Binary Maps

“…the origin of numbers from 0 and 1, which I have observed is the most beautiful symbol of the continuous creation of things from nothing, and of their dependence on God”

(Gottfried Leibniz, 1646–1716, written on 29-3-1698.

Source:Leibniz,G. 1863, “Mathematische Schriften”

ed.C.I.Gerhardt, volume V, Berlin: A.Ascher. page 239)

Let us now return to the 3 × 3 binary maps. Of the 255 total binary 3 × 3 map configurations up to maximum entropy class, some are topologically equivalent therefore yielding the same spatial complexity (because symmetric configurations produce topologically equivalent positions of cells). Calculations of CP1 and CP2 on isomorphic binary maps yield the same results. Thus, non-isomorphic binary maps can be identified that will be called here “generic” binary maps. These are specific for each entropy class. For r = 1, 2 and 3 these are shown in Fig. 11.2 and for r = 4 are shown in Fig. 11.3.

Fig. 11.2
figure 2

Generic 3 × 3 binary maps for entropy classes r = 1,2 and 3 black cells per binary map. Numbers atop of each binary map show the multiplicity of each generic map

Fig. 11.3
figure 3

Generic 3 × 3 binary maps of all the map configurations for entropy classes with r = 4 black cells per binary map withmultiplicity of each generic configuration

With r = 6, the 3 × 3 binary maps yield the same results in calculations as the binary maps with r = 3. Equivalently, for r = 7 the results are the same as in the case of r = 2. For this reason, the calculations are carried out only up to r = (n-1)/2, that is up to r = 4. Consequently, CP1 and CP2 are calculated for all 3 × 3 generic maps, up to maximum entropy class, as shown in Table 11.2.

Table 11.2 There are 49 generic binary maps of size 3 × 3 coresponding to 255 possible configurations in total

The average CP1 per entropy class r (for all entropy classes) can be described by the following cubic formula (Fig. 11.4):

Fig. 11.4
figure 4

CP1 complexity per individual entropy classes ri

$$\begin{aligned} C_{P1} & = 2.0 3 1 2 9+ 2. 3 1 2 2 6r - 0. 3 9 2 8 5 7r^{ 2} + 0.0 3 4 1 6 6 7r^{ 3} \\ & \quad \left( {{\text{corr}}.{\text{coeff}}. = 0. 9 9 6} \right). \\ \end{aligned}$$
(11.2)

Notice that the rate of increase of spatial complexity decreases with increasing entropy class.

The number of map configurations per CP1 complexity value (Fig. 11.5) can be modeled by a polynomial:

Fig. 11.5
figure 5

The number of 3 × 3 binary map configurations per CP1 value (up to maximum entropy class)

$$\begin{aligned} N_{{C_{P1} }} & = 512.143 - 434.091C_{P1} + 104.857C_{P1}^{2} - 6.19444C_{P1}^{3} \\ & \quad \left( {{\text{corr}}.{\text{coeff}}. = 0. 9 6 9} \right) \\ \end{aligned}$$
(11.3)

This function shows that it is more likely to encounter average and high CP1 values in 3 × 3 binary maps than lower complexity values.

The average CP2 per entropy class r is given by the following model (Fig. 11.6):

Fig. 11.6
figure 6

The CP2 complexity per individual entropy classes ri is given by a cubic relationship

$$\begin{aligned} C_{P2} & = 0.0 1 9 2 8 5 7 { } + { 2}. 5 5 5 6r + 0. 1 2 2 1 4 3r^{ 2} - \, 0. 10 4 1 6 7r^{ 3} \\ & \quad \left( {{\text{with}}\,{\text{correlation}}\,{\text{coefficient}} = 0. 9 9 8 9} \right), \\ \end{aligned}$$
(11.4)

while an approximation to the number of 3 × 3 binary maps NCP2= f(CP2) per CP2 value (Fig. 11.7) can be described by the model (corr.coeff. 0.86):

Fig. 11.7
figure 7

The number of 3 × 3 binary map configurations per CP2 value (up to maximum entropy class)

$$N_{{C_{P2} }} = 0.585859 - 7.31866C_{P2} + 6.64358C_{P2}^{2} - 0.658249C_{P2}^{3}$$
(11.5)

3 Patchiness, Adjacency and Clumpiness

“Nature is Harlequin’s cloak made entirely of solid patches and empty spaces; she is made of plenitude of void, beings and nonbeings, with one of the two posing itself as unlimited while limiting the other”

(Gilles Deleuze, 2012, p. 304)

The relationships of CP1 with patchiness P and clumpiness B are shown in Fig. 11.8 and the selected formulas best fitting the values of CP1 for both P are (corr.coeff. 0.996):

Fig. 11.8
figure 8

CP1—complexity with respect to patchiness P and clumpiness B in 3 × 3 binary maps

$$C_{P1} = 2.16082e^{0.558367P}$$
(11.6)

and for B:

$$\begin{aligned} C_{P1} & = 1.99101 + 1.4249B + 1.20611B^{2} - 0.37946B^{3} \\ & \quad \left( {{\text{with corr}}.{\text{coeff}}.0. 9 9 7} \right) \\ \end{aligned}$$
(11.7)

Thus high clumpiness and high patchiness are both associated with high CP1 complexity.

The relationships best fitting the values of CP2 with P and B classes respectively are both polynomial (Fig. 11.9):

Fig. 11.9
figure 9

Spatial complexity CP2 with respect to patchiness (P) and clumpiness (B) in 3 × 3 binary maps

$$\begin{aligned} C_{P2} & = - 0.00053822 + 2.50646P + 0.175495P^{2} - 0.00625255P^{3} \\ & \quad \left( {{\text{corr}}.{\text{coeff}}. \, 0. 9 9 5} \right) \\ \end{aligned}$$
(11.8)

and

$$\it \it \begin{aligned} C_{P2} & = 1.97166 - 2.55623P + 4.97499P^{2} - 1.30259P^{3} \\ & \quad \left( {{\text{corr}}.{\text{coeff}}. \, 0. 9 5 9} \right) \\ \end{aligned}$$
(11.9)

Further, the values of can be best described by polynomial models also (Fig. 11.10):

$$\begin{aligned} P & = 0.00247143 + 1.12461r - 0.131214r^{2} - 0.00575r^{3} \\ & \quad {\text{with}}\,{\text{corr}}.{\text{coeff}}.0. 9 9 9 9, \\ \end{aligned}$$
(11.10)
$$\begin{aligned} B & = 0.0197429 + 1.25588r - 0.425429r^{2} + 0.0708333r^{3} \\ & \quad {\text{with}}\,{\text{corr}}.{\text{coeff}}.0. 9 9 4\\ \end{aligned}$$
(11.11)

and

$$\begin{aligned} A_{d} & = - 0.00282857 - 0.114476r + 0.120286r^{2} - 0.00833333r^{3} \\ & \quad {\text{with corr}}.{\text{coeff}}.\, 0.9998\\ \end{aligned}$$
(11.12)
Fig. 11.10
figure 10

Patchiness (P), clumpiness (B) and adjacency (Ad) with respect to entropy class (r) in 3 × 3 binary maps

It consequently becomes apparent that patchiness, as well as clumpiness and adjacency, all increase with increasing entropy class, although patchiness shows a somewhat different behavior for the higher values of r: the maximum P (P = 2.08474) is at r = 3.486, that is at an entropy class lower than the maximum.

4 Generic 3 × 3 Binary Maps and Their Multiplicities

“You feel the hidden calculation… an elemental maze, unfathomable forest”

(Osip Mandelstam, 1891–1938, “Notre Dame”, 1912)

The percentage of generic maps with respect to the total number of possible map configurations decreases with increasing map size. For instance, in 2 × 2 binary maps, there are three generic configurations out of the ten possible configurations (hence 33% are generic maps) and in 3 × 3 binary maps there are 49 generic maps out of the 255 configurations (that is 19.2%). Furthermore, the number of generic maps Ng by entropy class decreases as the entropy class grows. A simulation model can be obtained by calculating the total number of generic map configurations per multiplicity ξ for all classes r (ξr), which is shown in Table 11.3 and defined as the sum:

Table 11.3 Numbers (Ng) of the 49 generic 3 × 3 binary maps per entropy class (r), with their respective multiplicity factors (ξr)
$$N_{g} = \sum\limits_{r = 1}^{r = 4} {\xi_{r} }$$
(11.13)

The relationship between Ng and ξ can be simulated by a polynomial function, of the form (Fig. 11.11):

Fig. 11.11
figure 11

The number of generic 3 × 3 binary maps (Ng) per multiplicity class (ξ) of generic maps, for all entropy classes r, can be described by a polynomial function

$$\begin{aligned} N_{g} & = - 9.7381 + 12.3443\xi - 1.47621\xi^{2} - 0.0466582\xi^{3} \\ & \quad \left( {{\text{correlation}}\,{\text{coefficient}}\,0. 9 4 2} \right). \\ \end{aligned}$$
(11.14)

Thus, the number of multiplicity of binary map configurations of 3 × 3 binary maps increases polymomially with the number of generic maps.

The generic maps are endowed with different topologies and so they can produce different symmetries. Spatial complexity can therefore be “tamed” by identifying topologically inequivalent configurations. This is evident, even at the simplest level of 3 × 3 maps with r = 1, where three different maps, all with the same entropy, but with different topologies, yield different spatial complexities (Fig. 11.12). If the exact generic forms are known, then a polynomial relationship (instead of an exponential model of allocations which would be expected from the formula 2n–1−1 = 255) suffices to produce all the 255 − 49 = 206 non-generic map configurations. This means that identifying generic forms is equivalent to focusing on a number of possible configurations at a scale of reduction which is important: a reduction from exponential to polynomial growth. And this reduction is only possible thanks to the identification of symmetric map configurations that can be produced by the generic maps.

Fig. 11.12
figure 12

Generic configurations of three simple 3 × 3 binary maps. In the case of map a, the colored cell has only 2 neighboring cells (one east, one south), in the case of b it has 3 (east, west, south) and in c it has 4 (all four directions)

Yet, spatial complexity depends on border effects and this dependence is more significant for smaller maps. The boundaries between cells can range from 2 to 3 or 4, depending on the location of the cell in the map (cells located at the border areas of a square map have 2 or 3 boundaries, while those located at the map’s central areas have four boundaries).

With the number of cells of a square map with two, three or four boundaries (Fig. 11.13) symbolized respectively as \(\partial_{2} ,\partial_{3} ,\partial_{4}\), the border cells \(\partial_{2} ,\partial_{3}\) and the central cells assume the following values (where n is the total number of cells of the square map):

Fig. 11.13
figure 13

There are three topological types of square cells according to the number of boundaries they share with their neighbouring cells. As the map size n increases, the number of 4-boundary cells increases at the expense of the other types of cells

$$\begin{array}{*{20}c} {\partial_{2} = 4} \\ {\partial_{3} = 4\sqrt n - 8} \\ {\partial_{4} = (\sqrt n - 2)^{2} } \\ \end{array}$$
(11.15)

Consequently, it is easy to verify that the larger the map size, the more insignificant the number of outer border cells becomes in comparison to the inner cells:

$$\mathop {\lim }\limits_{n \to \infty } \left( {\frac{{\partial_{2} + \partial_{3} }}{{\partial_{4} }}} \right) = \mathop {\lim }\limits_{n \to \infty } \left( {\frac{4\sqrt n - 4}{n + 4 - 4\sqrt n }} \right) = 0$$
(11.16)

In fact, only maps larger than 7 × 7 are essentially free from the effects of border cells: \(\partial_{4} - \partial_{3} > 0\) \(\forall n > 49\).

Thus, border cells affect the topology and therefore the spatial complexity of small maps, much more importantly than the spatial complexity of large maps.

It is however interesting to notice that 3 × 3 are the smallest square maps for which any other cells are more numerous than the four corner cells: \(\partial_{3} - \partial_{2} > 0\) \(\forall n > 9\)

Hence, assessments of spatial complexity on the basis of 3 × 3 binary maps can be made, although, for safer estimates, the analysis should be made on square domains at least 7 × 7 large.

Various ecological observations have confirmed correlations between increased “diversity” and “habitat complexity”; a notion which entails spatial complexity and functional complexity (Dean and Connell 1987; Poggio et al. 2010; Keith et al. 2006). Besides ecology, complexity correlates with “diversity” in various fields: in materials science (Gleitzer 1980), neurosciences (Blaustein and Golovina 2001), biochemistry (Okazaki et al. 1998) etc. Interestingly, from an ecological study in Switzerland (Lischke 2005), empirical observations showed that spatial complexity was high when the first species colonized the region, when, at the fronts of the Picea abies immigrations, “spots of increased diversity appeared” (Lischke 2005, p. 159). Thus, “invading species” in an ecosystem (or, equivalently, “invading” black cells in a binary map), regardless of their particular location in the map or how few they may be, immediately create a substantial difference in the map’s spatial complexity. As shown from the present study, even a slight introduction of “alterity” or “otherness” (that is dark cells) in a binary map induces a high increase in spatial complexity. This might be anticipated, although it could not have been verified without a complete complexity characterization of 3 × 3 binary maps. In fact, in both CP1 and CP2, the highest rate of increase in spatial complexity takes place in between the entropy classes 0 and 1, therefore suggesting that some entropy classes (the lower ones) are endowed with more “dynamism” to “produce” spatial complexity than others (Fig. 11.14).

Fig. 11.14
figure 14

The rate of increase in spatial complexity increases rapidly for both CP1 and CP2 as the entropy class rises from 0 to 1 and then decreases with higher entropy class

Yet, although the maximum average CP1 is at r = 4, the maximum of the average CP2 is attained (approximately) at the entropy class r = 3 (not at r = 4). Thus, the change of CP2 with entropy indicates that maximum spatial complexity may occur in between minimum and average entropy. The range of values that the metric CP2 yields for 3 × 3 binary maps conforms with the anticipated variations of complexity in “between order and chaos”, or “between order and randomness”, as complexity (not spatial complexity) is thought to be by many researchers, although with a somewhat different expression here: spatial complexity maximizes in between minimum and maximum entropy. There is a strong cross-disciplinary need for methods to calculate and compare the spatial complexities of two-dimensional images, maps, pictures, landscapes and other 2d representations and surfaces. This aim can not be satisfied without having a measure to compare spatial complexity with. For this reason it was necessary to calculate all the expected possible spatial complexity values for all possible binary spatial configurations. In the present case, this requirement was met at the level of 3 × 3 maps. Evidently, if larger than 3 × 3 binary maps were used, the results might differ. Although this may seem obvious, it has to be considered that we are still short of a formula that would enable us to estimate the spatial complexity of all the i.e. 36,493 configurations that would be required to calculate for the 4 × 4 binary maps (let alone for larger maps).

5 Spatial Analysis at “King’s Neighborhood”

The Pythagoreans decorated with meanings the numbers and the shapes of Gods

“Oἱ δὲ Πυθαγόρειοι καὶ ἀριθμοὺς

καὶ σχήματα θεῶν ἐκόσμησαν προσηγορίαις”

(Plutarch, 46-119 a.D., “De Iside et Osiride”, 381f)

Square arrangements keep puzzling scientists and artists for their geometric simplicity, which, in the digital era, carry some of the most complex information structures, such as big data of satellite imagery, GIS maps, and all forms of large geospatial databases, which are some of the most complex kind of observational data ever collected by humans.

More than twenty centuries ago, Pythagoras discovered the immense power of squares, by revealing that three squares can always be imagined to correspond  to each side of a triangle. Seen from this perspective, he essentially proved that the simplest of all spatial forms, the triangle, is intimately related to squares. The Pythagoreans claimed that the number 3 is the most important of all numbers and attributed to the triad a central role in the cosmos, because it summarizes the triplet beginning-middle-end. In praise of the number nine, the neoplatonic philosopher Plotin wrote his famous “Enneads” and, centuries earlier, according to Hesiod’s “Theogony” there were 9 days and nights separating the sky from the earth. The Pythagoreans were particularly inclined to study figurative numbers.Take, for instance, the tetraktys (τετρακτύς). It would be difficult not to observe that the sacred symbol of the Pythagoreans conceals a small (3 × 3 may be?) map (Fig. 11.15). Tetraktys formed the basis of the Pythagorean oath, but quaternities were not uncommon in philosophy and theology throughout the ages, with most widely known among them the “quadrivium” in Neoplatonic epistemology: a sign converting point data to area is an important (inherent?) process of human perception.

Fig. 11.15
figure 15

Tetraktys (left) formed the basis of the Pythagorean oath. The ten points might as well be perceived as defining a 3 × 3 map (right)

Simple 3 × 3 maps have been used by humans for planning the geographical space since the antiquity, while archaeological evidence suggests that the 3 × 3 game tic-tac-toe was played in many places all over the world. Probably invented in ancient Egypt, we now know that, as deceivingly “simple” as it looks, it can nevertheless be played in 9! = 362,880 different ways.

Two millennia ago, well-fields in ancient China applied a management scheme called “jing-tian-zhi” (well-land-system), consisting in 3 × 3 square fields with a communal area in the middle, surrounded by eight ownerships. Delving into some classic old chinese texts can be rewarding in ideas about the central role of the square number 9 in spatial analysis (3 × 3 squares). A legendary planner and geometer of ancient China, “Yu the Great”, measured nine mountains, nine rivers, nine marshes and arranged the lands to be cultivated within such areas. The “Yugong” (the book of the tribute to Yu) describes how Yu marked out the nine provinces of China. Characteristically, the classic Chinese text “The Tribute of Yu” (禹贡) reads as follows in the beginning: “Yu marked the nine provinces. Then, the hills, increased the rivers’ depth; defined the borders of the land”. The master plan for spatial divisions, the “Hong Fan” (洪 範) allegedly described the division in nine regions (“ch’eou”), and was brought to Yu by a turtle. The 3 × 3 arrangement had the central cell at the center and eight surrounding cells defining the 8 trigrams of the “Book of Changes”, the “I-Ching”, nine defined the shape of the royal residence (the “Ming T’ang”), and, as a matter of fact, was also the defining number for royal ceremonies in China. The Taoist ceremonies also have a base of nine, as those of the Mayas and the Aztecs. And, for Christians, it is the simplest square map that can host the shape of a cross.

As it turns out, 3 × 3 neighbourhoods are fundamental for the arts also, given the old and well known method of aesthetic appreciation that is called “rule of thirds”. This practical rule was first named so by John Thomas Smith in his book “Remarks on Rural Scenery”, quoting the work of Sir Joshua Reynolds (1783), discussing the balance of dark and light in a painting. Although not a mathematically proven rule, it is nevertheless a “rule of thumb” for evaluating and appreciating the emotional and artistic power emitted to the viewer by paintings, images, photographs, sceneries. The rule suggests the subdivision of a picture on the basis of a 3 × 3 grid, in order to determine the location in the grid so as to highlight what is more important in the entire scenery. The rule of thirds suggests that placing the picture’s most important element along the thirds lines (or close to their intersections) produces always a higher aesthetic impact than if it were placed anywhere else in the picture. Empirical observations also show that a much more powerful impression impact is conveyed to a spectator if the prominent figure of the image (the form of a human, a tree, a house etc.) is not located at the central square of the 3 × 3 grid, but in the area of the “thirds” instead (Fig. 11.16).

Fig. 11.16
figure 16

The “rule of thirds”. Locating the key feature of a painting on the intersection of the lines of thirds lines on the lower left part of the image creates a higher visual impact (that is makes the image more “interesting”) than if it were located at the centre of the image

Given these, it is expected that 3 × 3 maps would have not escaped the attention of visual artists. Kazimir Malevich painted (1915) his “Black Cross”: a simple black cross formed by joining the five central cells of a 3 × 3 black-and-white map. Similarly, Ad Reinhardt (1913–1967) painted uniformly black pictures, i.e. his “Abstract Painting” (1963) is essentially a grid of 3 × 3 black squares. Sol Le Witt painted (1967) his “Serial Plan”, a work of conceptual art created by using 3 × 3 squares. Clearly, these are only few representative examples among countless other ones in art, but what is more important is that 3 × 3 neighborhoods are a key to unlock the secrets of spatial complexity of small square binary maps.