cp's OEIS Frontend

This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.

Showing 1-10 of 21 results. Next

A114124 Decimal expansion of logarithm of A112302.

Original entry on oeis.org

5, 0, 7, 8, 3, 3, 9, 2, 2, 8, 6, 8, 4, 3, 8, 3, 9, 2, 1, 8, 9, 0, 4, 1, 8, 4, 0, 7, 2, 2, 0, 7, 6, 3, 7, 4, 2, 4, 6, 2, 1, 8, 4, 3, 3, 4, 3, 2, 6, 0, 0, 9, 2, 9, 5, 3, 6, 6, 3, 9, 2, 7, 5, 0, 3, 5, 1, 5, 2, 2, 5, 8, 0, 8, 9, 7, 1, 0, 8, 6, 1, 8, 3, 6, 9, 0, 1, 5, 3, 8, 5, 5, 3, 5, 4, 4, 0, 7, 5, 4, 1, 8, 8, 8, 3
Offset: 0

Views

Author

Eric W. Weisstein, Feb 08 2006

Keywords

Examples

			0.5078339228684383921890418407220763742462184334326009...
		

Crossrefs

Programs

Formula

Equals Sum_{n>=2} log(n)/2^n. - Jean-François Alcover, Apr 14 2014
Equals lim_{k->oo} (1/k) Sum_{i=1..k} A334074(i)/A334075(i). - Amiram Eldar, Apr 14 2020
Equals Sum_{n>=1} Lambda(n)/(2^n-1), where Lambda(n) = log(A014963(n)) is the Mangoldt function. - Amiram Eldar, Jul 07 2021
Equals lim_{m->oo} (1/m) * Sum_{k=1..m} f(k), where f(k) = Sum_{primes p <= k, binomial(2*k,k) mod p != 0} 1/p = A334074(k)/A334075(k) (Erdős et al., 1975). - Amiram Eldar, May 25 2025

A001511 The ruler function: exponent of the highest power of 2 dividing 2n. Equivalently, the 2-adic valuation of 2n.

Original entry on oeis.org

1, 2, 1, 3, 1, 2, 1, 4, 1, 2, 1, 3, 1, 2, 1, 5, 1, 2, 1, 3, 1, 2, 1, 4, 1, 2, 1, 3, 1, 2, 1, 6, 1, 2, 1, 3, 1, 2, 1, 4, 1, 2, 1, 3, 1, 2, 1, 5, 1, 2, 1, 3, 1, 2, 1, 4, 1, 2, 1, 3, 1, 2, 1, 7, 1, 2, 1, 3, 1, 2, 1, 4, 1, 2, 1, 3, 1, 2, 1, 5, 1, 2, 1, 3, 1, 2, 1, 4, 1, 2, 1, 3, 1, 2, 1, 6, 1, 2, 1, 3, 1, 2, 1, 4, 1
Offset: 1

Views

Author

Keywords

Comments

Number of 2's dividing 2*n.
a(n) is equivalently the exponent of the smallest power of 2 which does not divide n. - David James Sycamore, Oct 02 2023
a(n) - 1 is the number of trailing zeros in the binary expansion of n.
If you are counting in binary and the least significant bit is numbered 1, the next bit is 2, etc., a(n) is the bit that is incremented when increasing from n-1 to n. - Jud McCranie, Apr 26 2004
Number of steps to reach an integer starting with (n+1)/2 and using the map x -> x*ceiling(x) (cf. A073524).
a(n) is the number of the disk to be moved at the n-th step of the optimal solution to Towers of Hanoi problem (comment from Andreas M. Hinz).
Shows which bit to flip when creating the binary reflected Gray code (bits are numbered from the right, offset is 1). This is essentially equivalent to Hinz's comment. - Adam Kertesz, Jul 28 2001
a(n) is the Hamming distance between n and n-1 (in binary). This is equivalent to Kertesz's comments above. - Tak-Shing Chan (chan12(AT)alumni.usc.edu), Feb 25 2003
Let S(0) = {1}, S(n) = {S(n-1), S(n-1)-{x}, x+1} where x = last term of S(n-1); sequence gives S(infinity). - Benoit Cloitre, Jun 14 2003
The sum of all terms up to and including the first occurrence of m is 2^m-1. - Donald Sampson (marsquo(AT)hotmail.com), Dec 01 2003
m appears every 2^m terms starting with the 2^(m-1)th term. - Donald Sampson (marsquo(AT)hotmail.com), Dec 08 2003
Sequence read mod 4 gives A092412. - Philippe Deléham, Mar 28 2004
If q = 2n/2^A001511(n) and if b(m) is defined by b(0)=q-1 and b(m)=2*b(m-1)+1, then 2n = b(A001511(n)) + 1. - Gerald McGarvey, Dec 18 2004
Repeating pattern ABACABADABACABAE ... - Jeremy Gardiner, Jan 16 2005
Relation to C(n) = Collatz function iteration using only odd steps: a(n) is the number of right bits set in binary representation of A004767(n) (numbers of the form 4*m+3). So for m=A004767(n) it follows that there are exactly a(n) recursive steps where m
Between every two instances of any positive integer m there are exactly m distinct values (1 through m-1 and one value greater than m). - Franklin T. Adams-Watters, Sep 18 2006
Number of divisors of n of the form 2^k. - Giovanni Teofilatto, Jul 25 2007
Every prefix up to (but not including) the first occurrence of some k >= 2 is a palindrome. - Gary W. Adamson, Sep 24 2008
1 interleaved with (2 interleaved with (3 interleaved with ( ... ))). - Eric D. Burgess (ericdb(AT)gmail.com), Oct 17 2009
A054525 (Möbius transform) * A001511 = A036987 = A047999^(-1) * A001511. - Gary W. Adamson, Oct 26 2009
Equals A051731 * A036987, (inverse Möbius transform of the Fredholm-Rueppel sequence) = A047999 * A036987. - Gary W. Adamson, Oct 26 2009
Cf. A173238, showing links between generalized ruler functions and A000041. - Gary W. Adamson, Feb 14 2010
Given A000041, P(x) = A(x)/A(x^2) with P(x) = (1 + x + 2x^2 + 3x^3 + 5x^4 + 7x^5 + ...), A(x) = (1 + x + 3x^2 + 4x^3 + 10x^4 + 13x^5 + ...), A(x^2) = (1 + x^2 + 3x^4 + 4x^6 + 10x^8 + ...), where A092119 = (1, 1, 3, 4, 10, ...) = Euler transform of the ruler sequence, A001511. - Gary W. Adamson, Feb 11 2010
Subtracting 1 from every term and deleting any 0's yields the same sequence, A001511. - Ben Branman, Dec 28 2011
In the listing of the compositions of n as lists in lexicographic order, a(k) is the last part of composition(k) for all k <= 2^(n-1) and all n, see example. - Joerg Arndt, Nov 12 2012
According to Hinz, et al. (see links), this sequence was studied by Louis Gros in his 1872 pamphlet "Théorie du Baguenodier" and has therefore been called the Gros sequence.
First n terms comprise least squarefree word of length n using positive integers, where "squarefree" means that the word contains no consecutive identical subwords; e.g., 1 contains no square; 11 contains a square but 12 does not; 121 contains no square; both 1211 and 1212 have squares but 1213 does not; etc. - Clark Kimberling, Sep 05 2013
Length of 0-run starting from 2 (10, 100, 110, 1000, 1010, ...), or length of 1-run starting from 1 (1, 11, 101, 111, 1001, 1011, ...) of every second number, from right to left in binary representation. - Armands Strazds, Apr 13 2017
a(n) is also the frequency of the largest part in the integer partition having viabin number n. The viabin number of an integer partition is defined in the following way. Consider the southeast border of the Ferrers board of the integer partition and consider the binary number obtained by replacing each east step with 1 and each north step, except the last one, with 0. The corresponding decimal form is, by definition, the viabin number of the given integer partition. "Viabin" is coined from "via binary". For example, consider the integer partition [2,2,2,1]. The southeast border of its Ferrers board yields 10100, leading to the viabin number 20. - Emeric Deutsch, Jul 24 2017
As A000005(n) equals the number of even divisors of 2n and A001227(n) = A001227(2n), the formula A001511(n) = A000005(n)/A001227(n) might be read as "The number of even divisors of 2n is always divisible by the number of odd divisors of 2n" (where number of divisors means sum of zeroth powers of divisors). Conjecture: For any nonnegative integer k, the sum of the k-th powers of even divisors of n is always divisible by the sum of the k-th powers of odd divisors of n. - Ivan N. Ianakiev, Jul 06 2019
From Benoit Cloitre, Jul 14 2022: (Start)
To construct the sequence, start from 1's separated by a place 1,,1,,1,,1,,1,,1,,1,,1,,1,,1,,1,,1,,1,,1,...
Then put the 2's in every other remaining place
1,2,1,,1,2,1,,1,2,1,,1,2,1,,1,2,1,,1,2,1,,1,2,1,...
Then the 3's in every other remaining place
1,2,1,3,1,2,1,,1,2,1,3,1,2,1,,1,2,1,3,1,2,1,,1,2,1,...
Then the 4's in every other remaining place
1,2,1,3,1,2,1,4,1,2,1,3,1,2,1,,1,2,1,3,1,2,1,4,1,2,1,...
By iterating this process, we get the ruler function 1,2,1,3,1,2,1,4,1,2,1,3,1,2,1,5,1,2,1,3,1,2,1,4,1,2,1,... (End)
a(n) is the least positive integer k for which there does not exist i+j=n and a(i)=a(j)=k (cf. A322523). - Rémy Sigrist and Jianing Song, Aug 23 2022
a(n) is the smallest positive integer that does not occur in the coincidences of the sequence so far a(1..n-1) and its reverse. - Neal Gersh Tolunsky, Jan 18 2023
The geometric mean of this sequence approaches the Somos constant (A112302). - Jwalin Bhatt, Jan 31 2025

