Walks trails paths cycles Reachability connected graphs components
Walks, trails, paths, cycles Reachability – connected graphs - components
Geodesics, distance, eccentricity, diameter Eccentricity: maxjd(i, j) Πχ. Η εκκεντρότητα του n 2 είναι 2
cut points, bridges
Node connectivity (=2 στο παράδειγμα)
Affiliation network (bipartite graph) Actors = {n 1, n 2}, Affiliations = {n 3, n 4, n 5} Παράγωγα γραφήματα (δύο για κάθε διμερές γράφημα) !
Shortest paths l Αλγόριθμος Dijkstra l Let the node at which we are starting be called the initial node. Let the distance of node Y be the distance from th e initial node to Y. Dijkstra's algorithm will assign some initial distance values and will try to improve them step-by-step. Assign to every node a distance value. Set it to zero for our initial node and to infinity for all other nodes. Mark all nodes as unvisited. Set initial node as current. For current node, consider all its unvisited neighbors and calculate their distance (from the initial node). For example, if current node (A) has distance of 6, and an edge connecting it with another node (B) is 2, the distance to B through A will be 6+2=8. If this distance is less than the previously recorded distance (infinity in the beginning, zero for the initial node), overwrite the distance. When we are done considering all neighbors of the current node, mark it as visited. A visited node will not be checked ever again; its distance recorded now is final and minimal. If all nodes have been visited, finish. Otherwise, set the unvisited node with the smallest distance (from the initial node) as the next "current node" and continue from step 3 l l l
Spanning tree of a graph
Παράδειγμα l Στο link. The algorithm continuously increases the size of a tree, one edge at a time, starting with a tree consisting of a single vertex, until it spans all vertices. Input: A non-empty connected weighted graph with vertices V and edges E in which the weights are non-negative. Initialize: Vnew = {x}, where x is an arbitrary node (starting point) from V, Enew = {} Repeat until Vnew = V: Choose an edge (u, v) with minimal weight such that u is in Vnew and v is not (if there are multiple edges with the same weight, any of them may be picked) Add v to Vnew, and (u, v) to Enew Output: Vnew and Enew describe a minimal spanning tree
Six degrees of separation l Small worlds • Small average shortest path • Large clustering coefficients • Power law • the diameter of the network is growing with the logarithm of the number of nodes l l Bacon number Real Life !! (random graphs <> watts)
Οπτικά – 6 degrees of separation
Bacon number ! Kevin Bacon Number # of People 0 1 1 2333 2 236985 3 747329 4 184725 5 12551 6 1123 7 158 8 19 Total number of linkable actors: 1185224 Average Kevin Bacon number: 2. 977
Μοντέλο watts-strogatz
Num. Nodes Num. Edges Clustering Coefficient Avg. Length of Shortest Paths Diamete r Query Network 989 4846 0. 3495 2. 52 7 Erdos-Renyi Network 989 4837 0. 0106 2. 34 6
World trade network
Enron 2004 emails
Customers who bought this item also bought. . .
Sexual network (high school)
biblical names in the same chapter of the New Testament
- Slides: 37