89
Introduction to Network Theory Lecture 1 Manuel Sebastian Mariani URPP Social Networks Network Theory and Analytics | 18.09.18

IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

  • Upload
    others

  • View
    5

  • Download
    1

Embed Size (px)

Citation preview

Page 1: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Introduction to Network TheoryLecture 1

Manuel Sebastian MarianiURPP Social Networks

Network Theory and Analytics | 18.09.18

Page 2: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Outlook

L1: Introduction to Network Theory | 1. Outlook

Page 3: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

1 Outlook

2 Introductory example

3 Basic Concepts

4 Representation

5 Network types

6 Simple network models

7 Exercise

L1: Introduction to Network Theory | 1. Outlook

Page 4: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Introductory example

L1: Introduction to Network Theory | 2. Introductory example

Page 5: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

The bridges of Königsberg 5

Is there a trail that transverses each bridge exactly once?XVIII Century

Euler, 1736: Geometry is unimportant, only degree ma ers.First paper in the history of graph theory.

■ Nodes: landmasses; edges: bridges■ The number of bridges touching every landmass must be even■ Only start and end nodes might have odd degrees■ It is not possible to make such a trail

L1: Introduction to Network Theory | 2. Introductory example

Page 6: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

The bridges of Königsberg 5

Is there a trail that transverses each bridge exactly once?XVIII Century

Euler, 1736: Geometry is unimportant, only degree ma ers.First paper in the history of graph theory.

■ Nodes: landmasses; edges: bridges■ The number of bridges touching every landmass must be even■ Only start and end nodes might have odd degrees■ It is not possible to make such a trail

L1: Introduction to Network Theory | 2. Introductory example

Page 7: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

The bridges of Königsberg 5

Is there a trail that transverses each bridge exactly once?XVIII Century

Euler, 1736: Geometry is unimportant, only degree ma ers.First paper in the history of graph theory.

■ Nodes: landmasses; edges: bridges■ The number of bridges touching every landmass must be even■ Only start and end nodes might have odd degrees■ It is not possible to make such a trail

L1: Introduction to Network Theory | 2. Introductory example

Page 8: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

The bridges of Königsberg 5

Is there a trail that transverses each bridge exactly once?XVIII Century

Euler, 1736: Geometry is unimportant, only degree ma ers.First paper in the history of graph theory.

■ Nodes: landmasses; edges: bridges■ The number of bridges touching every landmass must be even■ Only start and end nodes might have odd degrees■ It is not possible to make such a trail

L1: Introduction to Network Theory | 2. Introductory example

Page 9: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

The bridges of Kaliningrad 6

Nowadays it is possible to transverse exactly once each of theexisting bridges

XXI Century

■ On the modern map of Kaliningrad:■ Green bridges survived until today■ Red bridges were destroyed in WWII■ Blue bridges were built last Century

L1: Introduction to Network Theory | 2. Introductory example

Page 10: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

The bridges of Kaliningrad 6

Nowadays it is possible to transverse exactly once each of theexisting bridges

XXI Century

■ On the modern map of Kaliningrad:■ Green bridges survived until today■ Red bridges were destroyed in WWII■ Blue bridges were built last Century

L1: Introduction to Network Theory | 2. Introductory example

Page 11: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Applications of Graph theory 7

■ Computer Science - graphs themselves are the objects ofinterest

■ Social Sciences - connections between people in society■ Electrical Engineering - designing circuit connections■ Epidemiology - contagion process in connected society■ Chemistry - graphs represent molecular structure■ …

L1: Introduction to Network Theory | 2. Introductory example

Page 12: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Applications of Graph theory 7

■ Computer Science - graphs themselves are the objects ofinterest

■ Social Sciences - connections between people in society■ Electrical Engineering - designing circuit connections■ Epidemiology - contagion process in connected society■ Chemistry - graphs represent molecular structure■ …

L1: Introduction to Network Theory | 2. Introductory example

Page 13: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Applications of Graph theory 7

■ Computer Science - graphs themselves are the objects ofinterest

■ Social Sciences - connections between people in society■ Electrical Engineering - designing circuit connections■ Epidemiology - contagion process in connected society■ Chemistry - graphs represent molecular structure■ …

L1: Introduction to Network Theory | 2. Introductory example

Page 14: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Applications of Graph theory 7

■ Computer Science - graphs themselves are the objects ofinterest

■ Social Sciences - connections between people in society■ Electrical Engineering - designing circuit connections■ Epidemiology - contagion process in connected society■ Chemistry - graphs represent molecular structure■ …

