Community Detection in Networks using Graph Distance

Sharmodeep Bhattacharyya, Peter J. Bickel

Introduction

The study of networks has received increased attention recently not only from the social sciences and statistics but also from physicists, computer scientists and mathematicians. With the information boom, a huge number of network data sets have come into prominence. In biology - gene transcription networks, protein-protein interaction network, in social media - Facebook, Twitter, Linkedin networks, information networks arising in connection with text mining, technological networks such as the Internet, ecological and epidemiological networks and many others have appeared. Although the study of networks has a long history in physics, social sciences and mathematics literature and informal methods of analysis have arisen in many fields of application, statistical inference on network models as opposed to descriptive statistics, empirical modeling and some Bayesian approaches has not been addressed extensively in the literature. A mathematical and systematic study of statistical inference on network models has only started in recent years.

One of the fundamental questions in analysis of such data is detecting and modeling community structure within the network. A lot of algorithmic approaches to community detection have been proposed, particularly in the physics and computer science literature . In terms of community detection, there are two different goals that researchers have tried to pursue -

Algorithmic Goal: Identify the community each vertex of the network belongs to.

Theoretical Goal: If the network is generated by an underlying generative model, then, what is the probability of success for the algorithm.

Several popular algorithms for community detection have been proposed in physics, computer science and statistics literature. Most of these algorithms show decent performance in community detection for selected real-world and simulated networks and have polynomial time complexity. We shall briefly mention some of these algorithms.

Modularity maximizing methods . One of the most popular method of community detection. The problem is NP hard but spectral relaxations of polynomial complexity exist .

Spectral clustering based methods , . These methods are also very popular. Most of the time these methods have linear or polynomial running times. Mostly shown to work for dense graphs only.

Profile likelihood maximization . The problem is NP hard, but heuristic algorithms have been proposed, which have good performance for dense graphs.

MCMC based likelihood maximization by Gibbs Sampling, the cavity method and belief propagation based on stochastic block model.

Variational Likelihood Maximization based on stochastic block model , . Polynomial running time but appears to work only for dense graphs.

Pseudo-likelihood Maximization . Fast method which works well for both dense and sparse graphs. But the method is not fully justified.

Mixed Membership Block Model . Iterative method and works for dense graphs. The algorithm for this model is based on variational approximation of the maximum likelihood estimation.

Degree-corrected block model : Incorporates degree inhomogeneity in the model. Algorithms based on maximum likelihood and profile likelihood estimation has been developed.

Overlapping stochastic block model : Stochastic block model where each vertex can lie within more than one community. The algorithm for this model is based on variational approximation of the maximum likelihood estimation.

Mixed configurations model : Another extension to degree-corrected stochastic block model, where, the model is a mixture of configurations model (degree-corrected block model with one block) and each vertex can lie in more than one community. The algorithm for this model is based on the EM algorithm and maximum likelihood estimation.

2 Theoretical Goal

The stochastic block model (SBM) is perhaps the most commonly used and best studied model for community detection. An SBM with QQ blocks states that each node belongs to a community c=(c1,…,cn)∈{1,…,Q}\boldsymbol{c}=(c_{1},\ldots,c_{n})\in\{1,\ldots,Q\} which are drawn independently from the multinomial distribution with parameter π=(π1,…,πQ)\boldsymbol{\pi}=(\pi_{1},\ldots,\pi_{Q}), where πi>0\pi_{i}>0 for all ii, and QQ is the number of communities, assumed known. Conditional on the labels, the edge variables AijA_{ij} for i<ji<j are independent Bernoulli variables with

where P=[Pab]P=[P_{ab}] and K=[Kab]K=[K_{ab}] are Q×QQ\times Q symmetric matrix. PP can be considered the connection probability matrix, where as KK is the kernel matrix for the connection. So, we have Pab≤1P_{ab}\leq 1 for all a,b=1,…,Qa,b=1,\ldots,Q, P1≤1P\mathbf{1}\leq\mathbf{1} and 1TP≤1\mathbf{1}^{T}P\leq\mathbf{1} element-wise. The network is undirected, so Aji=AijA_{ji}=A_{ij}, and Aii=0A_{ii}=0 (no self-loops). The problem of community detection is then to infer the node labels c\boldsymbol{c} from AA. Thus we are not really interested in estimation or inference on parameters π\boldsymbol{\pi} and PP, but, rather we are interested in estimating c\boldsymbol{c}. But, it does not mean the two problems are mutually exclusive. In reality, the inferential problem and the community detection problem are quite interlinked.

The theoretical results of community detection for stochastic block models can be divided into 3 different regimes -

All of the above mentioned algorithms perform satisfactorily on regime (a).

None of the above algorithms have been shown to have near perfect probability of success under either regime (b) or (c), for the full parameter space. Some algorithms like are shown to partially work in the sparse setting. Some very recent algorithms include .

In this paper, we shall only concentrate on stochastic block models. In the future, we shall try to extend our method and results for more general models.

3 Contributions and Outline of the Chapter

Our algorithm is based on graph distance between vertices of the graph. We perform spectral clustering based on the graph distance matrix of the graph. By looking at the graph distance matrix instead of adjacency matrix for spectral clustering increases the performance of the community detection, as the normalized distance between cluster centers increases when we go from the adjacency matrix to the graph distance matrix. This helps in community detection even for sparse matrices. We only show theoretical results for stochastic block models. The theoretical proofs are quite intricate and involve careful coupling of the stochastic block model with multi-type branching process to find asymptotic distribution of the typical graph distances. Then, a careful analysis of the eigenvector of the asymptotic graph distance matrix reveals the existence of separation needed for spectral clustering to succeed. This method of analysis has been used for spectral clustering analysis using the adjacency matrix also , but the analysis is simpler.

The rest of the paper is organized as follows. We give a summary of the preliminary results needed in Section 2. We present the algorithms in Section 3. We give an outline of proof of theoretical guarantee of performance of the method and then the details in Section 4. The numerical performance of the methods is demonstrated on a range of simulated networks and on some real world networks in Section 5. Section 6 concludes with discussion, and the Appendix contains some additional technical results.

Preliminaries

Let us suppose that we have a random graph GnG_{n} as the data. Let V(Gn)={vi,…,vn}V(G_{n})=\{v_{i},\ldots,v_{n}\} denote the vertices of GnG_{n} and E(Gn)={e1,…,em}E(G_{n})=\{e_{1},\ldots,e_{m}\} denote the edges of GnG_{n}. So, the number of vertices in GnG_{n} is ∣V(Gn)∣=n|V(G_{n})|=n and number of edges of GnG_{n} is ∣E(Gn)∣=m|E(G_{n})|=m. Let the adjacency matrix of GnG_{n} be denoted by An×nA_{n\times n}. For the sake of notational simplicity, from here onwards we shall denote GnG_{n} by GG having nn vertices unless specifically mentioned. We consider the nn vertices of GG are clustered into QQ different communities with each community having size nan_{a}, a=1,…,Qa=1,\dots,Q and ∑ana=n\sum_{a}n_{a}=n. In this paper, we are interested in the problem of vertex community identification or graph partitioning. That means that we are interested in finding which of the QQ different community each vertex of GG belongs to. However, the problem is an unsupervised learning problem. So, we assume that the data is coming from an underlying model and we try to verify how good ‘our’ community detection method works for that model.

As a model for community detection, we consider the stochastic block model. We shall define the stochastic block model shortly, but, we first we shall introduce some more general models, of which stochastic block model is a special case.

The general non-parametric model, as described in Bickel, Chen and Levina (2011) , that generates the random data network GG can be defined by the following equation -

where, w(u,v)≥0w(u,v)\geq 0, symmetric, 0≤u,v≤10\leq u,v\leq 1, ρn→0\rho_{n}\rightarrow 0. For block models, the latent variable for each vertex (ξ1,…,ξn)(\xi_{1},\ldots,\xi_{n}) can be considered to be coming from a discrete and finite set. Then, each element of that set can be considered to be inducing a partition in the vertex set V(Gn)V(G_{n}). Thus, we get a model for vertex partitioning, where, the set of vertices can be partitioned into finite number of disjoint classes, but however the partition to which each vertex belongs to is the latent variable in the model and thus unknown. The main goal becomes estimating this latent variable.

