SlideShare ist ein Scribd-Unternehmen logo
1 von 52
Downloaden Sie, um offline zu lesen
Faster algorithms for min-delay time
               semi-matching


              Bundit Laekhanukit
           C&O, University of Waterloo

                   joint work with
        J. Fakcharoenphol and D. Nanongkai



                         
Agenda
    ●   Definition of min-delay semimatching problem
    ●   Previous works & Our results
    ●   Unit cost
        –   Reduction to min-cost flow
        –   An algorithm for unit cost
    ●   General cost
        –   Reduction to weighted bipartite matching
        –   Sketch of an algorithm for general cost
                                      
Semimatching on bipartite graphs




                    
Matching M                           Semimatching M'
    U                  V                 U                 V




                           incident to                         No restriction
                           = 1 M'-edge



         incident to
         ≤ 1 M-edge


                                   
Unit cost
     U        V                Wait for being processed
     u1
                               1 unit of time

               x          u1   u2      u3
     u2

               y

     u3
     3
                                Wait for u1 and itself
               z
                                to be processed
     u4                         1 + 1 units of time

    Jobs   Machines




                       
Unit cost
     U        V
     u1

               x            u1      u2      u3
     u2
                          Delay time at machine a
               y          = 1 + 2 + 3 units of time
     u3
     3

               z
     u4


    Jobs   Machines




                       
Unit cost
     U                   V
     u1

                         x
     u2
                                            Total delay time
                         y                  (cost of semimatching)
     u3
     3                                      = 6 + 1 units of time

                         z
     u4


    Jobs             Machines


           Delay time is flow time in scheduling terminology
                                   
General cost
     U                V
     u1        2                      2      1      3

               1       x              u1     u2     u3
     u2
                                  Reorder to minimize delay
           3           y              1      2      3
     u3
     3                                u2     u1     u3

                       z           Delay time at machine x
               2
     u4                            = 1 + (1+2) + (1+2+3)
                                   units of time
    Jobs           Machines




                               
Previous works & Our results




                  
Previous Works & Our results
    ●   Unit cost
          Harvey, Ladner, Lovász, and Tamir (2003) :
          O(nm)-algorithm using modified Hungarian method
           Our algorithm : O(n1/2m log n)
    ●   General cost
          Bruno, Coffman, and Sethi (1974) :
          O(n3)-algorithm using a reduction to bipartite matching
          Our algorithm : O(nm log n)

 
              n : number of vertices, m : number of edges
                                     
Unit cost




         
Harvey et. al. reduction from unit cost
       semimatching to min-cost flow



                        
A reduction to min-cost flow
        U            V
        u1

                     x
        u2

                     y

        u3
        3

                     z
        u4




                  
A reduction to min-cost flow
            U                      V
            u1                            Cost centers
                                   x           C1
                                                       Cost=1
            u2
                                                    Cost=2
    s                              y           C2               t

            u3
            3                                       Cost=3
                                   z           C3

            u4

                                                         Infinite capacity

                 Capacity = 1, Cost = 0


                                
A reduction to min-cost flow
             U                      V
             u1                            Cost centers
                                    x           C1
                                                        Cost=1
             u2
                                                     Cost=2
    s                               y           C2               t

             u3
             3                                       Cost=3
                                    z           C3

             u4

                                                          Infinite capacity

                  Capacity = 1, Cost = 0

         min-cost flow = min-delay semimatching
                                 
An algorithm for unit cost




                 
Running time
    Directly apply min-cost flow : O(nm log2 n)
    Previous best (Harvey et. al. 2003) : O(nm)
          Our algorithm : O(n1/2m log n)



                         
Use the reduction to min-cost flow and
         divide & conquer technique



                       
High Level Details
Start from any
semimatching
and construct flow
                                      Low
                                      Cost



         s            U          V           t



                                      High
                                      Cost




                              