L1: Introduction to Network Theory | 2. Introductory example

Page 15: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Applications of Graph theory 7

■ Computer Science - graphs themselves are the objects ofinterest

■ Social Sciences - connections between people in society■ Electrical Engineering - designing circuit connections■ Epidemiology - contagion process in connected society■ Chemistry - graphs represent molecular structure■ …

L1: Introduction to Network Theory | 2. Introductory example

Page 16: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Basic Concepts

L1: Introduction to Network Theory | 3. Basic Concepts

Page 17: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Nodes 9

■ Set of nodes is called V■ Fundamental units of which graphs are formed■ Have many names:

■ Nodes■ Vertices■ Points■ Actors

■ Represent objects■ Individuals■ Websites■ Geographical Locations■ Banks■ ...

■ Are usually featureless (but not always)

L1: Introduction to Network Theory | 3. Basic Concepts

Page 18: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Nodes 9

■ Set of nodes is called V■ Fundamental units of which graphs are formed■ Have many names:

■ Nodes■ Vertices■ Points■ Actors

■ Represent objects■ Individuals■ Websites■ Geographical Locations■ Banks■ ...

■ Are usually featureless (but not always)

L1: Introduction to Network Theory | 3. Basic Concepts

Page 19: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Edges 10

■ Set of edges is called E■ Second fundamental unit■ Have many names:

■ Edges■ Arcs■ Lines■ Ties

■ Represent connections between objects:■ Friendship / follower / subscriber■ Web-link■ Geographical approachability■ Loan■ ...

■ Might have features (e.g. weight, see below)

L1: Introduction to Network Theory | 3. Basic Concepts

Page 20: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Edges 10

■ Set of edges is called E■ Second fundamental unit■ Have many names:

■ Edges■ Arcs■ Lines■ Ties

■ Represent connections between objects:■ Friendship / follower / subscriber■ Web-link■ Geographical approachability■ Loan■ ...

■ Might have features (e.g. weight, see below)

L1: Introduction to Network Theory | 3. Basic Concepts

Page 21: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Graph 11

■ Graph is an ordered pair G = (V , E )■ In networks, network size; In graph

theory, order of the graph: |V |■ In graph theory, size of the graph: |E

L1: Introduction to Network Theory | 3. Basic Concepts

Page 22: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Graph 12

■ Graph is an ordered pair G = (V , E )■ E consists of 2-element subsets of V■ Vertices belonging to an edge are called

ends or end vertices of the edge■ Vertices connected by an edge are

called neighbouring or adjacent.■ Some vertices may not belong to any

edge, but all edges belong to a pair ofvertices

L1: Introduction to Network Theory | 3. Basic Concepts

Page 23: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Graph 12

■ Graph is an ordered pair G = (V , E )■ E consists of 2-element subsets of V■ Vertices belonging to an edge are called

ends or end vertices of the edge■ Vertices connected by an edge are

called neighbouring or adjacent.■ Some vertices may not belong to any

edge, but all edges belong to a pair ofvertices

L1: Introduction to Network Theory | 3. Basic Concepts

Page 24: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Graph 12

■ Graph is an ordered pair G = (V , E )■ E consists of 2-element subsets of V■ Vertices belonging to an edge are called

ends or end vertices of the edge■ Vertices connected by an edge are

called neighbouring or adjacent.■ Some vertices may not belong to any

edge, but all edges belong to a pair ofvertices

L1: Introduction to Network Theory | 3. Basic Concepts

Page 25: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Graph 12

■ Graph is an ordered pair G = (V , E )■ E consists of 2-element subsets of V■ Vertices belonging to an edge are called

ends or end vertices of the edge■ Vertices connected by an edge are

called neighbouring or adjacent.■ Some vertices may not belong to any

edge, but all edges belong to a pair ofvertices

L1: Introduction to Network Theory | 3. Basic Concepts

Page 26: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Graph 12

■ Graph is an ordered pair G = (V , E )■ E consists of 2-element subsets of V■ Vertices belonging to an edge are called

ends or end vertices of the edge■ Vertices connected by an edge are

called neighbouring or adjacent.■ Some vertices may not belong to any

edge, but all edges belong to a pair ofvertices

L1: Introduction to Network Theory | 3. Basic Concepts

Page 27: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Graphs and networks 13

A graph is the mathematical object formally defined aboveGraph

A network is the representation of a real-world system. Nodesand links have a specific meaning within the context of the appli-cation. Also, they have a ributes

Network

