Class RelaxedGraphHeuristic

All Implemented Interfaces:
Heuristic, PlanningGraphHeuristic, StateHeuristic, Serializable
Direct Known Subclasses:
AdjustedSum, AdjustedSum2, AjustedSum2M, Combo, CriticalPath, FastForward, Max, Sum

public abstract class RelaxedGraphHeuristic extends AbstractStateHeuristic implements PlanningGraphHeuristic
This abstract class implements the basic methods used by all heuristics based on the computation of a relaxed planning graph ignoring negative effects. This implementation is based on the implementation of the fast forward planner proposed by J. Hoffmann. The relaxed planning computed does not compute mutual exclusion. To have more information about this implementation see Hoffmann, J. and Nebel, B. (2001). The FF Planning System: Fast Plan Generation Through Heuristic Search. Journal of Artificial Intelligence Research, 14(1):253-302.
See Also:
Serialized Form
  • Constructor Details

    • RelaxedGraphHeuristic

      protected RelaxedGraphHeuristic(Problem problem)
      Creates a new RelaxedGraphHeuristic heuristic.
      Parameters:
      problem - the problem to be solved.
  • Method Details

    • setGoal

      protected final void setGoal(Condition goal)
      Set the goal of the relaxed problem to solve in order to compute the heuristic.
      Overrides:
      setGoal in class AbstractStateHeuristic
      Parameters:
      goal - the goal.
      Throws:
      NullPointerException - if goal == null.
    • expandRelaxedPlanningGraph

      protected final int expandRelaxedPlanningGraph(State state)
      This method creates the relaxed planning graph from a specified initial state.
      Parameters:
      state - the initial state of the relaxed planning graph.
      Returns:
      the level of the graph built.
    • isGoalReachable

      protected final boolean isGoalReachable()
      Returns true if the goal is reachable after the planning graph expansion.
      Returns:
      true if the goal is reachable after the planning graph expansion; false otherwise.
    • getSumValue

      protected final int getSumValue()
      Compute the sum heuristic.
      Returns:
      the sum heuristic value.
      See Also:
      Sum
    • getMaxValue

      protected final int getMaxValue()
      Compute the max heuristic.
      Returns:
      max heuristic value.
      See Also:
      Max
    • getRelaxedPlanValue

      protected final int getRelaxedPlanValue()
      Compute the relaxed plan heuristic value.
      Returns:
      the relaxed plan heuristic value.
      See Also:
      FastForward