Matroids and submodular optimization Attila Bernáth Research fellow, Institute of Informatics, Warsaw University 23 May 2012 Attila Bernáth () Matroids and submodular optimization 23 May 2012 1 / 10
About me I have done my university studies and my PhD at Eötvös Loránd University, Budapest. Currently I am a postdoctoral researcher working in the ERC project titled Practical Approximation Algorithms led by Piotr Sankowski. Attila Bernáth () Matroids and submodular optimization 23 May 2012 2 / 10
About the course Title: Matroids and submodular optimization Subject: see later Language: English Prerequisities: some background in graph theory (spanning trees, network flows), linear algebra and complexity theory (polynomial algorithms, NP-completeness) Coursebook: Connections in Combinatorial Optimization written by András Frank Attila Bernáth () Matroids and submodular optimization 23 May 2012 3 / 10
Matroids - motivation Minimum weight spanning trees Given a (connected, undirected) graph G = (V, E) and edge-weights w : E R, find a spanning tree whose cost is minimal. Attila Bernáth () Matroids and submodular optimization 23 May 2012 4 / 10
Matroids - motivation Maximum weight spanning trees Given a (connected, undirected) graph G = (V, E) and edge-weights w : E R, find a spanning tree whose cost is maximal. Attila Bernáth () Matroids and submodular optimization 23 May 2012 4 / 10
Matroids - motivation Maximum weight spanning trees Given a (connected, undirected) graph G = (V, E) and edge-weights w : E R, find a spanning tree whose cost is maximal. Greedy algorithm (Kruskal) Assume w(e 1 ) w(e 2 ) w(e m ), and start with F = For i = 1, 2,..., m Include ei in F iff no cycle arises Output F. Attila Bernáth () Matroids and submodular optimization 23 May 2012 4 / 10
Matroids - motivation Given some vectors v 1, v 2,..., v m R n, find a linearly independent subset of maximum size... Attila Bernáth () Matroids and submodular optimization 23 May 2012 5 / 10
Matroids - motivation Given some vectors v 1, v 2,..., v m R n, find a linearly independent subset of maximum size... Or, more generally, find a linearly independent subset of maximum weight (where the weight w(v i ) of each vector is also given). Attila Bernáth () Matroids and submodular optimization 23 May 2012 5 / 10
Matroids - motivation Given some vectors v 1, v 2,..., v m R n, find a linearly independent subset of maximum size... Or, more generally, find a linearly independent subset of maximum weight (where the weight w(v i ) of each vector is also given). Greedy algorithm (the same as before) Assume w(v 1 ) w(v 2 ) w(v m ), and start with F = For i = 1, 2,..., m Include vi in F iff it remains linearly independent Output F. Attila Bernáth () Matroids and submodular optimization 23 May 2012 5 / 10
Matroids - definition Matroids grab this greedy structure (or: they generalize linear independence) Given some finite set S, let 2 S denote the set of all subsets of S. A family I 2 S is called hereditary, if X X I implies X I. Attila Bernáth () Matroids and submodular optimization 23 May 2012 6 / 10
Matroids - definition Matroids grab this greedy structure (or: they generalize linear independence) Given some finite set S, let 2 S denote the set of all subsets of S. A family I 2 S is called hereditary, if X X I implies X I. Definition (Matroid) The pair (S, I) is called a matroid, if I is nonempty, hereditary, and for any X S, the inclusionwise maximal members of I contained in X all have the same size. Members of I are called independent. Attila Bernáth () Matroids and submodular optimization 23 May 2012 6 / 10
Matroids - definition Matroids grab this greedy structure (or: they generalize linear independence) Given some finite set S, let 2 S denote the set of all subsets of S. A family I 2 S is called hereditary, if X X I implies X I. Definition (Matroid) The pair (S, I) is called a matroid, if I is nonempty, hereditary, and for any X S, the inclusionwise maximal members of I contained in X all have the same size. Members of I are called independent. In other words, if the greedy algorithm for finding a maximum weight member of I works for any 0 1 valued weight function (i.e. χ X ). Attila Bernáth () Matroids and submodular optimization 23 May 2012 6 / 10
Matroids - definition Matroids grab this greedy structure (or: they generalize linear independence) Given some finite set S, let 2 S denote the set of all subsets of S. A family I 2 S is called hereditary, if X X I implies X I. Definition (Matroid) The pair (S, I) is called a matroid, if I is nonempty, hereditary, and for any X S, the inclusionwise maximal members of I contained in X all have the same size. Members of I are called independent. In other words, if the greedy algorithm for finding a maximum weight member of I works for any 0 1 valued weight function (i.e. χ X ). (Note: this already implies that the greedy algorithm works properly for any weight function.) Attila Bernáth () Matroids and submodular optimization 23 May 2012 6 / 10
Matroids - examples Example 1: if G = (V, E) is a graph then forests form the independent sets of a matroid with ground set S = E (graphic matroid) Example 2: Given vectors v 1, v 2,..., v m, the linearly independent subsets also give a matroid (linear matroid). Attila Bernáth () Matroids and submodular optimization 23 May 2012 7 / 10
Matroids - applications Spanning tree union Given a graph G = (V, E), positive integer k, find k spanning trees, that are (pairwise) edge-disjoint. Polynomially solvable with matroid techniques, moreover... Attila Bernáth () Matroids and submodular optimization 23 May 2012 8 / 10
Matroids - applications Spanning tree union Given a graph G = (V, E), positive integer k, find k spanning trees, that are (pairwise) edge-disjoint. Polynomially solvable with matroid techniques, moreover... Maximum weight spanning tree union Given a graph G = (V, E), positive integer k and edge-weights w : E R, find k edge-disjoint spanning trees whose total weight is maximal. This is also polynomially solvable with matroid techniques (it is the special case of finding a maximum weight independent set in a matroid). Attila Bernáth () Matroids and submodular optimization 23 May 2012 8 / 10
Submodularity - motivating definition Suppose we have a factory that can produce any subset of a product set S. Attila Bernáth () Matroids and submodular optimization 23 May 2012 9 / 10
Submodularity - motivating definition Suppose we have a factory that can produce any subset of a product set S. If we decide to produce a subset X S, we have to pay a setup cost c(x ). Attila Bernáth () Matroids and submodular optimization 23 May 2012 9 / 10
Submodularity - motivating definition Suppose we have a factory that can produce any subset of a product set S. If we decide to produce a subset X S, we have to pay a setup cost c(x ). Suppose we have tentatively decided to produce some X S, and consider adding a new product e S \ X. The incremental setup cost will then be c(x + e) c(x ). Attila Bernáth () Matroids and submodular optimization 23 May 2012 9 / 10
Submodularity - motivating definition Suppose we have a factory that can produce any subset of a product set S. If we decide to produce a subset X S, we have to pay a setup cost c(x ). Suppose we have tentatively decided to produce some X S, and consider adding a new product e S \ X. The incremental setup cost will then be c(x + e) c(x ). Economists say, that in real-world applications this incremental setup cost of adding e can only get smaller, if X gets bigger, i.e. If X X and e S X, then c(x + e) c(x ) c(x + e) c(x ). Such a set function c is called submodular. Attila Bernáth () Matroids and submodular optimization 23 May 2012 9 / 10
Submodularity - motivating definition Suppose we have a factory that can produce any subset of a product set S. If we decide to produce a subset X S, we have to pay a setup cost c(x ). Suppose we have tentatively decided to produce some X S, and consider adding a new product e S \ X. The incremental setup cost will then be c(x + e) c(x ). Economists say, that in real-world applications this incremental setup cost of adding e can only get smaller, if X gets bigger, i.e. If X X and e S X, then c(x + e) c(x ) c(x + e) c(x ). Such a set function c is called submodular. Informally: introducing a new product is cheaper in a bigger factory. Attila Bernáth () Matroids and submodular optimization 23 May 2012 9 / 10
Submodularity - applications, examples Applications: optimization problems are usually tractable because submodularity is involved, many proofs in graph theory use submodularity. Attila Bernáth () Matroids and submodular optimization 23 May 2012 10 / 10
Submodularity - applications, examples Applications: optimization problems are usually tractable because submodularity is involved, Examples many proofs in graph theory use submodularity. The cut function d G : 2 V Z + of an (undirected) graph G = (V, E), defined by d G (X ) = {e E : e enters X } is submodular (it is also symmetric, meaning d G (X ) = d G ((V X ) for any X ), The in-degree function ϱ D : 2 V Z + of a directed graph D = (V, A) defined by ϱ D (X ) = {a A : a enters X } is (non-symmetric and) submodular (so is the out-degree function, of course), The rank function r : 2 S Z + of a matroid (S, I) defined by r(x ) = max{ I : I I, I X } is submodular. Attila Bernáth () Matroids and submodular optimization 23 May 2012 10 / 10