Graph theory versus network theory■ Different research questions■ Graph techniques can be used to analyse networks■ All networks are graphs (but the opposite is not true)

L1: Introduction to Network Theory | 3. Basic Concepts

Page 28: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Graphs and networks 13

A graph is the mathematical object formally defined aboveGraph

A network is the representation of a real-world system. Nodesand links have a specific meaning within the context of the appli-cation. Also, they have a ributes

Network

Graph theory versus network theory■ Different research questions■ Graph techniques can be used to analyse networks■ All networks are graphs (but the opposite is not true)

L1: Introduction to Network Theory | 3. Basic Concepts

Page 29: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Graphs and networks 13

A graph is the mathematical object formally defined aboveGraph

A network is the representation of a real-world system. Nodesand links have a specific meaning within the context of the appli-cation. Also, they have a ributes

Network

Graph theory versus network theory■ Different research questions■ Graph techniques can be used to analyse networks■ All networks are graphs (but the opposite is not true)

L1: Introduction to Network Theory | 3. Basic Concepts

Page 30: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Simplest graphs 14

Trivial graph has only one vertex

Null graph has no edges

L1: Introduction to Network Theory | 3. Basic Concepts

Page 31: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Path 15

Path is an alternating sequence of nodes and edges, beginning ata node and ending at a node. Paths do not visit any point morethan once

H - F - C - A - Dis a path

L1: Introduction to Network Theory | 3. Basic Concepts

Page 32: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Walk 16

Walk allows nodes to be visited more than once. Path is a specialcase of walk

H - F - C - A - F - Dis a walk

L1: Introduction to Network Theory | 3. Basic Concepts

Page 33: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Cycle 17

Cycle is a path that starts and ends in the same edge. Cycle is aspecial case of walk

H - F - C - A - D - G - His a cycle

L1: Introduction to Network Theory | 3. Basic Concepts

Page 34: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Connectivity 18

■ A node is reachable from another node if there exists a path ofany length from one node to another.

■ A graph is connected if there exists a path of any lengthbetween any pair of nodes.

■ A connected component is a subgraph, in which all nodes arereachable from every other.

L1: Introduction to Network Theory | 3. Basic Concepts

Page 35: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Representation

L1: Introduction to Network Theory | 4. Representation

Page 36: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Adjacency matrix 20

A = {aij}Ni ,j=1 =