1.2 Inhomogeneous Random Graph Model

The inhomogeneous random graph model (IRGM) was introduced in Bollobás et. al. (2007) . Let S\mathcal{S} be a separable metric space equipped with a Borel probability measure μ\mu. For most cases S=(0,1]\mathcal{S}=(0,1] with μ\mu Lebesgue measure, that means a U(0,1)U(0,1) distribution. The “kernel” κ\kappa will be a symmetric non-negative function on S×S\mathcal{S}\times\mathcal{S}. For each nn we have a deterministic or random sequence x=(x1,…,xn)\boldsymbol{x}=(x_{1},\ldots,x_{n}) of points in S\mathcal{S}. Writing δx\delta_{x} for the measure consisting of a point mass of weight 1 at xx, and

for the empirical distribution of x\boldsymbol{x}, it is assumed that νn\nu_{n} converges in probability to μ\mu as n→∞n\rightarrow\infty, with convergence in the usual space of probability measures on S\mathcal{S}. One example where the convergence holds is the random case, where the xix_{i} are independent and identically distributed on S\mathcal{S} with distribution μ\mu convergence in probability holds by the law of large numbers. Of course, we do not need (xn)n≥1(x_{n})_{n\geq 1} to be defined for every nn, but only for an infinite set of integers nn. From here onwards, we shall only focus on this special case, where, (x1,…,xn)∼iidμ(x_{1},\ldots,x_{n})\stackrel{{\scriptstyle iid}}{{\sim}}\mu.

A kernel κn\kappa_{n} on a ground space (S,μ)(\mathcal{S},\mu) is a symmetric non-negative (Borel) measurable function on S×S\mathcal{S}\times\mathcal{S}. κ\kappa is also continuous a.e. on S×S\mathcal{S}\times\mathcal{S}. By a kernel on a vertex space (S,μ,(xn)n≥1)(\mathcal{S},\mu,(x_{n})_{n\geq 1}) we mean a kernel on (S,μ)(\mathcal{S},\mu).

Given the (random) sequence (x1,…,xn)(x_{1},\ldots,x_{n}), we let G(n,κ)G(n,\kappa) be the random graph G(n,(pij))G(n,(p_{ij})) with

In other words, GV(n,κ)G^{\mathcal{V}}(n,\kappa) has nn vertices {1,…,n}\{1,\ldots,n\} and, given x1,…,xnx_{1},\ldots,x_{n}, an edge ijij (with i≠ji\neq j) exists with probability pijp_{ij}, independently of all other (unordered) pairs ijij. Based on the graph kernel we can also define an integral operator TκT_{\kappa} in the following way

The integral operator Tκ:L2(S)→L2(S)T_{\kappa}:L^{2}(\mathcal{S})\rightarrow L^{2}(\mathcal{S}) corresponding to G(n,κ)G(n,\kappa), is defined as

where, x∈Sx\in\mathcal{S} and any measurable function f∈L1(S)f\in L^{1}(\mathcal{S}).

The random graph G(n,κ)G(n,\kappa) depends not only on κ\kappa but also on the choice of x1,…,xnx_{1},\ldots,x_{n}. The freedom of choice of xix_{i} in this model gives some more flexibility than Bickel-Chen model. The asymptotic behavior of G(n,κ)G(n,\kappa) depend very much on S\mathcal{S} and μ\mu. Many of these key results such as existence of giant component, typical distance, phase transition properties are proved in . We shall use these results on inhomogeneous random graphs in order to prove results on graph distance for stochastic block models.

Here is further comparison of the Inhomogeneous random graph model (IRGM) with the Bickel-Chen model (BCM), to understand their similarities and dissimilarities -

In BCM, (ξ1,…,ξn)∼iidU(0,1)(\xi_{1},\ldots,\xi_{n})\stackrel{{\scriptstyle iid}}{{\sim}}U(0,1) are the latent variables associated with the vertices (v1,…,vn)(v_{1},\ldots,v_{n}) of random graph GnG_{n}. Similarly, in IRGM, (x1,…,xn)∼μ(x_{1},\ldots,x_{n})\sim\mu are the latent variables associated with the vertices (v1,…,vn)(v_{1},\ldots,v_{n}) of random graph GnG_{n}. Now, if in IRGM, (x1,…,xn)∼iidμ(x_{1},\ldots,x_{n})\stackrel{{\scriptstyle iid}}{{\sim}}\mu then the latent variable structure of the two models become equivalent.

In BCM, the conditional probability of connection between two vertices given the value of their latent variables is controlled by the kernel function hn(u,v)h_{n}(u,v). In IRGM, the conditional probability of connection between two vertices given the value of their latent variables is controlled by the kernel function κ(u,v)n\frac{\kappa(u,v)}{n}.

where, TκT_{\kappa} is the operator define in Definition 2.2 and ∣∣⋅∣∣||\cdot|| is the operator norm. In BCM,

If BCM and IRGM have same underlying measure spaces (S=(0,1),μ=U(0,1))(\mathcal{S}=(0,1),\mu=U(0,1)) and hn(u,v)=κ(u,v)/nh_{n}(u,v)=\kappa(u,v)/n and

1\mathbf{1} is the principal eigenfunction of TκT_{\kappa}, then

1\mathbf{1} is not the principal eigenfunction of TκT_{\kappa}, then

1.3 Stochastic Block Model

The stochastic block model is perhaps the most commonly used and best studied model for community detection. We continue with IRGM framework, so the graph is sparse.

A graph GQ(,(P,π))G^{Q}(,(P,\boldsymbol{\pi})) generated from stochastic block model (SBM) with QQ blocks and parameters P∈(0,1)Q×QP\in(0,1)^{Q\times Q} and π∈(0,1)Q\boldsymbol{\pi}\in(0,1)^{Q} can be defined in following way - each vertex of graph GnG_{n} from an SBM belongs to a community c=(c1,…,cn)∈{1,…,Q}\boldsymbol{c}=(c_{1},\ldots,c_{n})\in\{1,\ldots,Q\} which are drawn independently from the multinomial distribution with parameter π=(π1,…,πQ)\boldsymbol{\pi}=(\pi_{1},\ldots,\pi_{Q}), where πi>0\pi_{i}>0 for all ii. Conditional on the labels, the edge variables AijA_{ij} for i<ji<j are independent Bernoulli variables with

where P=[Pab]P=[P_{ab}] and K=[Kab]K=[K_{ab}] are Q×QQ\times Q symmetric matrices. PP is known as the connection probability matrix and KK as the kernel matrix for the connection. So, we have Pab≤1P_{ab}\leq 1 for all a,b=1,…,Qa,b=1,\ldots,Q, P1≤1P\mathbf{1}\leq\mathbf{1} and 1TP≤1\mathbf{1}^{T}P\leq\mathbf{1} element-wise.

The network is undirected, so Aji=AijA_{ji}=A_{ij}, and Aii=0A_{ii}=0 (no self-loops). The problem of community detection is then to infer the node labels c\boldsymbol{c} from AA. Thus we are not really interested in estimation or inference on parameters π\boldsymbol{\pi} and PP, but, rather we are interested in estimating c\boldsymbol{c}. But, it does not mean the two problems are mutually exclusive, in reality, the inferential problem and the community detection problem are quite interlinked.

We can see that SBM is a special case of both Bickel-Chen model and IRGM. In IRGM, if we consider S\mathcal{S} to be a finite set, (x1,…,xn)∈[Q]n(x_{1},\ldots,x_{n})\in[Q]^{n} ([Q]={1,…,Q}[Q]=\{1,\ldots,Q\}) with xi∼iidMult(n,π)x_{i}\stackrel{{\scriptstyle iid}}{{\sim}}Mult(n,\boldsymbol{\pi}) and kernel κ:[Q]→[Q]\kappa:[Q]\rightarrow[Q] as κ(a,b)=Kab\kappa(a,b)=K_{ab} (a,b=1,…,Qa,b=1,\ldots,Q), then the resulting IRGM graph follows stochastic block model. So, for SBM we can define an integral operator on [Q][Q] with measure {π1,…,πQ}\{\pi_{1},\ldots,\pi_{Q}\}.

