[ library(gfd) | Reference Manual | Alphabetic Index ]

# max_regret_lwb(?Var, ?Criterion)

Generic search compatible variable selection method, returns the regret value for Var

Var
  Domain variable or integer
Criterion
  Variable

## Description

This predicate is designed to be used as a variable selection method with generic search (lib(gfd_search)), and should be used with gfd_search's delete/5 and search/6. The effect is to select the first variable with the maximum regret (the largest difference between the smallest and second smallest value in the domain).

Unlike the built-in generic search's max_regret method, where the regret value is calculated in ECLiPSe from the variable's domain, this predicate obtain the regret value from Gecode.

## See Also

gfd_search : delete / 5, gfd_search : search / 6