High Level Details
                                                  Push flow to lower
                                                  cost centers

                                           Low
                                           Cost



    s    U                  V                           t



                                           High
                                           Cost




          Source and Sink can be ignored
                       
High Level Details
Divide into two
subproblems
                         G1
and recursively
solve them
                                      Low
                   U              V
                                      Cost



No residual
path from                G2
G2 to G1
                                      High
                   U              V
                                      Cost




                               
Start from an arbitrary semimatching
            U            V
            u1

                         x
            u2



            u3
            3            y



            u4
                         z

            u5




                      
Construct a corresponding flow
         U            V
         u1               Cost centers

                      x        C1
         u2                              Cost=1
                               C2   Cost=2
    s    u3
         3            y                           t
                                    Cost=3
                               C3
         u4                               Cost=4
                      z
                               C4

         u5




                   
A flow is not a cheapest
          U            V
          u1               Cost centers

                       x        C1
          u2                              Cost=1
                                C2   Cost=2
    s     u3
          3            y                           t
                                     Cost=3
                                C3
          u4                               Cost=4
                       z
                                C4

          u5




                    
Find a max-flow to lower cost centers
             U                     V    Cost centers
             u1

                                   x            C1
                                                       T'
             u2

                                                C2
             u3
             3                     y

                                                C3
             u4
                                   z                   S'
                                                C4

             u5

                  Source and Sink are ignored
                                
An improved flow
    U          V   Cost centers
    u1

               x        C1
    u2

                        C2
    u3
    3          y

                        C3
    u4
               z
                        C4

    u5




            
Divide & recursively solve subproblems
                      G1            Not reachable
                 u1                 from C3 , C4 by
                           x   C1   residual paths
Reachable from
                 u2
C3 , C4 by
residual paths                 C2
                 u3
                 3         y

                               C3
                 u4                   Separated
                           z
                               C4     by min-cut
                 u5

                       G2

                        
Divide & recursively solve subproblems
                   G1
              u1
                                  Push flow in G1
                        x   C1
Solve
              u2
subproblems
                            C2
              u3
              3         y

                            C3
              u4
                        z
                            C4

              u5
                                 No flow path in G2
                    G2

                     
A min-cost flow
        u1

                        x   C1
        u2

                            C2
    s   u3
        3               y        t

                            C3
        u4
                        z
                            C4

        u5




                     
A min-delay semimatching
       u1

                   x
       u2



       u3
       3           y



       u4
                   z

       u5




                
Running time




          
Running time analysis
    ●   Push flow to lower cost centers O(n1/2m)
        (Dinitz's blocking flow algorithm with analysis
        similar to Kazanov 1973, Even & Tarjan 1974)
    ●   Total running time
        T(n, m, c) = T(n1, m1, c/2) + T(n2, m2, c/2) + O(n1/2m)
                   = . . . = O(n1/2m log n)
        n = number of vertices, m = number of edges
        c = number of cost centers ≤ n
                                   
General cost




          
Bruno et. al. reduction to
    weighted bipartite matching



                  
A reduction to bipartite matching
      U                V
      u1        2                    1       2      3

                1       x            u2      u1     u3
      u2
                                   Delay time at machine a
            3           y          = 1 + (1+2) + (1+2+3)
      u3
      3                            =3·1+2·2+1·3
                                   units of time
                        z
                2
      u4


     Jobs           Machines




                                
A reduction to bipartite matching
     U                V       2·1
     u1                       1·1   x1
              2
                              3·1
              1       x
     u2       3
                  3           2·2
                      y
                              1·2   x2
                  5
     u3
     3                        3·2

          2           z
                              2·3
     u4
                              1·3   x3
                              3·3




                           
A reduction to bipartite matching
                                     x1
                        2
                        1
                        3
              u1          4
                         2           x2
                        6
                          6
              u2        3            x3
                         9

                                3
              u3
              3                      y1

                                5
                            2        z1
              u4
                                10
                            4
                                     z2




                     
