OFFSET
1,2
COMMENTS
n is in the sequence if and only if either n == 0, 3, 5, or 6 (mod 9) or n == 8 (mod 9) and (n-8)/9 is in the sequence. - Robert Israel, Dec 15 2016
LINKS
Robert Israel, Table of n, a(n) for n = 1..10000
Hao Fu, G.-N. Han, Computer assisted proof for Apwenian sequences related to Hankel determinants, arXiv preprint arXiv:1601.04370 [math.NT], 2016. See sequence "J" in Section 2.1.
MAPLE
filter:= proc(n) local m;
m:= padic:-ordp(n+1, 3);
(n+1)/3^m mod 3 = 1 + (m mod 2)
end proc:
select(filter, [$0..100]); # Robert Israel, Dec 15 2016
MATHEMATICA
isok[n_]:=Module[{ord=IntegerExponent[n+1, 3]}, Mod[(n+1)/3^ord, 3]==Mod[ord, 2]+1]; Select[Range[0, 131], isok](* Ray Chandler, Dec 17 2016 *)
CROSSREFS
KEYWORD
nonn
AUTHOR
N. J. A. Sloane, Dec 07 2016
EXTENSIONS
More terms from Robert Israel, Dec 15 2016
STATUS
approved