[seqfan] Re: Phil Scovis's problem

Giovanni Resta g.resta at iit.cnr.it
Tue Mar 5 20:28:33 CET 2013


On 03/05/2013 07:14 PM, Neil Sloane wrote:

> Definition. Let S be a set of n positive numbers such that
> all n choose 2 pairwise GCD's are distinct.

That was my first interpretation of the sequence's name.

However, after looking at the data (which was wrong but not so wrong),
I guessed the intended meaning:

Scovis: "Minimum element in a set of positive integers of size n where 
every pair of elements differs by their GCF".

Meaning:
Minimum possible element of a set of n positive integers a_1,a_2,...,a_n
such that for i != j,  |a_i - a_j| = GCD(a_i, a_j), where |x| denote
the absolute value of x.

I have computed the first sets, which give the sequence 1, 1, 2, 6, 36, 
210, 14976, ... where the sets are:
{1}, {1,2}, {2, 3, 4}, {6, 8, 9, 12}, {36, 40, 42, 45, 48}, {210, 216, 
220, 224, 225, 240}, and {14976, 14980, 14994, 15000, 15008, 15015, 15120}.

But in the meantime the sequence disappeared....

The Mma program I used is the following:

ok[v_, n_] := v == Select[v, GCD[#, n] == Abs[n - #] &];

ric[p_, cc_, k_] :=
  If[Length at p == k, sol = p; True,
   Block[{c = cc, x, r = False},
    While[c != {}, x = First at c; c = Rest at c;
     If[p == Select[p, GCD[#, x] == Abs[x - #] &] &&
      ric[Append[p, x], c, k], r = True; Break[]]]; r]];

a[k_] := Block[{n = 1, d}, While[Length[d = Divisors at n] < k - 1 ||
  !ric[{n}, n + d, k], n++]; n];

Do[Print[n, " ", a[n], " ", sol], {n, 7}]

Giovanni Resta



More information about the SeqFan mailing list