Introduction to Network And SNA Theory: Basic Concepts R. Nabati Department of Computer Engineering Islamic Azad University of Sanandaj

Slides:



Advertisements
Similar presentations
What is a Network? Network = graph
Advertisements

Chapter 9 Graphs.
22C:19 Discrete Math Graphs Fall 2010 Sukumar Ghosh.
22C:19 Discrete Math Graphs Fall 2014 Sukumar Ghosh.
Introduction to Network Theory: Modern Concepts, Algorithms
Introduction This chapter explores graphs and their applications in computer science This chapter explores graphs and their applications in computer science.
Advanced Topics in Data Mining Special focus: Social Networks.
CS 599: Social Media Analysis University of Southern California1 The Basics of Network Analysis Kristina Lerman University of Southern California.
C++ Programming: Program Design Including Data Structures, Third Edition Chapter 21: Graphs.
Mining and Searching Massive Graphs (Networks)
Graph & BFS.
Introduction to Graphs
Graphs G = (V,E) V is the vertex set. Vertices are also called nodes and points. E is the edge set. Each edge connects two different vertices. Edges are.
CS/ENGRD 2110 Object-Oriented Programming and Data Structures Fall 2014 Doug James Lecture 17: Graphs.
KNURE, Software department, Ph , N.V. Bilous Faculty of computer sciences Software department, KNURE Discrete.
22C:19 Discrete Math Graphs Spring 2014 Sukumar Ghosh.
Social Media Mining Graph Essentials.
CS105 Introduction to Social Network Lecture: Yang Mu UMass Boston.
Information Networks Power Laws and Network Models Lecture 3.
Models and Algorithms for Complex Networks Networks and Measurements Lecture 3.
GRAPH Learning Outcomes Students should be able to:
Introduction to Network Theory: Basic Concepts
Graphs Chapter 10.
Graph Theoretic Concepts. What is a graph? A set of vertices (or nodes) linked by edges Mathematically, we often write G = (V,E)  V: set of vertices,
Class 2: Graph theory and basic terminology Learning the language Network Science: Graph Theory 2012 Prof. Albert-László Barabási Dr. Baruch Barzel, Dr.
GRAPHS CSE, POSTECH. Chapter 16 covers the following topics Graph terminology: vertex, edge, adjacent, incident, degree, cycle, path, connected component,
Clustering of protein networks: Graph theory and terminology Scale-free architecture Modularity Robustness Reading: Barabasi and Oltvai 2004, Milo et al.
1 Topics Intro. to Graphs (11.1) A B C D EF G. 2 Definition (p.650) A graph G = V(G) + E(G) A set of vertices (or nodes), V(G) = {v 1, v 2, …, v n } A.
Chapter 6 Graph Theory R. Johnsonbaugh Discrete Mathematics 5 th edition, 2001.
1 CS104 : Discrete Structures Chapter V Graph Theory.
Based on slides by Y. Peng University of Maryland
Mathematics of Networks (Cont)
Week 11 - Monday.  What did we talk about last time?  Binomial theorem and Pascal's triangle  Conditional probability  Bayes’ theorem.
Data Structures & Algorithms Graphs
Basic Notions on Graphs. The House-and-Utilities Problem.
Complex Networks: Models Lecture 2 Slides by Panayiotis TsaparasPanayiotis Tsaparas.
1 12/2/2015 MATH 224 – Discrete Mathematics Formally a graph is just a collection of unordered or ordered pairs, where for example, if {a,b} G if a, b.
September1999 CMSC 203 / 0201 Fall 2002 Week #13 – 18/20/22 November 2002 Prof. Marie desJardins.
Chapter 5 Graphs  the puzzle of the seven bridge in the Königsberg,  on the Pregel.
An Introduction to Graph Theory
Graph Theory and Applications
Introduction to Graph Theory
GRAPHS. Graph Graph terminology: vertex, edge, adjacent, incident, degree, cycle, path, connected component, spanning tree Types of graphs: undirected,
Discrete Structures CISC 2315 FALL 2010 Graphs & Trees.
Graphs Lecture 2. Graphs (1) An undirected graph is a triple (V, E, Y), where V and E are finite sets and Y:E g{X V :| X |=2}. A directed graph or digraph.
Graph Theory Unit: 4.
Class 2: Graph Theory IST402. Can one walk across the seven bridges and never cross the same bridge twice? Network Science: Graph Theory THE BRIDGES OF.
Chapter 9: Graphs.
Introduction to Graph Theory By: Arun Kumar (Asst. Professor) (Asst. Professor)
Class 2: Graph Theory IST402.
Chapter 20: Graphs. Objectives In this chapter, you will: – Learn about graphs – Become familiar with the basic terminology of graph theory – Discover.
Graph Theory Graph Theory - History Leonhard Euler's paper on “Seven Bridges of Königsberg”, published in 1736.
1 GRAPH Learning Outcomes Students should be able to: Explain basic terminology of a graph Identify Euler and Hamiltonian cycle Represent graphs using.
1 Data Structures and Algorithms Graphs. 2 Graphs Basic Definitions Paths and Cycles Connectivity Other Properties Representation Examples of Graph Algorithms:
Fundamental Graph Theory (Lecture 1) Lectured by Hung-Lin Fu 傅 恆 霖 Department of Applied Mathematics National Chiao Tung University.
Chapter Chapter Summary Graphs and Graph Models Graph Terminology and Special Types of Graphs Representing Graphs and Graph Isomorphism Connectivity.
An Introduction to Graph Theory
Graphs: Definitions and Basic Properties
Chapter 9 (Part 2): Graphs
Special Graphs By: Sandeep Tuli Astt. Prof. CSE.
Graphs Hubert Chan (Chapter 9) [O1 Abstract Concepts]
Applications of graph theory in complex systems research
Graph theory Definitions Trees, cycles, directed graphs.
Taibah University College of Computer Science & Engineering Course Title: Discrete Mathematics Code: CS 103 Chapter 10 Graphs Slides are adopted from “Discrete.
Graphs Chapter 13.
Graphs All tree structures are hierarchical. This means that each node can only have one parent node. Trees can be used to store data which has a definite.
Graph Operations And Representation
Introduction to Graph Theory
Advanced Topics in Data Mining Special focus: Social Networks
Chapter 9 Graph algorithms
Presentation transcript:

