Class PseudoRandomNodeSelection<C,E extends Environment>

java.lang.Object
isula.aco.AntPolicy<C,E>
isula.aco.algorithms.antsystem.RandomNodeSelection<C,E>
isula.aco.algorithms.acs.PseudoRandomNodeSelection<C,E>
Type Parameters:
C - Class for components of a solution.
E - Class representing the Environment.

public class PseudoRandomNodeSelection<C,E extends Environment> extends RandomNodeSelection<C,E>
The selection policy for Ant Colony System algorithms. It defines to selection rules.

  • The first is the best selection rule. It picks the component with the better heuristic and pheromone information.
  • The other one is the usual ACO policy, selecting based on the probabilities of each possible component.

Using one or another is determined by a "best-choice" probability.

Author:
Carlos G. Gavidia
  • Constructor Details

    • PseudoRandomNodeSelection

      public PseudoRandomNodeSelection()
  • Method Details

    • applyPolicy

      public boolean applyPolicy(E environment, ConfigurationProvider configuration)
      Overrides:
      applyPolicy in class RandomNodeSelection<C,E extends Environment>
    • selectMostConvenient

      protected boolean selectMostConvenient(AcsConfigurationProvider configurationProvider)
      In a pseudo-random selection rule, determines if we greedily select the most convenient component.
      Parameters:
      configurationProvider - Algorithm configuration.
      Returns:
      True if the greedy approach is followed, false otherwise.
    • getMostConvenient

      public C getMostConvenient(Map<C,Double> componentsWithProbabilities)
      Returns the most convenient component based on heuristic and pheromone information.
      Parameters:
      componentsWithProbabilities - Possible components.
      Returns:
      Most convenient component.
    • doIfNoNodeWasSelected

      protected boolean doIfNoNodeWasSelected(E environment, ConfigurationProvider configuration)