A reduction to bipartite matching
                                            x1
                               2
                               1
                               3
                   u1            4          x2
                                                 Equivalent
                                2                to assign
                               6
                                 6               u1, u2 to x
                   u2          3            x3
                                9

                                       3
                   u3
                   3                        y1

                                       5
                                   2        z1
                   u4
                                       10
                                   4
                                            z2


     min-weight matching = min-delay semimatching
                            
An algorithm for general cost




                   
Running time
    Directly apply matching algorithm : O(nm2)
     Previous best (Bruno et. al. 1974) : O(n3)
           Our algorithm : O(nm log n)



                         
Use the reduction to bipartite matching
     exploit structure of potential function



                         
High level details
    Reduce to
    bipartite matching                x




                            U         y       Copies of
                                              vertices of V




                                      z




                                  
High level details
Augment matching by
                                    x
shortest augmenting paths
(Edmond & Karp 1970,
Tomizawa 1971)


                                    y
                            U




                                    z




                                 
High level details
Cost of matching edges
                                       x
are negative



                                - 10          Assign potential
                                       y      function to
                            U
                                              make non-negative
                                              reduced cost

                                 7

                                       z




                                  
High level details
Cost of matching edges
                                       x
are negative



                                - 10          Use distance
                                              labels from
                                       y
                            U                 previous round
                                              as potential
                                              function
                                 7

                                       z




                                  
Distances has a break point

                                                   x1

    Dual variables for                                          Distances are
    x1 ,x2, ..., xk have                                        weakly decreasing
    a break point             u1                    xi


                                                                Distances are
                                                                weakly increasing
                                                    xk




                  xj is a copy of x with edge costs multiplied by j

                                           
Data structure for fast query
    Use a data structure
    exploiting the property           x
    to find a shortest
    augmenting path

                                          Create data
                                          structures at
                                      y
                              U           each set for
                                          fast distance
                                          query


                                      z




                                   
Running time analysis
    ●   Using a special data structure, a shortest augmenting
        path can be found in O(n + m log n)
    ●   Augmenting the matching n times
    ●   Total running time O(nm log n)




                                  
Summary
    ●   Unit cost
        –   Previous best running time O(nm)
        –   Our running time O(n1/2m log n)
    ●   General cost
        –   Previous best running time O(n3)
        –   Our running time O(nm log n)




                                     
Open Problems
        Is it possible to meet the running time of bipartite
        matching?
    ●   Unit cost
        –   The best running time O(n1/2m) (Hopcroft & Karp 1973)
        –   Our algorithm O(n1/2m log n)
    ●   General cost
        –   The running time
             ●   O(nm) (Edmond & Karp 1970, Tomizawa 1971)
             ●   O(n1/2m log nWmax) (Gabow & Tajan 1989)

 
        –   Our algorithm O(nm log n)
                                     
Thank you for your attention




                  
Questions ?




          

Weitere ähnliche Inhalte

Was ist angesagt?

Cluster-cluster aggregation with (complete) collisional fragmentation
Cluster-cluster aggregation with (complete) collisional fragmentationCluster-cluster aggregation with (complete) collisional fragmentation
Cluster-cluster aggregation with (complete) collisional fragmentationColm Connaughton
 
Second Order Perturbations - National Astronomy Meeting 2011
Second Order Perturbations - National Astronomy Meeting 2011Second Order Perturbations - National Astronomy Meeting 2011
Second Order Perturbations - National Astronomy Meeting 2011Ian Huston
 
Nonequilibrium Statistical Mechanics of Cluster-cluster Aggregation Warwick ...
Nonequilibrium Statistical Mechanics of Cluster-cluster Aggregation Warwick  ...Nonequilibrium Statistical Mechanics of Cluster-cluster Aggregation Warwick  ...
Nonequilibrium Statistical Mechanics of Cluster-cluster Aggregation Warwick ...Colm Connaughton
 
