Class BlossomVOptions

java.lang.Object
org.jgrapht.alg.matching.blossom.v5.BlossomVOptions

public class BlossomVOptions extends Object
BlossomVOptions that define the strategies to use during the algorithm for updating duals and initializing the matching

According to the experimental results, the greedy initialization substantially speeds up the algorithm.

  • Field Details

    • ALL_OPTIONS

      public static final BlossomVOptions[] ALL_OPTIONS
      All possible options
  • Constructor Details

    • BlossomVOptions

      public BlossomVOptions(BlossomVOptions.InitializationType initializationType, BlossomVOptions.DualUpdateStrategy dualUpdateStrategy, boolean updateDualsBefore, boolean updateDualsAfter)
      Constructs a custom set of options for the algorithm
      Parameters:
      dualUpdateStrategy - greedy strategy to update dual variables globally
      initializationType - strategy for initializing the matching
      updateDualsBefore - whether to update duals of the tree before growth
      updateDualsAfter - whether to update duals of the tree after growth
    • BlossomVOptions

      public BlossomVOptions(BlossomVOptions.InitializationType initializationType)
      Constructs a new options instance with a initializationType
      Parameters:
      initializationType - defines a strategy to use to initialize the matching
    • BlossomVOptions

      public BlossomVOptions()
      Constructs a default set of options for the algorithm
  • Method Details

    • toString

      public String toString()
      Overrides:
      toString in class Object
    • isUpdateDualsBefore

      public boolean isUpdateDualsBefore()
      Returns the updateDualsBefore flag
      Returns:
      the flag updateDualsBefore
    • isUpdateDualsAfter

      public boolean isUpdateDualsAfter()
      Returns the updateDualsAfter flag
      Returns:
      the flag updateDualsAfter
    • getDualUpdateStrategy

      public BlossomVOptions.DualUpdateStrategy getDualUpdateStrategy()
      Returns dual updates strategy
      Returns:
      dual updates strategy
    • getInitializationType

      public BlossomVOptions.InitializationType getInitializationType()
      Returns initialization type
      Returns:
      initialization type