login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

Number of partitions of n into parts having no 2 in ternary representation.
2

%I #10 Mar 30 2012 18:51:11

%S 1,1,1,2,3,3,4,5,6,8,10,11,15,19,21,25,31,35,41,48,55,64,75,84,97,112,

%T 126,143,164,183,208,236,263,295,333,369,414,464,513,573,644,709,786,

%U 877,967,1066,1182,1298,1432,1584,1736,1905,2104,2302,2518,2764

%N Number of partitions of n into parts having no 2 in ternary representation.

%e a(10) = #{10, 9+1, 4+4+1+1, 4+3+3, 4+3+1+1+1, 4+6x1, 3+3+3+1, 3+3+1+1+1+1, 3+7x1, 10+1} = 10;

%e a(11) = #{10+1, 9+1+1, 4+4+3, 4+4+1+1+1, 4+3+3+1, 4+3+1+1+1+1, 4+7x1, 3+3+3+1+1, 3+3+5x1, 3+8x1, 11x1} = 11;

%e a(12) = #{12, 10+1+1, 9+3, 9+1+1+1, 4+4+4, 4+4+3+1, 4+4+1+1+1+1, 4+3+3+1+1, 4+3+5x1, 4+8x1, 3+3+3+3, 3+3+3+1+1+1, 3+3+6x1, 3+9x1, 12x1} = 15.

%o (Haskell)

%o a205216 = p $ tail a005836_list where

%o p _ 0 = 1

%o p ks'@(k:ks) m = if m < k then 0 else p ks' (m - k) + p ks m

%Y Cf. A205217, A007088, A005836.

%K nonn,base

%O 0,4

%A _Reinhard Zumkeller_, Jan 25 2012