Amortized Analysis of Algorithms
Amortized Analysis of Algorithms Amortized Analysis of Algorithms
Amortized Analysis of Algorithms sathish sak
 
Amortized analysis
Amortized analysisAmortized analysis
Amortized analysisajmalcs
 
Amortized complexity
Amortized complexityAmortized complexity
Amortized complexityparamita30
 
The inverse droplet coagulation problem
The inverse droplet coagulation problemThe inverse droplet coagulation problem
The inverse droplet coagulation problemColm Connaughton
 
Aoa amortized analysis
Aoa amortized analysisAoa amortized analysis
Aoa amortized analysisSalabat Khan
 
Weak Isotropic three-wave turbulence, Fondation des Treilles, July 16 2010
Weak Isotropic three-wave turbulence, Fondation des Treilles, July 16 2010Weak Isotropic three-wave turbulence, Fondation des Treilles, July 16 2010
Weak Isotropic three-wave turbulence, Fondation des Treilles, July 16 2010Colm Connaughton
 
Tele4653 l8
Tele4653 l8Tele4653 l8
Tele4653 l8Vin Voro
 
Amortized complexity
Amortized complexityAmortized complexity
Amortized complexityparamita30
 
Modèle de coordination du groupe de robots mobiles
Modèle de coordination du groupe de robots mobilesModèle de coordination du groupe de robots mobiles
Modèle de coordination du groupe de robots mobilesAkrem Hadji
 
Amortized Analysis
Amortized Analysis Amortized Analysis
Amortized Analysis sathish sak
 
Random Number Generators 2018
Random Number Generators 2018Random Number Generators 2018
Random Number Generators 2018rinnocente
 
Fluctuations and rare events in stochastic aggregation
Fluctuations and rare events in stochastic aggregationFluctuations and rare events in stochastic aggregation
Fluctuations and rare events in stochastic aggregationColm Connaughton
 
Derivatives pricing and Malliavin Calculus
Derivatives pricing and Malliavin CalculusDerivatives pricing and Malliavin Calculus
Derivatives pricing and Malliavin CalculusHugo Delatte
 

Was ist angesagt? (20)

Cluster-cluster aggregation with (complete) collisional fragmentation
Cluster-cluster aggregation with (complete) collisional fragmentationCluster-cluster aggregation with (complete) collisional fragmentation
Cluster-cluster aggregation with (complete) collisional fragmentation
 
13 Amortized Analysis
13 Amortized Analysis13 Amortized Analysis
13 Amortized Analysis
 
QMC: Operator Splitting Workshop, Perturbed (accelerated) Proximal-Gradient A...
QMC: Operator Splitting Workshop, Perturbed (accelerated) Proximal-Gradient A...QMC: Operator Splitting Workshop, Perturbed (accelerated) Proximal-Gradient A...
QMC: Operator Splitting Workshop, Perturbed (accelerated) Proximal-Gradient A...
 
Second Order Perturbations - National Astronomy Meeting 2011
Second Order Perturbations - National Astronomy Meeting 2011Second Order Perturbations - National Astronomy Meeting 2011
Second Order Perturbations - National Astronomy Meeting 2011
 
Nonequilibrium Statistical Mechanics of Cluster-cluster Aggregation Warwick ...
Nonequilibrium Statistical Mechanics of Cluster-cluster Aggregation Warwick  ...Nonequilibrium Statistical Mechanics of Cluster-cluster Aggregation Warwick  ...
Nonequilibrium Statistical Mechanics of Cluster-cluster Aggregation Warwick ...
 
Amortized Analysis of Algorithms
Amortized Analysis of Algorithms Amortized Analysis of Algorithms
Amortized Analysis of Algorithms
 
Amortized analysis
Amortized analysisAmortized analysis
Amortized analysis
 
09. amortized analysis
09. amortized analysis09. amortized analysis
09. amortized analysis
 
