Submodularity Reading Group Matroids Submodular Functions M Pawan
Submodularity Reading Group Matroids, Submodular Functions M. Pawan Kumar http: //www. robots. ox. ac. uk/~oval/
Submodularity Reading Group • Until 1980 s Tutorial Format – Matroids, Submodularity, Polymatroids – Submodular Function Minimization is “Easy” • 1990 s: Convex optimization for SF Min • 2000 s: Combinatorial algos for SF Min • 2010 s: SF Max (Greedy, Multilinear)
Subsequent Reading Groups • One every two weeks • Alternate with TVG reading group • Tuesdays? • 4 pm-6 pm? • I will send out emails for “volunteers”
Website
Outline • Matroids • Maximum Weight Independent Set • Submodular Functions • Relationship
€ 1000 Steal at most 2 items € 400 € 1000 € 700 Greedy Algorithm
Steal at most 1 item € 400 € 1000 € 1700 € 700 Greedy Algorithm
Steal at most 0 items € 400 € 1700 Greedy Algorithm Success
€ 1000 Steal at most 2. 5 kg 2 kg € 400 € 1000 2 kg 1 kg € 700 Greedy Algorithm (Most Expensive) 1. 5 kg
Steal at most 0. 5 kg € 400 € 1000 1 kg 2 kg € 700 Greedy Algorithm (Most Expensive) Failure 1. 5 kg
€ 1000 Steal at most 2. 5 kg 2 kg € 400 € 1000 2 kg 1 kg € 700 Greedy Algorithm (Best Ratio) 1. 5 kg
Steal at most 0. 5 kg € 400 € 1000 2 kg Why? 1 kg € 700 Greedy Algorithm (Best Ratio) Failure 1. 5 kg
Outline • Matroids – Definition – Examples – Terminology • Maximum Weight Independent Set • Submodular Functions • Relationship
Subset System Set S Non-empty collection of subsets I Property: If X I and Y⊆X, then Y I (S, I) is a subset system
Hereditary Property Set S Non-empty collection of subsets I Property: If X I and Y⊆X, then Y I (S, I) is a subset system
Example Set S = {1, 2, …, m} I = Set of all X ⊆ S such that |X| ≤ k Is (S, I) a subset system? Yes
Example Set S = {1, 2, …, m}, w ≥ 0 I = Set of all X ⊆ S such that Σs X w(s) ≤ W Is (S, I) a subset system Yes Not true if w can be negative
Matroid Subset system (S, I) Property: If X, Y I and |X| < |Y| then there exists a s YX such that X∪{s} I M = (S, I) is a matroid
Augmentation/Exchange Property Subset system (S, I) Property: If X, Y I and |X| < |Y| then there exists a s YX such that X∪{s} I M = (S, I) is a matroid
Example Set S = {1, 2, …, m} I = Set of all X ⊆ S such that |X| ≤ k Is M = (S, I) a matroid? Uniform matroid Yes
Example Set S = {1, 2, …, m}, w ≥ 0 I = Set of all X ⊆ S such that Σs X w(s) ≤ W Is M = (S, I) a matroid? No Coincidence? No
Matroids (S, I) is a matroid � (S, I) admits an optimal greedy algorithm
Matroids � (S, I) is a matroid (S, I) admits an optimal greedy algorithm Next section
Outline • Matroids – Definition – Examples – Terminology • Maximum Weight Independent Set • Submodular Functions • Relationship
Uniform Matroid S = {1, 2, …, m} X⊆S I = Set of all X ⊆ S such that |X| ≤ k
Graph Theory
Forest G = (V, E) v 0 v 1 v 4 v 2 v 3 V = {v 1, …, vn} v 5 E = {e 1, …, em} v 6 Subset of edges that contain no circuit
Forest G = (V, E) v 0 v 1 v 4 v 2 v 3 V = {v 1, …, vn} v 5 E = {e 1, …, em} v 6 Forest? Subset of edges that contain no circuit
Forest G = (V, E) v 0 v 1 v 4 v 2 v 3 V = {v 1, …, vn} v 5 E = {e 1, …, em} v 6 Forest? Subset of edges that contain no circuit
Forest G = (V, E) v 0 v 1 v 4 v 2 v 3 V = {v 1, …, vn} v 5 E = {e 1, …, em} v 6 Forest? Subset of edges that contain no circuit
Graphic Matroid G = (V, E), S = E X⊆S X ∈ I if X is a forest
Linear Algebra
1 2 3 1 2 2 4 1 2 3 2 4 3 6 1 2 3 1 2 4 8 1 2 3 2 4 Matrix A Subset of columns {a 1, a 2, …, ak} Linearly independent (LI)? ✗ There exists no α ≠ 0 such that Σi αi ai = 0
1 2 3 1 2 2 4 1 2 3 2 4 3 6 1 2 3 1 2 4 8 1 2 3 2 4 Matrix A Subset of columns {a 1, a 2, …, ak} Linearly independent (LI)? ✓ There exists no α ≠ 0 such that Σi αi ai = 0
1 2 3 1 2 2 4 1 2 3 2 4 3 6 1 2 3 1 2 4 8 1 2 3 2 4 Matrix A Subset of columns {a 1, a 2, …, ak} Linearly independent (LI)? ✓ There exists no α ≠ 0 such that Σi αi ai = 0
1 2 3 1 2 2 4 1 2 3 2 4 3 6 1 2 3 1 2 4 8 1 2 3 2 4 Matrix A Subset of columns {a 1, a 2, …, ak} Linearly independent (LI)? ✓ There exists no α ≠ 0 such that Σi αi ai = 0
Linear Matroid Matrix A of size n x m, S = {1, 2, …, m} X ⊆ S, A(X) = set of columns of A indexed by X X I if and only if A(X) are linearly independent
Outline • Matroids – Definition – Examples – Terminology • Maximum Weight Independent Set • Submodular Functions • Relationship
Independent Set Matroid M = (S, I) X ⊆ S is independent if X I X ⊆ S is dependent if X ∉ I
Base of a Subset Matroid M = (S, I) X is a base of U ⊆S if it satisfies three properties (i) X ⊆ U (ii) X ∈ I (iii) There exists no U’∈I, such that X ⊂ U’ ⊆ U Inclusionwise maximal independent subset of U
An Interesting Property M = (S, I) is a subset system M is a matroid � For all U ⊆ S, all bases of U have same size
An Interesting Property M = (S, I) is a subset system � M is a matroid For all U ⊆ S, all bases of U have same size Proof? X∈ I Y∈ I Base of X ∪ Y?
An Interesting Property M = (S, I) is a subset system � M is a matroid For all U ⊆ S, all bases of U have same size An alternate definition for matroids
Rank of a Subset Matroid M = (S, I) U ⊆S r. M(U) = Size of a base of U
Base of a Matroid M = (S, I) X is a base S
Rank of a Matroid M = (S, I) r. M = Rank of S
Recap • Subset System? Hereditary Property? • Matroid? Exchange Property? • Uniform, Graphic, Linear Matroids? • Base of a subset? • Rank of a subset?
Outline • Matroids • Maximum Weight Independent Set • Submodular Functions • Relationship
Independent Set Matroid M = (S, I) X ⊆ S is independent if X I X ⊆ S is dependent if X ∉ I
Weight of an Independent Set Matroid M = (S, I) Weight function w: S → Non-negative Real Weight of an independent set X The sum of weight of its elements
Weight of an Independent Set Matroid M = (S, I) Weight function w: S → Non-negative Real Weight of an independent set X w(X) = ∑s∈X w(s)
Example (Uniform Matroid) S = {1, 2, …, 9} k=4 X = {1, 3, 5} s 1 2 3 4 5 6 7 8 9 w(s) 10 5 2 1 3 6 12 2 1
Example (Uniform Matroid) S = {1, 2, …, 9} k=4 X = {1, 3, 5} w(X)? 15 s 1 2 3 4 5 6 7 8 9 w(s) 10 5 2 1 3 6 12 2 1
Example (Graphic Matroid) S=E 2 v 1 1 Forest X v 0 6 v 4 2 3 5 v 2 v 5 3 2 v 3 4 v 6
Example (Graphic Matroid) S=E 2 v 1 1 Forest X v 0 6 v 4 2 3 5 v 2 v 5 3 w(X)? 10 2 v 3 4 v 6
Maximum Weight Independent Set Matroid M = (S, I) Weight function w: S → Non-negative Real Find an independent set with maximum weight max. X∈I w(X)
Maximum Weight Independent Set Matroid M = (S, I) Weight function w: S → Non-negative Real Find an independent set with maximum weight max. X∈I ∑s∈X w(s)
True or False There exists an optimal solution that is a base of the matroid TRUE
Example (Uniform Matroid) S = {1, 2, …, 9} k=4 Feasible Solutions? s 1 2 3 4 5 6 7 8 9 w(s) 10 5 2 1 3 6 12 2 1
Example (Uniform Matroid) S = {1, 2, …, 9} k=4 Optimal Solution? s 1 2 3 4 5 6 7 8 9 w(s) 10 5 2 1 3 6 12 2 1
Example (Uniform Matroid) S = {1, 2, …, 9} k=4 s 1 2 3 4 5 6 7 8 9 w(s) 10 5 2 1 3 6 12 2 1
Example (Graphic Matroid) S=E 2 v 1 1 v 0 v 4 2 3 5 v 2 Feasible Solutions? 6 v 5 3 2 v 3 4 v 6
Example (Graphic Matroid) S=E 2 v 1 1 v 0 v 4 2 3 5 v 2 Optimal Solution? 6 v 5 3 2 v 3 4 v 6
Example (Graphic Matroid) S=E 2 v 1 1 v 0 v 4 2 3 5 v 2 Efficient Algorithm? 6 v 5 3 2 v 3 4 v 6
Outline • Matroids • Maximum Weight Independent Set – Greedy Algorithm – Efficiency – Optimality – Extensions • Submodular Functions • Relationship
Greedy Algorithm Start with an empty set Repeat Pick a new element with maximum weight such that the new set is independent Add the element to the set Until no more elements can be added
Greedy Algorithm X←ϕ Repeat Pick a new element with maximum weight such that the new set is independent Add the element to the set Until no more elements can be added
Greedy Algorithm X←ϕ Repeat s* = argmaxx∈SX w(s) such that the new set is independent Add the element to the set Until no more elements can be added
Greedy Algorithm X←ϕ Repeat s* = argmaxx∈SX w(s) such that X ∪ {s} ∈ I Add the element to the set Until no more elements can be added
Greedy Algorithm X←ϕ Repeat s* = argmaxx∈SX w(s) such that X ∪ {s} ∈ I X ← X ∪ {s} Until no more elements can be added
Example (Uniform Matroid) S = {1, 2, …, 9} k=4 s 1 2 3 4 5 6 7 8 9 w(s) 10 5 2 1 3 6 12 2 1
Example (Uniform Matroid) S = {1, 2, …, 9} k=4 s 1 2 3 4 5 6 7 8 9 w(s) 10 5 2 1 3 6 12 2 1
Example (Uniform Matroid) S = {1, 2, …, 9} k=4 s 1 2 3 4 5 6 7 8 9 w(s) 10 5 2 1 3 6 12 2 1
Example (Uniform Matroid) S = {1, 2, …, 9} k=4 s 1 2 3 4 5 6 7 8 9 w(s) 10 5 2 1 3 6 12 2 1
Example (Uniform Matroid) S = {1, 2, …, 9} k=4 s 1 2 3 4 5 6 7 8 9 w(s) 10 5 2 1 3 6 12 2 1
Example (Graphic Matroid) S=E 2 v 1 1 v 0 6 v 4 2 3 5 v 2 v 5 3 2 v 3 4 v 6
Example (Graphic Matroid) S=E 2 v 1 1 v 0 6 v 4 2 3 5 v 2 v 5 3 2 v 3 4 v 6
Example (Graphic Matroid) S=E 2 v 1 1 v 0 6 v 4 2 3 5 v 2 v 5 3 2 v 3 4 v 6
Example (Graphic Matroid) S=E 2 v 1 1 v 0 6 v 4 2 3 5 v 2 v 5 3 2 v 3 4 v 6
Example (Graphic Matroid) S=E 2 v 1 1 v 0 6 v 4 2 3 5 v 2 v 5 3 2 v 3 4 v 6
Example (Graphic Matroid) S=E 2 v 1 1 v 0 6 v 4 2 3 5 v 2 v 5 3 2 v 3 4 v 6
Example (Graphic Matroid) S=E 2 v 1 1 v 0 6 v 4 2 3 5 v 2 v 5 3 2 v 3 4 v 6
Outline • Matroids • Maximum Weight Independent Set – Greedy Algorithm – Efficiency – Optimality – Extensions • Submodular Functions • Relationship
Efficiency of Greedy Algorithm X←ϕ Repeat s* = argmaxx∈SX w(s) O(|S|) such that X ∪ {s} ∈ I X ← X ∪ {s} Until no more elements can be added O(|S|)
Independence Testing Oracle Efficiency depends on independence testing Brute-force is not an option Uniform matroid? Graphic matroid?
Outline • Matroids • Maximum Weight Independent Set – Greedy Algorithm – Efficiency – Optimality – Extensions • Submodular Functions • Relationship
Optimality: Necessity (S, I) is a matroid � (S, I) admits an optimal greedy algorithm Proof?
Proof Sketch Matroid M = (S, I) Proof by induction Current solution X X is part of optimal solution B (base of M)
Proof Sketch Next step chooses to add s If s ∈ B, trivial Otherwise, consider base B’ such that X ∪{s} ⊆ B’ ⊂ B ∪{s} How to construct B’? B’ = (B ∪{s}){t} w(B’) ≥ w(B) by construction
Optimality: Sufficiency � (S, I) is a matroid (S, I) admits an optimal greedy algorithm Proof?
Proof Sketch Subset system M = (S, I) X∈I Y∈I k = |X| < |Y| There should exist an s ∈ YX, X ∪{s} ∈ I Proof by contradiction
Proof Sketch k+2, if s ∈ X w(s) = Recall k = |X| k+1, if s ∈ YX 0, otherwise Greedy solution has weight k(k+2) w(Y) ≥ (k+1) > k(k+2)
Outline • Matroids • Maximum Weight Independent Set – Greedy Algorithm – Efficiency – Optimality – Extensions • Submodular Functions • Relationship
Maximum Weight Base Matroid M = (S, I) Weight function w: S → Real Find a base with maximum weight max. X∈B w(X) Does greedy work? YES
Minimum Weight Base Matroid M = (S, I) Weight function w: S → Real Find a base with minimum weight min. X∈B w(X) Does greedy work? YES
Maximum Weight Independent Set Matroid M = (S, I) Weight function w: S → Real Find an independent set with maximum weight max. X∈I w(X) Does greedy work? YES
Outline • Matroids • Submodular Functions • Relationship
Submodular Function Set S Function f over power set of S f(T) + f(U) ≥ f(T ∪ U) + f(T ∩ U) for all T, U ⊆ S
Supermodular Function Set S Function f over power set of S f(T) + f(U) ≤ f(T ∪ U) + f(T ∩ U) for all T, U ⊆ S
Modular Function Set S Function f over power set of S f(T) + f(U) = f(T ∪ U) + f(T ∩ U) for all T, U ⊆ S
Modular Function f(T) = ∑s ∈T w(s) + K Is f modular? YES All modular functions have above form? YES Prove at home
Outline • Matroids • Submodular Functions – Diminishing Returns – Examples • Relationship
Diminishing Returns Define df(s|T) = f(T ∪{s}) - f(T) Gain by adding s to T If f is submodular, df (s|T) is non-increasing
Diminishing Returns Define df(s|T) = f(T ∪{s}) - f(T) Gain by adding s to T Proof? f(U ∪ {s}) + f(U ∪ {t}) ≥ f(U) + f(U ∪{s, t}) for all U⊆ S and distinct s, t ∈ SU Necessary condition for submodularity
Diminishing Returns Define df(s|T) = f(T ∪{s}) - f(T) Gain by adding s to T Prove at home f(U ∪ {s}) + f(U ∪ {t}) ≥ f(U) + f(U ∪{s, t}) for all U⊆ S and distinct s, t ∈ SU Sufficient condition for submodularity
Outline • Matroids • Submodular Functions – Diminishing Returns – Examples • Relationship
Set Theory
Set Unions T 1, T 2, …, Tn ⊆ T S = {1, 2, … n} Prove at home f(U) = ∑s∈U’ w(s), U’ = ∪i∈U Ti Submodular Non-negative weight w(s) of element s ∈ T Minimum of f? 0 Is f non-decreasing? YES
Graph Theory
Directed Graph Cuts Digraph G = (V, A) f(U) = ∑a∈out-arcs(U) c(a) S=V Submodular Proof? Non-negative capacity c(a) of arc a ∈ A Minimum of f? 0 Is f non-decreasing? NO
Directed Graph Cuts Digraph G = (V, A) f(U) = ∑a∈out-arcs(U) c(a) S=V Submodular Proof? Non-negative capacity c(a) of arc a ∈ A Minimum of f over U ⊆ S{t} such that s ∈ U? Minimum s-t cut = Maximum s-t flow
Outline • Matroids • Submodular Functions • Relationship
Rank Function of Matroid M = (S, I) Rank function r X is independent if and only if r(X) = |X|
Property of Rank Function Proof? Rank function of a matroid r � Set S For all T, U ⊆ S if T ⊆U r(T) ≤ r(U) ≤ |U|
Property of Rank Function Set S Proof? � Rank function of a matroid r For all T, U ⊆ S r(T ∪ U) + r(T ∩ U) ≤ r(T) + r(U) Rank function of a matroid is submodular
Proof Sketch Matroid M = (S, I) X ⊆T∩U, X ∈I is inclusionwise maximal Y ⊆T∪U, X ⊆ Y, Y ∈I is inclusionwise maximal r(T∩U) = |X| Why?
Proof Sketch Matroid M = (S, I) X ⊆T∩U, X ∈I is inclusionwise maximal Y ⊆T∪U, X ⊆ Y, Y ∈I is inclusionwise maximal r(T∪U) = |Y| Why?
Proof Sketch Matroid M = (S, I) X ⊆T∩U, X ∈I is inclusionwise maximal Y ⊆T∪U, X ⊆ Y, Y ∈I is inclusionwise maximal r(T) ≥ |Y∩T| Why?
Proof Sketch Matroid M = (S, I) X ⊆T∩U, X ∈I is inclusionwise maximal Y ⊆T∪U, X ⊆ Y, Y ∈I is inclusionwise maximal r(U) ≥ |Y∩U| Why?
Proof Sketch Matroid M = (S, I) r(T) + r(U) ≥ |Y∩T| + |Y∩U| = |Y∩(T∩U)| + |Y∩(T∪U)| ≥ |X| + |Y| = r(T∩U) + r(T∪U)
Questions? Next time … Polytopes
- Slides: 121