Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Greedy Algorithm And
Edmonds Matroid Intersection Algorithm
Paul Wilhelm wilhelm@math.hu-berlin.de
Institut f¨ ur Mathematik Humboldt-Universit¨ at zu Berlin
July 17, 2010
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 1 / 32
Content I
1 Greedy Algorithm Prerequisites Algorithm
Feasibility In Matroids
Proof ’Greedy ⇒ Matroid’
Proof ’Matroid ⇒ Greedy’
2 Transversal Matroids Job Scheduling
Job Scheduling Problem Mathematical Describtion
Transversal Matroids
Definition Transversal Matroids Proof
Greedy Algorithm In Transversal Matroids
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Content II
Prerequisites
Example Intersection Of Two Matriods
Algorithm
Counterexample Intersection Of Three Matriods Complexity Of Edmonds’ Algorithm
Outlook
Correctnes of the Algorithm
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 3 / 32
Remind
Independence System / Matroid (E , I)
∅ ⊆ I (nonempty)
Y ⊆ I , X ⊆ Y ⇒ X ⊆ I (hereditary)
X , Y ∈ I, |X | < |Y | ⇒ ∃y ∈ Y \ X : X ∪ {y } ∈ I (augmentation)
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Prerequisites
Remind
Independence System / Matroid (E , I)
∅ ⊆ I (nonempty)
Y ⊆ I , X ⊆ Y ⇒ X ⊆ I (hereditary)
X , Y ∈ I, |X | < |Y | ⇒ ∃y ∈ Y \ X : X ∪ {y } ∈ I (augmentation)
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 4 / 32
Remind
Independence System / Matroid (E , I)
∅ ⊆ I (nonempty)
Y ⊆ I , X ⊆ Y ⇒ X ⊆ I (hereditary)
X , Y ∈ I, |X | < |Y | ⇒ ∃y ∈ Y \ X : X ∪ {y } ∈ I (augmentation)
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Prerequisites
Min/Max - Problem
(due to (Korte and Vygen, 2007, p. 306)) Maximization Problem
Find X ∈ I s.t. the weight w (X ) = P
e∈X
w (e) is maximum
Minimization Problem
Find a basis B s.t. the weight w (X ) = P
e∈X
w (e ) is minimum
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 5 / 32
Min/Max - Problem
(due to (Korte and Vygen, 2007, p. 306)) Maximization Problem
Find X ∈ I s.t. the weight w (X ) = P
e∈X
w (e) is maximum
Minimization Problem
Find a basis B s.t. the weight w (X ) = P
e∈X
w (e ) is minimum
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Prerequisites
Min/Max - Problem
(due to (Korte and Vygen, 2007, p. 306)) Maximization Problem
Find X ∈ I s.t. the weight w (X ) = P
e∈X
w (e) is maximum
Minimization Problem
Find a basis B s.t. the weight w (X ) = P
e∈X
w (e ) is minimum
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 5 / 32
Examples
Many combinatorial optimization problems can be formulated as min/max-problem (more in (Korte and Vygen, 2007, p. 306)):
maximum weight stable set travelling salesman shortest path
knapsack
minimum spanning tree maximum weight forest steiner tree
maximum weight branching
maximum weight matching
job scheduling
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Prerequisites
Examples
Many combinatorial optimization problems can be formulated as min/max-problem (more in (Korte and Vygen, 2007, p. 306)):
maximum weight stable set travelling salesman shortest path
knapsack
minimum spanning tree maximum weight forest steiner tree
maximum weight branching maximum weight matching job scheduling
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 6 / 32
Examples
Many combinatorial optimization problems can be formulated as min/max-problem (more in (Korte and Vygen, 2007, p. 306)):
maximum weight stable set travelling salesman shortest path
knapsack
minimum spanning tree maximum weight forest steiner tree
maximum weight branching
maximum weight matching
job scheduling
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Prerequisites
Examples
Many combinatorial optimization problems can be formulated as min/max-problem (more in (Korte and Vygen, 2007, p. 306)):
maximum weight stable set travelling salesman shortest path
knapsack
minimum spanning tree maximum weight forest steiner tree
maximum weight branching maximum weight matching job scheduling
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 6 / 32
Examples
Many combinatorial optimization problems can be formulated as min/max-problem (more in (Korte and Vygen, 2007, p. 306)):
maximum weight stable set travelling salesman shortest path
knapsack
minimum spanning tree maximum weight forest steiner tree
maximum weight branching
maximum weight matching
job scheduling
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Prerequisites
Examples
Many combinatorial optimization problems can be formulated as min/max-problem (more in (Korte and Vygen, 2007, p. 306)):
maximum weight stable set travelling salesman shortest path
knapsack
minimum spanning tree maximum weight forest steiner tree
maximum weight branching maximum weight matching job scheduling
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 6 / 32
Examples
Many combinatorial optimization problems can be formulated as min/max-problem (more in (Korte and Vygen, 2007, p. 306)):
maximum weight stable set travelling salesman shortest path
knapsack
minimum spanning tree maximum weight forest steiner tree
maximum weight branching
maximum weight matching
job scheduling
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Prerequisites
Examples
Many combinatorial optimization problems can be formulated as min/max-problem (more in (Korte and Vygen, 2007, p. 306)):
maximum weight stable set travelling salesman shortest path
knapsack
minimum spanning tree maximum weight forest steiner tree
maximum weight branching maximum weight matching job scheduling
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 6 / 32
Examples
Many combinatorial optimization problems can be formulated as min/max-problem (more in (Korte and Vygen, 2007, p. 306)):
maximum weight stable set travelling salesman shortest path
knapsack
minimum spanning tree maximum weight forest steiner tree
maximum weight branching
maximum weight matching
job scheduling
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Prerequisites
Examples
Many combinatorial optimization problems can be formulated as min/max-problem (more in (Korte and Vygen, 2007, p. 306)):
maximum weight stable set travelling salesman shortest path
knapsack
minimum spanning tree maximum weight forest steiner tree
maximum weight branching maximum weight matching job scheduling
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 6 / 32
Examples
Many combinatorial optimization problems can be formulated as min/max-problem (more in (Korte and Vygen, 2007, p. 306)):
maximum weight stable set travelling salesman shortest path
knapsack
minimum spanning tree maximum weight forest steiner tree
maximum weight branching
maximum weight matching
job scheduling
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Prerequisites
Oracle
The independence system (E, I ) is given by an oracle:
Independence Oracle
An oracle which decides whether F ⊆ E is in I or not.
∀F ⊆ E O (F ) :=
1 ,if F ∈ I 0 ,else
Basis-Superset Oracle
An oracle which decides whether B ⊆ E is an basis for I or not.
∀B ⊆ E O (B ) :=
1 ,if B ∈ I and ∄x ∈ E : B ∪ {x} ∈ I 0 ,else
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 7 / 32
Oracle
The independence system (E, I ) is given by an oracle:
Independence Oracle
An oracle which decides whether F ⊆ E is in I or not.
∀F ⊆ E O (F ) :=
1 ,if F ∈ I 0 ,else
Basis-Superset Oracle
An oracle which decides whether B ⊆ E is an basis for I or not.
∀B ⊆ E O (B ) :=
1 ,if B ∈ I and ∄x ∈ E : B ∪ {x} ∈ I
0 ,else
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Prerequisites
Oracle
The independence system (E, I ) is given by an oracle:
Independence Oracle
An oracle which decides whether F ⊆ E is in I or not.
∀F ⊆ E O (F ) :=
1 ,if F ∈ I 0 ,else
Basis-Superset Oracle
An oracle which decides whether B ⊆ E is an basis for I or not.
∀B ⊆ E O (B ) :=
1 ,if B ∈ I and ∄x ∈ E : B ∪ {x} ∈ I 0 ,else
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 7 / 32
Oracle
The independence system (E, I ) is given by an oracle:
Independence Oracle
An oracle which decides whether F ⊆ E is in I or not.
∀F ⊆ E O (F ) :=
1 ,if F ∈ I 0 ,else
Basis-Superset Oracle
An oracle which decides whether B ⊆ E is an basis for I or not.
∀B ⊆ E O (B ) :=
1 ,if B ∈ I and ∄x ∈ E : B ∪ {x} ∈ I
0 ,else
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Prerequisites
Oracle
The independence system (E, I ) is given by an oracle:
Independence Oracle
An oracle which decides whether F ⊆ E is in I or not.
∀F ⊆ E O (F ) :=
1 ,if F ∈ I 0 ,else
Basis-Superset Oracle
An oracle which decides whether B ⊆ E is an basis for I or not.
∀B ⊆ E O (B ) :=
1 ,if B ∈ I and ∄x ∈ E : B ∪ {x} ∈ I 0 ,else
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 7 / 32
Oracle
The independence system (E, I ) is given by an oracle:
Independence Oracle
An oracle which decides whether F ⊆ E is in I or not.
∀F ⊆ E O (F ) :=
1 ,if F ∈ I 0 ,else
Basis-Superset Oracle
An oracle which decides whether B ⊆ E is an basis for I or not.
∀B ⊆ E O (B ) :=
1 ,if B ∈ I and ∄x ∈ E : B ∪ {x} ∈ I
0 ,else
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Prerequisites
Oracle
The independence system (E, I ) is given by an oracle:
Independence Oracle
An oracle which decides whether F ⊆ E is in I or not.
∀F ⊆ E O (F ) :=
1 ,if F ∈ I 0 ,else
Basis-Superset Oracle
An oracle which decides whether B ⊆ E is an basis for I or not.
∀B ⊆ E O (B ) :=
1 ,if B ∈ I and ∄x ∈ E : B ∪ {x} ∈ I 0 ,else
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 7 / 32
Algorithm
Best-In-Greedy
Sort E = {e 1 , ..., e n } s.t. w (e 1 ) ≥ ... ≥ w (e n ) Set F := ∅∈ I
For i:=1 to n do:
If F ∪ {e
i}∈ I then set F := F ∪ {e
i} Output: F ∈ I
Sort the elements in E (O(n · log(n)))
Have to ask oracle in each step! Complexity of algorithm depends
mainly on complexity of oracle (O( O )).
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Algorithm
Algorithm
Best-In-Greedy
Sort E = {e 1 , ..., e n } s.t. w (e 1 ) ≥ ... ≥ w (e n ) Set F := ∅∈ I
For i:=1 to n do:
If F ∪ {e
i}∈ I then set F := F ∪ {e
i} Output: F ∈ I
Sort the elements in E (O(n · log(n)))
Have to ask oracle in each step! Complexity of algorithm depends mainly on complexity of oracle (O( O )).
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 8 / 32
Algorithm
Best-In-Greedy
Sort E = {e 1 , ..., e n } s.t. w (e 1 ) ≥ ... ≥ w (e n ) Set F := ∅∈ I
For i:=1 to n do:
If F ∪ {e
i}∈ I then set F := F ∪ {e
i} Output: F ∈ I
Sort the elements in E (O(n · log(n)))
Have to ask oracle in each step! Complexity of algorithm depends
mainly on complexity of oracle (O( O )).
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Algorithm
Algorithm
Best-In-Greedy
Sort E = {e 1 , ..., e n } s.t. w (e 1 ) ≥ ... ≥ w (e n ) Set F := ∅∈ I
For i:=1 to n do:
If F ∪ {e
i}∈ I then set F := F ∪ {e
i} Output: F ∈ I
Sort the elements in E (O(n · log(n)))
Have to ask oracle in each step! Complexity of algorithm depends mainly on complexity of oracle (O( O )).
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 8 / 32
Algorithm
Best-In-Greedy
Sort E = {e 1 , ..., e n } s.t. w (e 1 ) ≥ ... ≥ w (e n ) Set F := ∅∈ I
For i:=1 to n do:
If F ∪ {e
i}∈ I then set F := F ∪ {e
i} Output: F ∈ I
Sort the elements in E (O(n · log(n)))
Have to ask oracle in each step! Complexity of algorithm depends
mainly on complexity of oracle (O( O )).
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Algorithm
Algorithm
Best-In-Greedy
Sort E = {e 1 , ..., e n } s.t. w (e 1 ) ≥ ... ≥ w (e n ) Set F := ∅∈ I
For i:=1 to n do:
If F ∪ {e
i}∈ I then set F := F ∪ {e
i} Output: F ∈ I
Sort the elements in E (O(n · log(n)))
Have to ask oracle in each step! Complexity of algorithm depends mainly on complexity of oracle (O( O )).
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 8 / 32
Algorithm
Best-In-Greedy
Sort E = {e 1 , ..., e n } s.t. w (e 1 ) ≥ ... ≥ w (e n ) Set F := ∅∈ I
For i:=1 to n do:
If F ∪ {e
i}∈ I then set F := F ∪ {e
i} Output: F ∈ I
Sort the elements in E (O(n · log(n)))
Have to ask oracle in each step! Complexity of algorithm depends
mainly on complexity of oracle (O( O )).
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Algorithm
Algorithm
Best-In-Greedy
Sort E = {e 1 , ..., e n } s.t. w (e 1 ) ≥ ... ≥ w (e n ) Set F := ∅∈ I
For i:=1 to n do:
If F ∪ {e
i}∈ I then set F := F ∪ {e
i} Output: F ∈ I
Sort the elements in E (O(n · log(n)))
Have to ask oracle in each step! Complexity of algorithm depends mainly on complexity of oracle (O( O )).
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 8 / 32
Algorithm
Best-In-Greedy
Sort E = {e 1 , ..., e n } s.t. w (e 1 ) ≥ ... ≥ w (e n ) Set F := ∅∈ I
For i:=1 to n do:
If F ∪ {e
i}∈ I then set F := F ∪ {e
i} Output: F ∈ I
Sort the elements in E (O(n · log(n)))
Have to ask oracle in each step! Complexity of algorithm depends
mainly on complexity of oracle (O( O )).
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Theorem Feasibility
Asume the greedy algorithm work correctly in the independence system (E, I).
Theorem
An independence system is a matroid iff the best-in-greedy algorithm finds for all weight functions an optimum solution for the maximization problem.
If not a matroid:
find only locally optimum
cardinallity don’t have to be maximum, just maximal (i.e. there exists no superset)
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 9 / 32
Theorem Feasibility
Asume the greedy algorithm work correctly in the independence system (E, I).
Theorem
An independence system is a matroid iff the best-in-greedy algorithm finds for all weight functions an optimum solution for the maximization problem.
If not a matroid:
find only locally optimum
cardinallity don’t have to be maximum, just maximal (i.e. there exists
no superset)
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Theorem Feasibility
Asume the greedy algorithm work correctly in the independence system (E, I).
Theorem
An independence system is a matroid iff the best-in-greedy algorithm finds for all weight functions an optimum solution for the maximization problem.
If not a matroid:
find only locally optimum
cardinallity don’t have to be maximum, just maximal (i.e. there exists no superset)
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 9 / 32
Theorem Feasibility
Asume the greedy algorithm work correctly in the independence system (E, I).
Theorem
An independence system is a matroid iff the best-in-greedy algorithm finds for all weight functions an optimum solution for the maximization problem.
If not a matroid:
find only locally optimum
cardinallity don’t have to be maximum, just maximal (i.e. there exists
no superset)
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Theorem Feasibility
Asume the greedy algorithm work correctly in the independence system (E, I).
Theorem
An independence system is a matroid iff the best-in-greedy algorithm finds for all weight functions an optimum solution for the maximization problem.
If not a matroid:
find only locally optimum
cardinallity don’t have to be maximum, just maximal (i.e. there exists no superset)
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 9 / 32
Proof ’Greedy ⇒ Matroid’ By Contradiction
Assumption: (E , I) Is No Matroid:
i.e. ∃ X , Y ∈ I with |X | < |Y | s.t. ∀e ∈ Y \ X : X ∪ {e} ∈ I / Define Weight Function:
w (e) :=
1 + ε , if e ∈ X 1 , if e ∈ Y \ X 0 , if e ∈ E \ {X ∪ Y }
⇒ greedy outputs F with w (F ) = |X | · (1 + ε) + 0
⇒ w (F ) = |X |(1 + ε) < w (Y ) = |Y | for ε < |Y |X | | − 1
to w (F ) maximum for all weight functions.
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Greedy ⇒ Matroid’ By Contradiction
Assumption: (E , I) Is No Matroid:
i.e. ∃ X , Y ∈ I with |X | < |Y | s.t. ∀e ∈ Y \ X : X ∪ {e} ∈ I / Define Weight Function:
w (e) :=
1 + ε , if e ∈ X 1 , if e ∈ Y \ X 0 , if e ∈ E \ {X ∪ Y }
⇒ greedy outputs F with w (F ) = |X | · (1 + ε) + 0
⇒ w (F ) = |X |(1 + ε) < w (Y ) = |Y | for ε < |Y |X | | − 1
to w (F ) maximum for all weight functions.
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 10 / 32
Proof ’Greedy ⇒ Matroid’ By Contradiction
Assumption: (E , I) Is No Matroid:
i.e. ∃ X , Y ∈ I with |X | < |Y | s.t. ∀e ∈ Y \ X : X ∪ {e} ∈ I / Define Weight Function:
w (e) :=
1 + ε , if e ∈ X 1 , if e ∈ Y \ X 0 , if e ∈ E \ {X ∪ Y }
⇒ greedy outputs F with w (F ) = |X | · (1 + ε) + 0
⇒ w (F ) = |X |(1 + ε) < w (Y ) = |Y | for ε < |Y |X | | − 1
to w (F ) maximum for all weight functions.
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Greedy ⇒ Matroid’ By Contradiction
Assumption: (E , I) Is No Matroid:
i.e. ∃ X , Y ∈ I with |X | < |Y | s.t. ∀e ∈ Y \ X : X ∪ {e} ∈ I / Define Weight Function:
w (e) :=
1 + ε , if e ∈ X choose first |X | steps 1 , if e ∈ Y \ X
0 , if e ∈ E \ {X ∪ Y }
⇒ greedy outputs F with w (F ) = |X | · (1 + ε) + 0
⇒ w (F ) = |X |(1 + ε) < w (Y ) = |Y | for ε < |Y |X | | − 1
to w (F ) maximum for all weight functions.
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 10 / 32
Proof ’Greedy ⇒ Matroid’ By Contradiction
Assumption: (E , I) Is No Matroid:
i.e. ∃ X , Y ∈ I with |X | < |Y | s.t. ∀e ∈ Y \ X : X ∪ {e} ∈ I / Define Weight Function:
w (e) :=
1 + ε , if e ∈ X choose first |X | steps
1 , if e ∈ Y \ X can’t choose
0 , if e ∈ E \ {X ∪ Y }
⇒ greedy outputs F with w (F ) = |X | · (1 + ε) + 0
⇒ w (F ) = |X |(1 + ε) < w (Y ) = |Y | for ε < |Y |X | | − 1
to w (F ) maximum for all weight functions.
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Greedy ⇒ Matroid’ By Contradiction
Assumption: (E , I) Is No Matroid:
i.e. ∃ X , Y ∈ I with |X | < |Y | s.t. ∀e ∈ Y \ X : X ∪ {e} ∈ I / Define Weight Function:
w (e) :=
1 + ε , if e ∈ X choose first |X | steps
1 , if e ∈ Y \ X can’t choose
0 , if e ∈ E \ {X ∪ Y } don’t change the weight
⇒ greedy outputs F with w (F ) = |X | · (1 + ε) + 0
⇒ w (F ) = |X |(1 + ε) < w (Y ) = |Y | for ε < |Y |X | | − 1
to w (F ) maximum for all weight functions.
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 10 / 32
Proof ’Greedy ⇒ Matroid’ By Contradiction
Assumption: (E , I) Is No Matroid:
i.e. ∃ X , Y ∈ I with |X | < |Y | s.t. ∀e ∈ Y \ X : X ∪ {e} ∈ I / Define Weight Function:
w (e) :=
1 + ε , if e ∈ X choose first |X | steps
1 , if e ∈ Y \ X can’t choose
0 , if e ∈ E \ {X ∪ Y } don’t change the weight
⇒ greedy outputs F with w (F ) = |X | · (1 + ε) + 0
⇒ w (F ) = |X |(1 + ε) < w (Y ) = |Y | for ε < |Y |X | | − 1
to w (F ) maximum for all weight functions.
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Greedy ⇒ Matroid’ By Contradiction
Assumption: (E , I) Is No Matroid:
i.e. ∃ X , Y ∈ I with |X | < |Y | s.t. ∀e ∈ Y \ X : X ∪ {e} ∈ I / Define Weight Function:
w (e) :=
1 + ε , if e ∈ X choose first |X | steps
1 , if e ∈ Y \ X can’t choose
0 , if e ∈ E \ {X ∪ Y } don’t change the weight
⇒ greedy outputs F with w (F ) = |X | · (1 + ε) + 0
⇒ w (F ) = |X |(1 + ε) < w (Y ) = |Y | for ε < |Y |X | | − 1
to w (F ) maximum for all weight functions.
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 10 / 32
Proof ’Greedy ⇒ Matroid’ By Contradiction
Assumption: (E , I) Is No Matroid:
i.e. ∃ X , Y ∈ I with |X | < |Y | s.t. ∀e ∈ Y \ X : X ∪ {e} ∈ I / Define Weight Function:
w (e) :=
1 + ε , if e ∈ X choose first |X | steps
1 , if e ∈ Y \ X can’t choose
0 , if e ∈ E \ {X ∪ Y } don’t change the weight
⇒ greedy outputs F with w (F ) = |X | · (1 + ε) + 0
⇒ w (F ) = |X |(1 + ε) < w (Y ) = |Y | for ε < |Y |X | | − 1
to w (F ) maximum for all weight functions.
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Matroid ⇒ Greedy’
let w be an abitrary weight function
let F = {f 1 , ..., f r } the output of the greedy algorithm w.l.o.g. w (f 1 ) ≥ ... ≥ w (f r ) (if not change numbering) first prove that F has maximum cardinality
then prove by contradiction that w (F ) is maximum
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 11 / 32
Proof ’Matroid ⇒ Greedy’
let w be an abitrary weight function
let F = {f 1 , ..., f r } the output of the greedy algorithm w.l.o.g. w (f 1 ) ≥ ... ≥ w (f r ) (if not change numbering) first prove that F has maximum cardinality
then prove by contradiction that w (F ) is maximum
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Matroid ⇒ Greedy’
let w be an abitrary weight function
let F = {f 1 , ..., f r } the output of the greedy algorithm w.l.o.g. w (f 1 ) ≥ ... ≥ w (f r ) (if not change numbering) first prove that F has maximum cardinality
then prove by contradiction that w (F ) is maximum
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 11 / 32
Proof ’Matroid ⇒ Greedy’
let w be an abitrary weight function
let F = {f 1 , ..., f r } the output of the greedy algorithm w.l.o.g. w (f 1 ) ≥ ... ≥ w (f r ) (if not change numbering) first prove that F has maximum cardinality
then prove by contradiction that w (F ) is maximum
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Matroid ⇒ Greedy’
let w be an abitrary weight function
let F = {f 1 , ..., f r } the output of the greedy algorithm w.l.o.g. w (f 1 ) ≥ ... ≥ w (f r ) (if not change numbering) first prove that F has maximum cardinality
then prove by contradiction that w (F ) is maximum
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 11 / 32
Proof ’Matroid ⇒ Greedy’
let w be an abitrary weight function
let F = {f 1 , ..., f r } the output of the greedy algorithm w.l.o.g. w (f 1 ) ≥ ... ≥ w (f r ) (if not change numbering) first prove that F has maximum cardinality
then prove by contradiction that w (F ) is maximum
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Matroid ⇒ Greedy’
let w be an abitrary weight function
let F = {f 1 , ..., f r } the output of the greedy algorithm w.l.o.g. w (f 1 ) ≥ ... ≥ w (f r ) (if not change numbering) first prove that F has maximum cardinality
then prove by contradiction that w (F ) is maximum Proof Maximum Cardinality Of F By Contradiction Assume ∃ G ∈ I s.t. |F | < |G |
Augmentation property ⇒ ∃g ∈ G \ F s.t. F ∪ {g }
⇒ ∃t s.t. {f 1 , ..., f t , g , f t+1 , ..., f s } = F ∪ {g } ∈ I with w (f t ) ≥ w (g ) ≥ w (f t+1 )
⇒ {f 1 , ..., f t } ⊆ {f 1 , ..., f t , g } ∈ I
g should been choosen in step t + 1 of greedy algorithm
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 11 / 32
Proof ’Matroid ⇒ Greedy’
let w be an abitrary weight function
let F = {f 1 , ..., f r } the output of the greedy algorithm w.l.o.g. w (f 1 ) ≥ ... ≥ w (f r ) (if not change numbering) first prove that F has maximum cardinality
then prove by contradiction that w (F ) is maximum Proof Maximum Cardinality Of F By Contradiction Assume ∃ G ∈ I s.t. |F | < |G |
Augmentation property ⇒ ∃g ∈ G \ F s.t. F ∪ {g }
⇒ ∃t s.t. {f 1 , ..., f t , g , f t+1 , ..., f s } = F ∪ {g } ∈ I with w (f t ) ≥ w (g ) ≥ w (f t+1 )
⇒ {f 1 , ..., f t } ⊆ {f 1 , ..., f t , g } ∈ I
g should been choosen in step t + 1 of greedy algorithm
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Matroid ⇒ Greedy’
let w be an abitrary weight function
let F = {f 1 , ..., f r } the output of the greedy algorithm w.l.o.g. w (f 1 ) ≥ ... ≥ w (f r ) (if not change numbering) first prove that F has maximum cardinality
then prove by contradiction that w (F ) is maximum Proof Maximum Cardinality Of F By Contradiction Assume ∃ G ∈ I s.t. |F | < |G |
Augmentation property ⇒ ∃g ∈ G \ F s.t. F ∪ {g }
⇒ ∃t s.t. {f 1 , ..., f t , g , f t+1 , ..., f s } = F ∪ {g } ∈ I with w (f t ) ≥ w (g ) ≥ w (f t+1 )
⇒ {f 1 , ..., f t } ⊆ {f 1 , ..., f t , g } ∈ I
g should been choosen in step t + 1 of greedy algorithm
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 11 / 32
Proof ’Matroid ⇒ Greedy’
let w be an abitrary weight function
let F = {f 1 , ..., f r } the output of the greedy algorithm w.l.o.g. w (f 1 ) ≥ ... ≥ w (f r ) (if not change numbering) first prove that F has maximum cardinality
then prove by contradiction that w (F ) is maximum Proof Maximum Cardinality Of F By Contradiction Assume ∃ G ∈ I s.t. |F | < |G |
Augmentation property ⇒ ∃g ∈ G \ F s.t. F ∪ {g }
⇒ ∃t s.t. {f 1 , ..., f t , g , f t+1 , ..., f s } = F ∪ {g } ∈ I with w (f t ) ≥ w (g ) ≥ w (f t+1 )
⇒ {f 1 , ..., f t } ⊆ {f 1 , ..., f t , g } ∈ I
g should been choosen in step t + 1 of greedy algorithm
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Matroid ⇒ Greedy’
let w be an abitrary weight function
let F = {f 1 , ..., f r } the output of the greedy algorithm w.l.o.g. w (f 1 ) ≥ ... ≥ w (f r ) (if not change numbering) first prove that F has maximum cardinality
then prove by contradiction that w (F ) is maximum Proof Maximum Cardinality Of F By Contradiction Assume ∃ G ∈ I s.t. |F | < |G |
Augmentation property ⇒ ∃g ∈ G \ F s.t. F ∪ {g }
⇒ ∃t s.t. {f 1 , ..., f t , g , f t+1 , ..., f s } = F ∪ {g } ∈ I with w (f t ) ≥ w (g ) ≥ w (f t+1 )
⇒ {f 1 , ..., f t } ⊆ {f 1 , ..., f t , g } ∈ I
g should been choosen in step t + 1 of greedy algorithm
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 11 / 32
Proof ’Matroid ⇒ Greedy’
let w be an abitrary weight function
let F = {f 1 , ..., f r } the output of the greedy algorithm w.l.o.g. w (f 1 ) ≥ ... ≥ w (f r ) (if not change numbering) first prove that F has maximum cardinality
then prove by contradiction that w (F ) is maximum Proof Maximum Cardinality Of F By Contradiction Assume ∃ G ∈ I s.t. |F | < |G |
Augmentation property ⇒ ∃g ∈ G \ F s.t. F ∪ {g }
⇒ ∃t s.t. {f 1 , ..., f t , g , f t+1 , ..., f s } = F ∪ {g } ∈ I with w (f t ) ≥ w (g ) ≥ w (f t+1 )
⇒ {f 1 , ..., f t } ⊆ {f 1 , ..., f t , g } ∈ I
g should been choosen in step t + 1 of greedy algorithm
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Matroid ⇒ Greedy’
Proof w (F ) is maximum in (E , I ) by contradiction
Assume ∃G = {g 1 , ..., g r } ∈ I s.t. w (G ) > w (F ) and w(g i ) ≥ w (g i+1 )
⇒ P
g
i∈G
w (g i ) > P
f
i∈F
w (f i )
⇒ ∃ k : w (g k ) > w (f k ) (because |G | ≤ |F |)
take X := {f 1 , ..., f k−1 } (= ∅ if k = 1) and Y := {g 1 , ..., g k }
|X | < |Y | (augmentation property) ⇒ ∃ g t ∈ Y \ X with t ≤ k s.t.
{f 1 , ..., f k−1 , g t } = X ∪ {g t } ∈ I
Because w (g t ) ≥ w (g k ) > w (f k ) g t should been choosen before step k of the greedy algorithm
to correctness of greedy algorithm
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 12 / 32
Proof ’Matroid ⇒ Greedy’
Proof w (F ) is maximum in (E , I ) by contradiction
Assume ∃G = {g 1 , ..., g r } ∈ I s.t. w (G ) > w (F ) and w(g i ) ≥ w (g i+1 )
⇒ P
g
i∈G
w (g i ) > P
f
i∈F
w (f i )
⇒ ∃ k : w (g k ) > w (f k ) (because |G | ≤ |F |)
take X := {f 1 , ..., f k−1 } (= ∅ if k = 1) and Y := {g 1 , ..., g k }
|X | < |Y | (augmentation property) ⇒ ∃ g t ∈ Y \ X with t ≤ k s.t.
{f 1 , ..., f k−1 , g t } = X ∪ {g t } ∈ I
Because w (g t ) ≥ w (g k ) > w (f k ) g t should been choosen before step k of the greedy algorithm
to correctness of greedy algorithm
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Matroid ⇒ Greedy’
Proof w (F ) is maximum in (E , I ) by contradiction
Assume ∃G = {g 1 , ..., g r } ∈ I s.t. w (G ) > w (F ) and w(g i ) ≥ w (g i+1 )
⇒ P
g
i∈G
w (g i ) > P
f
i∈F
w (f i )
⇒ ∃ k : w (g k ) > w (f k ) (because |G | ≤ |F |)
take X := {f 1 , ..., f k−1 } (= ∅ if k = 1) and Y := {g 1 , ..., g k }
|X | < |Y | (augmentation property) ⇒ ∃ g t ∈ Y \ X with t ≤ k s.t.
{f 1 , ..., f k−1 , g t } = X ∪ {g t } ∈ I
Because w (g t ) ≥ w (g k ) > w (f k ) g t should been choosen before step k of the greedy algorithm
to correctness of greedy algorithm
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 12 / 32
Proof ’Matroid ⇒ Greedy’
Proof w (F ) is maximum in (E , I ) by contradiction
Assume ∃G = {g 1 , ..., g r } ∈ I s.t. w (G ) > w (F ) and w(g i ) ≥ w (g i+1 )
⇒ P
g
i∈G
w (g i ) > P
f
i∈F
w (f i )
⇒ ∃ k : w (g k ) > w (f k ) (because |G | ≤ |F |)
take X := {f 1 , ..., f k−1 } (= ∅ if k = 1) and Y := {g 1 , ..., g k }
|X | < |Y | (augmentation property) ⇒ ∃ g t ∈ Y \ X with t ≤ k s.t.
{f 1 , ..., f k−1 , g t } = X ∪ {g t } ∈ I
Because w (g t ) ≥ w (g k ) > w (f k ) g t should been choosen before step k of the greedy algorithm
to correctness of greedy algorithm
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Matroid ⇒ Greedy’
Proof w (F ) is maximum in (E , I ) by contradiction
Assume ∃G = {g 1 , ..., g r } ∈ I s.t. w (G ) > w (F ) and w(g i ) ≥ w (g i+1 )
⇒ P
g
i∈G
w (g i ) > P
f
i∈F
w (f i )
⇒ ∃ k : w (g k ) > w (f k ) (because |G | ≤ |F |)
take X := {f 1 , ..., f k−1 } (= ∅ if k = 1) and Y := {g 1 , ..., g k }
|X | < |Y | (augmentation property) ⇒ ∃ g t ∈ Y \ X with t ≤ k s.t.
{f 1 , ..., f k−1 , g t } = X ∪ {g t } ∈ I
Because w (g t ) ≥ w (g k ) > w (f k ) g t should been choosen before step k of the greedy algorithm
to correctness of greedy algorithm
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 12 / 32
Proof ’Matroid ⇒ Greedy’
Proof w (F ) is maximum in (E , I ) by contradiction
Assume ∃G = {g 1 , ..., g r } ∈ I s.t. w (G ) > w (F ) and w(g i ) ≥ w (g i+1 )
⇒ P
g
i∈G
w (g i ) > P
f
i∈F
w (f i )
⇒ ∃ k : w (g k ) > w (f k ) (because |G | ≤ |F |)
take X := {f 1 , ..., f k−1 } (= ∅ if k = 1) and Y := {g 1 , ..., g k }
|X | < |Y | (augmentation property) ⇒ ∃ g t ∈ Y \ X with t ≤ k s.t.
{f 1 , ..., f k−1 , g t } = X ∪ {g t } ∈ I
Because w (g t ) ≥ w (g k ) > w (f k ) g t should been choosen before step k of the greedy algorithm
to correctness of greedy algorithm
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Matroid ⇒ Greedy’
Proof w (F ) is maximum in (E , I ) by contradiction
Assume ∃G = {g 1 , ..., g r } ∈ I s.t. w (G ) > w (F ) and w(g i ) ≥ w (g i+1 )
⇒ P
g
i∈G
w (g i ) > P
f
i∈F
w (f i )
⇒ ∃ k : w (g k ) > w (f k ) (because |G | ≤ |F |)
take X := {f 1 , ..., f k−1 } (= ∅ if k = 1) and Y := {g 1 , ..., g k }
|X | < |Y | (augmentation property) ⇒ ∃ g t ∈ Y \ X with t ≤ k s.t.
{f 1 , ..., f k−1 , g t } = X ∪ {g t } ∈ I
Because w (g t ) ≥ w (g k ) > w (f k ) g t should been choosen before step k of the greedy algorithm
to correctness of greedy algorithm
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 12 / 32
Proof ’Matroid ⇒ Greedy’
Proof w (F ) is maximum in (E , I ) by contradiction
Assume ∃G = {g 1 , ..., g r } ∈ I s.t. w (G ) > w (F ) and w(g i ) ≥ w (g i+1 )
⇒ P
g
i∈G
w (g i ) > P
f
i∈F
w (f i )
⇒ ∃ k : w (g k ) > w (f k ) (because |G | ≤ |F |)
take X := {f 1 , ..., f k−1 } (= ∅ if k = 1) and Y := {g 1 , ..., g k }
|X | < |Y | (augmentation property) ⇒ ∃ g t ∈ Y \ X with t ≤ k s.t.
{f 1 , ..., f k−1 , g t } = X ∪ {g t } ∈ I
Because w (g t ) ≥ w (g k ) > w (f k ) g t should been choosen before step k of the greedy algorithm
to correctness of greedy algorithm
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Feasibility In Matroids
Proof ’Matroid ⇒ Greedy’
Proof w (F ) is maximum in (E , I ) by contradiction
Assume ∃G = {g 1 , ..., g r } ∈ I s.t. w (G ) > w (F ) and w(g i ) ≥ w (g i+1 )
⇒ P
g
i∈G
w (g i ) > P
f
i∈F
w (f i )
⇒ ∃ k : w (g k ) > w (f k ) (because |G | ≤ |F |)
take X := {f 1 , ..., f k−1 } (= ∅ if k = 1) and Y := {g 1 , ..., g k }
|X | < |Y | (augmentation property) ⇒ ∃ g t ∈ Y \ X with t ≤ k s.t.
{f 1 , ..., f k−1 , g t } = X ∪ {g t } ∈ I
Because w (g t ) ≥ w (g k ) > w (f k ) g t should been choosen before step k of the greedy algorithm
to correctness of greedy algorithm
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 12 / 32
Example Job Scheduling
Job Scheduling Problem Set of one worker jobs
Arranged in order of importance Pool of workers
Each is qualified to do a subset of jobs
Jobs have to be done simultaneously, so every worker can do at least one job
if not all jobs can be done, try optimal relative to the priority
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Job Scheduling
Example Job Scheduling
Job Scheduling Problem Set of one worker jobs
Arranged in order of importance Pool of workers
Each is qualified to do a subset of jobs
Jobs have to be done simultaneously, so every worker can do at least one job
if not all jobs can be done, try optimal relative to the priority
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 13 / 32
Example Job Scheduling
Job Scheduling Problem Set of one worker jobs
Arranged in order of importance Pool of workers
Each is qualified to do a subset of jobs
Jobs have to be done simultaneously, so every worker can do at least one job
if not all jobs can be done, try optimal relative to the priority
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Job Scheduling
Example Job Scheduling
Job Scheduling Problem Set of one worker jobs
Arranged in order of importance Pool of workers
Each is qualified to do a subset of jobs
Jobs have to be done simultaneously, so every worker can do at least one job
if not all jobs can be done, try optimal relative to the priority
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 13 / 32
Example Job Scheduling
Job Scheduling Problem Set of one worker jobs
Arranged in order of importance Pool of workers
Each is qualified to do a subset of jobs
Jobs have to be done simultaneously, so every worker can do at least one job
if not all jobs can be done, try optimal relative to the priority
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Job Scheduling
Example Job Scheduling
Job Scheduling Problem Set of one worker jobs
Arranged in order of importance Pool of workers
Each is qualified to do a subset of jobs
Jobs have to be done simultaneously, so every worker can do at least one job
if not all jobs can be done, try optimal relative to the priority
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 13 / 32
Example Job Scheduling
Job Scheduling Problem Set of one worker jobs
Arranged in order of importance Pool of workers
Each is qualified to do a subset of jobs
Jobs have to be done simultaneously, so every worker can do at least one job
if not all jobs can be done, try optimal relative to the priority
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Job Scheduling
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J-set of jobs in order of priority W-set of workers
W i is the set of jobs worker i can do W := {W i |i ∈ I , W i ⊆ J} (family of subsets)
Vertex set J ∪ W and the edge set
{jW i |j ∈ J, W i ∈ W} define the graph △[W]
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 14 / 32
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J j 1 ◦ j 2 ◦ j 3 ◦ j 4 ◦ j 5 ◦
J-set of jobs in order of priority W-set of workers
W i is the set of jobs worker i can do W := {W i |i ∈ I , W i ⊆ J} (family of subsets)
Vertex set J ∪ W and the edge set
{jW i |j ∈ J, W i ∈ W} define the graph △[W]
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Job Scheduling
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J W
j 1 ◦
j 2 ◦ ◦W 1
j 3 ◦ ◦W 2
j 4 ◦ ◦W 3
j 5 ◦ ◦W 4
j 6 ◦
J-set of jobs in order of priority W-set of workers
W i is the set of jobs worker i can do W := {W i |i ∈ I , W i ⊆ J} (family of subsets)
Vertex set J ∪ W and the edge set
{jW i |j ∈ J, W i ∈ W} define the graph △[W]
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 14 / 32
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J W
j 1 ◦
j 2 ◦ ◦W 1
j 3 ◦ ◦W 2
j 4 ◦ ◦W 3
j 5 ◦ ◦W 4
J-set of jobs in order of priority W-set of workers
W i is the set of jobs worker i can do W := {W i |i ∈ I , W i ⊆ J} (family of subsets)
Vertex set J ∪ W and the edge set
{jW i |j ∈ J, W i ∈ W} define the graph △[W]
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Job Scheduling
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J W
j 1 ◦
j 2 ◦ ◦W 1
j 3 ◦ ◦W 2
j 4 ◦ ◦W 3
j 5 ◦ ◦W 4
j 6 ◦
J-set of jobs in order of priority W-set of workers
W i is the set of jobs worker i can do W := {W i |i ∈ I , W i ⊆ J} (family of subsets)
Vertex set J ∪ W and the edge set
{jW i |j ∈ J, W i ∈ W} define the graph △[W]
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 14 / 32
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J W
j 1 ◦
j 2 ◦ ◦W 1
j 3 ◦ ◦W 2
j 4 ◦ ◦W 3
j 5 ◦ ◦W 4
J-set of jobs in order of priority W-set of workers
W i is the set of jobs worker i can do W := {W i |i ∈ I , W i ⊆ J} (family of subsets)
Vertex set J ∪ W and the edge set
{jW i |j ∈ J, W i ∈ W} define the graph △[W]
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Job Scheduling
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J W
j 1 ◦
j 2 ◦ ◦W 1
j 3 ◦ ◦W 2
j 4 ◦ ◦W 3
j 5 ◦ ◦W 4
j 6 ◦
J-set of jobs in order of priority W-set of workers
W i is the set of jobs worker i can do W := {W i |i ∈ I , W i ⊆ J} (family of subsets)
Vertex set J ∪ W and the edge set
{jW i |j ∈ J, W i ∈ W} define the graph △[W]
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 14 / 32
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J W
j 1 ◦
j 2 ◦ ◦W 1
j 3 ◦ ◦W 2
j 4 ◦ ◦W 3
j 5 ◦ ◦W 4
J-set of jobs in order of priority W-set of workers
W i is the set of jobs worker i can do W := {W i |i ∈ I , W i ⊆ J} (family of subsets)
Vertex set J ∪ W and the edge set
{jW i |j ∈ J, W i ∈ W} define the graph △[W]
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Job Scheduling
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J W
j 1 ◦
j 2 ◦ ◦W 1
j 3 ◦ ◦W 2
j 4 ◦ ◦W 3
j 5 ◦ ◦W 4
j 6 ◦
J-set of jobs in order of priority W-set of workers
W i is the set of jobs worker i can do W := {W i |i ∈ I , W i ⊆ J} (family of subsets)
Vertex set J ∪ W and the edge set
{jW i |j ∈ J, W i ∈ W} define the graph △[W]
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 14 / 32
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J W
j 1 ◦
j 2 ◦ ◦W 1
j 3 ◦ ◦W 2
j 4 ◦ ◦W 3
j 5 ◦ ◦W 4
J-set of jobs in order of priority W-set of workers
W i is the set of jobs worker i can do W := {W i |i ∈ I , W i ⊆ J} (family of subsets)
Vertex set J ∪ W and the edge set
{jW i |j ∈ J, W i ∈ W} define the graph △[W]
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Job Scheduling
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J W
j 1 ◦
j 2 ◦ ◦W 1
j 3 ◦ ◦W 2
j 4 ◦ ◦W 3
j 5 ◦ ◦W 4
j 6 ◦
W := {W i |i ∈ I , W i ⊆ J}
T ⊆ J partial transversal : ⇔ ∃ injective map ψ : T ։ I s.t. t ∈ W ψ(t) ∀t ∈ T i.e. matching for T in △[W ]
transversal iff |T | = |W|
The cardinality of the biggest (partial) transversal is the maximum number of jobs that can be done simultaneously in the example.
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 15 / 32
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J W
j 1 ◦
j 2 ◦ ◦W 1
j 3 ◦ ◦W 2
j 4 ◦ ◦W 3
j 5 ◦ ◦W 4
W := {W i |i ∈ I , W i ⊆ J}
T ⊆ J partial transversal : ⇔ ∃ injective map ψ : T ։ I s.t. t ∈ W ψ(t) ∀t ∈ T i.e. matching for T in △[W ]
transversal iff |T | = |W|
The cardinality of the biggest (partial)
transversal is the maximum number of jobs
that can be done simultaneously in the
example.
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Job Scheduling
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J W
j 1 ◦
j 2 ◦ ◦W 1
j 3 ◦ ◦W 2
j 4 ◦ ◦W 3
j 5 ◦ ◦W 4
j 6 ◦
W := {W i |i ∈ I , W i ⊆ J}
T ⊆ J partial transversal : ⇔ ∃ injective map ψ : T ։ I s.t. t ∈ W ψ(t) ∀t ∈ T i.e. matching for T in △[W ]
transversal iff |T | = |W|
The cardinality of the biggest (partial) transversal is the maximum number of jobs that can be done simultaneously in the example.
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 15 / 32
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J W
j 1 ◦
j 2 ◦ ◦W 1
j 3 ◦ ◦W 2
j 4 ◦ ◦W 3
j 5 ◦ ◦W 4
W := {W i |i ∈ I , W i ⊆ J}
T ⊆ J partial transversal : ⇔ ∃ injective map ψ : T ։ I s.t. t ∈ W ψ(t) ∀t ∈ T i.e. matching for T in △[W ]
transversal iff |T | = |W|
The cardinality of the biggest (partial)
transversal is the maximum number of jobs
that can be done simultaneously in the
example.
Greedy Algorithm Transversal Matroids Edmonds’ Intersection Algorithm References
Job Scheduling
Mathematical Describtion
Figure 1.19 from (Oxley, 2006, p. 47)
J W
j 1 ◦
j 2 ◦ ◦W 1
j 3 ◦ ◦W 2
j 4 ◦ ◦W 3
j 5 ◦ ◦W 4
j 6 ◦
W := {W i |i ∈ I , W i ⊆ J}
T ⊆ J partial transversal : ⇔ ∃ injective map ψ : T ։ I s.t. t ∈ W ψ(t) ∀t ∈ T i.e. matching for T in △[W ]
transversal iff |T | = |W|
The cardinality of the biggest (partial) transversal is the maximum number of jobs that can be done simultaneously in the example.
Paul Wilhelm (Math – HU Berlin) Greedy Algorithm July 17, 2010 15 / 32