Introduction to Network And SNA Theory: Basic Concepts R. Nabati Department of Computer Engineering Islamic Azad University of Sanandaj

What is a Network? Network = graph Network = graph Informally a graph is a set of nodes joined by a set of lines or arrows. Informally a graph is a set of nodes joined by a set of lines or arrows

Graph-based representations Representing a problem as a graph can provide a different point of view Representing a problem as a graph can make a problem much simpler More accurately, it can provide the appropriate tools for solving the problem

What is network theory? Network theory provides a set of techniques for analysing graphs Complex systems network theory provides techniques for analysing structure in a system of interacting agents, represented as a network Applying network theory to a system means using a graph-theoretic representation

What makes a problem graph-like? There are two components to a graph Nodes and edges In graph-like problems, these components have natural correspondences to problem elements Entities are nodes and interactions between entities are edges Most complex systems are graph-like

Friendship Network

Scientific collaboration network

Business ties in US biotech- industry

Genetic interaction network

Protein-Protein Interaction Networks

Transportation Networks

Internet

Ecological Networks

Graph Theory - History Leonhard Euler's paper on “Seven Bridges of Königsberg”, published in 1736.

Graph TheoryCh. 1. Fundamental Concept16 A Model A vertex : a region An edge : a path(bridge) between two regions e1e1 e2e2 e3e3 e4e4 e6e6 e5e5 e7e7 Z Y X W X Y Z W

Graph Theory - History Cycles in Polyhedra Thomas P. Kirkman William R. Hamilton Hamiltonian cycles in Platonic graphs

Graph Theory - History Gustav Kirchhoff Trees in Electric Circuits

Graph Theory - History Arthur Cayley James J. Sylvester George Polya Enumeration of Chemical Isomers

Graph Theory - History Francis Guthrie Auguste DeMorgan Four Colors of Maps

Definition: Graph G is an ordered triple G:=(V, E, f) G is an ordered triple G:=(V, E, f) V is a set of nodes, points, or vertices. V is a set of nodes, points, or vertices. E is a set, whose elements are known as edges or lines. E is a set, whose elements are known as edges or lines. f is a function f is a function maps each element of E maps each element of E to an unordered pair of vertices in V. to an unordered pair of vertices in V.

Definitions Vertex Vertex Basic Element Basic Element Drawn as a node or a dot. Drawn as a node or a dot. Vertex set of G is usually denoted by V(G), or V Vertex set of G is usually denoted by V(G), or V Edge Edge A set of two elements A set of two elements Drawn as a line connecting two vertices, called end vertices, or endpoints. Drawn as a line connecting two vertices, called end vertices, or endpoints. The edge set of G is usually denoted by E(G), or E. The edge set of G is usually denoted by E(G), or E.

