[go: up one dir, main page]

login
Search: a165420 -id:a165420
     Sort: relevance | references | number | modified | created      Format: long | short | data
a(n) = 2^(2^n).
(Formerly M1297 N0497)
+10
113
2, 4, 16, 256, 65536, 4294967296, 18446744073709551616, 340282366920938463463374607431768211456, 115792089237316195423570985008687907853269984665640564039457584007913129639936
OFFSET
0,1
COMMENTS
Or, write previous term in base 2, read in base 4.
a(1) = 2, a(n) = smallest power of 2 which does not divide the product of all previous terms.
Number of truth tables generated by Boolean expressions of n variables. - C. Bradford Barber (bradb(AT)shore.net), Dec 27 2005
From Ross Drewe, Feb 13 2008: (Start)
Or, number of distinct n-ary operators in a binary logic. The total number of n-ary operators in a k-valued logic is T = k^(k^n), i.e., if S is a set of k elements, there are T ways of mapping an ordered subset of n elements from S to an element of S. Some operators are "degenerate": the operator has arity p, if only p of the n input values influence the output. Therefore the set of operators can be partitioned into n+1 disjoint subsets representing arities from 0 to n.
For n = 2, k = 2 gives the familiar Boolean operators or functions, C = F(A,B). There are 2^2^2 = 16 operators, composed of: arity 0: 2 operators (C = 0 or 1), arity 1: 4 operators (C = A, B, not(A), not(B)), arity 2: 10 operators (including well-known pairs AND/NAND, OR/NOR, XOR/EQ). (End)
From José María Grau Ribas, Jan 19 2012: (Start)
Or, numbers that can be formed using the number 2, the power operator (^), and parenthesis. (End) [The paper by Guy and Selfridge (see also A003018) shows that this is the same as the current sequence. - N. J. A. Sloane, Jan 21 2012]
a(n) is the highest value k such that A173419(k) = n+1. - Charles R Greathouse IV, Oct 03 2012
Let b(0) = 8 and b(n+1) = the smallest number not in the sequence such that b(n+1) - Product_{i=0..n} b(i) divides b(n+1)*Product_{i=0..n} b(i). Then b(n) = a(n) for n > 0. - Derek Orr, Jan 15 2015
Twice the number of distinct minimal toss sequences of a coin to obtain all sequences of length n, which is 2^(2^n-1). This derives from the 2^n ways to cut each of the de Bruijn sequences B(2,n). - Maurizio De Leo, Feb 28 2015
I conjecture that { a(n) ; n>1 } are the numbers such that n^4-1 divides 2^n-1, intersection of A247219 and A247165. - M. F. Hasler, Jul 25 2015
REFERENCES
D. E. Knuth, The Art of Computer Programming, Vol. 4A, Section 7.1.1, p. 79.
N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).
LINKS
A. V. Aho and N. J. A. Sloane, Some doubly exponential sequences, Fibonacci Quarterly, Vol. 11, No. 4 (1973), pp. 429-437, alternative link.
Jan Brandts and Apo Cihangir, Enumeration and investigation of acute 0/1-simplices modulo the action of the hyperoctahedral group, Special Matrices, Vol. 5, No. 1 (2017), pp. 158-201, arXiv preprint, arXiv:1512.03044 [math.CO], 2015.
John H. Conway, Sphere packings, lattices, codes and greed, pp. 45-55 of Proc. Intern. Congr. Math., Vol. 2, 1994, alternative link.
Jose María Grau and A. M. Oller-Marcén On the last digit and the last non-zero digit of n^n in base b, arXiv:1203.4066 [math.NT], 2012.
Richard K. Guy and J. L. Selfridge, The nesting and roosting habits of the laddered parenthesis, Amer. Math. Monthly 80 (8) (1973), 868-876.
Rudolf Ondrejka, Exact values of 2^n, n=1(1)4000, Math. Comp., 23 (1969), 456.
Eric Weisstein's World of Mathematics, Irrationality Sequence, Quadratic Recurrence Equation, Coin Tossing.
FORMULA
a(n+1) = (a(n))^2.
1 = Sum_{n>=0} a(n)/A051179(n+1) = 2/3 + 4/15 + 16/255 + 256/65535, ..., with partial sums: 2/3, 14/15, 254/255, 65534/65535, ... - Gary W. Adamson, Jun 15 2003
a(n) = A000079(A000079(n)). - Robert Israel, Jan 15 2015
Sum_{n>=0} 1/a(n) = A007404. - Amiram Eldar, Oct 14 2020
From Amiram Eldar, Jan 28 2021: (Start)
Product_{n>=0} (1 + 1/a(n)) = 2.
Product_{n>=0} (1 - 1/a(n)) = A215016. (End)
MAPLE
A001146:=n->2^(2^n): seq(A001146(n), n=0..9); # Wesley Ivan Hurt, Sep 19 2014
MATHEMATICA
2^2^Range[0, 10] (* Harvey P. Dale, Jul 20 2011 *)
PROG
(Magma) [2^(2^n): n in [0..8]]; // Vincenzo Librandi, Jun 20 2011
(PARI) a(n)=1<<2^n \\ Charles R Greathouse IV, Jul 25 2011
(PARI) a(n)=2^2^n \\ Charles R Greathouse IV, Oct 03 2012
(Haskell)
a001146 = (2 ^) . (2 ^)
a001146_list = iterate (^ 2) 2 -- Reinhard Zumkeller, Jun 04 2012
(Python)
def A001146(n): return 1<<(1<<n) # Chai Wah Wu, Mar 14 2023
KEYWORD
nonn,easy,nice
STATUS
approved
Triangle of coefficients of polynomials P_n(z) defined by the recursion P_0(z) = z+1; for n>=1, P_n(z) = z + Product_{k=0..n-1} P_k(z).
+10
2
1, 1, 2, 1, 2, 4, 1, 4, 14, 16, 8, 1, 16, 112, 324, 508, 474, 268, 88, 16, 1, 256, 3584, 22912, 88832, 233936, 443936, 628064, 675456, 557492, 353740, 171644, 62878, 17000, 3264, 416, 32, 1, 65536, 1835008, 24576000, 209715200, 1281482752, 5974786048, 22114709504, 66752724992
OFFSET
1,3
COMMENTS
Length of the first row is 2; for i>=2, length of the i-th row is 2^{i-2}+1.
LINKS
A. V. Aho and N. J. A. Sloane, Some doubly exponential sequences, Fibonacci Quarterly, Vol. 11, No. 4 (1973), pp. 429-437, alternative link.
FORMULA
Another recursion is: P_n(z)=z+P_(n-1)(z)(P_(n-1)(z)-z).
Private values: P_n(0)=1; P_n(-1)=delta_(n,0)-1; {P_n(1)}=A000058; {P_n(2)}=A000215; {P_n(3)}={A000289(n+1)}; {P_n(4)}={A000324(n+1)}; {P_n(5)}={A001543(n+1)}; {P_n(6)}={A001544(n+1)}; {P_n(7)}={A067686(n)}; {P_n(8)}={A110360(n)}; {P_0(n)}={A000027(n+1)}; {P_1(n)}={A005408(n)}; {P_2(n)}={A056220(n+1)}.
EXAMPLE
Triangle begins:
1, 1;
2, 1;
2, 4, 1;
4, 14, 16, 8, 1;
16, 112, 324, 508, 474, 268, 88, 16, 1;
MAPLE
p:= proc(n) option remember;
z-> z+ `if`(n=0, 1, p(n-1)(z)*(p(n-1)(z)-z))
end:
deg:= n-> `if`(n=0, 1, 2^(n-1)):
T:= (n, k)-> coeff(p(n)(z), z, deg(n)-k):
seq(seq(T(n, k), k=0..deg(n)), n=0..6); # Alois P. Heinz, Dec 13 2010
MATHEMATICA
P[0][z_] := z + 1;
P[n_][z_] := P[n][z] = z + Product[P[k][z], {k, 0, n-1}];
row[n_] := CoefficientList[P[n][z], z] // Reverse;
Table[row[n], {n, 0, 6}] // Flatten (* Jean-François Alcover, Jun 11 2018 *)
CROSSREFS
KEYWORD
nonn,tabf
AUTHOR
Vladimir Shevelev, Dec 11 2010
EXTENSIONS
More terms from Alois P. Heinz, Dec 13 2010
STATUS
approved
a(0) = 1; if n is odd, a(n) = Product_{i=0..n-1} a(i); if n is even, a(n) = Sum_{i=0..n-1} a(i).
+10
2
1, 1, 2, 2, 6, 24, 36, 20736, 20808, 8947059130368, 8947059171984, 716210897494804754044764041567551881216, 716210897494804754044764059461670225184
OFFSET
0,3
COMMENTS
Next term is too large to include.
Odd terms are the product of previous terms and even terms are the sum of previous terms.
FORMULA
a(n) = a(n-1) + 2*a(n-2), for even n > 2.
a(n) = a(n-1) * a(n-2)^2, for odd n > 1.
EXAMPLE
5 is odd, so a(5) = 1 * 1 * 2 * 2 * 6 = 24.
6 is even, so a(6) = 1 + 1 + 2 + 2 + 6 + 24 = 36.
MATHEMATICA
a[0]:= 1; a[n_]:= If[OddQ[n], Product[a[j], {j, 0, n-1}], Sum[a[j], {j, 0, n -1}]]; Table[a[n], {n, 0, 15}] (* G. C. Greubel, Oct 19 2018 *)
PROG
(PARI) first(n) = my(res = vector(n, i, 1)); for(x=3, n, res[x]=if(x%2, sum(i=1, x-1, res[i]), prod(i=1, x-1, res[i]))); res
(PARI) first(n) = my(res = vector(n, i, 1)); res[3]++; for(x=4, n, res[x]=if(x%2, res[x-1]+2*res[x-2], res[x-1]*res[x-2]^2)); res
CROSSREFS
Sum of previous terms: A011782.
Product of previous terms: A165420.
KEYWORD
nonn
AUTHOR
Iain Fox, Oct 17 2018
STATUS
approved
Number of children at height n in a doubly logarithmic tree. Leaves are at height 0.
+10
1
0, 2, 2, 4, 16, 256, 65536, 4294967296, 18446744073709551616, 340282366920938463463374607431768211456, 115792089237316195423570985008687907853269984665640564039457584007913129639936
OFFSET
0,2
LINKS
Omer Berkman, Baruch Schieber and Uzi Vishkin, Optimal doubly logarithmic parallel algorithms based on finding all nearest smaller values, Journal of Algorithms, 14(1993)(3): 344-370.
FORMULA
a(0)=0, a(1)=2; for n>1, a(n) = 2^(2^(n-2)).
MATHEMATICA
Join[{0, 2}, Table[2^2^(n-2), {n, 2, 9}]] (* Harvey P. Dale, Feb 01 2014 *)
PROG
(Python)
def doubly_log_tree_children(n):
if n==0:
return 0
if n==1:
return 2
return 2**(2**(n-2))
CROSSREFS
Equals A001146 with the prefix 0, 2.
Cf. A165420. [R. J. Mathar, Dec 11 2009]
KEYWORD
nonn
AUTHOR
Chad Brewbaker, Dec 04 2009
EXTENSIONS
More terms from Harvey P. Dale, Feb 01 2014
STATUS
approved

Search completed in 0.121 seconds