Download
language Essence 1.3
$ prob006.essence: Golomb Ruler Problem
$ Problem details available at http://www.csplib.org/Problems/prob006/
$
$ Given n, put n integer ticks on a ruler of size m so that all inter-tick
$ distances are unique. Minimise m,
$
$ 03 September 2007
$

given n : int(1..)

letting bound be 2 ** n

find Ticks : set (size n) of int(0..bound)

minimising max(Ticks)

such that

    $ implied
    0 in Ticks,

    forAll {i, j} subsetEq Ticks .
        forAll {k, l} subsetEq Ticks .
            {i, j} != {k, l} -> i - j != k - l