The stochastic block model has deep connections with Multi-type branching process, just as, Erodös-Rényi random graph model (ERRGM) has connections with the branching process. Let us introduce branching process first.

2 Multi-type Branching Process

We shall try to link network formed by SBM with the tree network generated by multi-type Galton-Watson branching process. In our case, the Multi-type branching process (MTBP) has type space S={1,…,Q}S=\{1,\ldots,Q\}, where a particle of type a∈Sa\in S is replaced in the next generation by a set of particles distributed as a Poisson process on SS with intensity (Kabπb)b=1Q(K_{ab}\pi_{b})_{b=1}^{Q}. We denote this branching process, started with a single particle of type aa, by BK,π(a)\mathcal{B}_{K,\pi}(a). We write BK,π\mathcal{B}_{K,\pi} for the same process with the type of the initial particle random, distributed according to π\boldsymbol{\pi}.

Define ρk(K,π;a)\rho_{k}(K,\pi;a) as the probability that the branching process BK,π(a)\mathcal{B}_{K,\pi}(a) has a total population of exactly kk particles.

Define ρ≥k(K,π;a)\rho_{\geq k}(K,\pi;a) as the probability that the total population is at least kk.

Define ρ(K,π;a)\rho(K,\pi;a) as the probability that the branching process survives for eternity.

and define ρ≥k(K)\rho_{\geq k}(K) analogously. Thus, ρ(K,π)\rho(K,\pi) is the survival probability of the branching process BK,π\mathcal{B}_{K,\pi} given that its initial distribution is π\boldsymbol{\pi}

If the probability that a particle has infinitely many children is 0, then ρ(K,π;a)\rho(K,\pi;a) is equal to ρ∞(a)\rho_{\infty}(a), the probability that the total population is infinite. As we shall see later, the branching process BK,π(a)\mathcal{B}_{K,\pi}(a) arises naturally when exploring a component of GnG_{n} starting at a vertex of type aa; this is directly analogous to the use of the single-type Poisson branching process in the analysis of the Erdös-Rényi graph G(n,c/n)G(n,c/n).

3 Known Results for Stochastic Block Model

The performance of community detection algorithms depends on the parameters π\boldsymbol{\pi} and PP. We refer to Definition 2.3 for definition of stochastic block models. An important condition that we usually put on parameter PP is irreducibility.

A connection matrix PP on a S={1,…,Q}\mathcal{S}=\{1,\ldots,Q\} is reducible if there exists A⊂SA\subset\mathcal{S} with 0<∣A∣<Q0<|A|<Q such that P=0P=0 a.e. on A×(S−A)A\times(\mathcal{S}-A); otherwise PP is irreducible. Thus PP is irreducible if A⊆SA\subseteq\mathcal{S} and P=0P=0 a.e. on A×(S−A)A\times(\mathcal{S}-A) implies ∣A∣=0|A|=0 or ∣A∣=Q|A|=Q.

So, the results on existence of giant components in also apply for SBM. The following theorem describes the result on existence of giant components.

Let us define operator TKT_{K} as in definition 2.4,

If ∣∣TK∣∣≤1||T_{K}||\leq 1 (∣∣⋅∣∣||\cdot|| refer to operator norm), then the size of largest component is oP(n)o_{P}(n), while if ∣∣TK∣∣>1||T_{K}||>1, then the size of largest component is ΘP(n)\Theta_{P}(n) whp.

If PP is irreducible, then 1n(\mboxSizeoflargestcomponent)→πTρ\frac{1}{n}(\mbox{Size of largest component})\rightarrow\boldsymbol{\pi}^{T}\rho, where, ρ∈Q\rho\in^{Q} is the survival probability as defined in (5).

The theoretical results on community detection depend on the 3 different regime on which the generative model is based on -

If (a−b)2<2(a+b)(a-b)^{2}<2(a+b) then probability model of SBM and ERRGM with p=a+b2np=\frac{a+b}{2n} are mutually contiguous. Moreover, if (a−b)2<2(a+b)(a-b)^{2}<2(a+b), there exists no consistent estimators of aa and bb.

If (a−b)2>2(a+b)(a-b)^{2}>2(a+b) then probability model of SBM and ERRGM with p=a+b2np=\frac{a+b}{2n} are asymptotically orthogonal.

So, in the range (a−b)2>2(a+b)(a-b)^{2}>2(a+b), there should exists an algorithm which identifies highly correct clustering with high probability at least within the giant components.

Algorithm

The algorithm we propose depend on the graph distance or geodesic distance between vertices in a graph.

Graph distance or Geodesic distance between two vertices ii and jj of graph GG is given by the length of the shortest path between the vertices ii and jj, if they are connected. Otherwise, the distance is infinite.

So, for any two vertices u,v∈V(G)u,v\in V(G), graph distance, dgd_{g} is defined by

For sake of numerical convenience, we shall replace ∞\infty by a large number for value of dg(u,v)d_{g}(u,v), when, uu and vv are not connected. The main steps of the algorithm can be described as follows

Find the graph distance matrix D=[dg(vi,vj)]i,j=1nD=[d_{g}(v_{i},v_{j})]_{i,j=1}^{n} for a given network but with distance upper bounded by klog⁡nk\log n. Assign non-connected vertices an arbitrary high value BB.

Perform hierarchical clustering to identify the giant component GCG^{C} of graph GG. Let nC=∣V(GC)∣n_{C}=|V(G^{C})|.

Normalize the graph distance matrix on GCG^{C}, DCD^{C} by

Perform eigenvalue decomposition on DˉC\bar{D}^{C}.

Here are some important observations about the algorithm -

There are standard algorithms for graph distance finding in the algorithmic graph theory literature. In algorithmic graph theory literature the problem is known as the all pairs shortest path problem. The two most popular algorithms are Floyd-Warshall and Johnson’s algorithm . The time complexity of the Floyd-Warshall algorithm is O(n3)O(n^{3}), where as, the time complexity of Johnson’s algorithm is O(n2log⁡n+ne)O(n^{2}\log n+ne) (n=∣V(Gn)∣n=|V(G_{n})| and e=∣E(Gn)∣e=|E(G_{n})|). So, for sparse graphs, Johnson’s algorithm is faster than Floyd-Warshall. Memory storage is also another issue for this algorithm, since the algorithm involves a matrix multiplication step of complexity Ω(n2)\Omega(n^{2}). Recently, there also has been some progress on parallel implementation of all-pairs shortest path problem , which addresses both memory and computation aspects of the algorithm and lets us scale the algorithm for large graphs, both dense and sparse.

is minimized. The minimizer is attained by the rows of the matrix formed by the top QQ eigenvectors of DˉC\bar{D}^{C} as columns. So, performing spectral clustering on DˉC\bar{D}^{C} is the same as performing QQ-means clustering on the multi-dimensional scaled space.

Instead of DˉC\bar{D}^{C}, we could also use the matrix (DC)2(D^{C})^{2}, but then, the topmost eigenvector does not carry any information about the clustering. Similarly, we can also use the matrix DCD^{C} directly for spectral clustering, but, in that case, DCD^{C} is not a positive semi-definite matrix and as a result we have to consider the eigenvectors corresponding to largest absolute eigenvalues (since eigenvalues can be negative).

In the Step 5 of the algorithm QQ-means clustering if the expected degree of the blocks are equal. However, if the expected degree of the blocks are different, it leads to multi scale behavior in the eigenvectors of the normalized distance matrix. So, we perform Gaussian Mixture Model (GMM) based clustering instead of QQ-means to take into account the multi scale behavior.

Theory

