|
|
A131485
|
|
Smallest positive integer k == n mod 3 not occurring earlier such that the sum of two successive terms is a squarefree number.
|
|
1
|
|
|
1, 2, 3, 4, 11, 6, 7, 8, 9, 10, 5, 12, 19, 14, 15, 16, 17, 18, 13, 20, 21, 22, 29, 24, 31, 26, 27, 28, 23, 30, 25, 32, 33, 34, 35, 36, 37, 41, 42, 40, 38, 39, 43, 44, 45, 46, 47, 48, 49, 53, 54, 52, 50, 51, 55, 56, 57, 58, 65, 66, 61, 62, 60, 67, 71, 63, 64
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,2
|
|
COMMENTS
|
Mod 3 analog of A077223. A permutation of the natural numbers. There's an obvious limit to the number of successive values which can be consecutive integers.
|
|
LINKS
|
|
|
FORMULA
|
a(n) = MIN{k > 0 such that 3|(n-k) and k + a(n-1) not in A013929}. a(n) = MIN{k > 0 such that 3|(n-k) and k + a(n-1) in A005117}.
|
|
MAPLE
|
S:= {0, 1}: mink:= 2: A[1]:= 1:
for n from 2 to 100 do
for k from mink + (n-mink mod 3) by 3 do
if not member(k, S) and numtheory:-issqrfree(A[n-1]+k) then
A[n]:= k; S:= S union {k};
if k = mink then mink := min({$mink .. max(S)+1} minus S) fi;
break
fi
od
|
|
CROSSREFS
|
|
|
KEYWORD
|
easy,nonn
|
|
AUTHOR
|
|
|
EXTENSIONS
|
|
|
STATUS
|
approved
|
|
|
|