login
Indices of Catalan numbers (A000108) that are == 2 mod 3.
2

%I #13 Jun 30 2020 19:36:18

%S 2,3,4,8,9,10,26,27,28,38,39,40,80,81,82,92,93,94,110,111,112,116,117,

%T 118,242,243,244,254,255,256,272,273,274,278,279,280,326,327,328,332,

%U 333,334,350,351,352,362,363,364,728,729,730,740,741,742

%N Indices of Catalan numbers (A000108) that are == 2 mod 3.

%H Robert Israel, <a href="/A111020/b111020.txt">Table of n, a(n) for n = 1..10000</a>

%p filter:= proc(n) local L1,L2,L3;

%p L1:= convert(2*n,base,3);

%p L2:= convert(n,base,3);

%p L3:= convert(n-1,base,3);

%p mul(binomial(L1[i],L2[i]),i=1..nops(L2)) - mul(binomial(L1[i],L3[i]),i=1..nops(L3)) mod 3 = 2

%p end proc:

%p select(filter, [$1..1000]); # _Robert Israel_, Jun 30 2020

%t Flatten[Position[CatalanNumber[Range[750]],_?(Mod[#,3]==2&)]] (* _Harvey P. Dale_, Sep 21 2012 *)

%Y Cf. A000108.

%K nonn,look

%O 1,1

%A _Robert G. Wilson v_, Sep 09 2005