Graph Theory

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 2

University of Aberdeen

Author Kaja Wroblewska, 51984985


Department of Mathematics
Date 21.4.2021

MA2508 Linear Algebra


Essay on Linear Algebra in Graph Theory

Graph theory is a field of mathematics regarding mathematical structures used to model


pairwise relations between objects. A graph, usually denoted as G(N , L) is a representation
of a network where N is a set of vertices (also referred to as nods or points) and L – set
of links (or edges) between them. They can be used to model various types of relations or
processes in numerous fields such as biology, physics computer science, or even linguistics.
Apart from elegant visual representations of linked nods, graphs can be also presented in a
form of a matrix. The simplest of which would be the adjacency matrix A. The aij entry is
equal to the number of edges from i to j (which usually is 0 or 1). If the graph has no loops
the diagonal entries of A are always 0. Another form of a graph would be a weighted graph,
where individual edges have their own value denoted as wij . The 1’s and 0’s in the adjacency
matrix are replaced by corresponding weighted edges.
Another important structure within a graph is a component (also called a cluster). It is
a subset of vertices connected within each other but not connected to vertices outside the
subset. As it turns out the number of components in a graph and its overall connectivity
are strictly related to the eigenvalues of the Laplacian matrix. In order to define said matrix
we need to introduce one more term – the degree deg(v) of a vertex which is the number of
edges the vertex belongs to. Having those values in mind we can create the degree matrix D
described as a diagonal matrix diag(deg(1), deg(2), . . . , deg(n)) of the vertex degrees. From
that we can easily derive the formula for the Laplacian matrix by subtracting the diagonal
matrix from the adjacent matrix: LA = D − A. Let’s analyze this on an example.

1 2

4 3

 
0 w12 w13 0
w12 0 w23 w24 
A=
w13 w23 0

0 
0 w24 0 0
 
w12 + w13 0 0 0
 0 w12 + w23 + w24 0 0 
D= 
 0 0 w13 + w23 0 
0 0 0 w24
 
w12 + w13 −w12 −w13 0
 −w12 w12 + w23 + w24 −w23 −w24 
LA = 
 −w13

−w23 w13 + w23 0 
0 −w24 0 w24
Essay on Linear Algebra in Graph Theory 21.4.2021 page 2


di
 if i = j
We can also define the Laplacian Matrix as Lij = −wij if (i,j) is an edge where

0 if no edge between i,j

P
di = j|(ij)∈E wij
For matrix A, λ is an eigenvalue of A if there exists a non-zero vector v, such as Av = λv. v
is the eigenvector of A corresponding to λ. For graph with n vertices, its adjancency matrix
has n eigenvalues and n corresponding eigenvectors.
Eigenvalues of the Laplacian matrix (LA v = λv) reveal global graph properties not apparent
from the graph structure. By sorting out the values we define spectrum of the Laplacian as
0 = λ1 ≤ λ2 ≤ ... ≤ λn . If 0 is an eigenvalue of LA with k eigenvectors, then graph G has k
connected components. If G is connected and λ2 > 0 then λ2 is the algebraic connectivity of
G - the greater λ2 , the more connected G is. Accordingly, if we are looking for the bi-partition
of the graph; the smaller λ2 , the better quality of partitioning.
Eigendecomposition of the Laplacian matrix also yields eigenvectors. By mapping the nods
i in the graph G onto v2 (i) we are left with a set of vectors useful in determining clusters.
To find clusters C1 and C2 we need split a set in zero - assign v2 (i) > 0 to C1 and v2 (i) < 0
to C2 . This algorithm gives us a base for extending it to k-partitions. We know two basic
approaches to this problem. The first one being intuitive but unfortunately inefficient -
recursive application of the bi-partitioning algorithm. In other words, we are repetitively
dividing the graph in half. Another, more effective technique, is building a reduced space
from multiple eigenvectors. After embedding all the data points in the low-dimensional space
(spectra embedding) we can see that clusters are more obvious with the use of eigenvectors
of graph Laplacian.

References

[1] Algebraic Graph Theory by Chris Godsil, Gordon Royle

[2] Mieghem, P. (2010). Graph Spectra for Complex Network pages: 67-109

[3] Gilbert Strang. 18.065 Matrix Methods in Data Analysis, Signal Processing, and Ma-
chine Learning. Spring 2018. Massachusetts Institute of Technology: MIT OpenCourse-
Ware, https://ocw.mit.edu. License: Creative Commons BY-NC-SA.; lecture: 35. Find-
ing Clusters in Graphs

[4] Wikipedia - Graph theory

[5] Wikipedia - Spectral Clustering

You might also like