Example V:={1,2,3,4,5,6} E:={{1,2},{1,5},{2,3},{2,5},{3,4},{4,5},{4,6}}

Simple Graphs Simple graphs are graphs without multiple edges or self-loops.

Directed Graph (digraph) Edges have directions Edges have directions An edge is an ordered pair of nodes An edge is an ordered pair of nodes loop node multiple arc arc

Weighted graphs is a graph for which each edge has an associated weight, usually given by a weight function w: E  R.

Structures and structural metrics Graph structures are used to isolate interesting or important sections of a graph Structural metrics provide a measurement of a structural property of a graph Global metrics refer to a whole graph Local metrics refer to a single node in a graph

Graph structures Identify interesting sections of a graph Interesting because they form a significant domain-specific structure, or because they significantly contribute to graph properties A subset of the nodes and edges in a graph that possess certain characteristics, or relate to each other in particular ways

Connectivity a graph a graph is connected if you can get from any node to any other by following a sequence of edges OR any two nodes are connected by a path. A directed graph is strongly connected if there is a directed path from any node to any other node.

Component Every disconnected graph can be split up into a number of connected components. Every disconnected graph can be split up into a number of connected components.

Degree Number of edges incident on a node Number of edges incident on a node The degree of 5 is 3

Degree (Directed Graphs) In-degree: Number of edges entering In-degree: Number of edges entering Out-degree: Number of edges leaving Out-degree: Number of edges leaving Degree = indeg + outdeg Degree = indeg + outdeg outdeg(1)=2 indeg(1)=0 outdeg(2)=2 indeg(2)=2 outdeg(3)=1 indeg(3)=4

Degree: Simple Facts If G is a graph with m edges, then  deg(v) = 2m = 2 |E | If G is a digraph then  indeg(v)=  outdeg(v) = |E | Number of Odd degree Nodes is even

Walks A walk of length k in a graph is a succession of k (not necessarily different) edges of the form uv,vw,wx,…,yz. This walk is denote by uvwx…xz, and is referred to as a walk between u and z. A walk is closed is u=z.

Graph TheoryCh. 1. Fundamental Concept35 Chromatic Number The chromatic number of a graph G, written x(G), is the minimum number of colors needed to label the vertices so that adjacent vertices receive different colors Red Green Blue x(G) = 3

Path A path is a walk in which all the edges and all the nodes are different. A path is a walk in which all the edges and all the nodes are different. Walks and Paths 1,2,5,2,3,4 1,2,5,2,3,2,1 1,2,3,4,6 walk of length 5 CW of length 6 path of length 4

Cycle A cycle is a closed walk in which all the edges are different. 1,2,5,1 2,3,4,5,2 3-cycle 4-cycle

Special Types of Graphs Empty Graph / Edgeless graph Empty Graph / Edgeless graph No edge No edge Null graph Null graph No nodes No nodes Obviously no edge Obviously no edge

Trees Connected Acyclic Graph Connected Acyclic Graph Two nodes have exactly one path between them Two nodes have exactly one path between them

Special Trees Paths Stars

Connected Graph All nodes have the same degree Regular

Special Regular Graphs: Cycles C 3 C 4 C 5

Bipartite graph V can be partitioned into 2 sets V 1 and V 2 such that (u,v)  E implies V can be partitioned into 2 sets V 1 and V 2 such that (u,v)  E implies either u  V 1 and v  V 2 either u  V 1 and v  V 2 OR v  V 1 and u  V 2. OR v  V 1 and u  V 2.

Complete Graph Every pair of vertices are adjacent Every pair of vertices are adjacent Has n(n-1)/2 edges Has n(n-1)/2 edges

Complete Bipartite Graph Bipartite Variation of Complete Graph Bipartite Variation of Complete Graph Every node of one set is connected to every other node on the other set Every node of one set is connected to every other node on the other set Stars

Planar Graphs Can be drawn on a plane such that no two edges intersect Can be drawn on a plane such that no two edges intersect K 4 is the largest complete graph that is planar K 4 is the largest complete graph that is planar

Planar graphs 47

Subgraph Vertex and edge sets are subsets of those of G Vertex and edge sets are subsets of those of G a supergraph of a graph G is a graph that contains G as a subgraph. a supergraph of a graph G is a graph that contains G as a subgraph.

Special Subgraphs: Cliques. A clique is a maximum complete connected subgraph. AB D H FE C IG

Spanning subgraph Subgraph H has the same vertex set as G. Subgraph H has the same vertex set as G. Possibly not all the edges Possibly not all the edges “H spans G”. “H spans G”.

