/18 1
Ordering Metro Lines by Block Crossings
Martin Fink Lehrstuhl f¨ ur Informatik I Universit¨ at W¨ urzburg
Joint work with Sergey Pupyrev
Ordering Metro Lines by Block Crossings Martin Fink Lehrstuhl f - - PowerPoint PPT Presentation
Ordering Metro Lines by Block Crossings Martin Fink Lehrstuhl f ur Informatik I Universit at W urzburg Joint work with Sergey Pupyrev 1 /18 Metro Maps Vienna 2 /18 Metro Maps Paris 3 /18 Metro Maps Metro Lines 4
/18 1
Martin Fink Lehrstuhl f¨ ur Informatik I Universit¨ at W¨ urzburg
Joint work with Sergey Pupyrev
/18 2
/18 3
/18 4
/18 4
Previous work, e.g. [N¨
/18 4
Previous work, e.g. [N¨
Focus on drawing underlying graph
/18 5
Insert all lines L into embedded graph G = (V , E) such that ...
/18 5
Insert all lines L into embedded graph G = (V , E) such that ...
/18 5
Insert all lines L into embedded graph G = (V , E) such that ... the number of crossings is minimized.
/18 5
Insert all lines L into embedded graph G = (V , E) such that ... the number of crossings is minimized. crossings are placed on edges if possible.
/18 5
Insert all lines L into embedded graph G = (V , E) such that ... the number of crossings is minimized. crossings are placed on edges if possible.
/18 5
Insert all lines L into embedded graph G = (V , E) such that ... the number of crossings is minimized. crossings are placed on edges if possible.
/18 5
Insert all lines L into embedded graph G = (V , E) such that ... the number of crossings is minimized. crossings are placed on edges if possible.
/18 5
Insert all lines L into embedded graph G = (V , E) such that ... the number of crossings is minimized. crossings are placed on edges if possible. NP-hard [Bekos et al., 2007] & [Fink, Pupyrev, 2013]
/18 6
Line terminals are leaves of the graph.
/18 6
Line terminals are leaves of the graph. Follow two lines:
/18 6
Line terminals are leaves of the graph. Follow two lines:
/18 6
Line terminals are leaves of the graph. Follow two lines:
/18 6
Line terminals are leaves of the graph. Follow two lines:
Crossing Minimization: Solvable in linear time [Pupyrev et al., 2012]
/18 6
Line terminals are leaves of the graph. Follow two lines:
Crossing Minimization: Solvable in linear time [Pupyrev et al., 2012] additional restriction: two lines intersect in a path
/18 7
4 single crossings
/18 7
4 single crossings 1 block crossing
/18 7
4 single crossings 1 block crossing
/18 7
4 single crossings 1 block crossing 12 single crossings
/18 7
4 single crossings 1 block crossing 12 single crossings 3 block crossings
/18 8
New problem variants: BCM: Minimize the number of block crossings
/18 8
New problem variants: BCM: Minimize the number of block crossings MBCM: Minimize the number of monotone block crossings
/18 8
New problem variants: BCM: Minimize the number of block crossings MBCM: Minimize the number of monotone block crossings no double crossings!
/18 9
/18 9
/18 9
/18 9
/18 9
/18 9
/18 9
/18 9
1 2 3 4 5 1 2 3 4 5
/18 9
1 2 3 4 5 1 2 3 4 5
/18 9
1 2 3 4 5 1 2 3 4 5 Equivalent to Sorting by Transpositions for permutations
/18 9
1 2 3 4 5 1 2 3 4 5 Equivalent to Sorting by Transpositions for permutations NP-hard [Bulteau et al., 2012]
/18 9
1 2 3 4 5 1 2 3 4 5 Equivalent to Sorting by Transpositions for permutations NP-hard [Bulteau et al., 2012] simple 3-approximation [Bafna, Pevzner, 1998]
/18 10
1 2 3 4 5 1 2 3 4 5
/18 10
1 2 3 4 5 1 2 3 4 5
/18 10
1 2 3 4 5 1 2 3 4 5
/18 10
1 2 3 4 5 1 2 3 4 5
/18 10
1 2 3 4 5 1 2 3 4 5 |L| + 1 good pairs
/18 10
1 2 3 4 5 1 2 3 4 5 |L| + 1 good pairs no good pair for simple permutation
/18 10
1 2 3 4 5 1 2 3 4 5 |L| + 1 good pairs no good pair for simple permutation
/18 10
1 2 3 4 5 1 2 3 4 5 |L| + 1 good pairs no good pair for simple permutation
/18 10
1 2 3 4 5 1 2 3 4 5 |L| + 1 good pairs no good pair for simple permutation
/18 10
1 2 3 4 5 1 2 3 4 5 |L| + 1 good pairs no good pair for simple permutation
/18 10
1 2 3 4 5 1 2 3 4 5 |L| + 1 good pairs no good pair for simple permutation
/18 10
1 2 3 4 5 1 2 3 4 5 |L| + 1 good pairs no good pair for simple permutation ≤ |L| − 1 crossings
/18 10
1 2 3 4 5 1 2 3 4 5 |L| + 1 good pairs no good pair for simple permutation ≤ |L| − 1 crossings
/18 10
1 2 3 4 5 1 2 3 4 5 |L| + 1 good pairs no good pair for simple permutation ≤ |L| − 1 crossings
/18 10
1 2 3 4 5 1 2 3 4 5 |L| + 1 good pairs no good pair for simple permutation ≤ |L| − 1 crossings ≤ 3 good pairs can be created per crossing 3-approx.
/18 10
1 2 3 4 5 1 2 3 4 5 |L| + 1 good pairs no good pair for simple permutation ≤ |L| − 1 crossings ≤ 3 good pairs can be created per crossing 3-approx. solution uses monotone block crossings!
/18 11
/18 11
/18 11
/18 11
/18 11
lines end
/18 11
lines end
/18 11
lines end
Redefine good pairs:
/18 11
lines end
Redefine good pairs: – lines end together
/18 11
lines end
Redefine good pairs: – lines end together – inheritance b a1 a2
/18 11
lines end
Redefine good pairs: – lines end together – inheritance b a1 a2 ≤ 3 good pairs created per crossing
/18 12
e treat edges from left to right
/18 12
e treat edges from left to right
/18 12
e treat edges from left to right identify good pairs
/18 12
e treat edges from left to right
/18 12
e treat edges from left to right
/18 12
e treat edges from left to right
/18 12
e treat edges from left to right bring ending lines to top/bottom keeping good pairs together
/18 12
e treat edges from left to right bring ending lines to top/bottom keeping good pairs together create 1 good pair per block crossing crossing
/18 12
e treat edges from left to right bring ending lines to top/bottom keeping good pairs together create 1 good pair per block crossing crossing
3-approximation
/18 12
e treat edges from left to right bring ending lines to top/bottom keeping good pairs together create 1 good pair per block crossing crossing
3-approximation Special Case: Destroying good pairs e l
a c b a
/18 12
e treat edges from left to right bring ending lines to top/bottom keeping good pairs together create 1 good pair per block crossing crossing
3-approximation Special Case: Destroying good pairs e l
a c b a
– preferably destroy non-initial good pair – if none: destroy longest-living good pair
/18 12
e treat edges from left to right bring ending lines to top/bottom keeping good pairs together create 1 good pair per block crossing crossing
3-approximation algorithm can be adjusted for monotone block crossings
/18 12
e treat edges from left to right bring ending lines to top/bottom keeping good pairs together create 1 good pair per block crossing crossing
3-approximation algorithm can be adjusted for monotone block crossings adjust inheritance of good pairs: c b a1 a2
/18 12
e treat edges from left to right bring ending lines to top/bottom keeping good pairs together create 1 good pair per block crossing crossing
3-approximation algorithm can be adjusted for monotone block crossings adjust inheritance of good pairs: c b a1 a2
new strategy when destroying good pairs: ensure monotonicity
/18 13
root at some leave
/18 13
root at some leave after treating edge recursively order subtrees
/18 13
root at some leave after treating edge recursively order subtrees
/18 13
root at some leave after treating edge recursively order subtrees
/18 13
root at some leave after treating edge recursively order subtrees insert lines between subtrees
/18 13
root at some leave after treating edge recursively order subtrees insert lines between subtrees ≤ 2 crossings per line
/18 13
root at some leave after treating edge recursively order subtrees insert lines between subtrees ≤ 2 crossings per line right insertion order needed for: – avoiding vertex crossings – avoiding double crossings
/18 13
root at some leave after treating edge recursively order subtrees insert lines between subtrees ≤ 2 crossings per line right insertion order needed for: – avoiding vertex crossings – avoiding double crossings worst-case instances: 2|L| − 3 crossings necessary
/18 14
/18 14
simplification use tree algorithm 6-approximation for monotone block crossings
/18 15
Process edges in arbitrary order
/18 15
Process edges in arbitrary order Completely sort lines on an edge
/18 15
Process edges in arbitrary order Completely sort lines on an edge
/18 15
Process edges in arbitrary order Completely sort lines on an edge lines l, l′ seen together on edge will never cross (again) l l′
/18 15
Process edges in arbitrary order Completely sort lines on an edge lines l, l′ seen together on edge will never cross (again) l l′ lines l, l′ seen together for the first time information gain
/18 16
e
/18 16
e follow lines
/18 16
e follow lines
/18 16
e follow lines
/18 16
e follow lines find cut edges
/18 16
e follow lines find cut edges
/18 16
e follow lines find cut edges
/18 16
e follow lines find cut edges identify groups of lines
/18 16
e follow lines find cut edges identify groups of lines group stays parallel
/18 16
e follow lines find cut edges identify groups of lines group stays parallel consider pairs of groups
/18 16
e follow lines find cut edges identify groups of lines group stays parallel consider pairs of groups
/18 16
e follow lines find cut edges identify groups of lines group stays parallel consider pairs of groups
/18 16
e follow lines find cut edges identify groups of lines group stays parallel consider pairs of groups merge lines if possible
/18 16
e follow lines find cut edges identify groups of lines group stays parallel consider pairs of groups merge lines if possible sort by insertion into largest group
/18 16
e follow lines find cut edges identify groups of lines group stays parallel consider pairs of groups merge lines if possible sort by insertion into largest group undo merging
/18 17
e finally: all edges
/18 17
e finally: all edges
pairs of lines cross at most once monotone block crossings
/18 17
e finally: all edges
pairs of lines cross at most once monotone block crossings (bc(e))2 ≤ I(e) information gain block crossings on edge
/18 17
e finally: all edges
pairs of lines cross at most once monotone block crossings (bc(e))2 ≤ I(e) information gain block crossings on edge
/18 17
e finally: all edges
pairs of lines cross at most once monotone block crossings (bc(e))2 ≤ I(e) information gain block crossings on edge
Using Cauchy-Schwarz:
/18 17
e finally: all edges
pairs of lines cross at most once monotone block crossings (bc(e))2 ≤ I(e) information gain block crossings on edge
Using Cauchy-Schwarz:
worst-case instances: Ω(|L|
crossings necessary
/18 18
new model for counting crossings approximations for paths and upward trees tight upper bound for trees algorithm for general graphs upper bound asymptotically tight
/18 18
new model for counting crossings approximations for paths and upward trees tight upper bound for trees algorithm for general graphs upper bound asymptotically tight Open Questions: Complexity of monotone block crossings on a single edge? Approximations for trees / general graphs?
/18 18
new model for counting crossings approximations for paths and upward trees tight upper bound for trees algorithm for general graphs upper bound asymptotically tight Open Questions: Complexity of monotone block crossings on a single edge? Approximations for trees / general graphs?