Complexity Theory of Polynomial-Time Problems

Similar documents
Complexity Theory of Polynomial-Time Problems

Subcubic Equivalence of Triangle Detection and Matrix Multiplication

Complexity Theory of Polynomial-Time Problems

Complexity Theory of Polynomial-Time Problems

CS367 Lecture 3 (old lectures 5-6) APSP variants: Node Weights, Earliest Arrivals, Bottlenecks Scribe: Vaggos Chatziafratis Date: October 09, 2015

Matching Triangles and Basing Hardness on an Extremely Popular Conjecture

CS173 Lecture B, November 3, 2015

Lecture 4: An FPTAS for Knapsack, and K-Center

Complexity Theory of Polynomial-Time Problems

Complexity Theory of Polynomial-Time Problems

Complexity Theory of Polynomial-Time Problems

NP and Computational Intractability

Lecture Notes for Chapter 25: All-Pairs Shortest Paths

Note that M i,j depends on two entries in row (i 1). If we proceed in a row major order, these two entries will be available when we are ready to comp

Shortest paths with negative lengths

Classical Complexity and Fixed-Parameter Tractability of Simultaneous Consecutive Ones Submatrix & Editing Problems

Algorithms and Theory of Computation. Lecture 22: NP-Completeness (2)

arxiv: v1 [cs.ds] 27 Mar 2017

Tree-width and algorithms

Tree Edit Distance Cannot be Computed in Strongly Subcubic Time (unless APSP can)

Lecture 18: More NP-Complete Problems

8. INTRACTABILITY I. Lecture slides by Kevin Wayne Copyright 2005 Pearson-Addison Wesley. Last updated on 2/6/18 2:16 AM

CS 4407 Algorithms Lecture: Shortest Path Algorithms

Learning Large-Alphabet and Analog Circuits with Value Injection Queries

Chapter 11. Approximation Algorithms. Slides by Kevin Wayne Pearson-Addison Wesley. All rights reserved.

16.1 Min-Cut as an LP

General Methods for Algorithm Design

Finite Metric Spaces & Their Embeddings: Introduction and Basic Tools

Flows. Chapter Circulations

Lecture 22: Counting

Analysis of Algorithms I: All-Pairs Shortest Paths

Chapter 9: Relations Relations

The minimum G c cut problem

Discrete Optimization 2010 Lecture 2 Matroids & Shortest Paths

CS151 Complexity Theory

Design and Analysis of Algorithms

R ij = 2. Using all of these facts together, you can solve problem number 9.

- Well-characterized problems, min-max relations, approximate certificates. - LP problems in the standard form, primal and dual linear programs

Limits to Approximability: When Algorithms Won't Help You. Note: Contents of today s lecture won t be on the exam

A An Overview of Complexity Theory for the Algorithm Designer

Complexity Theory VU , SS The Polynomial Hierarchy. Reinhard Pichler

Outline. Complexity Theory EXACT TSP. The Class DP. Definition. Problem EXACT TSP. Complexity of EXACT TSP. Proposition VU 181.

8.5 Sequencing Problems

More on NP and Reductions

Subcubic Equivalences Between Path, Matrix, and Triangle Problems

Ma/CS 6b Class 25: Error Correcting Codes 2

Lecture 10. Sublinear Time Algorithms (contd) CSC2420 Allan Borodin & Nisarg Shah 1

Separating Hierarchical and General Hub Labelings

Connections between exponential time and polynomial time problem Lecture Notes for CS294

The Budget-Constrained Maximum Flow Problem

and e 2 ~ e 2 iff e 1

Speeding up the Dreyfus-Wagner Algorithm for minimum Steiner trees

Theory of Computation CS3102 Spring 2014 A tale of computers, math, problem solving, life, love and tragic death

Divide and Conquer. Maximum/minimum. Median finding. CS125 Lecture 4 Fall 2016

Combinatorial Optimization

Lecture 11. Single-Source Shortest Paths All-Pairs Shortest Paths

Cutting Plane Methods II

Partitioning Metric Spaces

Single Source Shortest Paths

Written Qualifying Exam. Spring, Friday, May 22, This is nominally a three hour examination, however you will be

The Knapsack Problem. 28. April /44

ORIE 6334 Spectral Graph Theory November 22, Lecture 25

Hardness of Approximation

A Complexity Theory for Parallel Computation