Spanning tree Let G be a connected graph. Then a spanning tree in G is a subgraph of G that includes every node and is also a tree. Let G be a connected graph. Then a spanning tree in G is a subgraph of G that includes every node and is also a tree.

Isomorphism Bijection, i.e., a one-to-one mapping: Bijection, i.e., a one-to-one mapping: f : V(G) -> V(H) u and v from G are adjacent if and only if f(u) and f(v) are adjacent in H. If an isomorphism can be constructed between two graphs, then we say those graphs are isomorphic. If an isomorphism can be constructed between two graphs, then we say those graphs are isomorphic.

Isomorphism Problem Determining whether two graphs are isomorphic Determining whether two graphs are isomorphic Although these graphs look very different, they are isomorphic; one isomorphism between them is Although these graphs look very different, they are isomorphic; one isomorphism between them is f(a)=1 f(b)=6 f(c)=8 f(d)=3 f(g)=5 f(h)=2 f(i)=4 f(j)=7

Graph TheoryCh. 1. Fundamental Concept54 Components The components of a graph G are its maximal connected subgraphs An isolated vertex is a vertex of degree 0

Representation (Matrix) Incidence Matrix Incidence Matrix V x E V x E [vertex, edges] contains the edge's data [vertex, edges] contains the edge's data Adjacency Matrix Adjacency Matrix V x V V x V Boolean values (adjacent or not) Boolean values (adjacent or not) Or Edge Weights Or Edge Weights

Matrices

Representation (List) Edge List Edge List pairs (ordered if directed) of vertices pairs (ordered if directed) of vertices Optionally weight and other data Optionally weight and other data Adjacency List (node list) Adjacency List (node list)

Implementation of a Graph. Adjacency-list representation Adjacency-list representation an array of |V | lists, one for each vertex in V. an array of |V | lists, one for each vertex in V. For each u  V, ADJ [ u ] points to all its adjacent vertices. For each u  V, ADJ [ u ] points to all its adjacent vertices.

Edge and Node Lists Edge List Node List

Edge List Edge Lists for Weighted Graphs

Topological Distance A shortest path is the minimum path connecting two nodes. The number of edges in the shortest path connecting p and q is the topological distance between these two nodes, d p,q

Degree Centrality B ED C A degree

Betweenness centrality The number of shortest paths in the graph that pass through the node divided by the total number of shortest paths.

Betweenness centrality B Shortest paths are: AB, AC, ABD, ABE, BC, BD, BE, CBD, CBE, DBE B has a BC of 5 A C D E

Betweenness centrality Nodes with a high betweenness centrality are interesting because they control information flow in a network may be required to carry more information And therefore, such nodes may be the subject of targeted attack

Closeness centrality The normalised inverse of the sum of topological distances in the graph.

B ED C A Closeness centrality

B ED C A Closeness

Node B is the most central one in spreading information from it to the other nodes in the network. Closeness centrality

|V | x |V | matrix D = ( d ij ) such that d ij is the topological distance between i and j. Distance Matrix

 A community is defined as a clique in the communicability graph.  Identifying communities is reduced to the “all cliques problem” in the communicability graph. Communicability Graph

Social (Friendship) Network Communities: Example

The Network Its Communicability Graph

Communities Social Networks Metabolic Networks

Social Network Analysis Introduction

Diameter Average Path Length The longest shortest path in a graph The average of the shortest paths for all pairs of nodes. 76

Characterizing networks:Is everything connected? 77

The adjacency matrix of a network with several components can be written in a block-diagonal form, so that nonzero elements are confined to squares, with all other elements being zero: CONNECTIVITY OF UNDIRECTED GRAPHS Adjacency Matrix 78

Bridges and Local Bridges0 And edge that joins two nodes A and B in a graph is called a bridge if deleting the edge would cause A and B to lay in two different components local bridge - in real-world networks (with a giant component) - if deleting an edge between A and B would increase distance > 2 79

Clustering coefficient 80

Clustering coefficient: what fraction of your neighbors are connected? Node i with degree k i C i in [0,1] CLUSTERING COEFFICIENT 81

WWW > directed multigraph with self-interactions Protein Interactions > undirected unweighted with self-interactions Collaboration network > undirected multigraph or weighted. Mobile phone calls > directed, weighted. Facebook Friendship links > undirected, unweighted. GRAPHOLOGY: Real networks can have multiple characteristics 82

