login
A082575
Nonnegative numbers in (3*A005836) union (3*A005836 - 2) [A005836 lists the numbers with base-3 representation containing no 2].
2
0, 1, 3, 7, 9, 10, 12, 25, 27, 28, 30, 34, 36, 37, 39, 79, 81, 82, 84, 88, 90, 91, 93, 106, 108, 109, 111, 115, 117, 118, 120, 241, 243, 244, 246, 250, 252, 253, 255, 268, 270, 271, 273, 277, 279, 280, 282, 322, 324, 325, 327, 331, 333, 334, 336, 349, 351, 352
OFFSET
1,3
COMMENTS
Numbers k such that the Motzkin number A001006(k) == 1 (mod 3).
LINKS
Rob Burns, Asymptotic density of Motzkin numbers modulo small primes, arXiv:1611.04910 [math.NT], 2016.
MATHEMATICA
(* m = MotzkinNumber *) m[0] = 1; m[n_] := m[n] = m[n - 1] + Sum[m[k]*m[n - 2 - k], {k, 0, n - 2}]; Select[Range[0, 400], Mod[m[#], 3] == 1 &] (* Jean-François Alcover, Jul 10 2013 *)
max = 150; Sort @ Join[Select[3*Range[0, max], DigitCount[#, 3, 2] == 0 &], Select[3*Range[max] - 2, DigitCount[# + 2, 3, 2] == 0 &]] (* Amiram Eldar, Jun 04 2022 *)
CROSSREFS
KEYWORD
nonn,base
AUTHOR
EXTENSIONS
Offset changed to 1 (sequence is a list) by L. Edson Jeffery, Nov 27 2015
STATUS
approved