Amortized
AmortizedAmortized
Amortized
 
Amortized complexity
Amortized complexityAmortized complexity
Amortized complexity
 
The inverse droplet coagulation problem
The inverse droplet coagulation problemThe inverse droplet coagulation problem
The inverse droplet coagulation problem
 
Aoa amortized analysis
Aoa amortized analysisAoa amortized analysis
Aoa amortized analysis
 
Weak Isotropic three-wave turbulence, Fondation des Treilles, July 16 2010
Weak Isotropic three-wave turbulence, Fondation des Treilles, July 16 2010Weak Isotropic three-wave turbulence, Fondation des Treilles, July 16 2010
Weak Isotropic three-wave turbulence, Fondation des Treilles, July 16 2010
 
Tele4653 l8
Tele4653 l8Tele4653 l8
Tele4653 l8
 
Amortized complexity
Amortized complexityAmortized complexity
Amortized complexity
 
Modèle de coordination du groupe de robots mobiles
Modèle de coordination du groupe de robots mobilesModèle de coordination du groupe de robots mobiles
Modèle de coordination du groupe de robots mobiles
 
Amortized Analysis
Amortized Analysis Amortized Analysis
Amortized Analysis
 
Random Number Generators 2018
Random Number Generators 2018Random Number Generators 2018
Random Number Generators 2018
 
Fluctuations and rare events in stochastic aggregation
Fluctuations and rare events in stochastic aggregationFluctuations and rare events in stochastic aggregation
Fluctuations and rare events in stochastic aggregation
 
Derivatives pricing and Malliavin Calculus
Derivatives pricing and Malliavin CalculusDerivatives pricing and Malliavin Calculus
Derivatives pricing and Malliavin Calculus
 

Andere mochten auch

Typical christmas dinner in Spain
Typical christmas dinner in SpainTypical christmas dinner in Spain
Typical christmas dinner in Spainsergioaltea
 