Cographs; chordal graphs and tree decompositions

Data Streams & Communication Complexity

CSE 431/531: Analysis of Algorithms. Dynamic Programming. Lecturer: Shi Li. Department of Computer Science and Engineering University at Buffalo

Lecture 6 September 21, 2016

U.C. Berkeley CS294: Spectral Methods and Expanders Handout 11 Luca Trevisan February 29, 2016

Introduction to Algorithms

Reverse mathematics of some topics from algorithmic graph theory

Linear Time Selection

CS 241 Analysis of Algorithms

Scribes: Po-Hsuan Wei, William Kuzmaul Editor: Kevin Wu Date: October 18, 2016

All-Pairs Shortest Paths

Improved Quantum Algorithm for Triangle Finding via Combinatorial Arguments

Algorithms for Picture Analysis. Lecture 07: Metrics. Axioms of a Metric

6.S078 A FINE-GRAINED APPROACH TO ALGORITHMS AND COMPLEXITY LECTURE 1

Optimal Tree-decomposition Balancing and Reachability on Low Treewidth Graphs

Decompositions of graphs into cycles with chords

Algebraic Methods in Combinatorics

Computability and Complexity

CMPS 6610 Fall 2018 Shortest Paths Carola Wenk

RECAP: Extremal problems Examples

Discrete Optimization 2010 Lecture 8 Lagrangian Relaxation / P, N P and co-n P

Algorithm Design and Analysis

1 Primals and Duals: Zero Sum Games

Geometric Steiner Trees

Dynamic Programming: Shortest Paths and DFA to Reg Exps

CS675: Convex and Combinatorial Optimization Fall 2016 Combinatorial Problems as Linear and Convex Programs. Instructor: Shaddin Dughmi

Chapter 11. Approximation Algorithms. Slides by Kevin Wayne Pearson-Addison Wesley. All rights reserved.

CMPT 307 : Divide-and-Conqer (Study Guide) Should be read in conjunction with the text June 2, 2015

Temporal Constraint Networks

UC Berkeley CS 170: Efficient Algorithms and Intractable Problems Handout 22 Lecturer: David Wagner April 24, Notes 22 for CS 170

CS311 Computational Structures. NP-completeness. Lecture 18. Andrew P. Black Andrew Tolmach. Thursday, 2 December 2010

Solutions to Exercises

Hardness for easy problems. An introduction

A FINE-GRAINED APPROACH TO ALGORITHMS AND COMPLEXITY. Virginia Vassilevska Williams Stanford University

arxiv: v2 [cs.ds] 3 Oct 2017

Finding, Minimizing, and Counting Weighted Subgraphs

Transcription:

Complexity Theory of Polynomial-Time Problems Lecture 5: Subcubic Equivalences Karl Bringmann

Reminder: Relations = Reductions transfer hardness of one problem to another one by reductions problem P instance I size n reduction r(n) time problem Q instance J size s(n) I is a yes -instance () J is a yes -instance t(n) algorithm for Q implies a r n + t(s n ) algorithm for P if P has no r n + t(s n ) algorithm then Q has no t(n) algorithm

Reminder: Relations = Reductions problem P instance I size n reduction total time r(n) problem Q instance I 1 size n. instance I k size n 0

Subcubic Reduction A subcubic reduction from P to Q is an algorithm A for P with oracle access to Q s.t.: problem P instance I reduction problem Q instance I 1 size n. Properties: size n total time r(n) instance I k size n 0 for any instance I, algorithm A(I) correctly solves problem P on I A runs in time r(n) = O(n 567 ) for some γ > 0 for any ε > 0 there is a δ > 0 s.t. 0 n 56? >@. > n 56B

Subcubic Reduction A subcubic reduction from P to Q is an algorithm A for P with oracle access to Q with: Properties: problem Q problem P reduction instance I instance A subcubic I reduction implies: 1 size n. If Q has an O(n 56C ) algorithm for some α > 0, then P has an O(n 56E ) algorithm for some β > 0 size n total time instance I k r(n) size n 0 for any instance I, algorithm A(I) correctly solves problem P on I A runs in time r(n) = O(n 567 ) for some γ > 0 for any ε > 0 there is a δ > 0 s.t. 0 n 56? >@. > n 56B similar: subquadratic/subquartic reductions