Let us consider that we have a random graph GnG_{n} as the data. Let V(Gn)={vi,…,vn}V(G_{n})=\{v_{i},\ldots,v_{n}\} denote the vertices of GnG_{n} and E(Gn)={e1,…,em}E(G_{n})=\{e_{1},\ldots,e_{m}\} denote the edges of GnG_{n}. So, the number of vertices in GnG_{n} is ∣V(Gn)∣=n|V(G_{n})|=n and number of edges of GnG_{n} is ∣E(Gn)∣=m|E(G_{n})|=m. Let the adjacency matrix of GnG_{n} be denoted by An×nA_{n\times n}. For sake of notational simplicity, from here onwards we shall denote GnG_{n} by GG having nn vertices unless specifically mentioned. There are QQ communities for the vertices and each community has (na)a=1Q(n_{a})_{a=1}^{Q} number of vertices. In this paper, we are interested in the problem of vertex community identification or graph partitioning. However, the problem is an unsupervised learning problem. So, we assume that the data is coming from an underlying model and we try to verify how good ‘our’ community detection method works for that model.

The theoretical analysis of the algorithm has two main parts -

Finding the limiting distribution of graph distance between two typical vertices of type aa and type bb (where, a,b=1,…,Qa,b=1,\ldots,Q). This part of the analysis is highly dependent on results from multi-type branching processes and their relation with stochastic block models. The proof techniques and results are borrowed from , and .

Finding the behavior of top QQ eigenvectors of the graph distance matrix DD using the limiting distribution of the typical graph distances. This part of analysis is highly dependent on perturbation theory of linear operators. The proof techniques and results are borrowed from , and .

Let λ>1\lambda>1 (defined in Eq. (8)), then, the graph distance dG(u,v)d_{G}(u,v) between two uniformly chosen vertices of type aa and bb respectively, conditioned on being connected, satisfies the following asymptotic relation -

In Theorem 4.1 we had a point-wise result, so, we combine these point-wise results to give a matrix result -

Let λ=∣∣TK∣∣>1\lambda=||T_{K}||>1, then, within the big connected component,

Thus, the above theorem gives us an idea about the limiting behavior of the normalized version of geodesic matrix D\mathbf{D}.

A rough idea of the proof of part I is as follows. Fix two vertices, say 1 and 2, in the giant component. Think of a branching process starting from vertices of type 1 and 2, so that at time tt, BPπ(a)(t)\mathcal{B}_{P\pi}(a)(t) is the branching process tree from vertex of type aa and includes the shortest paths to all vertices in the tree at or before time tt from vertex aa, a=1,2a=1,2. When these two trees meet via the formation of an edge (v1,v2)(v_{1},v_{2}) between two vertices v1∈BPπ(1)(⋅)v_{1}\in\mathcal{B}_{P\pi}(1)(\cdot) and v2∈BPπ(2)(⋅)v_{2}\in\mathcal{B}_{P\pi}(2)(\cdot), then the shortest-length path between the two vertices 1 and 2 has been found. If Dn(va)D_{n}(v_{a}), a=1,2a=1,2, denotes the number of edges between the source aa and the vertex vav_{a} along the tree BPπ(a)\mathcal{B}_{P\pi}(a), then the graph distance dn(1,2)d_{n}(1,2) is given by

The above idea is indeed a very rough sketch of our proof and it follows from the graph distance finding idea developed in . In the paper, we embed the SBM in a multi-type branching process (MTMBP) or a single-type marked branching process (MBP), depending on whether the types of two vertices are same or not. The offspring distribution is binomial with parameters n−1n-1 and kernel PP (see Section 4.4). With high probability, the vertex exploration process in the SBM can be coupled with two multi-type branching processes, bounding the vertex exploration process on SBM on both sides. Now, using the property of the two multi-type branching processes, we can bound the number of vertices explored in the vertex exploration process of a SBM graph and infer about the asymptotic limit of the graph distance.

With the above sketch of proof can be organized as follows.

We analyze various properties of a Galton-watson process conditioned on non-extinction, including times to grow to a particular size. In this branching process, the offspring will have a Poisson distribution.

We introduce multi-type branching process trees with binomially distributed offspring and make the connection between these trees and the SBM. We bound the vertices explored for an SBM graph, starting from a fixed vertex, by considering a muti-type branching process coupled with it.

We bound the geodesic distance using the number of vertices explored in the coupled multi-type branching processes within a certain generation. The limiting behavior of the generation give us the limiting behavior of graph distance.

The whole analysis is true for IRGM. So, the results are true for SBM with increasing block numbers and degree-corrected block models also.

The idea of the argument is quite simple, but making these ideas rigorous takes some technical work, particularly because we need to condition on our vertices being in the giant component.

2 Results of Part II

The limiting kernel matrix, DQ×Q\mathcal{D}_{Q\times Q} is defined as

Now, we assume some conditions on the limiting low-dimensional matrix D\mathcal{D}.

The eigenvalues of D\mathcal{D}, λ1(D)≥⋯≥λQ(D)\lambda_{1}(\mathcal{D})\geq\cdots\geq\lambda_{Q}(\mathcal{D}), satisfy the condition that there exists an constant α\alpha, such that, 0<α≤λQ(D)0<\alpha\leq\lambda_{Q}(\mathcal{D}).

The number of vertices in each type (n1,…,nQ)(n_{1},\ldots,n_{Q}), satisfy the condition that there exists a constant θ\theta such that 0<θ<nan0<\theta<\frac{n_{a}}{n} for all a=1,…,Qa=1,\ldots,Q and all nn.

3 Branching Process Results

Let us recall our notation for the survival probabilities of particles in BK(a)\mathcal{B}_{K}(a). We write ρk(K;a)\rho_{k}(K;a) for the probability that the total population consists of exactly kk particles, and ρ≥k(K;a)\rho_{\geq k}(K;a) for the probability that the total population contains at least kk particles. Furthermore, ρ(K;a)\rho(K;a) is the probability that the branching process survives for eternity. We write ρk(K),ρ≥k(K)\rho_{k}(K),\rho_{\geq k}(K) and ρ(K)\rho(K) for the corresponding probabilities for BK\mathcal{B}_{K} , so that, e.g., ρk(K)=∑a=1Qρk(K;a)πa\rho_{k}(K)=\sum_{a=1}^{Q}\rho_{k}(K;a)\pi_{a}.

Now, we try to find a coupling relation between neighborhood exploration process of a vertex of type aa in stochastic block model and multi-type Galton-Watson process, B(a)\mathcal{B}(a) starting from a vertex of type aa.

We assume all vertices of graph GnG_{n} generated from a stochastic block model has been assigned a community or type ξi\xi_{i} (say) for vertex vi∈V(Gn)v_{i}\in V(G_{n}). By neighborhood exploration process of a vertex of type aa in stochastic block model, we mean that we start from a random vertex viv_{i} of type aa in the random graph GnG_{n} generated from stochastic block model. Then, we count the number of vertices of the random graph GnG_{n} are neighbors of viv_{i}, N(vi)N(v_{i}). We repeat the neighborhood exploration process by looking at the neighbors of the vertices in N(vi)N(v_{i}). We continue until we have covered all the vertices in GnG_{n}. Since, we either consider GnG_{n} connected or only the giant component of GnG_{n}, the neighborhood exploration process will end in finite steps but the number of steps may depend on nn.

Within the giant component, the neighborhood exploration process for a stochastic block model graph with parameters (P,π)=(K/n,π)(P,\pi)=(K/n,\pi), can be bounded with high probability by two multi-type branching processes with kernels (1−2ϵ)K(1-2\epsilon)K and (1+ϵ)K(1+\epsilon)K for some ϵ>0\epsilon>0.

The proof is given in Appendix A1 and follows from Lemma 9.6 . ∎

Now, we restrict ourselves to the giant component only. So, if we condition that the exploration process does not leave the giant component, it is same as conditioning that the branching process does not die out. Under this additional condition, the branching process can be coupled with another branching process with a different kernel. The kernel of that branching process is given in following lemma.

If we condition a branching process, BKπ\mathcal{B}_{K\pi} on survival, the new branching process has kernel (Kab(ρ(K;a)+ρ(K;b)−ρ(K;a)ρ(K;b)))a,b=1Q\left(K_{ab}\left(\rho(K;a)+\rho(K;b)-\rho(K;a)\rho(K;b)\right)\right)_{a,b=1}^{Q}.

The proof is given in Appendix A2 and follows from Section 10 of . ∎