Examples

			For example, 2^1|2, 2^2|4, 2^1|6, 2^3|8, 2^1|10, 2^2|12, ... giving the initial terms 1, 2, 1, 3, 1, 2, ...
From _Omar E. Pol_, Jun 12 2009: (Start)
Triangle begins:
1;
2,1;
3,1,2,1;
4,1,2,1,3,1,2,1;
5,1,2,1,3,1,2,1,4,1,2,1,3,1,2,1;
6,1,2,1,3,1,2,1,4,1,2,1,3,1,2,1,5,1,2,1,3,1,2,1,4,1,2,1,3,1,2,1;
7,1,2,1,3,1,2,1,4,1,2,1,3,1,2,1,5,1,2,1,3,1,2,1,4,1,2,1,3,1,2,1,6,1,2,1,3,...
(End)
S(0) = {} S(1) = 1 S(2) = 1, 2, 1 S(3) = 1, 2, 1, 3, 1, 2, 1 S(4) = 1, 2, 1, 3, 1, 2, 1, 4, 1, 2, 1, 3, 1, 2, 1. - Yann David (yann_david(AT)hotmail.com), Mar 21 2010
From _Joerg Arndt_, Nov 12 2012: (Start)
The 16 compositions of 5 as lists in lexicographic order:
[ n]  a(n)  composition
[ 1]  [ 1]  [ 1 1 1 1 1 ]
[ 2]  [ 2]  [ 1 1 1 2 ]
[ 3]  [ 1]  [ 1 1 2 1 ]
[ 4]  [ 3]  [ 1 1 3 ]
[ 5]  [ 1]  [ 1 2 1 1 ]
[ 6]  [ 2]  [ 1 2 2 ]
[ 7]  [ 1]  [ 1 3 1 ]
[ 8]  [ 4]  [ 1 4 ]
[ 9]  [ 1]  [ 2 1 1 1 ]
[10]  [ 2]  [ 2 1 2 ]
[11]  [ 1]  [ 2 2 1 ]
[12]  [ 3]  [ 2 3 ]
[13]  [ 1]  [ 3 1 1 ]
[14]  [ 2]  [ 3 2 ]
[15]  [ 1]  [ 4 1 ]
[16]  [ 5]  [ 5 ]
a(n) is the last part in each list.
(End)
From _Omar E. Pol_, Aug 20 2013: (Start)
Also written as a triangle in which the right border gives A000027 and row lengths give A011782 and row sums give A000079 the sequence begins:
1;
2;
1,3;
1,2,1,4;
1,2,1,3,1,2,1,5;
1,2,1,3,1,2,1,4,1,2,1,3,1,2,1,6;
1,2,1,3,1,2,1,4,1,2,1,3,1,2,1,5,1,2,1,3,1,2,1,4,1,2,1,3,1,2,1,7;
(End)
G.f. = x + 2*x^2 + x^3 + 3*x^4 + x^5 + 2*x^6 + x^7 + 4*x^8 + x^9 + 2*x^10 + ...
		

