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

# <ConsistencyModule:> ham_path_g(?Start,?End,+Succ)

Constrains elements in Succ to form a Hamiltonian path from Start to End, with native Gecode indexing.

Start
  An integer or (domain) variable (array notation accepted)
End
  An integer or (domain) variable (array notation accepted)
Succ
  A collection of different (domain) variables or integers

## Description

This version of ham_path/3 uses the native Gecode indexing, which starts from 0. This is different from normal ECLiPSe's indexing, which starts from 1, and may be incompatible with existing ECLiPSe code.

See ham_path/3 for a more detailed description of this predicate.

## Examples

    [eclipse 6]: ham_path_g(S,E,[A,B]).

    S = S{[0, 1]}
    E = E{[0, 1]}
    A = A{[1, 2]}
    B = B{[0, 2]}

    [eclipse 7]: ham_path_g(1,0,[A,B]).

    A = 2
    B = 0

    [eclipse 8]: ham_path_g(S,E,[1,3,0]).

    S = 2
    E = 1

## See Also

ham_path / 3