Now, we shall try to prove the limiting behavior of typical distance between vertices vv and ww of GnG_{n}, where, v,w∈V(Gn)v,w\in V(G_{n}). We first try to find a lower bound for distance between two vertices. We shall separately give an upper bound and lower bound for distance between two vertices of same type and different types. The result on lower bound in proved in Lemma 4.8.

type of v=a≠b=v=a\neq b= type of ww (say) and λ≡∣∣TK∣∣>1\lambda\equiv||T_{K}||>1, then,

type of v=v= type of w=aw=a (say), λ≡∣∣TK∣∣<πaKaa\lambda\equiv||T_{K}||<\pi_{a}K_{aa} and λ>1\lambda>1, then,

The proof is given in Appendix A3 and follows from Lemma 14.2 of . ∎

Now, we first try to upper bound the typical distance between two vertices of the same type. For the same type vertices, we just focus on the subgraph of the original graph from stochastic block model having vertices of same type. So, in Lemma 4.9, the graph GnG_{n} is the subgraph of the original graph containing only the vertices of the same type. So, the coupled branching process on that graph automatically becomes a single-type branching process.

For vertices v,w∈V(G)v,w\in V(G), if type of v=v= type of w=aw=a (say)

conditioned on the event that the branching process BKaa(a)\mathcal{B}_{K_{aa}}(a) survives.

The proof is given in Appendix A4 and follows from Lemma 14.3 of . ∎

Now, let us try to upper bound the typical distance between two vertices of different types. So, in Lemma 4.10, the graph GnG_{n} is the original graph containing with vertices of the different types. So, the coupled branching process on that graph becomes a multi-type branching process.

conditioned on the event that the branching process BK\mathcal{B}_{K} survives.

The proof is given in Appendix A5 follows from Lemma 14.3 of . ∎

4 Proof of Theorem 4.1 and Theorem 4.3

We shall try to prove the limiting behavior of typical graph distance in the giant component as n→∞n\rightarrow\infty. The Theorem essentially follows from Lemma 4.8 - 4.10. Under the conditions mentioned in the Theorem, part (a) follows from Lemma 4.8(b) and 4.9 and part (b) follows from Lemma 4.8(a) and 4.10.

4.2 Proof of Theorem 4.3

From the definition 4.2, we have that Dij=\mathbf{D}_{ij}= graph distance between vertices viv_{i} and vjv_{j}, where, vi,vj∈V(Gn)v_{i},v_{j}\in V(G_{n}).

For the case when type of vi=v_{i}= type of vj=av_{j}=a (say) From Lemma 4.8(b), we get for any vertices vv and ww of same type aa with high probability,

Also from Lemma 4.9, we get, for any vertices vv and ww of same type aa

So, we have that, for vi,vjv_{i},v_{j} having same type aa, with high probability,

Since, ϵ=O(n−1/2)\epsilon=O(n^{-1/2}) by Eq (19) and (1−exp(−Ω(n2η)))n2→1(1-exp(-\Omega(n^{2\eta})))^{n^{2}}\rightarrow 1 as n→∞n\rightarrow\infty,

For the case when type of vi≠v_{i}\neq type of vjv_{j} From Lemma 4.8(a), we get for any vertices vv and ww with high probability,

So, putting the two statements together, we get that with high probability,

since, by Eq. (19) ϵ=O(1/n)\epsilon=O(1/\sqrt{n}) and and (1−exp(−Ω(n2η)))n2→1(1-exp(-\Omega(n^{2\eta})))^{n^{2}}\rightarrow 1 as n→∞n\rightarrow\infty.

So, putting the two cases together, we get that with high probability,

5 Perturbation Theory of Linear Operators

The Davis-Kahan Theorem states a bound on perturbation of eigenspace instead of eigenvector, as discussed previously. The sin⁡θ\sin\theta Theorem of Davis-Kahan

6 Proof of Theorem 4.5

With high probability it holds that ∣λQ(D/log⁡n)∣≥O(n)|\lambda_{Q}(\mathbf{D}/\log n)|\geq O(n) and λQ+1(D/log⁡n)≤O(n1−ε)\lambda_{Q+1}(\mathbf{D}/\log n)\leq O(n^{1-\varepsilon}).

By Weyl’s Inequality, for all i=1,…,ni=1,\ldots,n,

So, ∣λQ(D/log⁡n)∣≥O(n)−O(n1−ε)=O(n)|\lambda_{Q}(\mathbf{D}/\log n)|\geq O(n)-O(n^{1-\varepsilon})=O(n) for large nn and ∣λQ+1(D/log⁡n)∣≤−1+O(n1−ε)=O(n1−ε)|\lambda_{Q+1}(\mathbf{D}/\log n)|\leq-1+O(n^{1-\varepsilon})=O(n^{1-\varepsilon}). ∎

Now, the relationship between the rows of WW can be specified based on Assumption (C3) as follows -

For any two rows i,ji,j of Wn×Q\mathbf{W}_{n\times Q} matrix, ∣∣ui−uj∣∣2≥O(1/n)||u_{i}-u_{j}||_{2}\geq O(1/\sqrt{n}), if type of vi≠v_{i}\neq type of vjv_{j}.

By Lemma 4.15, for large nn, we can get constant CC, such that, QQ balls, B1,…,BQB_{1},\ldots,B_{Q}, of radius r=Cn−1/2r=Cn^{-1/2} around QQ distinct rows of W\mathbf{W} are disjoint.

Now note that with high probability the number of rows ii such that ∣∣Ci−(WR)i∣∣>r||\mathbf{C}_{i}-(\mathbf{W}\mathbf{R})_{i}||>r is at most O(n1/2−ε)O(n^{1/2-\varepsilon}). If the statement does not hold then,

So, we get a contradiction, since ∣∣C−WR∣∣F≤O(n−ε)||\mathbf{C}-\mathbf{W}\mathbf{R}||_{F}\leq O(n^{-\varepsilon}). Thus, the number of mistakes should be at most of order O(n1/2−ε)O(n^{1/2-\varepsilon}).

So, for each vi∈V(Gn)v_{i}\in V(G_{n}), if ξi\xi_{i} is the type of viv_{i} and ξ^i\hat{\xi}_{i} is the type of viv_{i} as estimated from applying QQ-means on top QQ eigenspace of geodesic matrix D\mathbf{D}, we get that with high probability, for some small 0<ε0<\varepsilon,

Application

We investigate the empirical performance of the algorithm in several different setup. At first, we use simulated networks from stochastic block model to find the empirical performance of the algorithm. Then, we apply our method to find communities in several real world networks.

We simulate networks from stochastic block models with Q=3Q=3 blocks. Let ww correspond to a QQ-block model defined by parameters θ=(π,ρn,S)\theta=(\boldsymbol{\pi},\rho_{n},S), where πa\pi_{a} is the probability of a node being assigned to block aa as before, and

and the probability of node ii to be assigned to block aa to be πa\pi_{a} (a=1,…,Ka=1,\ldots,K).

In the following figures, we try to see the behavior of mean and variances of the count statistics, as we vary λn\lambda_{n} as we vary ν\nu.

1.2 Unequal Density Clusters

In the following figures, we try to see the behavior of mean and variances of the count statistics, as we vary λn\lambda_{n} as we vary ν\nu.

2 Application to Real Network Data

In this application, we try to find communities for Facebook collegiate networks. The networks were presented in the paper by Traud et.al. (2011) . The network is formed by Facebook users acting as nodes and if two Facebook users are “friends” there is an edge between the corresponding nodes. Along with the network structure, we also have the data on covariates of the nodes. Each node has covariates: gender, class year, and data fields that represent (using anonymous numerical identifiers) high school, major, and dormitory residence. We consider the network of a specific college (Caltech). We compare the communities found with the dormitory affiliation of the nodes.

2.2 Political Web Blogs Network