{1 if there is an edge from i to j ,0 otherwise

(1)

L1: Introduction to Network Theory | 4. Representation

Page 37: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Edgelist 21

Note that this edgelist must said to be undirected, otherwise it isnot full, and more edges must be added to the list, from target tosources.

L1: Introduction to Network Theory | 4. Representation

Page 38: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Adjacency matrix vs. Edge list 22

Adjacency matrix Edge listMemory O(N2) O(E )Lookup specific edge Fast, O(1) SlowIterate over all edges Slow, O(N2) FastFind neighbours of a node Time O(N) Time O(E )Be er for Dense graphs Sparse graphsAdding new vertices Hard EasyAdding new edges O(1) O(1) or O(E )

L1: Introduction to Network Theory | 4. Representation

Page 39: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Network types

L1: Introduction to Network Theory | 5. Network types

Page 40: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Network types 24

1. By mode of nodes:1.1 One mode

1.2 Two nodes2. By direction of edges:

2.1 Directed2.2 Undirected

3. By weights of edges:3.1 Weighted

3.2 Unweighted

Any combination is possible!

L1: Introduction to Network Theory | 5. Network types

Page 41: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Network types 24

1. By mode of nodes:1.1 One mode

1.2 Two nodes2. By direction of edges:

2.1 Directed2.2 Undirected

3. By weights of edges:3.1 Weighted

3.2 Unweighted

Any combination is possible!

L1: Introduction to Network Theory | 5. Network types

Page 42: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Network types 24

1. By mode of nodes:1.1 One mode

1.2 Two nodes2. By direction of edges:

2.1 Directed2.2 Undirected

3. By weights of edges:3.1 Weighted

3.2 Unweighted

Any combination is possible!

L1: Introduction to Network Theory | 5. Network types

Page 43: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Network types 24

1. By mode of nodes:1.1 One mode

1.2 Two nodes2. By direction of edges:

2.1 Directed2.2 Undirected

3. By weights of edges:3.1 Weighted

3.2 Unweighted

Any combination is possible!

L1: Introduction to Network Theory | 5. Network types

Page 44: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Network types 24

1. By mode of nodes:1.1 One mode

1.2 Two nodes2. By direction of edges:

2.1 Directed2.2 Undirected

3. By weights of edges:3.1 Weighted

3.2 Unweighted

Any combination is possible!

L1: Introduction to Network Theory | 5. Network types

Page 45: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Unipartite networks 25

Unipartite networks (one mode)■ All nodes are of the same nature;■ E.g.: Social networks, Internet,

WWW, Firms

Unipartite graph can also be:■ Undirected unweighted: aij ∈ {0, 1}, A is symmetric -

Simplification;■ Directed unweighted: aij ∈ {0, 1}, A is asymmetric - Followers;■ Undirected weighted: aij ∈ R, A is symmetric - Contact;■ Directed weighted: aij ∈ R, A is asymmetric - Economic

relations;

L1: Introduction to Network Theory | 5. Network types

Page 46: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Unipartite networks 25

Unipartite networks (one mode)■ All nodes are of the same nature;■ E.g.: Social networks, Internet,

WWW, Firms

Unipartite graph can also be:■ Undirected unweighted: aij ∈ {0, 1}, A is symmetric -

Simplification;■ Directed unweighted: aij ∈ {0, 1}, A is asymmetric - Followers;■ Undirected weighted: aij ∈ R, A is symmetric - Contact;■ Directed weighted: aij ∈ R, A is asymmetric - Economic

relations;

L1: Introduction to Network Theory | 5. Network types

Page 47: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Unipartite networks 25

Unipartite networks (one mode)■ All nodes are of the same nature;■ E.g.: Social networks, Internet,

WWW, Firms

Unipartite graph can also be:■ Undirected unweighted: aij ∈ {0, 1}, A is symmetric -

Simplification;■ Directed unweighted: aij ∈ {0, 1}, A is asymmetric - Followers;■ Undirected weighted: aij ∈ R, A is symmetric - Contact;■ Directed weighted: aij ∈ R, A is asymmetric - Economic

relations;

L1: Introduction to Network Theory | 5. Network types

Page 48: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Unipartite networks 25

Unipartite networks (one mode)■ All nodes are of the same nature;■ E.g.: Social networks, Internet,

WWW, Firms

Unipartite graph can also be:■ Undirected unweighted: aij ∈ {0, 1}, A is symmetric -

Simplification;■ Directed unweighted: aij ∈ {0, 1}, A is asymmetric - Followers;■ Undirected weighted: aij ∈ R, A is symmetric - Contact;■ Directed weighted: aij ∈ R, A is asymmetric - Economic

relations;

L1: Introduction to Network Theory | 5. Network types

Page 49: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Unipartite networks 25

Unipartite networks (one mode)■ All nodes are of the same nature;■ E.g.: Social networks, Internet,

WWW, Firms

Unipartite graph can also be:■ Undirected unweighted: aij ∈ {0, 1}, A is symmetric -

Simplification;■ Directed unweighted: aij ∈ {0, 1}, A is asymmetric - Followers;■ Undirected weighted: aij ∈ R, A is symmetric - Contact;■ Directed weighted: aij ∈ R, A is asymmetric - Economic

relations;

L1: Introduction to Network Theory | 5. Network types

Page 50: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One-mode undirected unweighted 26

L1: Introduction to Network Theory | 5. Network types

Page 51: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One-mode undirected unweighted 27■ All connections are mutual and of the same strength■ Adjacency matrix: symmetric, ∀i , j : aij ∈ {0, 1}■ e.g.: Friendship network of Facebook users

L1: Introduction to Network Theory | 5. Network types

Page 52: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One-mode directed unweighted 28

L1: Introduction to Network Theory | 5. Network types

Page 53: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One-mode directed unweighted 29■ Connections are not mutual, but of the same strength■ Adjacency matrix: non-symmetric, ∀i , j : aij ∈ {0, 1}■ e.g.: Follower network of Twi er users

h p://sites.davidson.eduL1: Introduction to Network Theory | 5. Network types

Page 54: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One-mode undirected weighted 30

L1: Introduction to Network Theory | 5. Network types

Page 55: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One-mode undirected weighted 31

■ All connections are mutual, but of different strength■ Adjacency matrix: symmetric, ∀i , j : aij ∈ R■ e.g.: Cooperation network between individuals in ICIC

(1919-1927)

h p://www.martingrandjean.ch/intellectual-cooperation-multi-level-network-analysis/

L1: Introduction to Network Theory | 5. Network types

Page 56: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One-mode directed weighted 32

L1: Introduction to Network Theory | 5. Network types

Page 57: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One-mode directed weighted 33

■ Connections are not mutual and of different strength■ Adjacency matrix: non-symmetric, ∀i , j : aij ∈ R■ e.g.: Affinity network of EU countries at Eurovision 2009-2012

L1: Introduction to Network Theory | 5. Network types

Page 58: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One-mode directed weighted 33

■ Connections are not mutual and of different strength■ Adjacency matrix: non-symmetric, ∀i , j : aij ∈ R■ e.g.: Affinity network of EU countries at Eurovision 2009-2012

L1: Introduction to Network Theory | 5. Network types

Page 59: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One-mode directed weighted 33

■ Connections are not mutual and of different strength■ Adjacency matrix: non-symmetric, ∀i , j : aij ∈ R■ e.g.: Affinity network of EU countries at Eurovision 2009-2012

L1: Introduction to Network Theory | 5. Network types

Page 60: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Bipartite networks 34

Bipartite networks (two modes)■ Nodes are of two well-differentiated nature■ Node of one type can only be connected to a node of another

type;■ e.g.:

■ Recommender systems (product/user)■ Goods (buyer/product; buyer/seller; manufacturer/contractor)

Bipartite graph can also be:■ Unweighted: aij ∈ {0, 1}, A is

rectangular■ Weighted: aij ∈ R, A is rectangular;

L1: Introduction to Network Theory | 5. Network types

Page 61: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Bipartite networks 34

Bipartite networks (two modes)■ Nodes are of two well-differentiated nature■ Node of one type can only be connected to a node of another

type;■ e.g.:

■ Recommender systems (product/user)■ Goods (buyer/product; buyer/seller; manufacturer/contractor)

Bipartite graph can also be:■ Unweighted: aij ∈ {0, 1}, A is

rectangular■ Weighted: aij ∈ R, A is rectangular;

L1: Introduction to Network Theory | 5. Network types

Page 62: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Bipartite networks 34

Bipartite networks (two modes)■ Nodes are of two well-differentiated nature■ Node of one type can only be connected to a node of another

type;■ e.g.:

■ Recommender systems (product/user)■ Goods (buyer/product; buyer/seller; manufacturer/contractor)

Bipartite graph can also be:■ Unweighted: aij ∈ {0, 1}, A is

rectangular■ Weighted: aij ∈ R, A is rectangular;

L1: Introduction to Network Theory | 5. Network types

Page 63: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Bipartite networks 34

Bipartite networks (two modes)■ Nodes are of two well-differentiated nature■ Node of one type can only be connected to a node of another

type;■ e.g.:

■ Recommender systems (product/user)■ Goods (buyer/product; buyer/seller; manufacturer/contractor)

Bipartite graph can also be:■ Unweighted: aij ∈ {0, 1}, A is

rectangular■ Weighted: aij ∈ R, A is rectangular;

L1: Introduction to Network Theory | 5. Network types

Page 64: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Bipartite networks 34

Bipartite networks (two modes)■ Nodes are of two well-differentiated nature■ Node of one type can only be connected to a node of another

type;■ e.g.:

■ Recommender systems (product/user)■ Goods (buyer/product; buyer/seller; manufacturer/contractor)

Bipartite graph can also be:■ Unweighted: aij ∈ {0, 1}, A is

rectangular■ Weighted: aij ∈ R, A is rectangular;

L1: Introduction to Network Theory | 5. Network types

Page 65: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Bipartite networks: example 35

A supermarket chain wants to know which products arefrequently bought together.

They have the following data:

L1: Introduction to Network Theory | 5. Network types

Page 66: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Bipartite network: Nodes 36

L1: Introduction to Network Theory | 5. Network types

Page 67: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Bipartite network: Edges 37

L1: Introduction to Network Theory | 5. Network types

Page 68: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Bipartite networks: adjacency matrix 38■ Blue nodes - reciepts; Green nodes - products■ Edges exist only between nodes of different types.■ Adjacency matrix for bipartite networks: block-matrix;

L1: Introduction to Network Theory | 5. Network types

Page 69: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Bipartite networks: edge list 39

■ Blue nodes - receipts; Green nodes - products■ Edges exist only between nodes of different types.

L1: Introduction to Network Theory | 5. Network types

Page 70: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One mode projection 40

Link all products that were bought together on the same receipt

Consider receipt F first

L1: Introduction to Network Theory | 5. Network types

Page 71: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One mode projection 41

Link all products that were bought together on the same receipt

Now consider receipt G

L1: Introduction to Network Theory | 5. Network types

Page 72: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One mode projection 42

Link all products that were bought together on the same receipt

Finally, consider receipt I

L1: Introduction to Network Theory | 5. Network types

Page 73: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

One mode projection 43

Resulting graph is unipartite, undirected, unweighted

L1: Introduction to Network Theory | 5. Network types

Page 74: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Network of ingredients 44Network of ingredients that occur together more than by chance:

Teng, Lin, & Adamic (2011)

L1: Introduction to Network Theory | 5. Network types

Page 75: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Simple network models

L1: Introduction to Network Theory | 6. Simple network models

Page 76: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

What are network models? 46

■ A model is an abstract, idealised description of reality that stillcaptures a specific trait

■ Network models are constructed to represent complexsystems: social, physical, information, etc.

■ In this course, we focus on network models of complexsocio-economic systems

L1: Introduction to Network Theory | 6. Simple network models

Page 77: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

What are network models? 46

■ A model is an abstract, idealised description of reality that stillcaptures a specific trait

■ Network models are constructed to represent complexsystems: social, physical, information, etc.

■ In this course, we focus on network models of complexsocio-economic systems

L1: Introduction to Network Theory | 6. Simple network models

Page 78: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

What are network models? 46

■ A model is an abstract, idealised description of reality that stillcaptures a specific trait

■ Network models are constructed to represent complexsystems: social, physical, information, etc.

■ In this course, we focus on network models of complexsocio-economic systems

L1: Introduction to Network Theory | 6. Simple network models

Page 79: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Simple network types 47

Fully connected network

■ All-to-all, well-mixedpopulation;

■ Amenable for analyticalcalculations;

■ In most situations: artificial;■ ki = N − 1■ Diameter: 1

L1: Introduction to Network Theory | 6. Simple network models

Page 80: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Simple network types 48

Star network

■ Extremely centralised;■ Can represent topology of

computer network(client-server)

■ k0 = N − 1, ki = 1∀i > 0■ Diameter: 2

L1: Introduction to Network Theory | 6. Simple network models

Page 81: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Regular networks 49

One dimensional la ice

■ Traffic lanes;■ ki = 2κ

■ Diameter: ∝ N

L1: Introduction to Network Theory | 6. Simple network models

Page 82: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Regular networks 50

Bi-dimensional la ice

■ Geographical data■ ki = 4κ

■ Diameter: ∝ N1/2

L1: Introduction to Network Theory | 6. Simple network models

Page 83: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Why these models are important? 51

■ These models represent some real-world structures (computernetworks, geographical data, traffic lanes);

■ Can be used for analysis and modelling of the networks■ Estimation of: connectivity, average (or maximum) load on lanes

or server, etc.■ Can be used for prediction of future behavior;

L1: Introduction to Network Theory | 6. Simple network models

Page 84: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

References I 52

▶ Chin-Yuen Teng, Yu-Ru Lin, Lada A. Adamic, Reciperecommendation using ingredient networks, arXiv preprint:arXiv:1111.3919, 2012.

L1: Introduction to Network Theory | 6. Simple network models

Page 85: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Manuel Sebastian Mariani

URPP Social Networks

B [email protected]

m h p://www.socialnetworks.uzh.ch

L1: Introduction to Network Theory | 6. Simple network models

Page 86: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Exercise

L1: Introduction to Network Theory | 7. Exercise

Page 87: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Degree distribution 55

■ Download one unipartite unweighted network fromhttp://snap.stanford.edu/data/index.html, ideally composed of∼ 1000 to 10, 000 nodes.

■ Describe the meaning of the nodes and the edges.■ Analyze the network with a network-analysis package, using

your favorite programming language.■ Recommended: igraph, networkx.

L1: Introduction to Network Theory | 7. Exercise

Page 88: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Degree distribution 56

■ Plot the selected network’s degree distribution P(k). Is itbe er to plot it on a linear scale, or on a log-log scale? Discuss.

■ Compare with the expectation for a random graph:

PER(k) = N pk (1 − p)N−k−1.

(Find the normalization factor N .)■ Are the observed and expected distribution similar? Discuss

the meaning of the result.

L1: Introduction to Network Theory | 7. Exercise

Page 89: IntroductiontoNetworkTheory - UZH · L1: Introduction to Network Theory | 3. Basic Concepts. Graphsandnetworks 13 A graph is the mathematical object formally defined above Graph

Manuel Sebastian Mariani

URPP Social Networks

B [email protected]

m h p://www.socialnetworks.uzh.ch