A294339 Number of ways to write 2^n as a finite power-tower of positive integers greater than one, allowing both left and right nesting of parentheses.
1, 2, 2, 5, 2, 6, 2, 12, 5, 6, 2, 19, 2, 6, 6, 32, 2, 19, 2, 19, 6, 6, 2, 56, 5, 6, 12, 19, 2, 26, 2, 79, 6, 6, 6, 71, 2, 6, 6, 56, 2, 26, 2, 19, 19, 6, 2, 169, 5, 19, 6, 19, 2, 56, 6, 56, 6, 6, 2, 101, 2, 6, 19, 203, 6, 26, 2, 19, 6, 26, 2, 237, 2, 6, 19, 19
Offset: 1
Keywords
Examples
The a(6) = 6 ways are 64, 8^2, (2^3)^2, 4^3, (2^2)^3, 2^6.
Links
- Hans Havermann, Table of n, a(n) for n = 1..10000
Crossrefs
Programs
-
Maple
f:= proc(n) option remember; local F,t,s,g,a; F:= ifactors(n)[2]; g:= igcd(op(map(t -> t[2],F))); t:= 1; for s in numtheory:-divisors(g) minus {1} do t:= t + procname(mul(a[1]^(a[2]/s),a=F))*procname(s) od; t end proc: seq(f(2^n),n=1..100); # Robert Israel, Dec 01 2017
-
Mathematica
a[n_]:=1+Sum[a[n^(1/g)]*a[g],{g,Rest[Divisors[GCD@@FactorInteger[n][[All,2]]]]}]; Table[a[2^n],{n,100}]
Formula
a(n) = A294338(2^n). - R. J. Mathar, Nov 27 2017