This dataset on political blogs was compiled by soon after the 2004 U.S. presidential election. The nodes are blogs focused on US politics and the edges are hyperlinks between these blogs. Each blog was manually labeled as liberal or conservative by , and we treat these as true community labels. We ignore directions of the hyperlinks and analyze the largest connected component of this network, which has 1222 nodes and the average degree of 27. The distribution of degrees is highly skewed to the right (the median degree is 13, and the maximum is 351). This is a network where the degree distribution is heavy-tailed and the graph is inhomogeneous.

Conclusion

We demonstrate the empirical performance of the method by using both simulated and real world networks. We compare with the pseudo-likelihood method and show that they have similar empirical performances. We demonstrate the empirical performance by applying the method for community detection in several real world networks too.

The method also works when number of blocks in the stochastic block model brows with nn (number of vertices) and for degree-corrected block model . We conjecture that under these models too the method will have the theoretical guarantee of correct community detection. The proof can be obtained by using similar techniques that we have used in this paper.

References

Appendix: Branching Process Results

We have nan_{a} vertices of type aa ,a=1,…,Qa=1,\ldots,Q, and that na/n→a.s.πan_{a}/n\stackrel{{\scriptstyle a.s.}}{{\rightarrow}}\pi_{a}. From now on we condition on n1,…,nQn_{1},\ldots,n_{Q}; we may thus assume that n1,…,nQn_{1},\ldots,n_{Q} are deterministic with na/n→πan_{a}/n\rightarrow\pi_{a}. Let ω(n)\omega(n) be any function such that ω(n)→∞\omega(n)\rightarrow\infty and ω(n)/n→0\omega(n)/n\rightarrow 0. We call a component of Gn≡G(n,P)=G(n,K/n)G_{n}\equiv G(n,P)=G(n,K/n) big if it has at least ω(n)\omega(n) vertices. Let BB be the union of the big components, so ∣B∣=N≥ω(n)(Gn)|B|=N_{\geq\omega(n)}(G_{n}). Fix ϵ>0\epsilon>0.We may assume that nn is so large that ω(n)/n<ϵ\omega(n)/n<\epsilon πi\pi_{i} and ∣na/n−πa∣<ϵ|n_{a}/n-\pi_{a}|<\epsilon πa\pi_{a} for every aa; thus (1−ϵ)πan<na<(1+ϵ)πan(1-\epsilon)\pi_{a}n<n_{a}<(1+\epsilon)\pi_{a}n. We may also assume that n>max⁡Kn>\max K, as KK is a function on the finite set S×S\mathcal{S}\times\mathcal{S}. Since, na/nn_{a}/n is a n\sqrt{n}-consistent estimator of πa\pi_{a}, we get that

Select a vertex and explore its component in the usual way, that means looking at its neighbors, one vertex at a time. We first reveal all edges from the initial vertex, and put all neighbors that we find in a list of unexplored vertices; we then choose one of these and reveal its entire neighborhood, and so on. Stop when we have found at least ω(n)\omega(n) vertices (so x∈Bx\in B), or when there are no unexplored vertices left (so we have found the entire component and x∉Bx\notin B).

Consider one step in this exploration, and assume that we are about to reveal the neighborhood of a vertex xx of type aa. Let us write nb′n^{\prime}_{b} for the number of unused vertices of type bb remaining. Note that nb≥nb′≥nb−ω(n)n_{b}\geq n^{\prime}_{b}\geq n_{b}-\omega(n), so

The number of new neighbors of xx of type bb has a binomial Bin(nb′,Kab/n)Bin(n^{\prime}_{b},K_{ab}/n) distribution, and the numbers for different bb are independent. The total variation distance between a binomial Bin(n,p)Bin(n,p) distribution and the Poisson distribution with the same mean is at most p. Hence the total variation distance between the binomial distribution above and the Poisson distribution Poi(Kabnb′/n)Poi(K_{ab}n^{\prime}_{b}/n) is at most Kab/n=O(1/n)K_{ab}/n=O(1/n). Also, by (20),

Since we perform at most ω(n)\omega(n) steps in the exploration, we may, with an error probability of O(ω(n)/n)=o(1)O(\omega(n)/n)=o(1), couple the exploration with two multi-type branching processes B((1−2ϵ)K)\mathcal{B}((1-2\epsilon)K) and B((1+ϵ)K)\mathcal{B}((1+\epsilon)K) such that the first process always finds at most as many new vertices of each type as the exploration, and the second process finds at least as many. Consequently, for a vertex xx of type aa,

Since ω(n)→∞\omega(n)\rightarrow\infty, by Lemma 9.5 of , we have ρ≥ω(n)(K;a)→ρ(K;a)\rho_{\geq\omega(n)}(K;a)\rightarrow\rho(K;a) for every matrix or finitary kernel KK, which parametrizes the offspring distribution of the branching process in the sense that the number of offsprings of type bb coming from a parent of type aa follows Poi(Kabπb)Poi(K_{ab}\pi_{b}) distribution. So we can rewrite (22) as

A2. proof of Lemma 4.7

We need to consider certain branching process expectations σ(K)\sigma(K) and σ≥k(K)\sigma_{\geq k}(K) in place of ρ(K)\rho(K) and ρ≥k(K)\rho_{\geq k}(K). In preparation for the proof, we shall relate ζ(K)\zeta(K) to the branching process BK\mathcal{B}_{K} via σ(K)\sigma(K). As before, we assume that KK is a kernel on (S,π)(\mathcal{S},\pi) with K∈L1K\in L^{1}.

Let AA be a Poisson process on S\mathcal{S}, with intensity given by a finite measure λ\lambda, so that AA is a random multi-set on S\mathcal{S}. If gg is a bounded measurable function on multi-sets on S\mathcal{S}, it is easy to see that

Let B(x)B(x) denote the first generation of the branching process BK(x)\mathcal{B}_{K}(x). Thus B(x)B(x) is given by a Poisson process on S\mathcal{S} with intensity K(x,y)πxK(x,y)\pi_{x}. Suppose that ∑bKabπb<∞\sum_{b}K_{ab}\pi_{b}<\infty for every a=1,…,Qa=1,\ldots,Q, so B(x)B(x) is finite. Let σ(K;x)\sigma(K;x) denote the expectation of ∣B(x)∣1[∣BK(x)∣=∞]|B(x)|\mathbf{1}[|\mathcal{B}_{K}(x)|=\infty], recalling that under the assumption ∑bKabπb<∞\sum_{b}K_{ab}\pi_{b}<\infty for every aa, the branching process BK(x)\mathcal{B}_{K}(x) dies out if and only if ∣BK(x)∣<∞|\mathcal{B}_{K}(x)|<\infty. Then

Here the penultimate step is from (24); the last step uses the fact that the branching process dies out if and only if none of the children of the initial particle survives. Writing BB for the first generation of BK\mathcal{B}_{K} conditioned on survival becomes

Then, integrating over xx and subtracting from ∑a,bKabπaπb\sum_{a,b}K_{ab}\pi_{a}\pi_{b}, we get,

So, the kernel for the conditioned branching process becomes

A3. proof of Lemma 4.8

We have S\mathcal{S} is finite, say S={1,2,…,Q}\mathcal{S}=\{1,2,\ldots,Q\}. Let Γd(v)≡Γd(v,Gn)\Gamma_{d}(v)\equiv\Gamma_{d}(v,G_{n}) denote the dd-distance set of vv in GnG_{n}, i.e., the set of vertices of GnG_{n} at graph distance exactly dd from vv, and let Γ≤d(v)≡Γ≤d(v,Gn)\Gamma_{\leq d}(v)\equiv\Gamma_{\leq d}(v,G_{n}) denote the dd-neighborhood ∪d′≤dΓd′(v)\cup_{d^{\prime}\leq d}\Gamma_{d^{\prime}}(v) of vv.

Let 0<ε<1/100<\varepsilon<1/10 be arbitrary. The proof of (23) involved first showing that, for nn large enough, the neighborhood exploration process starting at a given vertex vv of GnG_{n} with type aa (chosen without inspecting GnG_{n}) could be coupled with the branching process B(1+ε)K′(i)\mathcal{B}_{(1+\varepsilon)K^{\prime}}(i), where the K′K^{\prime} is defined by equation (26), so that the branching process is conditioned to survive. However, henceforth we shall abuse notation and denote K′K^{\prime} as KK.

