www.biomathforum.org/biomath/index.php/biomath ORIGINAL ARTICLE Which Matrices Show Perfect Nestedness or the Absence of Nestedness? An Analytical Study on the Performance of NODF and WNODF N. F. Britton∗, M. Almeida Neto †, Gilberto Corso ‡ ∗Department of Mathematical Sciences and Centre for Mathematical Biology University of Bath, Bath BA2 7AY, UK. Email: n.f.britton@bath.ac.uk †Departmento de Ecologia, Universidade Federal de Goiás, 74001-970 Goiânia-GO, Brazil, Email: marioeco@gmail.com ‡Departamento de Biofı́sica e Farmacologia, Centro de Biociências, Universidade Federal do Rio Grande do Norte, 59072-970 Natal-RN, Brazil, Email: corso@cb.ufrn.br Received: 25 April 2015, accepted: 17 December 2015, published: 16 January 2016 Abstract—Nestedness is a concept employed to describe a particular pattern of organization in species interaction networks and in site-by-species incidence matrices. Currently the most widely used nestedness index is the NODF (Nestedness metric based on Overlap and Decreasing Fill), initially presented for binary data and later extended to quantitative data, WNODF. In this manuscript we present a rigorous formulation of this index for both cases, NODF and WNODF. In addition, we characterize the matrices corresponding to the two extreme cases, (W)NODF=1 and (W)NODF=0, rep- resenting a perfectly nested pattern and the absence of nestedness respectively. After permutations of rows and columns if necessary, the perfectly nested pattern is a full triangular matrix, which must of course be square, with additional inequalities between the elements for WNODF. On the other hand there are many patterns characterized by the total absence of nestedness. Indeed, any binary ma- trix (whether square or rectangular) with uniform row and column sums (or marginals) satisfies this condition: the chessboard and a pattern reflecting an underlying annular ecological gradient, which we shall call gradient-like, are symmetrical or nearly symmetrical examples from this class. Keywords-biogeography, interaction networks, nestedness, bipartite networks I. INTRODUCTION Observing nature is one of the most fascinating experiences in life. A honeybee visits a daisy, a rosemary, and other ten different species. Another bee of the same family is specialized in just one flower that by its turn is visited by twenty diverse pollinators. Once we put together the community of pollinators and flowers an intricate mutualist network arises [5]. In the opposite side of life a caterpillar feed on two asteraceae species which are eaten by another couple of insects, the full set of herbivorous and plants forms a complex antagonist network. An central quest in ecology Citation: N. F. Britton, M. Almeida Neto, Gilberto Corso, Which Matrices Show Perfect Nestedness or the Absence of Nestedness? An Analytical Study on the Performance of NODF and WNODF, Biomath 4 (2015), 1512171, http://dx.doi.org/10.11145/j.biomath.2015.12.171 Page 1 of 9 http://www.biomathforum.org/biomath/index.php/biomath http://dx.doi.org/10.11145/j.biomath.2015.12.171 N. F. Britton et al., Which Matrices Show Perfect Nestedness or the Absence of Nestedness ... of communities today is the search for patterns in networks that can distinguish between mutualist and antagonist webs [13, 21]. One network pattern that is part of this answer is nestedness, the subject of this manuscript. Nestedness is a concept used in ecology to study a specific formation pattern in species interaction networks and in site-by-species incidence matri- ces. In general terms, nestedness is a specific kind of topological organization in adjacency matrices of bipartite networks where any vertex S, with m links, tend to be connected to a subset of the vertices connected to any other vertex with n links, where n > m. The nestedness concept was first introduced by [8] to characterize species distribution pattern in a spatial set of isolated habitats such as islands. In a perfectly nested pattern site-by-site incidence matrix there is a hierarchy of sites such that the set of species inhabiting any site is a subset of the set inhabiting any site further up the hierarchy. When applied to describe the topological organization in ecological interaction networks this new nestedness concept was first used to networks formed by pollinators and flowering plants and by seed dispersers and flesh-fruited plants [4, 12]. In cases a network is perfectly nested if (i) there is a hierarchy of plant species such that the set of animal (pollinator or seed disperser) species interacting with any plant is a subset of the set of animals interacting with any plant further up the hierarchy, and (ii) there is a similar hierarchy of animals. It is clear that in such a network generalist species interact with specialists and generalists, but specialists do not interact with each other. The proper mathematical framework for intro- ducing nestedness is in the context of bipartite networks. From a general perspective we consider a bipartite network formed by two sets S1 and S2. Nestedness is characterized by several indices [22, 18] and it is not the objective of this work to compare them. Here we focus on the NODF index, which has a clear mathematical definition that allows further analytic developments. The NODF index, an acronym for Nestedness metric based on Overlap and Decreasing Fill, is an index that was introduced in [2] and that has been widely used in the literature. An extension of this index to quantitative networks, WNODF , was recently proposed [3], and we include it in our analysis because of the importance of quantitative networks, specially for networks of interacting species [9, 13]. Null models are an important methodological tool widely used in ecology to test model fitting, perform statistical tests or test the validity of indices and measures [10]. In order to assess an index a large set of empirical or artificial data is used as a data bank to explore its limitations and fragility. This process has already been used to test a set of nestedness indices [22]. Null models are necessary because statistical tests are otherwise always questionable by limitation in the range of tested parameters, interpretation bias of the results, or equivocal choice of random models. These studies emphasis the necessity of analytic results to strength confidence about nestedness indices and their applications. The original definition of the NODF index depends on how the rows and columns are ordered, and a frequently used software for calculating NODF explicitly asks the user if they would like to order the matrix according to row and column sums (or marginals) [11]. In this paper we employ a definition of (W)NODF in which the matrix is previously sorted before the computation of the index. In this paper we give rigorous definitions of NODF and WNODF and prove two mathemat- ical theorems in each case. For the sake of clarity, and for historical reasons, we explore separately qualitative (binary) and quantitative (weighted) networks. The treatment of the qualitative case is more intuitive and helps the reader to follow the analytic developments. In section 2 we start with a formal definition of NODF and WNODF and present two theorems that characterize the extreme cases, NODF = 0 and WNODF = 0 corresponding to absence of nestedness, and NODF = 1 and WNODF = 1 corresponding Biomath 4 (2015), 1512171, http://dx.doi.org/10.11145/j.biomath.2015.12.171 Page 2 of 9 http://dx.doi.org/10.11145/j.biomath.2015.12.171 N. F. Britton et al., Which Matrices Show Perfect Nestedness or the Absence of Nestedness ... to the perfectly nested arrangement. In section 3 we summarize the main ideas of the work and put the results in a broader context. II. ANALYTIC TREATMENT We shall consider a bipartite network of set S1, containing m elements, and set S2, containing n elements, with quantitative data for the frequency wij of the interactions between element i of set S1 and element j of set S2. In the simplest case wi,j is equal to 1 or 0, a situation corresponding to the binary network, qualitative network or pres- ence/absence matrix. The adjacency matrix for the network is the m×n matrix A = (aij), where aij is defined by: aij =   1 if wij 6= 0, so that element i of S1 and element j of S2 are linked 0 if wij = 0, so that they are not linked. (1) We define the row and column marginal totals MT ri and MT c l by MT ri = n∑ j=1 aij and MT c l = m∑ k=1 akl, (2) so that MT ri is the number of elements of S2 interacting with element i of S1, and MT cl is the number of elements of S1 interacting with element l of S2. Define the row and column decreasing-fill indicators DF rij and DF c kl by DF rij = { 1 if MT ri > MT r j , 0 if MT ri ≤ MT r j , (3) DF ckl = { 1 if MT ck > MT c l , 0 if MT ck ≤ MT c l . (4) Note that, if i < j, so that row i is above row j, then DF rij = 1 if and only if element i of set S1 is linked with more elements of set S2 than element j of S1; similarly, if k < l, so that column k is to the left of column l, then DF ckl = 1 if and only if element k of S2 is linked with more elements of set S1 than element l of S2. It is always possible to permute the rows and columns of the matrix so that MT ri ≥ MT r j whenever i < j, and MT c k ≥ MT r l whenever k < l, but the definition does not require this to be done. A. Qualitative matrices, the case NODF In order to define NODF we start with the row paired-overlap quantifier POrij as the fraction of unit elements in row j that are matched by unit elements in row i, and the column paired-overlap quantifier POckl as the fraction of unit elements in column l that are matched by unit elements in row k, so that POrij = ∑n p=1 aipajp∑n p=1 ajp , POckl = ∑n q=1 akqalq∑n q=1 alq . (5) Note that POrij is the fraction of elements of S2 linked to element j of S1 that are also linked to element i of S1, and similarly for POckl. Define the row paired nestedness NP rij between rows i and j, and the column paired nestedness NP ckl between columns k and l, by NP rij = DF r ijPO r ij + DF r jiPO r ji, (6) NP ckl = DF c klPO c kl + DF c lkPO c lk. (7) Note that these definitions are valid whatever the signs of MT ri −MT r j and MT c k −MT c l . Finally, define the row and column nestedness metrics NODF r and NODF c by NODF r = ∑m i=1 ∑m j=i+1 NP r ij 1 2 m(m−1) , (8) NODF c = ∑n k=1 ∑n l=k+1 NP c kl 1 2 n(n−1) , (9) and the overall nestedness metric NODF as a weighted average of these, by NODF = m∑ i=1 m∑ j=i+1 NP rij + n∑ k=1 n∑ l=k+1 NP ckl 1 2 m(m−1) + 1 2 n(n−1) . (10) Biomath 4 (2015), 1512171, http://dx.doi.org/10.11145/j.biomath.2015.12.171 Page 3 of 9 http://dx.doi.org/10.11145/j.biomath.2015.12.171 N. F. Britton et al., Which Matrices Show Perfect Nestedness or the Absence of Nestedness ... 1) Conditions for NODF = 0: Our objective is to characterize all matrices for which NODF = 0. It is clear that NODF = 0 if and only if both NODF r = 0 and NODF c = 0, so let us first consider the conditions for which NODF r = 0. This is true if and only if NP rij = 0 for all pairs (i, j) of rows. From equation (6), NP rij = 0 if and only if either MT ri = MT r j , so that DF rij = DF r ji = 0, or ∑n p=1 aipajp = 0, so that POrij = PO r ji = 0. In other words, either rows i and j have the same number of unit elements, so that elements i and j of S1 interact with the same number of elements of S2, or there is no p in S2 that interacts with both i and j. If our bipartite network is connected, then it is possible to move from any i in S1 to any other j in S1 by following a path composed of edges of the network from S1 to S2 to S1 and so on. Hence, in this connected case, NODF r = 0 if and only if all elements of S1 are linked to the same number of elements of S2. Similarly, for a connected network, NODF c = 0 if and only if all elements of S2 are linked to the same number of elements of S1, and NODF = 0 if and only if both these conditions hold. If our network is disconnected, then NODF = 0 if and only if all elements of S1 are linked to the same number of elements of S2, and all elements of S2 are linked to the same number of elements of S1 within each connected component, or compartment. This is a necessary and sufficient condition for NODF = 0. There are many networks that satisfy this condition. For example in figure 1 we show a 9×6 network where each of the nine elements of S1 interact with a dif- ferent pair of elements of S2, so that each element of S2 interacts with three elements of S1. Figure 1(c) does not resemble any of the NODF = 0 configurations exhibited in the literature [4, 15], which are all (including the chessboard after row and column permutation) compartmented with full connectivity within the compartments. Case 1(d) seems to reflect an underlying cyclic ecological gradient [15], and we call it gradient-like. The requirement that the gradient be cyclic is manifest in the occupied cell at the bottom left of the matrix, and it is occupied to fulfil the rule that there should be two nonzero elements in each row and three in each column. It is interesting that the dimensions (m, n) of the adjacency matrix obey a constraint in the NODF = 0 case. The total number of matrix elements that is distributed along columns and rows should follow the relation: n∑ i=1 MT ci = m∑ j=1 MT rj . (11) As MT ci and MT r j are constants we can rewrite 11 in the form nMT c = mMT r. 2) Conditions for NODF = 1: We now wish to characterize all matrices for which NODF = 1, see figure 2. It is clear that NODF = 1 if and only if both NODF r = 1 and NODF c = 1, so let us first consider the conditions under which NODF r = 1. This is true if and only if NP rij = 1 for all pairs (i, j) of rows. From equation (6), NP rij = 1 implies that MT r i 6= MT r j , so that either DF rij = 1 or DF r ji = 1. If there are more elements of S2 interacting with element i in S1 than with j in S1, then MT ri > MT r j , so that DF rij = 1, DF r ji = 0. Then we also require that∑n p=1 aipajp = ∑n p=1 ajp, so that PO r ij = 1, in other words that aip = 1 whenever ajp = 1. Thus all elements of S2 interacting with element j in S1 also interact with element i in S1, or the set of elements of S2 interacting with j in S1 is nested within (or a proper subset of) the set of elements of S2 interacting with i in S1 . Similarly, if there are more elements of S2 interacting with j in S1 than with i in S1, then the set of elements of S2 interacting with i in S1 must be nested within the set of elements of S2 interacting with j in S1. Similar results hold for NODF c = 1, so that the set of elements of S1 interacting with any k in S2 must be a proper subset or superset of the set of S1 elements interacting with any other l in S2. For NODF = 1, all (S1 and S2) interaction sets must be proper sub- or supersets, so that by the pigeon- hole principle we must have m = n, and it must be possible to permute the rows and columns of the matrix A so that aij = 1 if i ≥ j, aij = 0 otherwise. The matrix with NODF = 1 is the Biomath 4 (2015), 1512171, http://dx.doi.org/10.11145/j.biomath.2015.12.171 Page 4 of 9 http://dx.doi.org/10.11145/j.biomath.2015.12.171 N. F. Britton et al., Which Matrices Show Perfect Nestedness or the Absence of Nestedness ... Fig. 1: Some NODF = 0 patterns. Panels (a) and (b) represent the same matrix after permutation of lines and columns; this non-chessboard tiling is a composition of three disconnected networks. Panels (c) and (d) show two connected networks that have NODF = 0, since MT ci = 3 and MT r j = 2 for all i and j respectively. Case (d) represents a gradient-like structure. Biomath 4 (2015), 1512171, http://dx.doi.org/10.11145/j.biomath.2015.12.171 Page 5 of 9 http://dx.doi.org/10.11145/j.biomath.2015.12.171 N. F. Britton et al., Which Matrices Show Perfect Nestedness or the Absence of Nestedness ... full triangular matrix, unique up to permutation of rows and columns. B. Quantitative matrix, the case WNODF To construct the WNODF index we define the row-pair dominance quantifier Drij as the fraction of non-zero weights in row j that are dominated by (less than) the corresponding weight in row i, and the column-pair dominance quantifier Dckl as the fraction of non-zero weights in column l that are dominated by the corresponding weight in column k, so that Drij = ∑n p=1 H(wip −wjp)H(wjp) MT rj , (12) Dckl = ∑m q=1 H(wqk −wql)H(wql) MT cl , (13) where H is the Heaviside step function with H(0) = 0. Note that Drij is the fraction of elements of S2 interacting with j in S1 that interact more strongly with i in S1, and similarly for Dckl. Note that, when calculating NODF for qualitative networks, the quantity corresponding to Drij is the row-pair overlap quantifier POrij which is the fraction of elements of S2 interacting with j in S1 that also interact with i in S1, and similarly for Dckl; the requirement that the interaction be stronger is not (and cannot be) applied. This is the essential difference between the index WNODF for quantitative networks and the index NODF for qualitative ones. Now define the row-pair dominance nestedness between rows i and j, and the column-pair dominance nestedness between columns k and l, by DNrij = DF r ijD r ij + DF r jiD r ji, (14) DNckl = DF c klD c kl + DF c lkD c lk. (15) Note that these definitions are valid whatever the signs of MT ri −MT r j and MT c k −MT c l . For example, (i) if MT ri > MT r j then DF r ij = 1 and DF rji = 0, so DN r ij = D r ij, (ii) if MT r i < MT r j then DF rij = 0 and DF r ji = 1, so DN r ij = D r ji, and (iii) if MT ri = MT r j then DF r ij = DF r ji = 0, and DNrij = 0. Finally, define the row and column weighted nestedness metrics WNODF r and WNODF c by WNODF r = ∑m i=1 ∑m j=1 DN r ij m(m−1) , (16) WNODF c = ∑n k=1 ∑n l=1 DN c kl n(n−1) , (17) and the overall weighted nestedness metric WNODF as a weighted average of these, by WNODF = m∑ i=1 m∑ j=1 DNrij + n∑ k=1 n∑ l=1 DNckl m(m−1) + n(n−1) . 1) Conditions for WNODF = 0: The treat- ment of WNODF = 0 shares some similarities with the previous analysis of NODF = 0. To characterize all matrices for which WNODF = 0 we proceed as follows. It is clear that WNODF = 0 if and only if both WNODF r = 0 and WNODF c = 0, so let us first consider the conditions for which WNODF r = 0. This is true if and only if DNrij = 0 for all pairs (i, j) of rows. From equation (14), DNrij = 0 if and only if either (i) MT ri = MT r j , so that DF rij = DF r ji = 0, or (ii) MT r i > MT r j and ∑n p=1 H(wip − wjp)H(wjp) = 0, so that Drij = DF r ji = 0, or (iii) MT r i < MT r j and∑n p=1 H(wjp − wip)H(wip) = 0, so that D r ji = DF rij = 0. In case (i), the elements i and j of S1 interact with the same number of S2 elements. In case (ii), i in S1 interacts with more elements of S2 than does j in S1, but any interaction between j and any element p of S2 is at least as strong as the corresponding interaction between i and p. Although i in S1 strictly dominates j in S1 in terms of the number of its interactions, j in S1 (not necessarily strictly) dominates i in S1 in terms of the strength of the interactions it does have. Case Biomath 4 (2015), 1512171, http://dx.doi.org/10.11145/j.biomath.2015.12.171 Page 6 of 9 http://dx.doi.org/10.11145/j.biomath.2015.12.171 N. F. Britton et al., Which Matrices Show Perfect Nestedness or the Absence of Nestedness ... Fig. 2: The maximal nestedness pattern exemplified for qualitative (a) and quantitative (b) cases. In the second situation the weight of the link between species is indicated by grey tones. (iii) is analogous, with i and j interchanged. There are many possible ways to obtain WNODF r = 0, and similarly WNODF c = 0 and WNODF = 0. In particular any connected bipartite network in which all elements of S1 interact with the same number of elements of S2, and all elements of S2 interact with the same number of elements of S1, has WNODF = 0, as does any network in which each element of W is either 0 or 1. Note that WNODF is not a continuous function of the elements of W ; for example, if W is a 2 × 2 matrix with w11 = 1 + ε, w12 = w21 = 1, w22 = 0, then WNODF(W) = 0 if ε = 0 but WNODF(W) = 1 if ε is positive, however small it is. C. Conditions for WNODF = 1 We now wish to characterize all matrices for which WNODF = 1, see figure 2. This demon- stration has some points in common with the case NODF = 1. It is clear that WNODF = 1 if and only if both WNODF r = 1 and WNODF c = 1, so let us first consider the conditions under which WNODF r = 1. This is true if and only if DNrij = 1 for all pairs (i, j) of rows. From equa- tion (15), DNrij = 1 implies that MT r i 6= MT r j , so that either DF rij = 1 or DF r ji = 1. If there are more elements of S2 interacting with i in S1 than with j in S1, then MT ri > MT r j , and DF rij = 1, DF r ji = 0. Then we also require that ∑n p=1 H(wip − wjp)H(wjp) = MT r j , so that Drij = 1, in other words that wip ≥ wjp whenever wjp 6= 0. Thus all elements of S2 interacting with j in S1 not only interact with i in S1, but interact more strongly with i than with j. The set of elements of S2 interacting with j in S1 not only has to be nested within (or a proper subset of) the set of S2 elements interacting with i in S1, but all the interactions with i in S1 must be stronger than the corresponding interaction with j in S1. Similarly, if there are more S2 elements interacting with j in S1 than with i in S1, then the set of S2 elements interacting with i in S1 must be nested within the set of S2 elements interacting with j in S1, and each interaction with j in S1 must be stronger than the corresponding interaction with i in S1. Similar results hold for WNODF c = 1, so that the set of elements of S1 interacting with any k in S2 must be a proper subset or superset of the set of S1 elements interacting with any other l in S2, corresponding interactions in subsets must be weaker, and corresponding interactions in supersets stronger. For WNODF = 1, all (S1 and S2) interaction sets must be proper sub- or supersets, so that by the pigeon-hole principle we must have m = n, and it must be possible to Biomath 4 (2015), 1512171, http://dx.doi.org/10.11145/j.biomath.2015.12.171 Page 7 of 9 http://dx.doi.org/10.11145/j.biomath.2015.12.171 N. F. Britton et al., Which Matrices Show Perfect Nestedness or the Absence of Nestedness ... permute the rows and columns of the matrix W so that wij > 0 if i + j ≤ n + 1, wij = 0 otherwise. Any matrix with WNODF = 1 has the same adjacency matrix, up to permutation of rows and columns, and also satisfies the row and column strict dominance properties wik > wjk for all i < j whenever wjk > 0, wki > wkj for all i < j whenever wkj > 0. III. FINAL REMARKS This work focuses on probably the most com- monly used nestedness index: the Nestedness met- ric based on Overlap and Decreasing Fill. Initially we introduce a rigorous formulation for NODF and WNODF . We then elucidate the patterns of maximal and minimal nestedness, (W)NODF = 1 and (W)NODF = 0. The maximal nestedness pattern is already known in the literature [15, 2], but an understanding of the minimum nestedness pattern is substantially extended in this work. The literature usually presents the chessboard pattern as the prototype of the zero nestedness arrange- ment; but this work shows that there is in fact a large class of matrices that fulfil this condition. We cite the completely compartmented networks with equal modules (of which the chessboard is a special case) and gradient-like matrices. But there is another class of non-symmetrical matrices that also have zero nestedness as long as the row and column sums of the adjacency matrix are uniform. The theoretical discussion about nestedness to- day resembles the debate around diversity and its measurements [14, 16, 17]. In both cases the com- munity of ecologists is aware of the importance of the concept in understanding and quantifying patterns in ecological processes. In both contexts, also, there is a dynamic debate about the true meaning of the concepts, and the most adequate way to transform them into an index [1, 18, 20]. Intriguingly, the comparison between diversity and nestedness is not just a curiosity in the story of theoretical ecology, but also a challenging aspect of theory itself, because beta diversity and nested- ness show common similarities and dissimilarities [6, 19]. We hope that this rigorous work that highlight the nestedeness of (W)NODF will contribute to the discussion about the general meaning of nest- edness by clarifying the extreme cases: zero and maximal nestedness. The basics of the mathemat- ical framework presented here is flexible enough to encourage further developments using alterna- tive pairwise nestedness indices. Despite the large number of nestedness indices, there are few ana- lytic results relating the properties of a nestedness index and the characteristics of the corresponding adjacent matrix; an exception is [7]. With the exact results shown in this manuscript we add new elements to the debate about the real meaning of nestedness and the best way to measure it. Acknowledgements Financial support to Gilberto Corso from CNPq (Conselho Nacional de Desenvolvimento Cientı́fico e Tecnológico) is acknowledged. REFERENCES [1] M. Almeida-Neto, D. M. B. Frensel, and W. Ulrich. Rethinking the relatioship be- tween nestedness and beta diversity: a com- ment on Baselga(2010). Global Ecology and Biogeography, 21:772–777, 2012. [2] M. Almeida-Neto, P.R. Guimarães, P. R. Guimarães Jr, R. D. Loyola, and W. Ulrich. A consistent metric for nestedness analysis in ecological systems: reconciling concept and measurement. Oikos, 117:1227, 2008. [3] M. Almeida-Neto and W. Ulrich. A straight- forward computational approach for measur- ing nestedness using quantitative matrices. Enviromental Modeling & Software, 26:1713, 2011. [4] J. Bascompte, P. Jordano, C. J. Melián, and J. M. Olesen. The nested assembly of plant- animal mutualistic networks. Proc. Natl Acad. Sci USA, 100:9383, 2003. [5] Jordi BAscompte and Pedro Jordano. Mutu- alistic Networks. Princeton University Press, 2013. [6] A. Baselga. Partitioning the turnover and nestedness components of beta diversity. Biomath 4 (2015), 1512171, http://dx.doi.org/10.11145/j.biomath.2015.12.171 Page 8 of 9 http://dx.doi.org/10.11145/j.biomath.2015.12.171 N. F. Britton et al., Which Matrices Show Perfect Nestedness or the Absence of Nestedness ... Global Ecology and Biogeography, 19:134– 143, 2010. [7] G. Corso, A. L. de Araujo, and A. M. de Almeida. Connectivity and nestedness in bipartite networks from community ecol- ogy. Journal of Physics: Conference Series, 285:012009, 2011. [8] J. P. Darlington. Zoogeography: the geo- graphical distribution of animals. Wiley, 1957. [9] Luis J. Gilarranz, Juan M. Pastor, and Javier Galeano. The architecture of weighted mu- tualistic networks. Oikos, 121:1154, 2011. [10] N. J. Gotelli and G.R. Graves. Null models in ecology. Smithsonian Institution Press, Washington, D.C., 1996. [11] P. R. Guimarães Jr. and P. Guimarães. Im- proving the analyses of nestedness for large sets of matrices. Environmental Modeling & Software, 21:1512, 2007. [12] P. R. Guimarães Jr., V. Rico-Gray, S. F. dos Reis, and J. N. Thompson. Asymmetries in specialisation in ant–plant mutualistic net- works. Proc. R. Soc B, 273:2041, 2006. [13] T. C. Ings, J. M. Montoya, J. Bascompte, N. Bluthgen, L. Brown, C. F. Dormann, F. Edwards, D. Figueroa, U. Jacob, J. I. Jones, R. B. Lauridsen, M. E. Ledger, H. M. Lewis, J. M. Olesen, F.J. Frank van Veen, P. H. Warren, and G. Woodward. Ecological networks - beyond food webs. Journal of Animal Ecology, 78:253, 2009. [14] L. Jost. Entropy and diversity. Oikos, 113:363–375, 2006. [15] T. M. Lewinsohn, P. I. Prado, P. Jordano, J. Bascompte, and J. M. Olesen. Structure in plant-animal interaction assemblages. Oikos, 113:174, 2006. [16] A. E. Magurran. Measuring Biological Diversity. Blackwell Publishing Company, 2004. [17] O. Parkash and A. K. Thukral. Statistical measures as measures of diversity. Inter- national Journal of Biomathematics, 3:173, 2010. [18] J. Podani and D. Schmera. A comparative evaluation of pairwise nestedness measures. Ecography, 35:1, 2012. [19] D. Schmera and J. Podani. Comments on sep- arating components of beta diversity. Com- munity Ecology, 12:153–160, 2011. [20] P. P. A. Staniczenko, J. C. Kopp, and S. Allesina. The ghost of nestedness in eco- logical networks. Nature communications, 4:1391, 2013. [21] E. Thébault and C. Fontaine. Stability of ecological communities and the architecture of mutualistic and trophic networks. Science, 329:853, 2010. [22] W. Ulrich, M. Almeida-Neto, and N. J. Gotelli. A consumer’s guide to nestedness analysis. Oikos, 118:3, 2009. Biomath 4 (2015), 1512171, http://dx.doi.org/10.11145/j.biomath.2015.12.171 Page 9 of 9 http://dx.doi.org/10.11145/j.biomath.2015.12.171 Introduction Analytic treatment Qualitative matrices, the case NODF Conditions for NODF = 0 Conditions for NODF = 1 Quantitative matrix, the case WNODF Conditions for WNODF = 0 Conditions for WNODF = 1 Final Remarks