Undirected network N=2,018 proteins as nodes L=2,930 binding interactions as links. Average degree =2.90. Not connected: 185 components the largest (giant component) 1,647 nodes A CASE STUDY: PROTEIN-PROTEIN INTERACTION NETWORK 83

p k is the probability that a node has degree k. N k = # nodes with degree k p k = N k / N A CASE STUDY: PROTEIN-PROTEIN INTERACTION NETWORK 84

d max =14 =5.61 A CASE STUDY: PROTEIN-PROTEIN INTERACTION NETWORK 85

=0.12 A CASE STUDY: PROTEIN-PROTEIN INTERACTION NETWORK 86

Real network properties Most nodes have only a small number of neighbors (degree), but there are some nodes with very high degree (power-law degree distribution) scale-free networks If a node x is connected to y and z, then y and z are likely to be connected high clustering coefficient Most nodes are just a few edges away on average. small world networks Networks from very diverse areas (from internet to biological networks) have similar properties Is it possible that there is a unifying underlying generative process? 87

The basic random graph model The measurements on real networks are usually compared against those on “random networks” The basic G n,p (Erdös-Renyi) random graph model: n : the number of vertices 0 ≤ p ≤ 1 for each pair (i,j), generate the edge (i,j) independently with probability p

Degree distributions Problem: find the probability distribution that best fits the observed data degree frequency k fkfk f k = fraction of nodes with degree k p(k) = probability of a randomly selected node to have degree k

Power-law distributions The degree distributions of most real-life networks follow a power law Right-skewed/Heavy-tail distribution there is a non-negligible fraction of nodes that has very high degree (hubs) scale-free: no characteristic scale, average is not informative In stark contrast with the random graph model! Poisson degree distribution, z=np highly concentrated around the mean the probability of very high degree nodes is exponentially small p(k) = Ck - 

Power-law signature Power-law distribution gives a line in the log-log plot  : power-law exponent (typically 2 ≤  ≤ 3) degree frequency log degree log frequency α log p(k) = -  logk + logC

Power Laws Albert and Barabasi (1999) Power-law distributions are straight lines in log-log space. -- slope being r y=k -r  log y = -r log k  ly= -r lk How should random graphs be generated to create a power-law distribution of node degrees? Hint: Pareto’s* Law: Wealth distribution follows a power law. Power laws in real networks: (a) WWW hyperlinks (b) co-starring in movies (c) co-authorship of physicists (d) co-authorship of neuroscientists * Same Velfredo Pareto, who defined Pareto optimality in game theory.

Examples of degree distribution for power laws Taken from [Newman 2003]

A random graph example

What is a Logarithm? The common or base-10 logarithm of a number is the power to which 10 must be raised to give the number. Since 100 = 10 2, the logarithm of 100 is equal to 2. This is written as: Log(100) = 2. 1,000,000 = 10 6 (one million), and Log (1,000,000) = 6.

Years before present (YBP)

Data plotted with linear scale All except the first two data points are hidden on the axis.

Log (YBP)

Plot using Logs All data are well represented despite their wide range.

Your calculator should have a button marked LOG. Make sure you can use it to generate this table.

Copyright © by Houghton Mifflin Company, Inc. All rights reserved.101 x y Graph f(x) = log 2 x Since the logarithm function is the inverse of the exponential function of the same base, its graph is the reflection of the exponential function in the line y = x –1 –2 2x2x x y = log 2 x y = x y = 2 x (1, 0) x-intercept horizontal asymptote y = 0 vertical asymptote x = 0

Example Sketch the graph of the function y = ln x. Solution We first sketch the graph of y = e x. 1 x y 1 y =exy =exy =exy =ex y = ln x y =xy =xy =xy =x  The required graph is the mirror image of the graph of y = e x with respect to the line y = x:

Exponential distribution Observed in some technological or collaboration networks Identified by a line in the log-linear plot p(k) = e - k log p(k) = - k + log degree log frequency λ

104 An Experiment by Milgram (1967) Outcome revealed two fundamental components of a social network: Very short paths between arbitrary pairs of nodes Individuals operating with purely local information are very adept at finding these paths

105 What is the “small world” phenomenon? Principle that most people in a society are linked by short chains of acquaintances Sometimes referred to as the “six degrees of separation” theory

References  Aldous & Wilson, Graphs and Applications. An Introductory Approach, Springer,  Wasserman & Faust, Social Network Analysis, Cambridge University Press,  Estrada & Rodríguez-Velázquez, Phys. Rev. E 2005, 71,  Estrada & Hatano, Phys. Rev. E. 2008, 77,

107 Questions?Questions?