The neighborhood exploration process and multi-type branching process can be coupled so that for every dd, ∣Γd(v)∣|\Gamma_{d}(v)| is at most the number NdN_{d} of particles in generation dd of B(1+2ε)K(i)\mathcal{B}_{(1+2\varepsilon)K}(i). The number of vertices at generation dd of type cc of branching process B(1+2ε)K(a)\mathcal{B}_{(1+2\varepsilon)K}(a), denoted by Nd,caN^{a}_{d,c} and the number of vertices of type cc at distance dd from vv for the neighborhood exploration process of GnG_{n} is denoted by ∣Γd,ca(v)∣|\Gamma^{a}_{d,c}(v)|f, where, c=1,…,Qc=1,\ldots,Q.

Let Nta(c)N^{a}_{t}(c) be the number of particles of type cc in the tt-th generation of BK(a)\mathcal{B}_{K}(a), then, NtaN^{a}_{t} is the vector (Nta(1),…,Nta(Q))(N^{a}_{t}(1),\ldots,N^{a}_{t}(Q)). Also, let ν=(ν1,…,νQ)\nu=(\nu_{1},\ldots,\nu_{Q}) be the eigenvector of TKT_{K} with eigenvalue λ\lambda (unique, up to normalization, as PP is irreducible). From standard branching process results, we have

where X≥0X\geq 0 is a real-valued random variable, XX is continuous except that it has some mass at 0, and X=0X=0 if and only if the branching process eventually dies out and lastly,

under the conditions given in Theorem V.6.1 and Theorem V.6.2 of .

Set D=(1−10ε)log⁡(n/νaνb)/log⁡λD=(1-10\varepsilon)\log(n/\nu_{a}\nu_{b})/\log\lambda. Then D<(1−ε)log⁡(n/νaνb)/log⁡((1+2ε)λ)D<(1-\varepsilon)\log(n/\nu_{a}\nu_{b})/\log((1+2\varepsilon)\lambda) if ε\varepsilon is small enough, which we shall assume. Thus,

A4. proof of Lemma 4.9

We consider the branching process conditioned on survival. Now, we consider the single type branching process with offspring distribution Poi(Kaaπa)Poi(K_{aa}\pi_{a}) and the corresponding stochastic block model graph Gn′G^{\prime}_{n}, is the induced subgraph of the original graph GnG_{n}, where, vertices of Gn′G^{\prime}_{n} are only the vertices of type aa from GnG_{n}. So, Gn′G^{\prime}_{n} has in total nan_{a} vertices. So, we can always upper bound the the distance between two vertices of same type in GnG_{n}, by the distance between the two vertices in Gn′G^{\prime}_{n}, since, the path representing distance between two vertices in Gn′G^{\prime}_{n} is present in GnG_{n} but, the converse is not true. So, distance between two vertices in GnG_{n} is always less than distance between two vertices in Gn′G^{\prime}_{n}. So, we can say for any v,w∈V(Gn)orV(Gn′)v,w\in V(G_{n})orV(G^{\prime}_{n}) of same type,

From here on, we shall abuse notation a bit and call Gn′G^{\prime}_{n} as GnG_{n}, since we are only considering the graph Gn′G^{\prime}_{n} from here on as the graph from stochastic block model.

We have Kaa>0K_{aa}>0. Fix 0<η<1/100<\eta<1/10. We shall assume that η\eta is small enough that (1−2η)Kaaπa>1(1-2\eta)K_{aa}\pi_{a}>1. In the argument leading to (23) in proof of Lemma 4.6, we showed that, given ω(n)\omega(n) with ω(n)=o(n)\omega(n)=o(n) and a vertex vv of type aa, the neighborhood exploration process of vv in GnG_{n} could be coupled with the branching process B(1−2η)Kaa(a)\mathcal{B}_{(1-2\eta)K_{aa}}(a) so that whp the former dominates until it reaches size ω(n)\omega(n).

From here onwards we shall only consider a single-type branching process where particles have type aa. More precisely, writing Nd,aN_{d,a} for the number of vertices of type aa in generation dd of B(1−2η)Kaa(a)\mathcal{B}_{(1-2\eta)K_{aa}}(a), and Γd,a(v)\Gamma_{d,a}(v) for the set of type-aa vertices at graph distance dd from vv, whp

This relation between the number of vertices at generation dd of branching process B(1−2η)Kaa(a)\mathcal{B}_{(1-2\eta)K_{aa}}(a), denoted by Nd,aN_{d,a} and the number of vertices at distance dd from vv for the neighborhood exploration process of GnG_{n}, denoted by ∣Γd,a(v)∣|\Gamma_{d,a}(v)| becomes highly important later on in this proof. Note that the relation only holds when ∣Γ≤d(v)∣<ω(n)|\Gamma_{\leq d}(v)|<\omega(n) for some ω(n)\omega(n) such that ω(n)/n→0\omega(n)/n\rightarrow 0 as n→∞n\rightarrow\infty.

Now let us begin the second part of the proof. Let Nt(a)N_{t}(a) be the number of particles of type aa in the tt-th generation of BK\mathcal{B}_{K}. Also, let λa=Kaaπa\lambda_{a}=K_{aa}\pi_{a}. From standard branching process results, we have

where X≥0X\geq 0 is a real-valued random variable, XX is continuous except that it has some mass at 0, and X=0X=0 if and only if the branching process eventually dies out.

Now, we have conditioned that the branching process with kernel KaaK_{aa} is conditioned to survive. The right-hand side tends to ρ(Kaa)=1\rho(K_{aa})=1 as η→0\eta\rightarrow 0. Hence, given any fixed γ>0\gamma>0, if we choose η>0\eta>0 small enough we have

Now, the neighborhood exploration process and branching process can be coupled so that for every dd, ∣Γd(v)∣|\Gamma_{d}(v)| is at most the number MdM_{d} of particles in generation dd of B(1+2ε)Kaa(a)\mathcal{B}_{(1+2\varepsilon)K_{aa}}(a) from Lemma 4.6 and Eq (21). So, we have,

if η\eta is small enough, since DD be the integer part of log⁡((nπa)1/2+2η)/log⁡((1−2η)λa)\log((n\pi_{a})^{1/2+2\eta})/\log((1-2\eta)\lambda_{a}) and ∣na/n−πa∣<ε|n_{a}/n-\pi_{a}|<\varepsilon. Note that the power 2/32/3 here is arbitrary, we could have any power in the range (1/2,1)(1/2,1). Hence,

and whp the coupling described in (28) extends at least to the DD-neighborhood. So, now, we are in a position to apply Eq (28), as we have ∣Γ≤D(v)∣≤na2/3<ω(n)|\Gamma_{\leq D}(v)|\leq n_{a}^{2/3}<\omega(n), with ω(n)/n→0\omega(n)/n\rightarrow 0.

Now let vv and ww be two fixed vertices of G(na,Pa)G(n_{a},P_{a}), of type aa. We explore both their neighborhoods at the same time, stopping either when we reach distance DD in both neighborhoods, or we find an edge from one to the other, in which case vv and ww are within graph distance 2D+12D+1. We consider two independent branching processes B(1−2η)Kaa(a)\mathcal{B}_{(1-2\eta)K_{aa}}(a), B(1−2η)Kaa′(a)\mathcal{B}^{\prime}_{(1-2\eta)K_{aa}}(a), with Nd,aN_{d,a} and Nd,a′N^{\prime}_{d,a} vertices of type aa in generation dd respectively. By previous equation, whp we encounter o(n)o(n) vertices in the explorations so, by the argument leading to (28), whp either the explorations meet, or ∣ΓD,a(v)∣≥ND,a|\Gamma_{D,a}(v)|\geq N_{D,a} and ∣ΓD,a(w)∣≥ND,a′|\Gamma_{D,a}(w)|\geq N^{\prime}_{D,a} with the explorations not meeting. Using bound on Nd,aN_{d,a} and the independence of the branching processes, it follows that