iWiFi Bondi Presentation [#momosyd]
iWiFi Bondi Presentation [#momosyd]iWiFi Bondi Presentation [#momosyd]
iWiFi Bondi Presentation [#momosyd]Ranjeet Elkunchwar
 
Creative Commons
Creative CommonsCreative Commons
Creative Commonslbundit
 
구글과 페이스북의 인재전쟁
구글과 페이스북의 인재전쟁구글과 페이스북의 인재전쟁
구글과 페이스북의 인재전쟁Sungmin Kim
 
An O(log^2 k)-approximation algorithm for k-vertex connected spanning subgraph
An O(log^2 k)-approximation algorithm for k-vertex connected spanning subgraphAn O(log^2 k)-approximation algorithm for k-vertex connected spanning subgraph
An O(log^2 k)-approximation algorithm for k-vertex connected spanning subgraphlbundit
 

Andere mochten auch (6)

Typical christmas dinner in Spain
Typical christmas dinner in SpainTypical christmas dinner in Spain
Typical christmas dinner in Spain
 
iWiFi Bondi Presentation [#momosyd]
iWiFi Bondi Presentation [#momosyd]iWiFi Bondi Presentation [#momosyd]
iWiFi Bondi Presentation [#momosyd]
 
adbyme
adbymeadbyme
adbyme
 
Creative Commons
Creative CommonsCreative Commons
Creative Commons
 
구글과 페이스북의 인재전쟁
구글과 페이스북의 인재전쟁구글과 페이스북의 인재전쟁
구글과 페이스북의 인재전쟁
 
An O(log^2 k)-approximation algorithm for k-vertex connected spanning subgraph
An O(log^2 k)-approximation algorithm for k-vertex connected spanning subgraphAn O(log^2 k)-approximation algorithm for k-vertex connected spanning subgraph
An O(log^2 k)-approximation algorithm for k-vertex connected spanning subgraph
 

Kürzlich hochgeladen

1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdfQucHHunhnh
 
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991RKavithamani
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesFatimaKhan178732
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxNirmalaLoungPoorunde1
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...EduSkills OECD
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptxVS Mahajan Coaching Centre
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introductionMaksud Ahmed
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxmanuelaromero2013
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13Steve Thomason
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104misteraugie
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfciinovamais
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfsanyamsingh5019
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdfSoniaTolstoy
 
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...RKavithamani
 
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpinStudent login on Anyboli platform.helpin
Student login on Anyboli platform.helpinRaunakKeshri1
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionSafetyChain Software
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeThiyagu K
 

Kürzlich hochgeladen (20)

1029 - Danh muc Sach Giao Khoa 10 . pdf
1029 -  Danh muc Sach Giao Khoa 10 . pdf1029 -  Danh muc Sach Giao Khoa 10 . pdf
1029 - Danh muc Sach Giao Khoa 10 . pdf
 
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
Industrial Policy - 1948, 1956, 1973, 1977, 1980, 1991
 
Separation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and ActinidesSeparation of Lanthanides/ Lanthanides and Actinides
Separation of Lanthanides/ Lanthanides and Actinides
 
Employee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptxEmployee wellbeing at the workplace.pptx
Employee wellbeing at the workplace.pptx
 
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
Presentation by Andreas Schleicher Tackling the School Absenteeism Crisis 30 ...
 
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions  for the students and aspirants of Chemistry12th.pptxOrganic Name Reactions  for the students and aspirants of Chemistry12th.pptx
Organic Name Reactions for the students and aspirants of Chemistry12th.pptx
 
microwave assisted reaction. General introduction
microwave assisted reaction. General introductionmicrowave assisted reaction. General introduction
microwave assisted reaction. General introduction
 
How to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptxHow to Make a Pirate ship Primary Education.pptx
How to Make a Pirate ship Primary Education.pptx
 
The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13The Most Excellent Way | 1 Corinthians 13
The Most Excellent Way | 1 Corinthians 13
 
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdfTataKelola dan KamSiber Kecerdasan Buatan v022.pdf
TataKelola dan KamSiber Kecerdasan Buatan v022.pdf
 
Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104Nutritional Needs Presentation - HLTH 104
Nutritional Needs Presentation - HLTH 104
 
Activity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdfActivity 01 - Artificial Culture (1).pdf
Activity 01 - Artificial Culture (1).pdf
 
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptxINDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
INDIA QUIZ 2024 RLAC DELHI UNIVERSITY.pptx
 
Sanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdfSanyam Choudhary Chemistry practical.pdf
Sanyam Choudhary Chemistry practical.pdf
 
Staff of Color (SOC) Retention Efforts DDSD
Staff of Color (SOC) Retention Efforts DDSDStaff of Color (SOC) Retention Efforts DDSD
Staff of Color (SOC) Retention Efforts DDSD
 
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdfBASLIQ CURRENT LOOKBOOK  LOOKBOOK(1) (1).pdf
BASLIQ CURRENT LOOKBOOK LOOKBOOK(1) (1).pdf
 
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
Privatization and Disinvestment - Meaning, Objectives, Advantages and Disadva...
 
Student login on Anyboli platform.helpin
Student login on Anyboli platform.helpinStudent login on Anyboli platform.helpin
Student login on Anyboli platform.helpin
 
Mastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory InspectionMastering the Unannounced Regulatory Inspection
Mastering the Unannounced Regulatory Inspection
 
Measures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and ModeMeasures of Central Tendency: Mean, Median and Mode
Measures of Central Tendency: Mean, Median and Mode
 

Faster algorithms for min-delay semi-matching

  • 1. Faster algorithms for min-delay time semi-matching Bundit Laekhanukit C&O, University of Waterloo joint work with J. Fakcharoenphol and D. Nanongkai    
  • 2. Agenda ● Definition of min-delay semimatching problem ● Previous works & Our results ● Unit cost – Reduction to min-cost flow – An algorithm for unit cost ● General cost – Reduction to weighted bipartite matching – Sketch of an algorithm for general cost    
  • 4. Matching M Semimatching M' U V U V incident to No restriction = 1 M'-edge incident to ≤ 1 M-edge    
  • 5. Unit cost U V Wait for being processed u1 1 unit of time x u1 u2 u3 u2 y u3 3 Wait for u1 and itself z to be processed u4 1 + 1 units of time Jobs Machines    
  • 6. Unit cost U V u1 x u1 u2 u3 u2 Delay time at machine a y = 1 + 2 + 3 units of time u3 3 z u4 Jobs Machines    
  • 7. Unit cost U V u1 x u2 Total delay time y (cost of semimatching) u3 3 = 6 + 1 units of time z u4 Jobs Machines Delay time is flow time in scheduling terminology    
  • 8. General cost U V u1 2 2 1 3 1 x u1 u2 u3 u2 Reorder to minimize delay 3 y 1 2 3 u3 3 u2 u1 u3 z Delay time at machine x 2 u4 = 1 + (1+2) + (1+2+3) units of time Jobs Machines    
  • 9. Previous works & Our results    
  • 10. Previous Works & Our results ● Unit cost Harvey, Ladner, Lovász, and Tamir (2003) : O(nm)-algorithm using modified Hungarian method Our algorithm : O(n1/2m log n) ● General cost Bruno, Coffman, and Sethi (1974) : O(n3)-algorithm using a reduction to bipartite matching Our algorithm : O(nm log n)   n : number of vertices, m : number of edges  
  • 12. Harvey et. al. reduction from unit cost semimatching to min-cost flow    
  • 13. A reduction to min-cost flow U V u1 x u2 y u3 3 z u4    
  • 14. A reduction to min-cost flow U V u1 Cost centers x C1 Cost=1 u2 Cost=2 s y C2 t u3 3 Cost=3 z C3 u4 Infinite capacity Capacity = 1, Cost = 0    
  • 15. A reduction to min-cost flow U V u1 Cost centers x C1 Cost=1 u2 Cost=2 s y C2 t u3 3 Cost=3 z C3 u4 Infinite capacity Capacity = 1, Cost = 0 min-cost flow = min-delay semimatching    
  • 16. An algorithm for unit cost    
  • 17. Running time Directly apply min-cost flow : O(nm log2 n) Previous best (Harvey et. al. 2003) : O(nm) Our algorithm : O(n1/2m log n)    
  • 18. Use the reduction to min-cost flow and divide & conquer technique    
  • 19. High Level Details Start from any semimatching and construct flow Low Cost s U V t High Cost    
  • 20. High Level Details Push flow to lower cost centers Low Cost s U V t High Cost Source and Sink can be ignored    
  • 21. High Level Details Divide into two subproblems G1 and recursively solve them Low U V Cost No residual path from G2 G2 to G1 High U V Cost    
  • 22. Start from an arbitrary semimatching U V u1 x u2 u3 3 y u4 z u5    
  • 23. Construct a corresponding flow U V u1 Cost centers x C1 u2 Cost=1 C2 Cost=2 s u3 3 y t Cost=3 C3 u4 Cost=4 z C4 u5    
  • 24. A flow is not a cheapest U V u1 Cost centers x C1 u2 Cost=1 C2 Cost=2 s u3 3 y t Cost=3 C3 u4 Cost=4 z C4 u5    
  • 25. Find a max-flow to lower cost centers U V Cost centers u1 x C1 T' u2 C2 u3 3 y C3 u4 z S' C4 u5 Source and Sink are ignored    
  • 26. An improved flow U V Cost centers u1 x C1 u2 C2 u3 3 y C3 u4 z C4 u5    
  • 27. Divide & recursively solve subproblems G1 Not reachable u1 from C3 , C4 by x C1 residual paths Reachable from u2 C3 , C4 by residual paths C2 u3 3 y C3 u4 Separated z C4 by min-cut u5 G2    
  • 28. Divide & recursively solve subproblems G1 u1 Push flow in G1 x C1 Solve u2 subproblems C2 u3 3 y C3 u4 z C4 u5 No flow path in G2 G2    
  • 29. A min-cost flow u1 x C1 u2 C2 s u3 3 y t C3 u4 z C4 u5    
  • 30. A min-delay semimatching u1 x u2 u3 3 y u4 z u5    
  • 32. Running time analysis ● Push flow to lower cost centers O(n1/2m) (Dinitz's blocking flow algorithm with analysis similar to Kazanov 1973, Even & Tarjan 1974) ● Total running time T(n, m, c) = T(n1, m1, c/2) + T(n2, m2, c/2) + O(n1/2m) = . . . = O(n1/2m log n) n = number of vertices, m = number of edges c = number of cost centers ≤ n    
  • 34. Bruno et. al. reduction to weighted bipartite matching    
  • 35. A reduction to bipartite matching U V u1 2 1 2 3 1 x u2 u1 u3 u2 Delay time at machine a 3 y = 1 + (1+2) + (1+2+3) u3 3 =3·1+2·2+1·3 units of time z 2 u4 Jobs Machines    
  • 36. A reduction to bipartite matching U V 2·1 u1 1·1 x1 2 3·1 1 x u2 3 3 2·2 y 1·2 x2 5 u3 3 3·2 2 z 2·3 u4 1·3 x3 3·3    
  • 37. A reduction to bipartite matching x1 2 1 3 u1 4 2 x2 6 6 u2 3 x3 9 3 u3 3 y1 5 2 z1 u4 10 4 z2    
  • 38. A reduction to bipartite matching x1 2 1 3 u1 4 x2 Equivalent 2 to assign 6 6 u1, u2 to x u2 3 x3 9 3 u3 3 y1 5 2 z1 u4 10 4 z2 min-weight matching = min-delay semimatching    
  • 39. An algorithm for general cost    
  • 40. Running time Directly apply matching algorithm : O(nm2) Previous best (Bruno et. al. 1974) : O(n3) Our algorithm : O(nm log n)    
  • 41. Use the reduction to bipartite matching exploit structure of potential function    
  • 42. High level details Reduce to bipartite matching x U y Copies of vertices of V z    
  • 43. High level details Augment matching by x shortest augmenting paths (Edmond & Karp 1970, Tomizawa 1971) y U z    
  • 44. High level details Cost of matching edges x are negative - 10 Assign potential y function to U make non-negative reduced cost 7 z    
  • 45. High level details Cost of matching edges x are negative - 10 Use distance labels from y U previous round as potential function 7 z    
  • 46. Distances has a break point x1 Dual variables for Distances are x1 ,x2, ..., xk have weakly decreasing a break point u1 xi Distances are weakly increasing xk xj is a copy of x with edge costs multiplied by j    
  • 47. Data structure for fast query Use a data structure exploiting the property x to find a shortest augmenting path Create data structures at y U each set for fast distance query z    
  • 48. Running time analysis ● Using a special data structure, a shortest augmenting path can be found in O(n + m log n) ● Augmenting the matching n times ● Total running time O(nm log n)    
  • 49. Summary ● Unit cost – Previous best running time O(nm) – Our running time O(n1/2m log n) ● General cost – Previous best running time O(n3) – Our running time O(nm log n)    
  • 50. Open Problems Is it possible to meet the running time of bipartite matching? ● Unit cost – The best running time O(n1/2m) (Hopcroft & Karp 1973) – Our algorithm O(n1/2m log n) ● General cost – The running time ● O(nm) (Edmond & Karp 1970, Tomizawa 1971) ● O(n1/2m log nWmax) (Gabow & Tajan 1989)   – Our algorithm O(nm log n)  
  • 51. Thank you for your attention