(Translated by https://www.hiragana.jp/)
A213918 - OEIS
login
A213918
a(n) = smallest possible element of a set of n positive integers s_1, s_2, ..., s_n such that for i != j, |s_i - s_j| = gcd(s_i, s_j), where |x| denotes absolute value.
2
1, 1, 2, 6, 36, 210, 14976, 552720, 309582000
OFFSET
1,3
EXAMPLE
Examples of sets for the first few cases:
{1},
{1,2},
{2, 3, 4},
{6, 8, 9, 12},
{36, 40, 42, 45, 48},
{210, 216, 220, 224, 225, 240},
{14976, 14980, 14994, 15000, 15008, 15015, 15120},
{552720, 552825, 552960, 553000, 553014, 553140, 553280, 554400},
{309582000, 309583680, 309583800, 309583872, 309583890, 309584000, 309584025, 309584100, 309584160}.
MATHEMATICA
ok[v_, n_] := v == Select[v, GCD[#, n] == Abs[n - #] &];
ric[p_, cc_, k_] :=
If[Length@p == k, sol = p; True,
Block[{c = cc, x, r = False},
While[c != {}, x = First@c; c = Rest@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@n] < k - 1 ||
!ric[{n}, n + d, k], n++]; n];
Do[Print[n, " ", a[n], " ", sol], {n, 7}]
CROSSREFS
Sequence in context: A101609 A281024 A152668 * A239889 A086325 A343581
KEYWORD
nonn,more
AUTHOR
Phil Scovis, Mar 04 2013
EXTENSIONS
Corrected (with Mathematica program) by Giovanni Resta, Mar 05 2013. Entry revised by N. J. A. Sloane, Mar 05 2013
a(8) from Robert Gerbicz, Mar 05 2013
a(9) from Robert Gerbicz, Mar 06 2013
STATUS
approved