Note that the two events in the above probability statement are not disjoint. We shall try to find the probability that the second event in the above equation holds but not the first. We have not examined any edges from ΓD(v)\Gamma_{D}(v) to ΓD(w)\Gamma_{D}(w), so these edges are present independently with their original unconditioned probabilities. The expected number of these edges is at least ∣ΓD,a(v)∣∣ΓD,a(w)∣Kaa/n|\Gamma_{D,a}(v)||\Gamma_{D,a}(w)|K_{aa}/n. If Kaa>0K_{aa}>0, this expectation is Ω((n1/2+η)2/n)=Ω(n2η)\Omega((n^{1/2+\eta})^{2}/n)=\Omega(n^{2\eta}). It follows that at least one edge is present with probability 1−exp⁡(−Ω(n2η))=1−o(1)1-\exp(-\Omega(n^{2\eta}))=1-o(1). If such an edge is present, then d(v,w)≤2D+1d(v,w)\leq 2D+1. So, the probability that the second event in the above equation holds but not the first is o(1)o(1). Thus, the last equation implies that

Choosing η\eta small enough, we have 2D+1≤(1+ε)log⁡n/log⁡λa2D+1\leq(1+\varepsilon)\log n/\log\lambda_{a}. As γ\gamma is arbitrary, we have

Now, λa=Kaaπa\lambda_{a}=K_{aa}\pi_{a} and the lemma follows.

A5. proof of Lemma 4.10

We consider the multi-type branching process with probability kernel Pab=KabnP_{ab}=\frac{K_{ab}}{n} ∀a,b=1,…,Q\forall a,b=1,\ldots,Q and the corresponding random graph GnG_{n} generated from stochastic block model has in total nn nodes. We condition that branching process BK\mathcal{B}_{K} survives.

Note that an upper bound 11 is obvious, since we are bounding a probability, so it suffices to prove a corresponding lower bound. We may and shall assume that Kab>0K_{ab}>0 for some a,ba,b.

Fix 0<η<1/100<\eta<1/10. We shall assume that η\eta is small enough that (1−2η)λ>1(1-2\eta)\lambda>1. In the argument leading to (23) in proof of Lemma 4.6, we showed that, given ω(n)\omega(n) with ω(n)=o(n)\omega(n)=o(n) and a vertex vv of type aa, the neighborhood exploration process of vv in GnG_{n} could be coupled with the branching process B(1−2η)K(a)\mathcal{B}_{(1-2\eta)K}(a) so that whp the former dominates until it reaches size ω(n)\omega(n). More precisely, writing Nd,cN_{d,c} for the number of particles of type cc in generation dd of B(1−2η)K(a)\mathcal{B}_{(1-2\eta)K}(a), and Γd,c(v)\Gamma_{d,c}(v) for the set of type cc vertices at graph distance dd from vv, whp

This relation between the number of vertices at generation dd of type cc of branching process B(1−2η)K(a)\mathcal{B}_{(1-2\eta)K}(a), denoted by Nd,cN_{d,c} and the number of vertices of type cc at distance dd from vv for the neighborhood exploration process of GnG_{n}, denoted by ∣Γd,c(v)∣|\Gamma_{d,c}(v)| becomes highly important later on in this proof, where, c=1,…,Qc=1,\ldots,Q. Note that the relation only holds when ∣Γ≤d(v)∣<ω(n)|\Gamma_{\leq d}(v)|<\omega(n) for some ω(n)\omega(n) such that ω(n)/n→0\omega(n)/n\rightarrow 0 as n→∞n\rightarrow\infty.

Let Nta(c)N^{a}_{t}(c) be the number of particles of type cc in the tt-th generation of BK(a)\mathcal{B}_{K}(a), then, NtaN^{a}_{t} is the vector (Nta(1),…,Nta(Q))(N^{a}_{t}(1),\ldots,N^{a}_{t}(Q)). Also, let ν=(ν1,…,νQ)\nu=(\nu_{1},\ldots,\nu_{Q}) be the eigenvector of TKT_{K} with eigenvalue λ\lambda (unique, up to normalization, as PP is irreducible). From standard branching process results, we have

where X≥0X\geq 0 is a real-valued random variable, XX is continuous except that it has some mass at 0, and X=0X=0 if and only if the branching process eventually dies out and lastly,

under the conditions given in Theorem V.6.1 and Theorem V.6.2 of .

Now, we have conditioned that the branching process with kernel KK is conditioned to survive. The right-hand side tends to ρ(K)=1\rho(K)=1 as η→0\eta\rightarrow 0. Hence, given any fixed γ>0\gamma>0, if we choose η>0\eta>0 small enough we have

Now, the neighborhood exploration process and branching process can be coupled so that for every dd, ∣Γd(v)∣|\Gamma_{d}(v)| is at most the number MdM_{d} of particles in generation dd of B(1+2ε)K(a)\mathcal{B}_{(1+2\varepsilon)K}(a) from Lemma 4.6 and Eq (21). So, we have,

if η\eta is small enough, since DD be the integer part of log⁡(n1/2+2η)/log⁡((1−2η)λ)\log(n^{1/2+2\eta})/\log((1-2\eta)\lambda). Note that the power 2/32/3 here is arbitrary, we could have any power in the range (1/2,1)(1/2,1). Hence,

and whp the coupling described in (30) extends at least to the DD-neighborhood. So, now, we are in a position to apply Eq (30), as we have ∣Γ≤D(v)∣≤na2/3<ω(n)|\Gamma_{\leq D}(v)|\leq n_{a}^{2/3}<\omega(n), with ω(n)/n→0\omega(n)/n\rightarrow 0.

Now let vv and ww be two fixed vertices of G(n,P)G(n,P), of types aa and bb respectively. We explore both their neighborhoods at the same time, stopping either when we reach distance DD in both neighborhoods, or we find an edge from one to the other, in which case vv and ww are within graph distance 2D+12D+1. We consider two independent branching processes B(1−2η)K(a)\mathcal{B}_{(1-2\eta)K}(a), B(1−2η)K′(b)\mathcal{B}^{\prime}_{(1-2\eta)K}(b), with Nd,caN^{a}_{d,c} and Nd,cbN^{b}_{d,c} vertices of type cc in generation dd respectively. By previous equation, whp we encounter o(n)o(n) vertices in the explorations so, by the argument leading to (30), whp either the explorations meet, or ∣ΓD,ca(v)∣≥ND,ca|\Gamma^{a}_{D,c}(v)|\geq N^{a}_{D,c} and ∣ΓD,cb(w)∣≥ND,cb|\Gamma^{b}_{D,c}(w)|\geq N^{b}_{D,c}, c=1,…,Qc=1,\ldots,Q, with the explorations not meeting. Using bound on Nd,caN^{a}_{d,c} and the independence of the branching processes, it follows that

Note that the two events in the above probability statement are not disjoint. We shall try to find the probability that the second event in the above equation holds but not the first. We have not examined any edges from ΓD(v)\Gamma_{D}(v) to ΓD(w)\Gamma_{D}(w), so these edges are present independently with their original unconditioned probabilities. For any c1c_{1}, c2c_{2}, the expected number of these edges is at least ∣ΓD,c1a(v)∣∣ΓD,c2b(w)∣Kc1c2/n|\Gamma^{a}_{D,c_{1}}(v)||\Gamma^{b}_{D,c_{2}}(w)|K_{c_{1}c_{2}}/n. Choosing c1,c2c_{1},c_{2} such that Kc1c2>0K_{c_{1}c_{2}}>0, this expectation is Ω((n1/2+η)2/n)=Ω(n2η)\Omega((n^{1/2+\eta})^{2}/n)=\Omega(n^{2\eta}). It follows that at least one edge is present with probability 1−exp⁡(−Ω(n2η))=1−o(1)1-\exp(-\Omega(n^{2\eta}))=1-o(1). If such an edge is present, then d(v,w)≤2D+1d(v,w)\leq 2D+1. So, the probability that the second event in the above equation holds but not the first is o(1)o(1). Thus, the last equation implies that

Choosing η\eta small enough, we have 2D+1≤(1+ε)log⁡(n)/log⁡λ2D+1\leq(1+\varepsilon)\log(n)/\log\lambda. As γ\gamma is arbitrary, we have