References

  • J.-P. Allouche and J. Shallit, Automatic Sequences, Cambridge Univ. Press, 2003.
  • E. R. Berlekamp, J. H. Conway and R. K. Guy, Winning Ways, Academic Press, NY, 2 vols., 2nd ed., 2001-2003; see Dim- and Dim+ on p. 98; Dividing Rulers, on pp. 436-437; The Ruler Game, pp. 469-470; Ruler Fours, Fives, ... Fifteens on p. 470.
  • L. Gros, Théorie du Baguenodier, Aimé Vingtrinier, Lyon, 1872.
  • R. K. Guy, Unsolved Problems in Number Theory, Springer, 1st edition, 1981. See section E22.
  • A. M. Hinz, The Tower of Hanoi, in Algebras and combinatorics (Hong Kong, 1997), 277-289, Springer, Singapore, 1999.
  • D. E. Knuth, The Art of Computer Programming, vol. 4A, Combinatorial Algorithms, Section 7.1.3, Problem 41, p. 589.
  • Andrew Schloss, "Towers of Hanoi" composition, in The Digital Domain. Elektra/Asylum Records 9 60303-2, 1983. Works by Jaffe (Finale to "Silicon Valley Breakdown"), McNabb ("Love in the Asylum"), Schloss ("Towers of Hanoi"), Mattox ("Shaman"), Rush, Moorer ("Lions are Growing") and others.
  • 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).

Crossrefs

Column 1 of table A050600.
Sequence read mod 2 gives A035263.
Sequence is bisection of A007814, A050603, A050604, A067029, A089309.
This is Guy Steele's sequence GS(4, 2) (see A135416).
Cf. A005187 (partial sums), A085058 (bisection), A112302 (geometric mean), A171977 (2^a(n)).
Cf. A287896, A002487, A209229 (Mobius trans.), A092673 (Dirichlet inv.).
Cf. generalized ruler functions for k=3,4,5: A051064, A115362, A055457.

