login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 


Sum of digits (bits) in base two representation of 3^(2^n).
0

%I #19 Jun 16 2024 16:42:57

%S 2,2,3,6,11,26,56,97,204,415,769,1606,3268,6460,12889,25915,52046,

%T 104099,207000,416542,831430,1662247,3324374,6646337,13292865,

%U 26593542,53182276,106364450,212732814,425465107,850887793,1701801109

%N Sum of digits (bits) in base two representation of 3^(2^n).

%e 3^(2^2) = 81 = 64 + 16 + 1, so a(2) = 3.

%p a := proc (n) local b2: b2 := convert(3^(2^n), base, 2): add(b2[j], j = 1 .. nops(b2)) end proc: seq(a(n), n = 0 .. 20); # _Emeric Deutsch_, Jul 21 2009

%t Table[Total[IntegerDigits[3^2^n,2]],{n,0,25}] (* The program generates the first 26 terms of the seequence. *) (* _Harvey P. Dale_, Jun 16 2024 *)

%o (J, version 6.0.1)

%o s=:(+/@|:@#:@ (3x ^ 2x ^ i.))

%o s 13

%o (PARI) a(n) = hammingweight(3^(2^n)); \\ _Michel Marcus_, Mar 03 2019

%Y Cf. A000120, A011764 (3^2^n).

%K nonn,base

%O 0,1

%A _Daniel R. L. Brown_, Jul 07 2009

%E Extended by _Emeric Deutsch_, Jul 21 2009

%E More terms from _Michel Marcus_, Mar 03 2019

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 20 09:27 EDT 2024. Contains 376068 sequences. (Running on oeis4.)