Subcubic Reduction subcubic reduction: write P Q subcubic equivalent: write P Q if P Q and Q P Transitivity: (Exercise) For problems A, B, C with A B and B C we have A C. In particular: If A B and B C and C A then A, B, C are subcubic equivalent. B A C Lemma: (without proof) If A B and B is in time O n 5 /2N(OPQ R)S/T then A is in time O n 5 /2 N(OPQ R)S/T.

Reminder All-Pairs-Shortest-Paths (APSP): given a weighted directed graph G, compute the (length of the) shortest path between any pair of vertices each edge has a weight in {1,.., n W } Floyd-Warshall 62: O(n 5 )... Williams 14: O n 5 /2N(OPQ R)S/T Conjecture: for any ε > 0 APSP has no O n 56? algorithm there exists c > 0 such that

Reminder Min-Plus Matrix Product: each entry in {1,.., n W, } given n. n [ -matrix A and n [ n 5 -matrix B, define their min-plus product as the n. n 5 -matrix C with C >,\ = min.`0`r T A >,0 + B 0,\ from definition: O n 5 (if n = n. = n [ = n 5 ) Conjecture: for any ε > 0 there is no O n 56? algorithm there exists c > 0 such that

Reminder Thm: If APSP has a T(n) algorithm then Min-Plus Product has an O(T n + n [ ) algorithm. Thm: If Min-Plus Product has a T(n) algorithm then APSP has an O((T n + n [ ) log n) algorithm. Consider adjacency matrix A of G n n n Add selfloops with cost 0: A + I Square log n times using Min-Plus w i, k = A[i, k] w k, j = B[k, j] Product: B (A + I) [ mno p Then B >,\ is the length of the shortest path from i to j

Subcubic Reduction A subcubic reduction from P to Q is an algorithm A for P with oracle access to Q with: problem P instance I reduction problem Q instance I 1 size n. Properties: size n total time r(n) instance I k size n 0 for any instance I, algorithm A(I) correctly solves problem P on I A runs in time r(n) = O(n 567 ) for some γ > 0 for any ε > 0 there is a δ > 0 s.t. 0 n 56? >@. > n 56B

Subcubic Equivalences Thm: IfAPSP has a T(n) algorithm then Min-Plus Product has an O(T(n)) algorithm. Thm: If Min-Plus Product has a T(n) algorithm then APSP has an O(T n log n) algorithm. APSP and Min-Plus Product are subcubic equivalent Cor: APSP has an O(n 56? ) algorithm for some ε > 0 if and only if Min-Plus Product has an O(n 56B ) algorithm for some δ > 0 Cor: Min-Plus Product is in time O n 5 /2N(OPQ R)S/T

Subcubic Equivalences 2 nd Shortest Path Maximum Submatrix Metricity APSP Min-Plus Product All-Pairs- Negative- Negative Betweenness Centrality Radius Median [Vassilevska-Williams,Williams 10] [Abboud,Grandoni,Vassilevska-Williams 15]

Problems Negative each edge has a weight in { n W,.., n W } Given a weighted directed graph G Decide whether there are vertices i, j, k such that w j, i + w i, k + w k, j < 0 from definition: O(n 5 ) no O n 56? algorithm known (which works for all c > 0) Intermediate problem: All-Pairs-Negative- Given a weighted directed graph G with vertex set V = I J K Decide for every i I, j J whether there is a vertex k K s.t. w j, i + w i, k + w k, j < 0

Subcubic Equivalences 2 nd Shortest Path Maximum Submatrix Metricity APSP Min-Plus Product All-Pairs- Negative- Negative Betweenness Centrality Radius Median [Vassilevska-Williams,Williams 10] [Abboud,Grandoni,Vassilevska-Williams 15]

Neg- to Min-Plus-Product Given a weighted directed graph G on vertex set {1,, n} Adjacency matrix A: A >,\ = weight of edge i, j, or if the edge does not exist Min-Plus Product Negative 1. Compute Min-Plus Product B A A: B >,\ = min 0 A >,0 + A 0,\ 2. Compute min >,\ A \,> + B >,\ this equals min >,\,0 A \,> + A >,0 + A 0,\ i.e. the smallest weight of any triangle thus we solved Negative A: 3 1 4 1 5 2 2 7 1 Running Time: T Q ƒ QO n T ˆO Š n + O(n [ ) subcubic reduction

Subcubic Equivalences 2 nd Shortest Path Maximum Submatrix Metricity APSP Min-Plus Product All-Pairs- Negative- Negative Betweenness Centrality Radius Median [Vassilevska-Williams,Williams 10] [Abboud,Grandoni,Vassilevska-Williams 15]

3 1 4 2 1 A Min-Plus to All-Pairs-Neg- I 2 1 3 1 4 2 K 5 7 2 4 5 7 2 4 7 Add all edges from J to I with (carefully chosen) weights w(j, i) Run All-Pairs-Negative- algorithm J B n = 4 in the picture Min-Plus Product All-Pairs- Negative- Result: for all i, j, is there a k such that w j, i + w i, k + w k, j < 0? w i, k + w k, j < w j, i WANTED: Min-Plus: for all i, j: min 0 w i, k + w k, j = minimum number z s.t. there is a k s.t. w i, k + w k, j < z + 1 binary search via w j, i! simultaneous for all i, j!

3 1 4 2 1 A Min-Plus to All-Pairs-Neg- I 2 1 3 1 4 2 7 5 7 2 4 5 7 2 4 binary search via w j, i! simultaneous for all i, j! K need that all (finite) weights are in { n W,, n W } each entry of Min-Plus Product is in { 2n W,, 2n W, } binary search takes log [ 4n W + 1 = O(log n) steps J B n = 4 in the picture Min-Plus Product All-Pairs- Negative-

3 1 4 2 1 A Min-Plus to All-Pairs-Neg- I 2 1 3 1 4 2 7 K 5 7 2 4 J 5 7 2 4 binary search via w j, i! simultaneous for all i, j! B n = 4 in the picture Min-Plus Product All-Pairs- Negative- for all i, j: initialize m i, j 2n W and M(i, j): = 2n W repeat log (4n W ) times: for all i, j: set w j, i (m i, j + M(i, j))/2 compute All-Pairs-Negative- for all i, j: if i,j is in negative triangle: M i, j w j, i 1 otherwise: m i, j w j, i (missing: handling of )

3 1 4 2 1 A Min-Plus to All-Pairs-Neg- I 2 1 3 1 4 2 7 K 5 7 2 4 J 5 7 2 4 B n = 4 in the picture Min-Plus Product All-Pairs- Negative- binary search takes log [ 4n W + 1 = O(log n) steps T(n) algorithm for All-Pairs-Neg- yields O(T(n) log n) algorithm for Min-Plus Product In particular: O(n 56? ) algorithm for All-Pairs-Neg- for some ε > 0 implies O(n 56? ) algorithm for Min-Plus Product for some ε > 0 subcubic reduction

Subcubic Equivalences 2 nd Shortest Path Maximum Submatrix Metricity APSP Min-Plus Product All-Pairs- Negative- Negative Betweenness Centrality Radius Median [Vassilevska-Williams,Williams 10] [Abboud,Grandoni,Vassilevska-Williams 15]

All-Pairs-Neg- to Neg- Negative Given graph G Decide whether there are vertices i, j, k such that w j, i + w i, k + w k, j < 0 All-Pairs- Negative- Negative All-Pairs-Negative- Given graph G with vertex set V = I J K Decide for every i I, j J whether there is a vertex k K such that w j, i + w i, k + w k, j < 0 K Split I, J, K into n/s parts of size s: I.,, I R/, J.,, J R/, K.,, K R/ I K J For each of the (n/s) 5 triples (I, J, K ): consider graph G[I J K ] I J

All-Pairs-Neg- to Neg- Initialize C as n n all-zeroes matrix For each of the (n/s) 5 triples of parts (I, J, K ): While G[I J K ] contains a negative triangle: Find a negative triangle (i, j, k) in G[I J K ] Set C i, j 1 Set w(i, j) (i, j) is in no more negative triangles K All-Pairs- Negative- Negative guaranteed termination: can set n [ weights to I K J correctness: if (i, j) is in negative triangle, we will find one I J

All-Pairs-Neg- to Neg- Find a negative triangle (i, j, k) in G[I J K ] How to find a negative triangle if we can only decide whether one exists? Partition I into I (.), I ([), J into J (.), J ([), K into K (.),K ([) All-Pairs- Negative- Negative Since G[I J K ] contains a negative triangle, at least one of the 2 5 subgraphs G[I (š) J ( ) K (W) ] contains a negative triangle K Decide for each such subgraph whether it contains a negative triangle I J Recursively find a triangle in one subgraph

All-Pairs-Neg- to Neg- Find a negative triangle (i, j, k) in G[I J K ] How to find a negative triangle if we can only decide whether one exists? Partition I into I (.), I ([), J into J (.), J ([), K into K (.),K ([) All-Pairs- Negative- Negative Since G[I J K ] contains a negative triangle, at least one of the 2 5 subgraphs G[I (š) J ( ) K (W) ] contains a negative triangle Running Time: T œ Q ƒ QO n Decide for each such subgraph whether it contains a negative triangle Recursively find a triangle in one subgraph 2 5 T Ÿ Q ƒ QO (n) + T œ Q ƒ QO n/2 = O(T Ÿ Q ƒ QO n )

All-Pairs-Neg- to Neg- Initialize C as n n all-zeroes matrix All-Pairs- Negative- For each of the (n/s) 5 triples of parts (I, J, K ): While G[I J K ] contains a negative triangle: Find a negative triangle (i, j, k) in G[I J K ] Set C i, j 1 Set w(i, j) ( ) Negative Running Time: ( ) = O(T œ Q ƒ QO (s)) = O(T Ÿ Q ƒ QO (s)) Total time: #triples + #triangles found ( ) n/s 5 + n [ T Ÿ Q ƒ QO (s) Set s = n./5 and assume T Ÿ Q ƒ QO n = O(n 56? ) Total time: O n [ n.6?/5 = O(n 56?/5 )

Subcubic Equivalences 2 nd Shortest Path Maximum Submatrix Metricity APSP Min-Plus Product All-Pairs- Negative- Negative Betweenness Centrality Radius Median [Vassilevska-Williams,Williams 10] [Abboud,Grandoni,Vassilevska-Williams 15]

Radius G is a weighted directed graph d(u, v) is the distance from u to v in G Radius: min max d(u, v) u is in some sense the most central vertex u w(u, v) v Radius APSP compute all pairwise distances, then evaluate definition of radius in time O(n [ ) subcubic reduction Radius is in time O n 5 /2N(OPQ R)S/T

Negative to Radius Radius Negative instance: graph G with n nodes, edge-weights in { n W,, n W } i w(i, j) j Radius instance: graph H with O(n) nodes, edge-weights in {0,, O(n W )} i i i i ¹ j j j j ¹ Negative M = 3n W 1) Make four layers with n nodes 2) For any edge (i, j): Add i, j, i, j, i,j ¹ with weight M + w(i, j) A B C D

Negative to Radius Radius Negative instance: graph G with n nodes, edge-weights in { n W,, n W } i w(i, j) j k (i, j, k) has weight W Radius instance: graph H with O(n) nodes, edge-weights in {0,, O(n W )} i i ¹ j k Negative M = 3n W 1) Make four layers with n nodes 2) For any edge (i, j): Add i, j, i, j, i,j ¹ with weight M + w(i, j) A B C D path has length 3M + W i, j, k,i ¹ -path of length 3M 1?

Negative to Radius Radius Negative instance: graph G with n nodes, edge-weights in { n W,, n W } i w(i, j) j k (i, j, k) has weight W Radius instance: graph H with O(n) nodes, edge-weights in {0,, O(n W )} i i ¹ j k Negative M = 3n W 1) Make four layers with n nodes 2) For any edge (i, j): Add i, j, i, j, i,j ¹ with weight M + w(i, j) A B C D path has length 3M + W 3) Add edges of weight 3M 1 from any i to all nodes except i ¹ (and i ) i, j, k,i ¹ -path of length 3M 1? Radius: min max d(u, v) Claim: Radius of H is 3M 1 iff there is a negative triangle in G

Negative to Radius Radius Claim: Proof: Radius of H is 3M 1 iff there is a negative triangle in G Negative If there is a negative triangle (i, j, k) then i is in distance 3M 1 to i ¹ (by (2)), and in distance 3M 1 to any other vertex (by (3)), so the radius is max d i, v 3M 1 If there is no negative triangle i, j, k : Any node u of the form i /i /i ¹ cannot reach A, so it has max d u, v = Any i is in distance 3M to i ¹, since there is no i, j, k,i ¹ -path of length 3M 1 (note that the edges added in (3) also do not help) Hence, for all u, max d u, v 3M, and thus the radius is at least 3M

Subcubic Equivalences 2 nd Shortest Path Maximum Submatrix Metricity APSP Min-Plus Product All-Pairs- Negative- Negative Betweenness Centrality Radius Median [Vassilevska-Williams,Williams 10] [Abboud,Grandoni,Vassilevska-Williams 15]

MaxSubmatrix MaxSubmatrix: given an n n matrix A with entries in { n W,.., n W } Σ B sum of all entries of matrix B compute maximum Σ B over all submatrices B of A y. y [ A B x. x [ Thm: MaxSubmatrix is subcubic equivalent to APSP [Tamaki,Tokuyama 98] [Backurs,Dikkala,Tzamos 16] there are O(n ¾ ) possible submatrices B computing Σ B : O(n [ ) trivial running time: O(n ) Exercise: design an O(n 5 ) algorithm

MaxSubmatrix MaxSubmatrix: given an n n matrix A with entries in { n W,.., n W } Σ B sum of all entries of matrix B compute maximum Σ B over all submatrices B of A y. y [ A B x. x [ Thm: MaxSubmatrix is subcubic equivalent to APSP [Tamaki,Tokuyama 98] [Backurs,Dikkala,Tzamos 16] MaxCenteredSubmatrix: compute maximum Σ B over all submatrices B of A containing the center of A i.e. we require x. n/2 < x [ and y. n/2 < y [ Thm: MaxCenteredSubmatrix is subcubic equ. to APSP A we only prove: Negative MaxCenteredSubmatrix B Exercise: MaxCenteredSubmatrix APSP

Neg to MaxCentSubmatrix A Positive instance: graph G with n nodes, edge-weights in { n W,, n W } i w(i, j) MaxCenteredSubmatrix: 2n 2n-matrix A entries in { n Â(W),, n  (W) } y. y [ B x. x [ M 2n WÃ5 j k y. = k II I In quadrant II we want for any k, i: R R Æ Æ A, = w(k, i) Σ B ÄÄ = w(k, i) Σ B Ä = w(j, k) @0 @> this is satisfied by defining: A 0,> w k, i w k + 1, i y [ n = i w k, i + 1 + w(k + 1, i + 1) (where w x, y 0 for x > n or y > n) M M M M [ III M 0 M M Σ B ÄÅ = w(i, j) IV x. = i x [ n = j

Neg to MaxCentSubmatrix A Positive instance: graph G with n nodes, edge-weights in { n W,, n W } i MaxCenteredSubmatrix: 2n 2n-matrix A entries in { n Â(W),, n  (W) } y. y [ B x. x [ M 2n WÃ5 w(i, j) j k In quadrant II we want for any k, i: R R Æ Æ A, = w(k, i) @0 @> this is satisfied by defining: A 0,> w k, i w k + 1, i w k, i + 1 + w(k + 1, i + 1) (where w x, y 0 for x > n or y > n) With this definition of A, for any 1 k, i n: R R Æ Æ A, @0 @> R R = Æ Æw y, x w y + 1,x @0 @> w y, x + 1 +w(y + 1, x + 1) where any w(y,x) with k < y n and i < x n appears with factors +1 1 1 + 1 = 0 and any w y, x, s.t. exactly one of y = k or y = n + 1 or x = i or x = n + 1 holds, appears with factors +1 1 = 0 and since w(y, n + 1) = w(n + 1, x) = 0, the only remaining summand is w(k, i)

Neg to MaxCentSubmatrix A Positive instance: graph G with n nodes, edge-weights in { n W,, n W } MaxCenteredSubmatrix: 2n 2n-matrix A entries in { n Â(W),, n  (W) } y. y [ B x. x [ i w(i, j) Claim: MaxCentSubmatrix of A is > M iff G has a positive triangle M 2n WÃ5 j k y. = k II I In quadrant II we want for any k, i: R R Æ Æ A, = w(k, i) Σ B ÄÄ = w(k, i) Σ B Ä = w(j, k) @0 @> this is satisfied by defining: A 0,> w k, i w k + 1, i y [ n = i w k, i + 1 + w(k + 1, i + 1) (where w x, y 0 for x > n or y > n) M M M M [ III M 0 M M Σ B ÄÅ = w(i, j) IV x. = i x [ n = j

Summary 2 nd Shortest Path Maximum Submatrix Metricity APSP Min-Plus Product All-Pairs- Negative- Negative Betweenness Centrality Radius Median