OFFSET
1,1
LINKS
Vincenzo Librandi, Table of n, a(n) for n = 1..1000
FORMULA
a(n) = A007931(n) + A002276(A000523(n+1)) = A032810(n) + A256077(n) etc. - M. F. Hasler, Mar 27 2015
From Robert Israel, Apr 03 2017:
a(2*n+1) = 10*a(n)+3.
a(2*n+2) = 10*a(n)+4.
G.f. g(x) satisfies g(x) = 10*(x+x^2)*g(x^2) + x*(3+4*x)/(1-x^2). (End)
MAPLE
S[1]:= [3, 4]:
for d from 2 to 5 do S[d]:= map(t -> (10*t+3, 10*t+4), S[d-1]) od:
seq(op(S[d]), d=1..5); # Robert Israel, Apr 03 2017
MATHEMATICA
Flatten[Table[FromDigits[#, 10]&/@Tuples[{3, 4}, n], {n, 5}]] (* Vincenzo Librandi, May 30 2012 *)
PROG
(Magma) [n: n in [1..35000] | Set(IntegerToSequence(n, 10)) subset {3, 4}]; // Vincenzo Librandi, May 30 2012
(PARI) A032834(n)=vector(#n=binary(n+1)[2..-1], i, 10^(#n-i))*n~+10^#n\3 \\ M. F. Hasler, Mar 27 2015
CROSSREFS
KEYWORD
nonn,base,easy
AUTHOR
EXTENSIONS
Crossrefs added by M. F. Hasler, Mar 27 2015
Name corrected by Robert Israel, Apr 03 2017
STATUS
approved