Programs

  • Haskell
    a001511 n = length $ takeWhile ((== 0) . (mod n)) a000079_list
    -- Reinhard Zumkeller, Sep 27 2011
    
  • Haskell
    a001511 n | odd n = 1 | otherwise = 1 + a001511 (n `div` 2)
    -- Walt Rorie-Baety, Mar 22 2013
    
  • MATLAB
    nmax=5;r=1;for n=2:nmax;r=[r n r];end % Adriano Caroli, Feb 26 2016
    
  • Magma
    [Valuation(2*n,2): n in [1..105]]; // Bruno Berselli, Nov 23 2015
    
  • Maple
    A001511 := n->2-wt(n)+wt(n-1); # where wt is defined in A000120
    # This is the binary logarithm of the denominator of (256^n-1)B_{8n}/n, in Maple parlance a := n -> log[2](denom((256^n-1)*bernoulli(8*n)/n)). - Peter Luschny, May 31 2009
    A001511 := n -> padic[ordp](2*n,2): seq(A001511(n), n=1..105);  # Peter Luschny, Nov 26 2010
    a:= n-> ilog2((Bits[Xor](2*n, 2*n-1)+1)/2): seq(a(n), n=1..50);  # Gary Detlefs, Dec 13 2018
  • Mathematica
    Array[ If[ Mod[ #, 2] == 0, FactorInteger[ # ][[1, 2]], 0] &, 105] + 1 (* or *)
    Nest[ Flatten[ # /. a_Integer -> {1, a + 1}] &, {1}, 7] (* Robert G. Wilson v, Mar 04 2005 *)
    IntegerExponent[2*n, 2] (* Alexander R. Povolotsky, Aug 19 2011 *)
    myHammingDistance[n_, m_] := Module[{g = Max[m, n], h = Min[m, n]}, b1 = IntegerDigits[g, 2]; b2 = IntegerDigits[h, 2, Length[b1]]; HammingDistance[b1, b2]] (* Vladimir Shevelev A206853 *) Table[ myHammingDistance[n, n - 1], {n, 111}] (* Robert G. Wilson v, Apr 05 2012 *)
    Table[Position[Reverse[IntegerDigits[n,2]],1,1,1],{n,110}]//Flatten (* Harvey P. Dale, Aug 18 2017 *)
  • PARI
    a(n) = sum(k=0,floor(log(n)/log(2)),floor(n/2^k)-floor((n-1)/2^k)) /* Ralf Stephan */
    
  • PARI
    a(n)=if(n%2,1,factor(n)[1,2]+1) /* Jon Perry, Jun 06 2004 */
    
  • PARI
    {a(n) = if( n, valuation(n, 2) + 1, 0)}; /* Michael Somos, Sep 30 2006 */
    
  • PARI
    {a(n)=if(n==1,1,polcoeff(x-sum(k=1, n-1, a(k)*x^k*(1-x^k)*(1-x+x*O(x^n))), n))} /* Paul D. Hanna, Jun 22 2007 */
    
  • Python
    def a(n): return bin(n)[2:][::-1].index("1") + 1 # Indranil Ghosh, May 11 2017
    
  • Python
    A001511 = lambda n: (n&-n).bit_length() # M. F. Hasler, Apr 09 2020
    
  • Python
    def A001511(n): return (~n & n-1).bit_length()+1 # Chai Wah Wu, Jul 01 2022
    
  • Sage
    [valuation(2*n,2) for n in (1..105)]  # Bruno Berselli, Nov 23 2015
    
  • Scheme
    (define (A001511 n) (let loop ((n n) (e 1)) (if (odd? n) e (loop (/ n 2) (+ 1 e))))) ;; Antti Karttunen, Oct 06 2017

Formula

a(n) = A007814(n) + 1 = A007814(2*n).
a(2*n+1) = 1; a(2*n) = 1 + a(n). - Philippe Deléham, Dec 08 2003
a(n) = 2 - A000120(n) + A000120(n-1), n >= 1. - Daniele Parisse
a(n) = 1 + log_2(abs(A003188(n) - A003188(n-1))).
Multiplicative with a(p^e) = e+1 if p = 2; 1 if p > 2. - David W. Wilson, Aug 01 2001
For any real x > 1/2: lim_{N->infinity} (1/N)*Sum_{n=1..N} x^(-a(n)) = 1/(2*x-1); also lim_{N->infinity} (1/N)*Sum_{n=1..N} 1/a(n) = log(2). - Benoit Cloitre, Nov 16 2001
s(n) = Sum_{k=1..n} a(k) is asymptotic to 2*n since s(n) = 2*n - A000120(n). - Benoit Cloitre, Aug 31 2002
For any n >= 0, for any m >= 1, a(2^m*n + 2^(m-1)) = m. - Benoit Cloitre, Nov 24 2002
a(n) = Sum_{d divides n and d is odd} mu(d)*tau(n/d). - Vladeta Jovovic, Dec 04 2002
G.f.: A(x) = Sum_{k>=0} x^(2^k)/(1-x^(2^k)). - Ralf Stephan, Dec 24 2002
a(1) = 1; for n > 1, a(n) = a(n-1) + (-1)^n*a(floor(n/2)). - Vladeta Jovovic, Apr 25 2003
A fixed point of the mapping 1->12; 2->13; 3->14; 4->15; 5->16; ... . - Philippe Deléham, Dec 13 2003
Product_{k>0} (1+x^k)^a(k) is g.f. for A000041(). - Vladeta Jovovic, Mar 26 2004
G.f. A(x) satisfies A(x) = A(x^2) + x/(1-x). - Franklin T. Adams-Watters, Feb 09 2006
a(A118413(n,k)) = A002260(n,k); = a(A118416(n,k)) = A002024(n,k); a(A014480(n)) = A003602(A014480(n)). - Reinhard Zumkeller, Apr 27 2006
Ordinal transform of A003602. - Franklin T. Adams-Watters, Aug 28 2006 (The ordinal transform of a sequence b_0, b_1, b_2, ... is the sequence a_0, a_1, a_2, ... where a_n is the number of times b_n has occurred in {b_0 ... b_n}.)
Could be extended to n <= 0 using a(-n) = a(n), a(0) = 0, a(2*n) = a(n)+1 unless n=0. - Michael Somos, Sep 30 2006
A094267(2*n) = A050603(2*n) = A050603(2*n + 1) = a(n). - Michael Somos, Sep 30 2006
Sequence = A129360 * A000005 = M*V, where M = an infinite lower triangular matrix and V = d(n) as a vector: [1, 2, 2, 3, 2, 4, ...]. - Gary W. Adamson, Apr 15 2007
Row sums of triangle A130093. - Gary W. Adamson, May 13 2007
Dirichlet g.f.: zeta(s)*2^s/(2^s-1). - Ralf Stephan, Jun 17 2007
a(n) = -Sum_{d divides n} mu(2*d)*tau(n/d). - Benoit Cloitre, Jun 21 2007
G.f.: x/(1-x) = Sum_{n>=1} a(n)*x^n*( 1 - x^n ). - Paul D. Hanna, Jun 22 2007
2*n = 2^a(n)* A000265(n). - Eric Desbiaux, May 14 2009 [corrected by Alejandro Erickson, Apr 17 2012]
Multiplicative with a(2^k) = k + 1, a(p^k) = 1 for any odd prime p. - Franklin T. Adams-Watters, Jun 09 2009
With S(n): 2^n - 1 first elements of the sequence then S(0) = {} (empty list) and if n > 0, S(n) = S(n-1), n, S(n-1). - Yann David (yann_david(AT)hotmail.com), Mar 21 2010
a(n) = log_2(A046161(n)/A046161(n-1)). - Johannes W. Meijer, Nov 04 2012
a((2*n-1)*2^p) = p+1, p >= 0 and n >= 1. - Johannes W. Meijer, Feb 05 2013
a(n+1) = 1 + Sum_{j=0..ceiling(log_2(n+1))} (j * (1 - abs(sign((n mod 2^(j + 1)) - 2^j + 1)))). - Enrico Borba, Oct 01 2015
Conjecture: a(n) = A181988(n)/A003602(n). - L. Edson Jeffery, Nov 21 2015
a(n) = log_2(A006519(n)) + 1. - Doug Bell, Jun 02 2017
Inverse Moebius transform of A209229. - Andrew Howroyd, Aug 04 2018
a(n) = 1 + (A183063(n)/A001227(n)). - Omar E. Pol, Nov 06 2018 (after Franklin T. Adams-Watters)
a(n) = log_2((Xor(2*n,2*n-1)+1)/2). - Gary Detlefs, Dec 13 2018
(2^(a(n)-1)-1)*(n mod 4) = 2*floor(((n+1) mod 4)/3). - Gary Detlefs, Dec 14 2018
a(n) = A000005(n)/A001227(n). - Ivan N. Ianakiev, Jul 05 2019
a(n) = Sum_{j=1..r} (j/2^j)*(Product_{k=1..j} (1 - (-1)^floor( (n+2^(j-1))/2^(k-1) ))), for n < a predefined 2^r. - Adriano Caroli, Sep 30 2019

Extensions

Name edited following suggestion by David James Sycamore, Oct 05 2023

A066099 Triangle read by rows, in which row n lists the compositions of n in reverse lexicographic order.

Original entry on oeis.org

1, 2, 1, 1, 3, 2, 1, 1, 2, 1, 1, 1, 4, 3, 1, 2, 2, 2, 1, 1, 1, 3, 1, 2, 1, 1, 1, 2, 1, 1, 1, 1, 5, 4, 1, 3, 2, 3, 1, 1, 2, 3, 2, 2, 1, 2, 1, 2, 2, 1, 1, 1, 1, 4, 1, 3, 1, 1, 2, 2, 1, 2, 1, 1, 1, 1, 3, 1, 1, 2, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 6, 5, 1, 4, 2, 4, 1, 1, 3, 3, 3, 2, 1, 3, 1, 2, 3, 1, 1, 1, 2, 4, 2, 3
Offset: 1

Author

Alford Arnold, Dec 30 2001

Keywords

Comments

The representation of the compositions (for fixed n) is as lists of parts, the order between individual compositions (for the same n) is (list-)reversed lexicographic; see the example by Omar E. Pol. - Joerg Arndt, Sep 03 2013
This is the standard ordering for compositions in this database; it is similar to the Mathematica ordering for partitions (A080577). Other composition orderings include A124734 (similar to the Abramowitz & Stegun ordering for partitions, A036036), A108244 (similar to the Maple partition ordering, A080576), etc (see crossrefs).
Factorize each term in A057335; sequence records the values of the resulting exponents. It also runs through all possible permutations of multiset digits.
This can be regarded as a table in two ways: with each composition as a row, or with the compositions of each integer as a row. The first way has A000120 as row lengths and A070939 as row sums; the second has A001792 as row lengths and A001788 as row sums. - Franklin T. Adams-Watters, Nov 06 2006
This sequence includes every finite sequence of positive integers. - Franklin T. Adams-Watters, Nov 06 2006
Compositions (or ordered partitions) are also generated in sequence A101211. - Alford Arnold, Dec 12 2006
The equivalent sequence for partitions is A228531. - Omar E. Pol, Sep 03 2013
The sole partition of zero has no components, not a single component of length one. Hence the first nonempty row is row 1. - Franklin T. Adams-Watters, Apr 02 2014 [Edited by Andrey Zabolotskiy, May 19 2018]
See sequence A261300 for another version where the terms of each composition are concatenated to form one single integer: (0, 1, 2, 11, 3, 21, 12, 111,...). This also shows how the terms can be obtained from the binary numbers A007088, cf. Arnold's first Example. - M. F. Hasler, Aug 29 2015
The k-th composition in the list is obtained by taking the set of positions of 1's in the reversed binary expansion of k, prepending 0, taking first differences, and reversing again. This is described as the standard ordering used in the OEIS, although the sister sequence A228351 is also sometimes considered to be canonical. Both sequences define a bijective correspondence between nonnegative integers and integer compositions. - Gus Wiseman, May 19 2020
First differences of A030303 = positions of bits 1 in the concatenation A030190 (= A030302) of numbers written in binary (A007088). - Indices of record values (= first occurrence of n) are given by A005183: a(A005183(n)) = n, cf. FORMULA for more. - M. F. Hasler, Oct 12 2020
The geometric mean approaches the Somos constant (A112302). - Jwalin Bhatt, Feb 10 2025

Examples

			A057335 begins 1 2 4 6 8 12 18 30 16 24 36 ... so we can write
  1 2 1 3 2 1 1 4 3 2 2 1 1 1 1 ...
  . . 1 . 1 2 1 . 1 2 1 3 2 1 1 ...
  . . . . . . 1 . . . 1 . 1 2 1 ...
  . . . . . . . . . . . . . . 1 ...
and the columns here gives the rows of the triangle, which begins
  1
  2; 1 1
  3; 2 1; 1 2; 1 1 1
  4; 3 1; 2 2; 2 1 1; 1 3; 1 2 1; 1 1 2; 1 1 1 1
  ...
From _Omar E. Pol_, Sep 03 2013: (Start)
Illustration of initial terms:
  -----------------------------------
  n  j       Diagram   Composition j
  -----------------------------------
  .               _
  1  1           |_|   1;
  .             _ _
  2  1         |  _|   2,
  2  2         |_|_|   1, 1;
  .           _ _ _
  3  1       |    _|   3,
  3  2       |  _|_|   2, 1,
  3  3       | |  _|   1, 2,
  3  4       |_|_|_|   1, 1, 1;
  .         _ _ _ _
  4  1     |      _|   4,
  4  2     |    _|_|   3, 1,
  4  3     |   |  _|   2, 2,
  4  4     |  _|_|_|   2, 1, 1,
  4  5     | |    _|   1, 3,
  4  6     | |  _|_|   1, 2, 1,
  4  7     | | |  _|   1, 1, 2,
  4  8     |_|_|_|_|   1, 1, 1, 1;
(End)
		

Crossrefs

Lists of compositions of integers: this sequence (reverse lexicographic order; minus one gives A108730), A228351 (reverse colexicographic order - every composition is reversed; minus one gives A163510), A228369 (lexicographic), A228525 (colexicographic), A124734 (length, then lexicographic; minus one gives A124735), A296774 (length, then reverse lexicographic), A337243 (length, then colexicographic), A337259 (length, then reverse colexicographic), A296773 (decreasing length, then lexicographic), A296772 (decreasing length, then reverse lexicographic), A337260 (decreasing length, then colexicographic), A108244 (decreasing length, then reverse colexicographic), also A101211 and A227736 (run lengths of bits).
Cf. row length and row sums for different splittings into rows: A000120, A070939, A001792, A001788.
Cf. lists of partitions of integers, or multisets of integers: A026791 and crosserfs therein, A112798 and crossrefs therein.
See link for additional crossrefs pertaining to standard compositions.
A related ranking of finite sets is A048793/A272020.

Programs

  • Haskell
    a066099 = (!!) a066099_list
    a066099_list = concat a066099_tabf
    a066099_tabf = map a066099_row [1..]
    a066099_row n = reverse $ a228351_row n
    -- (each composition as a row)
    -- Peter Kagey, Aug 25 2016
    
  • Mathematica
    Table[FactorInteger[Apply[Times, Map[Prime, Accumulate @ IntegerDigits[n, 2]]]][[All, -1]], {n, 41}] // Flatten (* Michael De Vlieger, Jul 11 2017 *)
    stc[n_] := Differences[Prepend[Join @@ Position[Reverse[IntegerDigits[n, 2]], 1], 0]] // Reverse;
    Table[stc[n], {n, 0, 20}] // Flatten (* Gus Wiseman, May 19 2020 *)
    Table[Reverse @ LexicographicSort @ Flatten[Permutations /@ Partitions[n], 1], {n, 10}] // Flatten (* Eric W. Weisstein, Jun 26 2023 *)
  • PARI
    arow(n) = {local(v=vector(n),j=0,k=0);
       while(n>0,k++; if(n%2==1,v[j++]=k;k=0);n\=2);
       vector(j,i,v[j-i+1])} \\ returns empty for n=0. - Franklin T. Adams-Watters, Apr 02 2014
    
  • Python
    from itertools import islice
    from itertools import accumulate, count, groupby, islice
    def A066099_gen():
        for i in count(1):
            yield [len(list(g)) for _,g in groupby(accumulate(int(b) for b in bin(i)[2:]))]
    A066099 = list(islice(A066099_gen(), 120))  # Jwalin Bhatt, Feb 28 2025
  • Sage
    def a_row(n): return list(reversed(Compositions(n)))
    flatten([a_row(n) for n in range(1,6)]) # Peter Luschny, May 19 2018
    

Formula

From M. F. Hasler, Oct 12 2020: (Start)
a(n) = A030303(n+1) - A030303(n).
a(A005183(n)) = n; a(A005183(n)+1) = n-1 (n>1); a(A005183(n)+2) = 1. (End)

Extensions

Edited with additional terms by Franklin T. Adams-Watters, Nov 06 2006
0th row removed by Andrey Zabolotskiy, May 19 2018

A055209 a(n) = Product_{i=0..n} i!^2.

Original entry on oeis.org

1, 1, 4, 144, 82944, 1194393600, 619173642240000, 15728001190723584000000, 25569049282962188245401600000000, 3366980847587422591723894776791040000000000, 44337041641882947649156022595410930014617600000000000000
Offset: 0

Author

N. J. A. Sloane, Jul 18 2000

Keywords

Comments

a(n) is the discriminant of the polynomial x(x+1)(x+2)...(x+n). - Yuval Dekel (dekelyuval(AT)hotmail.com), Nov 13 2003
This is the Hankel transform (see A001906 for definition) of the sequence: 1, 0, 1, 0, 5, 0, 61, 0, 1385, 0, 50521, ... (see A000364: Euler numbers). - Philippe Deléham, Apr 06 2005
Also, for n>0, the quotient of (-1)^(n-1)S(u)^(n^2)/S(un) and the determinant of the (n-1) X (n-1) square matrix [P'(u), P''(u), ..., P^(n-1)(u); P''(u), P'''(u), ..., P^(n)(u); P'''(u), P^(4)(u), ..., P^(n+1)(u); ...; P^(n-1)(u), P^(n)(u), ..., P^(2n-3)(u)] where S and P are the Weierstrass Sigma and The Weierstrass P-function, respectively and f^(n) is the n-th derivative of f. See the King and Schwarz & Weierstrass references. - Balarka Sen, Jul 31 2013
a(n) is the number of idempotent monotonic labeled magmas. That is, prod(i,j) >= max(i,j) and prod(i,i) = i. - Chad Brewbaker, Nov 03 2013
Ramanujan's infinite nested radical sqrt(1+2*sqrt(1+3*sqrt(1+...))) = 3 can be written sqrt(1+sqrt(4+sqrt(144+...))) = sqrt(a(1)+sqrt(a(2)+sqrt(a(3)+...))). Vijayaraghavan used that to prove convergence of Ramanujan's formula. - Petros Hadjicostas and Jonathan Sondow, Mar 22 2014
a(n) is the determinant of the (n+1)-th order Hankel matrix whose (i,j)-entry is equal to A000142(i+j), i,j = 0,1,...,n. - Michael Shmoish, Sep 02 2020

References

  • R. Bruce King, Beyond The Quartic Equation, Birkhauser Boston, Berlin, 1996, p. 72.
  • Srinivasa Ramanujan, J. Indian Math. Soc., III (1911), 90 and IV (1912), 226.
  • T. Vijayaraghavan, in Collected Papers of Srinivasa Ramanujan, G.H. Hardy, P.V. Seshu Aiyar and B.M. Wilson, eds., Cambridge Univ. Press, 1927, p. 348; reprinted by Chelsea, 1962.

Crossrefs

Cf. A055209 is the Hankel transform (see A001906 for definition) of A000023, A000142, A000166, A000522, A003701, A010842, A010843, A051295, A052186, A053486, A053487.

Programs

  • Magma
    [1] cat [(&*[(Factorial(k))^2: k in [1..n]]): n in [1..10]]; // G. C. Greubel, Oct 14 2018
  • Maple
    seq(mul(mul(j^2,j=1..k), k=0..n), n=0..10); # Zerinvary Lajos, Sep 21 2007
  • Mathematica
    Table[Product[(i!)^2,{i,n}],{n,0,11}] (* Harvey P. Dale, Jul 06 2011 *)
    Table[BarnesG[n + 2]^2, {n, 0, 11}] (* Jan Mangaldan, May 07 2014 *)
  • PARI
    a(n)=prod(i=1,n,i!)^2 \\ Charles R Greathouse IV, Jan 12 2012
    
  • Sage
    def A055209(n) :
       return prod(factorial(i)^(2) for i in (0..n))
    [A055209(n) for n in (0..11)] # Jani Melik, Jun 06 2015
    

Formula

a(n) = A000178(n)^2. - Philippe Deléham, Mar 06 2004
a(n) = Product_{i=0..n} i^(2*n - 2*i + 2). - Charles R Greathouse IV, Jan 12 2012
Asymptotic: a(n) ~ exp(2*zeta'(-1)-3/2*(1+n^2)-3*n)*(2*Pi)^(n+1)*(n+1)^ (n^2+2*n+5/6). - Peter Luschny, Jun 23 2012
lim_{n->infinity} a(n)^(2^(-(n+1))) = 1. - Vaclav Kotesovec, Jun 06 2015
Sum_{n>=0} 1/a(n) = A258619. - Amiram Eldar, Nov 17 2020

A052129 a(0) = 1; thereafter a(n) = n*a(n-1)^2.

Original entry on oeis.org

1, 1, 2, 12, 576, 1658880, 16511297126400, 1908360529573854283038720000, 29134719286683212541013468732221146917416153907200000000
Offset: 0

Author

Reinhard Zumkeller, Feb 12 2002

Keywords

Comments

Somos's quadratic recurrence sequence.
Iff n is prime (n>2), the n-adic valuation of a(2n) is 3*A001045(n) (three times the values at the prime indices of Jacobsthal numbers), which is 2^n+1. For example: the 11-adic valuation at a(22) = 2049 = 3*A001045(11)= 683. 3*683 = 2^11+1 = 2049. True because: When n is prime, n-adic valuation is 1 at A052129(n), then doubles as n-increases to 2n, at which point 1 is added; thus A052129(2n) = 2^n+1. Since 3*A001045(n) = 2^n+1, n-adic valuation of A052129(2n) = 3*A001045(n) when n is prime. - Bob Selcoe, Mar 06 2014
Unreduced denominators of: f(1) = 1, f(n) = f(n-1) + f(n-1)/(n-1). - Daniel Suteu, Jul 29 2016

Examples

			a(3) = 3*a(2)^2 = 3*(2*a(1)^2)^2 = 3*(2*(1*a(0)^2)^2)^2 = 3*(2*(1*1^2)^2)^2 = 3*(2*1)^2 = 3*4 = 12.
G.f. = 1 + x + 2*x^2 + 12*x^3 + 576*x^4 + 1658880*x^5 + 16511297126400*x^6 + ...
		

References

  • S. R. Finch, Mathematical Constants, Cambridge University Press, Cambridge, 2003, p. 446.

Crossrefs

Programs

  • Mathematica
    Join[{1},RecurrenceTable[{a[1]==1,a[n]==n a[n-1]^2},a,{n,10}]]  (* Harvey P. Dale, Apr 26 2011 *)
    a[ n_] := If[ n < 1, Boole[n == 0], Product[ (n - k)^2^k, {k, 0, n - 1}]]; (* Michael Somos, May 24 2013 *)
    a[n_] := Product[ k^(2^(n - k)), {k,1,n}] (* Jonathan Sondow, Mar 17 2014 *)
    NestList[{#[[1]]+1,#[[1]]*#[[2]]^2}&,{1,1},10][[All,2]] (* Harvey P. Dale, Jul 30 2018 *)
  • PARI
    {a(n) = if( n<1, n==0, prod(k=0, n-1, (n - k)^2^k))}; /* Michael Somos, May 24 2013 */

Formula

a(n) ~ s^(2^n) / (n + 2 - 1/n + 4/n^2 - 21/n^3 + 138/n^4 - 1091/n^5 + ...) where s = 1.661687949633... (see A112302) and A116603. - Michael Somos, Apr 02 2006
a(n) = n * A030450(n - 1) if n>0. - Michael Somos, Oct 22 2006
a(n) = (a(n-1) + a(n-2)^2) * (a(n-1) / a(n-2))^2. - Michael Somos, Mar 20 2012
a(n) = product_{k=1..n} k^(2^(n-k)). - Jonathan Sondow, Mar 17 2014
A088679(n+1)/a(n) = n+1. -Daniel Suteu, Jul 29 2016

A123854 Denominators in an asymptotic expansion for the cubic recurrence sequence A123851.

Original entry on oeis.org

1, 4, 32, 128, 2048, 8192, 65536, 262144, 8388608, 33554432, 268435456, 1073741824, 17179869184, 68719476736, 549755813888, 2199023255552, 140737488355328, 562949953421312, 4503599627370496, 18014398509481984, 288230376151711744, 1152921504606846976
Offset: 0

Author

Keywords

Comments

A cubic analog of the asymptotic expansion A116603 of Somos's quadratic recurrence sequence A052129. Numerators are A123853.
Equals 2^A004134(n); also the denominators in expansion of (1-x)^(-1/4). - Alexander Adamchuk, Oct 27 2006
All terms are powers of 2 and log_2 a(n) = A004134(n) = 3*n - A000120(n). - Alexander Adamchuk, Oct 27 2006 [Edited by Petros Hadjicostas, May 14 2020]
Is this the same sequence as A088802? - N. J. A. Sloane, Mar 21 2007
Almost certainly this is the same as A088802. - Michael Somos, Aug 23 2007
Denominators of Gegenbauer_C(2n,1/4,2). The denominators of Gegenbauer_C(n,1/4,2) give the doubled sequence. - Paul Barry, Apr 21 2009
If the Greubel formula in A088802 and the Luschny formula here are correct (they are the same), the sequence is a duplicate of A088802. - R. J. Mathar, Aug 02 2023

Examples

			A123851(n) ~ c^(3^n)*n^(- 1/2)/(1 + 3/(4*n) - 15/(32*n^2) + 113/(128*n^3) - 5397/(2048*n^4) + ...) where c = 1.1563626843322... is the cubic recurrence constant A123852.
		

References

  • Steven R. Finch, Mathematical Constants, Cambridge University Press, Cambridge, 2003, p. 446.

Crossrefs

Programs

  • Maple
    f:=proc(t,x) exp(sum(ln(1+m*x)/t^m,m=1..infinity)); end; for j from 0 to 29 do denom(coeff(series(f(3,x),x=0,30),x,j)); od;
    # Alternatively:
    A123854 := n -> denom(binomial(1/4,n)):
    seq(A123854(n), n=0..25); # Peter Luschny, Apr 07 2016
  • Mathematica
    Denominator[CoefficientList[Series[ 1/Sqrt[Sqrt[1-x]], {x, 0, 25}], x]] (* Robert G. Wilson v, Mar 23 2014 *)
  • PARI
    vector(25, n, n--; denominator(binomial(1/4,n)) ) \\ G. C. Greubel, Aug 08 2019
  • Sage
    # uses[A000120]
    def A123854(n): return 1 << (3*n-A000120(n))
    [A123854(n) for n in (0..25)]  # Peter Luschny, Dec 02 2012
    

Formula

From Alexander Adamchuk, Oct 27 2006: (Start)
a(n) = 2^A004134(n).
a(n) = 2^(3n - A000120(n)). (End)
a(n) = denominator(binomial(1/4,n)). - Peter Luschny, Apr 07 2016

A082850 Let S(0) = {}, S(n) = {S(n-1), S(n-1), n}; sequence gives S(infinity).

Original entry on oeis.org

1, 1, 2, 1, 1, 2, 3, 1, 1, 2, 1, 1, 2, 3, 4, 1, 1, 2, 1, 1, 2, 3, 1, 1, 2, 1, 1, 2, 3, 4, 5, 1, 1, 2, 1, 1, 2, 3, 1, 1, 2, 1, 1, 2, 3, 4, 1, 1, 2, 1, 1, 2, 3, 1, 1, 2, 1, 1, 2, 3, 4, 5, 6, 1, 1, 2, 1, 1, 2, 3, 1, 1, 2, 1, 1, 2, 3, 4, 1, 1, 2, 1, 1, 2, 3, 1, 1, 2, 1, 1, 2, 3, 4, 5, 1, 1, 2, 1, 1, 2, 3, 1, 1, 2, 1
Offset: 1

Author

Benoit Cloitre, Apr 14 2003

Keywords

Comments

Sequence counts up to successive values of A001511; i.e., apply the morphism k -> 1,2,...,k to A001511. If all 1's are removed from the sequence, the resulting sequence b has b(n) = a(n)+1. A101925 lists the positions of 1's in this sequence.
The geometric mean of this sequence approaches the Somos constant (A112302). - Jwalin Bhatt, Jan 30 2025

Examples

			S(1) = {1}, S(2) = {1,1,2}, S(3) = {1,1,2,1,1,2,3}, etc.
		

Crossrefs

Cf. A082851 (partial sums).
Cf. A215020.

Programs

  • Mathematica
    Fold[Flatten[{#1, #1, #2}] &, {}, Range[5]] (* Birkas Gyorgy, Apr 13 2011 *)
    Flatten[Table[Length@Last@Split@IntegerDigits[2 n, 2], {n, 20}] /. {n_ ->Range[n]}] (* Birkas Gyorgy, Apr 13 2011 *)
  • Python
    S = []; [S.extend(S + [n]) for n in range(1, 8)]
    print(S) # Michael S. Branicky, Jul 02 2022
    
  • Python
    from itertools import count, islice
    def A082850_gen(): # generator of terms
        S = []
        for n in count(1):
            yield from (m:=S+[n])
            S += m #
    A082850_list = list(islice(A082850_gen(),20)) # Chai Wah Wu, Mar 06 2023

Formula

a(2^m - 1) = m.
If n = 2^m - 1 + k with 0 < k < 2^m, then a(n) = a(k). - Franklin T. Adams-Watters, Aug 16 2006
a(n) = log_2(A182105(n)) + 1. - Laurent Orseau, Jun 18 2019
a(n) = 1 + A215020(n). - Joerg Arndt, Mar 04 2025

A116603 Coefficients in asymptotic expansion of sequence A052129.

Original entry on oeis.org

1, 2, -1, 4, -21, 138, -1091, 10088, -106918, 1279220, -17070418, 251560472, -4059954946, 71250808916, -1351381762990, 27552372478592, -601021307680207, 13969016314470386, -344653640328891233, 8997206549370634644, -247772400254700937149, 7178881153198162073002
Offset: 0

Author

Michael Somos, Feb 18 2006

Keywords

Examples

			G.f. = 1 + 2*x - x^2 + 4*x^3 - 21*x^4 + 138*x^5 - 1091*x^6 + 10088*x^7 + ...
		

References

  • Steven R. Finch, Mathematical Constants, Cambridge University Press, Cambridge, 2003, p. 446.

Programs

  • Mathematica
    terms = 20; A[] = 1; Do[A[x] = -A[x] + 2/A[x/(1+x)]^(-1/2)*(1+x) + O[x]^j // Normal, {j, 1, terms}]; CoefficientList[A[x], x] (* Jean-François Alcover, Jul 28 2011, updated Jan 12 2018 *)
  • PARI
    {a(n) = my(A); if( n<0, 0, A=1; for( k=1, n, A = truncate( A + O(x^k)) + x * O(x^k); A = -A + 2 / subst(A^(-1/2), x, x/(1 + x)) * (1 + x);); polcoeff(A, n))};

Formula

a(0) = 1; thereafter, a(n) = (1/n)*Sum_{j=1..n} (-1)^(j-1)*2*b(j)*a(n-j), where b(j) = A000670(j) [Nemes]. - N. J. A. Sloane, Sep 11 2017
G.f. A(x) satisfies (1 + x)^2 = A(x)^2 / A(x/(1 + x)).
A003504(n+1) ~ C^(2^n) * (n + 2 - 1/n + 4/n^2 - 21/n^3 + 138/n^4 - 1091/n^5 + ...) where C = 1.04783144757... (see A115632).
A052129(n) ~ s^(2^n) / (n + 2 - 1/n + 4/n^2 - 21/n^3 + 138/n^4 - 1091/n^5 + ...) where s = 1.661687949633... (see A112302).
From Seiichi Manyama, May 26 2025: (Start)
G.f.: Product_{k>=1} (1 + k*x)^(1/2^k).
G.f.: exp(2 * Sum_{k>=1} (-1)^(k-1) * A000670(k) * x^k/k).
G.f.: 1/B(-x), where B(x) is the g.f. of A084785. (End)
a(n) ~ (-1)^(n+1) * (n-1)! / log(2)^(n+1). - Vaclav Kotesovec, May 27 2025

A123851 A cubic recurrence: a(0) = 1, a(n) = n*a(n-1)^3 for n >= 1.

Original entry on oeis.org

1, 1, 2, 24, 55296, 845378412871680, 3624972460853492659595005581182702601633792000
Offset: 0

Author

Keywords

Comments

A cubic analog of Somos's quadratic recurrence sequence A052129.
Terms a(7) onward are too big to include in data section. - G. C. Greubel, Aug 10 2019

Examples

			a(3) = 3*a(2)^3 = 3*(2*a(1)^3)^3 = 3*(2*(1*a(0)^3)^3)^3 = 3*(2*(1*1^3)^3)^3 = 3*(2*1)^3 = 3*8 = 24.
G.f. = 1 + x + 2*x^2 + 24*x^3 + 55296*x^4 + 845378412871680*x^5 + ...
		

References

  • Steven R. Finch, Mathematical Constants, Cambridge University Press, Cambridge, 2003, p. 446.

Programs

  • GAP
    List([0..8], n-> Product([0..n-1], k-> (n-k)^(3^k)) ); # G. C. Greubel, Aug 10 2019
  • Magma
    [n eq 0 select 1 else (&*[(n-k)^(3^k): k in [0..n-1]]):n in [0..8]]; // G. C. Greubel, Aug 10 2019
    
  • Mathematica
    a[n_]:= If[n==0, 1, n*a[n-1]^3]; Table[a[n], {n,0,7}]
    nxt[{n_,a_}]:={n+1, (n+1)a^3}; NestList[nxt,{0,1},7][[All,2]] (* Harvey P. Dale, May 25 2019 *)
  • PARI
    {a(n) = if( n<1, n==0, prod(k=0, n-1, (n - k)^3^k))}; /* Michael Somos, Aug 07 2016 */
    
  • Sage
    [1]+[prod((n-k)^(3^k) for k in (0..n-1)) for n in (1..8)] # G. C. Greubel, Aug 10 2019
    

Formula

a(n) ~ c^(3^n)*n^(-1/2)/(1 + 3/(4*n) - 15/(32*n^2) + 113/(128*n^3) + ...) where c = 1.1563626843322... is the cubic recurrence constant A123852.

Extensions

Corrected by Harvey P. Dale, May 25 2019

A135002 Decimal expansion of 2/e.

Original entry on oeis.org

7, 3, 5, 7, 5, 8, 8, 8, 2, 3, 4, 2, 8, 8, 4, 6, 4, 3, 1, 9, 1, 0, 4, 7, 5, 4, 0, 3, 2, 2, 9, 2, 1, 7, 3, 4, 8, 9, 1, 6, 2, 2, 2, 6, 2, 0, 6, 3, 5, 3, 5, 6, 6, 9, 0, 1, 5, 6, 7, 3, 6, 0, 3, 3, 9, 4, 9, 2, 2, 9, 9, 1, 4, 8, 9, 7, 9, 9, 6
Offset: 0

Author

Omar E. Pol, Nov 15 2007

Keywords

Comments

From Johannes W. Meijer, Jun 27 2016: (Start)
This constant is related to the values of zeta(2*n-1) of the Riemann zeta function and the Euler Mascheroni constant gamma. If we define Z(n) = (1/n) * (sum(zeta(2*n-2*k-1) * Z(k), k=0..n-2) + gamma * Z(n-1)), with Z(0) = 1, then limit(Z(n), n -> infinity) = 2/exp(1).
Similar formulas appear in A090998 and A112302.
The structure of the n! * Z(n) formulas leads to the multinomial coefficients A036039. (End).

Examples

			0.735758882342... = 2*A068985.
		

Crossrefs

Programs

Formula

Integral of log x from x = 1/e to e. - Charles R Greathouse IV, Apr 16 2015
Equals lim_{k->0} 2*(1 - k)^(1/k). - Ilya Gutkovskiy, Jun 27 2016
Equals Sum_{i>=0} ((-1)^i)(1-i)/i!. - Maciej Kaniewski, Sep 10 2017
Equals Sum_{i>=0} ((-1)^i)(i^2+2)/i!. - Maciej Kaniewski, Sep 12 2017
From Peter Bala, Mar 21 2022: (Start)
2/e = Integral_{x = 1..oo} (2*x/(1+x))^n*(x^2+x+1-n)/x^2*exp(-x) dx;
2/e = - Integral_{x = 0..1} (2*x/(1+x))^n*(x^2+x+1-n)/x^2*exp(-x) dx, both valid for n >= 2. (End)
Showing 1-10 of 21 results. Next