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 35 results. Next

A247714 Position of A036561(n) in sequence A003586.

Original entry on oeis.org

1, 2, 3, 4, 5, 7, 6, 8, 10, 12, 9, 11, 14, 16, 19, 13, 15, 18, 21, 24, 27, 17, 20, 23, 26, 30, 33, 37, 22, 25, 29, 32, 36, 40, 44, 49, 28, 31, 35, 39, 43, 47, 52, 57, 62, 34, 38, 42, 46, 51, 55, 60, 66, 71, 77, 41, 45, 50, 54, 59, 64, 69, 75, 81, 87, 93, 48
Offset: 0

Views

Author

Michel Marcus, Sep 22 2014

Keywords

Comments

Motivated by L. Edson Jeffery comment in A036561 that says it is a permutation of A003586.

Crossrefs

Programs

  • Haskell
    import Data.List (elemIndex); import Data.Maybe (fromJust)
    a247714 = (+ 1) . fromJust .
                      (`elemIndex` a003586_list) . (a036561_list !!)
    -- Reinhard Zumkeller, Sep 23 2014
  • Maple
    N0:= 10: # to get the first (N0+1)*(N0+2)/2 terms
    V:= 3^N0:
    S:= {seq(seq(2^i*3^j, i=0..ilog2(V/3^j)),j=0..N0)}:
    # in Maple 11 or earlier, uncomment the next line and comment out the previous one
    # S:= sort([seq(seq(2^i*3^j, i=0..ilog2(V/3^j)),j=0..N0)]):
    for k from 1 to nops(S) do
      r:= S[k];
      jr:= padic[ordp](r,3);
      ir:= jr + padic[ordp](r,2);
      A[1+jr+ir*(ir+1)/2] := k;
    od:
    seq(A[k],k=1..(N0+1)*(N0+2)/2); # Robert Israel, Sep 22 2014
  • PARI
    lista(nn) = {w = readvec("b036561.txt"); v = readvec("b003586.txt"); for (i=1, nn, print1(setsearch(v, w[i], 0), ", "););}
    

A082976 Erroneous version of A036561.

Original entry on oeis.org

1, 2, 3, 4, 6, 9, 8, 16, 18, 24, 16, 24, 36, 54, 81, 33, 48, 72, 108, 162, 243
Offset: 0

Views

Author

Keywords

Examples

			1; 2,3; 4,6,9; 8,16,18,24; ...
		

References

  • Robert Fludd, Utriusque Cosmi ... Historia, Oppenheim, 1617-1619.

A003586 3-smooth numbers: numbers of the form 2^i*3^j with i, j >= 0.

Original entry on oeis.org

1, 2, 3, 4, 6, 8, 9, 12, 16, 18, 24, 27, 32, 36, 48, 54, 64, 72, 81, 96, 108, 128, 144, 162, 192, 216, 243, 256, 288, 324, 384, 432, 486, 512, 576, 648, 729, 768, 864, 972, 1024, 1152, 1296, 1458, 1536, 1728, 1944, 2048, 2187, 2304, 2592, 2916, 3072, 3456, 3888
Offset: 1

Views

Author

Paul Zimmermann, Dec 11 1996

Keywords

Comments

This sequence is easily confused with A033845, which gives numbers of the form 2^i*3^j with i, j >= 1. Don't simply say "numbers of the form 2^i*3^j", but specify which sequence you mean. - N. J. A. Sloane, May 26 2024
These numbers were once called "harmonic numbers", see Lenstra links. - N. J. A. Sloane, Jul 03 2015
Successive numbers k such that phi(6k) = 2k. - Artur Jasinski, Nov 05 2008
Where record values greater than 1 occur in A088468: A160519(n) = A088468(a(n)). - Reinhard Zumkeller, May 16 2009
Also numbers that are divisible by neither 6k - 1 nor 6k + 1, for all k > 0. - Robert G. Wilson v, Oct 26 2010
Also numbers m such that the rooted tree with Matula-Goebel number m has m antichains. The Matula-Goebel number of a rooted tree can be defined in the following recursive manner: to the one-vertex tree there corresponds the number 1; to a tree T with root degree 1 there corresponds the t-th prime number, where t is the Matula-Goebel number of the tree obtained from T by deleting the edge emanating from the root; to a tree T with root degree m>=2 there corresponds the product of the Matula-Goebel numbers of the m branches of T. The vertices of a rooted tree can be regarded as a partially ordered set, where u<=v holds for two vertices u and v if and only if u lies on the unique path between v and the root. An antichain is a nonempty set of mutually incomparable vertices. Example: m=4 is in the sequence because the corresponding rooted tree is \/=ARB (R is the root) having 4 antichains (A, R, B, AB). - Emeric Deutsch, Jan 30 2012
A204455(3*a(n)) = 3, and only for these numbers. - Wolfdieter Lang, Feb 04 2012
The number of terms less than or equal to n is Sum_{i=0..floor(log_2(n))} floor(log_3(n/2^i) + 1), or Sum_{i=0..floor(log_3(n))} floor(log_2(n/3^i) + 1), which requires fewer terms to compute. - Robert G. Wilson v, Aug 17 2012
Named 3-friables in French. - Michel Marcus, Jul 17 2013
In the 14th century Levi Ben Gerson proved that the only pairs of terms which differ by 1 are (1,2), (2,3), (3,4), and (8,9); see A235365, A235366, A236210. - Jonathan Sondow, Jan 20 2014
Range of values of A000005(n) (and also A181819(n)) for cubefree numbers n. - Matthew Vandermast, May 14 2014
A036561 is a permutation of this sequence. - L. Edson Jeffery, Sep 22 2014
Also the sorted union of A000244 and A007694. - Lei Zhou, Apr 19 2017
The sum of the reciprocals of the 3-smooth numbers is equal to 3. Brief proof: 1 + 1/2 + 1/3 + 1/4 + 1/6 + 1/8 + 1/9 + ... = (Sum_{k>=0} 1/2^k) * (Sum_{m>=0} 1/3^m) = (1/(1-1/2)) * (1/(1-1/3)) = (2/(2-1)) * (3/(3-1)) = 3. - Bernard Schott, Feb 19 2019
Also those integers k for which, for every prime p > 3, p^(2k) - 1 == 0 (mod 24k). - Federico Provvedi, May 23 2022
For n>1, the exponents’ parity {parity(i), parity(j)} of one out of four consecutive terms is {odd, odd}. Therefore, for n>1, at least one out of every four consecutive terms is a Zumkeller number (A083207). If for the term whose parity is {even, odd}, even also means nonzero, then this term is also a Zumkeller number (as is the case with the last of the four consecutive terms 1296, 1458, 1536, 1728). - Ivan N. Ianakiev, Jul 10 2022
Except the initial terms 2, 3, 4, 8, 9 and 16, these are numbers k such that k^6 divides 6^k. Except the initial terms 2, 3, 4, 6, 8, 9, 16, 18 and 27, these are numbers k such that k^12 divides 12^k. - Mohammed Yaseen, Jul 21 2022
In music theory, a comma is a ratio, close to 1 (typically less than 1.04), between two natural numbers divisible by only small primes (typically single digit). In this sequence, a(131) / a(130) = 531441 / 524288 ~ 1.013643 is the Pythagorean comma (A221363), the difference between 12 perfect fifths and 7 octaves. - Hal M. Switkay, Mar 23 2025

References

  • J.-M. De Koninck & A. Mercier, 1001 Problèmes en Théorie Classique des Nombres, Problème 654 pp. 85, 287-8, Ellipses Paris 2004.
  • S. Ramanujan, Collected Papers, Ed. G. H. Hardy et al., Cambridge 1927; Chelsea, NY, 1962, p. xxiv.
  • R. Tijdeman, Some applications of Diophantine approximation, pp. 261-284 of Surveys in Number Theory (Urbana, May 21, 2000), ed. M. A. Bennett et al., Peters, 2003.

Crossrefs

Cf. A051037, A002473, A051038, A080197, A080681, A080682, A117221, A105420, A062051, A117222, A117220, A090184, A131096, A131097, A186711, A186712, A186771, A088468, A061987, A080683 (p-smooth numbers with other values of p), A025613 (a subsequence).
Cf. also A000244, A007694. - Lei Zhou, Apr 19 2017
Cf. A191475 (successive values of i), A191476 (successive values of j), A022330 (indices of the pure terms 2^i), A022331 (indices of the pure terms 3^j). - N. J. A. Sloane, May 26 2024
Cf. A221363.

Programs

  • Haskell
    import Data.Set (Set, singleton, insert, deleteFindMin)
    smooth :: Set Integer -> [Integer]
    smooth s = x : smooth (insert (3*x) $ insert (2*x) s')
      where (x, s') = deleteFindMin s
    a003586_list = smooth (singleton 1)
    a003586 n = a003586_list !! (n-1)
    -- Reinhard Zumkeller, Dec 16 2010
    
  • Magma
    [n: n in [1..4000] | PrimeDivisors(n) subset [2,3]]; // Bruno Berselli, Sep 24 2012
  • Maple
    A003586 := proc(n) option remember; if n = 1 then 1; else for a from procname(n-1)+1 do numtheory[factorset](a) minus {2,3} ; if % = {} then return a; end if; end do: end if; end proc: # R. J. Mathar, Feb 28 2011
    with(numtheory): for i from 1 to 23328 do if(i/phi(i)=3)then print(i/6) fi od; # Gary Detlefs, Jun 28 2011
  • Mathematica
    a[1] = 1; j = 1; k = 1; n = 100; For[k = 2, k <= n, k++, If[2*a[k - j] < 3^j, a[k] = 2*a[k - j], {a[k] = 3^j, j++}]]; Table[a[i], {i, 1, n}] (* Hai He (hai(AT)mathteach.net) and Gilbert Traub, Dec 28 2004 *)
    aa = {}; Do[If[EulerPhi[6 n] == 2 n, AppendTo[aa, n]], {n, 1, 1000}]; aa (* Artur Jasinski, Nov 05 2008 *)
    fQ[n_] := Union[ MemberQ[{1, 5}, # ] & /@ Union@ Mod[ Rest@ Divisors@ n, 6]] == {False}; fQ[1] = True; Select[ Range@ 4000, fQ] (* Robert G. Wilson v, Oct 26 2010 *)
    powerOfTwo = 12; Select[Nest[Union@Join[#, 2*#, 3*#] &, {1}, powerOfTwo-1], # < 2^powerOfTwo &] (* Robert G. Wilson v and T. D. Noe, Mar 03 2011 *)
    fQ[n_] := n == 3 EulerPhi@ n; Select[6 Range@ 4000, fQ]/6 (* Robert G. Wilson v, Jul 08 2011 *)
    mx = 4000; Sort@ Flatten@ Table[2^i*3^j, {i, 0, Log[2, mx]}, {j, 0, Log[3, mx/2^i]}] (* Robert G. Wilson v, Aug 17 2012 *)
    f[n_] := Block[{p2, p3 = 3^Range[0, Floor@ Log[3, n] + 1]}, p2 = 2^Floor[Log[2, n/p3] + 1]; Min[ Select[ p2*p3, IntegerQ]]]; NestList[f, 1, 54] (* Robert G. Wilson v, Aug 22 2012 *)
    Select[Range@4000, Last@Map[First, FactorInteger@#] <= 3 &] (* Vincenzo Librandi, Aug 25 2016 *)
    Select[Range[4000],Max[FactorInteger[#][[All,1]]]<4&] (* Harvey P. Dale, Jan 11 2017 *)
  • PARI
    test(n)=for(p=2,3, while(n%p==0, n/=p)); n==1;
    for(n=1,4000,if(test(n),print1(n",")))
    
  • PARI
    list(lim)=my(v=List(),N);for(n=0,log(lim\1+.5)\log(3),N=3^n;while(N<=lim,listput(v,N);N<<=1));vecsort(Vec(v)) \\ Charles R Greathouse IV, Jun 28 2011
    
  • PARI
    is_A003586(n)=n<5||vecmax(factor(n,5)[, 1])<5 \\ M. F. Hasler, Jan 16 2015
    
  • PARI
    list(lim)=my(v=List(), N); for(n=0, logint(lim\=1,3), N=3^n; while(N<=lim, listput(v, N); N<<=1)); Set(v) \\ Charles R Greathouse IV, Jan 10 2018
    
  • Python
    from itertools import count, takewhile
    def aupto(lim):
        pows2 = list(takewhile(lambda x: xMichael S. Branicky, Jul 08 2022
    
  • Python
    from sympy import integer_log
    def A003586(n):
        def bisection(f,kmin=0,kmax=1):
            while f(kmax) > kmax: kmax <<= 1
            while kmax-kmin > 1:
                kmid = kmax+kmin>>1
                if f(kmid) <= kmid:
                    kmax = kmid
                else:
                    kmin = kmid
            return kmax
        def f(x): return n+x-sum((x//3**i).bit_length() for i in range(integer_log(x,3)[0]+1))
        return bisection(f,n,n) # Chai Wah Wu, Sep 15 2024
    
  • Python
    # faster for initial segment of sequence
    import heapq
    from itertools import islice
    def A003586gen(): # generator of terms
        v, oldv, h, psmooth_primes, = 1, 0, [1], [2, 3]
        while True:
            v = heapq.heappop(h)
            if v != oldv:
                yield v
                oldv = v
                for p in psmooth_primes:
                    heapq.heappush(h, v*p)
    print(list(islice(A003586gen(), 65))) # Michael S. Branicky, Sep 17 2024
    (C++) // Returns A003586 <= threshold without approximations nor sorting
    #include 
    std::forward_list A003586(const int threshold) {
        std::forward_list sequence;
        auto start_it = sequence.before_begin();
        for (int i = 1; i <= threshold; i *= 2) {
            for (int inc = 1; std::next(start_it) != sequence.end() && inc <= i; inc *= 3)
                ++start_it;
            auto it = start_it;
            for (int j = 1; i * j <= threshold; j *= 3) {
                sequence.emplace_after(it, i * j);
                for (int inc = 1; std::next(it) != sequence.end() && inc <= i; inc *= 2)
                    ++it;
            }
        }
        return sequence;
    } // Eben Gino Lester, Apr 17 2025
    
  • Sage
    def isA003586(n) :
        return not any(d != 2 and d != 3 for d in prime_divisors(n))
    @CachedFunction
    def A003586(n) :
        if n == 1 : return 1
        k = A003586(n-1) + 1
        while not isA003586(k) : k += 1
        return k
    [A003586(n) for n in (1..55)] # Peter Luschny, Jul 20 2012
    

Formula

An asymptotic formula for a(n) is roughly a(n) ~ 1/sqrt(6)*exp(sqrt(2*log(2)*log(3)*n)). - Benoit Cloitre, Nov 20 2001
A061987(n) = a(n + 1) - a(n), a(A084791(n)) = A084789(n), a(A084791(n) + 1) = A084790(n). - Reinhard Zumkeller, Jun 03 2003
Union of powers of 2 and 3 with n such that psi(n) = 2*n, where psi(n) = n*Product_(1 + 1/p) over all prime factors p of n = A001615(n). - Lekraj Beedassy, Sep 07 2004; corrected by Franklin T. Adams-Watters, Mar 19 2009
a(n) = 2^A022328(n)*3^A022329(n). - N. J. A. Sloane, Mar 19 2009
The characteristic function of this sequence is given by Sum_{n >= 1} x^a(n) = Sum_{n >= 1} moebius(6*n)*x^n/(1 - x^n). - Paul D. Hanna, Sep 18 2011
a(n) = A007694(n+1)/2. - Lei Zhou, Apr 19 2017

Extensions

Deleted claim that this sequence is union of 2^n (A000079) and 3^n (A000244) sequences -- this does not include the terms which are not pure powers. - Walter Roscello (wroscello(AT)comcast.net), Nov 16 2008

A000178 Superfactorials: product of first n factorials.

Original entry on oeis.org

1, 1, 2, 12, 288, 34560, 24883200, 125411328000, 5056584744960000, 1834933472251084800000, 6658606584104736522240000000, 265790267296391946810949632000000000, 127313963299399416749559771247411200000000000, 792786697595796795607377086400871488552960000000000000
Offset: 0

Views

Author

Keywords

Comments

a(n) is also the Vandermonde determinant of the numbers 1,2,...,(n+1), i.e., the determinant of the (n+1) X (n+1) matrix A with A[i,j] = i^j, 1 <= i <= n+1, 0 <= j <= n. - Ahmed Fares (ahmedfares(AT)my-deja.com), May 06 2001
a(n) = (1/n!) * D(n) where D(n) is the determinant of order n in which the (i,j)-th element is i^j. - Amarnath Murthy, Jan 02 2002
Determinant of S_n where S_n is the n X n matrix S_n(i,j) = Sum_{d|i} d^j. - Benoit Cloitre, May 19 2002
Appears to be det(M_n) where M_n is the n X n matrix with m(i,j) = J_j(i) where J_k(n) denote the Jordan function of row k, column n (cf. A059380(m)). - Benoit Cloitre, May 19 2002
a(2n+1) = 1, 12, 34560, 125411328000, ... is the Hankel transform of A000182 (tangent numbers) = 1, 2, 16, 272, 7936, ...; example: det([1, 2, 16, 272; 2, 16, 272, 7936; 16, 272, 7936, 353792; 272, 7936, 353792, 22368256]) = 125411328000. - Philippe Deléham, Mar 07 2004
Determinant of the (n+1) X (n+1) matrix whose i-th row consists of terms 1 to n+1 of the Lucas sequence U(i,Q), for any Q. When Q=0, the Vandermonde matrix is obtained. - T. D. Noe, Aug 21 2004
Determinant of the (n+1) X (n+1) matrix A whose elements are A(i,j) = B(i+j) for 0 <= i,j <= n, where B(k) is the k-th Bell number, A000110(k) [I. Mezo, JIS 14 (2011) # 11.1.1]. - T. D. Noe, Dec 04 2004
The Hankel transform of the sequence A090365 is A000178(n+1); example: det([1,1,3; 1,3,11; 3,11,47]) = 12. - Philippe Deléham, Mar 02 2005
Theorem 1.3, page 2, of Polynomial points, Journal of Integer Sequences, Vol. 10 (2007), Article 07.3.6, provides an example of an Abelian quotient group of order (n-1) superfactorial, for each positive integer n. The quotient is obtained from sequences of polynomial values. - E. F. Cornelius, Jr. (efcornelius(AT)comcast.net), Apr 09 2007
Starting with offset 1 this is a 'Matryoshka doll' sequence with alpha=1, the multiplicative counterpart to the additive A000292. seq(mul(mul(i,i=alpha..k), k=alpha..n),n=alpha..12). - Peter Luschny, Jul 14 2009
For n>0, a(n) is also the determinant of S_n where S_n is the n X n matrix, indexed from 1, S_n(i,j)=sigma_i(j), where sigma_k(n) is the generalized divisor sigma function: A000203 is sigma_1(n). - Enrique Pérez Herrero, Jun 21 2010
a(n) is the multiplicative Wiener index of the (n+1)-vertex path. Example: a(4)=288 because in the path on 5 vertices there are 3 distances equal to 2, 2 distances equal to 3, and 1 distance equal to 4 (2*2*2*3*3*4=288). See p. 115 of the Gutman et al. reference. - Emeric Deutsch, Sep 21 2011
a(n-1) = Product_{j=1..n-1} j! = V(n) = Product_{1 <= i < j <= n} (j - i) (a Vandermondian V(n), see the Ahmed Fares May 06 2001 comment above), n >= 1, is in fact the determinant of any n X n matrix M(n) with entries M(n;i,j) = p(j-1,x = i), 1 <= i, j <= n, where p(m,x), m >= 0, are monic polynomials of exact degree m with p(0,x) = 1. This is a special x[i] = i choice in a general theorem given in Vein-Dale, p. 59 (written for the transposed matrix M(n;j,x_i) = p(i-1,x_j) = P_i(x_j) in Vein-Dale, and there a_{k,k} = 1, for k=1..n). See the Aug 26 2013 comment under A049310, where p(n,x) = S(n,x) (Chebyshev S). - Wolfdieter Lang, Aug 27 2013
a(n) is the number of monotonic magmas on n elements labeled 1..n with a symmetric multiplication table. I.e., Product(i,j) >= max(i,j); Product(i,j) = Product(j,i). - Chad Brewbaker, Nov 03 2013
The product of the pairwise differences of n+1 integers is a multiple of a(n) [and this does not hold for any k > a(n)]. - Charles R Greathouse IV, Aug 15 2014
a(n) is the determinant of the (n+1) X (n+1) matrix M with M(i,j) = (n+j-1)!/(n+j-i)!, 1 <= i <= n+1, 1 <= j <= n+1. - Stoyan Apostolov, Aug 26 2014
All terms are in A064807 and all terms after a(2) are in A005101. - Ivan N. Ianakiev, Sep 02 2016
Empirical: a(n-1) is the determinant of order n in which the (i,j)-th entry is the (j-1)-th derivative of x^(x+i-1) evaluated at x=1. - John M. Campbell, Dec 13 2016
Empirical: If f(x) is a smooth, real-valued function on an open neighborhood of 0 such that f(0)=1, then a(n) is the determinant of order n+1 in which the (i,j)-th entry is the (j-1)-th derivative of f(x)/((1-x)^(i-1)) evaluated at x=0. - John M. Campbell, Dec 27 2016
Also the automorphism group order of the n-triangular honeycomb rook graph. - Eric W. Weisstein, Jul 14 2017
Is the zigzag Hankel transform of A000182. That is, a(2*n+1) is the Hankel transform of A000182 and a(2*n+2) is the Hankel transform of A000182(n+1). - Michael Somos, Mar 11 2020
Except for n = 0, 1, superfactorial a(n) is never a square (proof in link Mabry and Cormick, FFF 4 p. 349); however, when k belongs to A349079 (see for further information), there exists m, 1 <= m <= k such that a(k) / m! is a square. - Bernard Schott, Nov 29 2021

Examples

			a(3) = (1/6)* | 1 1 1 | 2 4 8 | 3 9 27 |
a(7) = n! * a(n-1) = 7! * 24883200 = 125411328000.
a(12) = 1! * 2! * 3! * 4! * 5! * 6! * 7! * 8! * 9! * 10! * 11! * 12!
= 1^12 * 2^11 * 3^10 * 4^9 * 5^8 * 6^7 * 7^6 * 8^5 * 9^4 * 10^3 * 11^2 * 12^1
= 2^56 * 3^26 * 5^11 * 7^6 * 11^2.
G.f. = 1 + x + 2*x^2 + 12*x^3 + 288*x^4 + 34560*x^5 + 24883200*x^6 + ...
		

References

  • Miklos Bona, editor, Handbook of Enumerative Combinatorics, CRC Press, 2015, page 545.
  • Steven R. Finch, Mathematical Constants, Cambridge, 2003, pp. 135-145.
  • A. Fletcher, J. C. P. Miller, L. Rosenhead and L. J. Comrie, An Index of Mathematical Tables. Vols. 1 and 2, 2nd ed., Blackwell, Oxford and Addison-Wesley, Reading, MA, 1962, Vol. 1, p. 50.
  • R. L. Graham, D. E. Knuth and O. Patashnik, Concrete Mathematics. Addison-Wesley, Reading, MA, 1990, p. 231.
  • H. J. Ryser, Combinatorial Mathematics. Mathematical Association of America, Carus Mathematical Monograph 14, 1963, p. 53.
  • 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).
  • R. Vein and P. Dale, Determinants and Their Applications in Mathematical Physics, Springer, 1999.

Crossrefs

Programs

  • Magma
    [&*[Factorial(k): k in [0..n]]: n in [0..20]]; // Bruno Berselli, Mar 11 2015
    
  • Maple
    A000178 := proc(n)
        mul(i!,i=1..n) ;
    end proc:
    seq(A000178(n),n=0..10) ; # R. J. Mathar, Oct 30 2015
  • Mathematica
    a[0] := 1; a[1] := 1; a[n_] := n!*a[n - 1]; Table[a[n], {n, 1, 12}] (* Stefan Steinerberger, Mar 10 2006 *)
    Table[BarnesG[n], {n, 2, 14}] (* Zerinvary Lajos, Jul 16 2009 *)
    FoldList[Times,1,Range[20]!] (* Harvey P. Dale, Mar 25 2011 *)
    RecurrenceTable[{a[n] == n! a[n - 1], a[0] == 1}, a, {n, 0, 12}] (* Ray Chandler, Jul 30 2015 *)
    BarnesG[Range[2, 20]] (* Eric W. Weisstein, Jul 14 2017 *)
  • Maxima
    A000178(n):=prod(k!,k,0,n)$ makelist(A000178(n),n,0,30); /* Martin Ettl, Oct 23 2012 */
    
  • PARI
    A000178(n)=prod(k=2,n,k!) \\ M. F. Hasler, Sep 02 2007
    
  • PARI
    a(n)=polcoeff(1-sum(k=0, n-1, a(k)*x^k/prod(j=1, k+1, (1+j!*x+x*O(x^n)) )), n) \\ Paul D. Hanna, Oct 02 2013
    
  • PARI
    for(j=1,13, print1(prod(k=1,j,k^(j-k)),", ")) \\ Hugo Pfoertner, Apr 09 2020
    
  • Python
    A000178_list, n, m = [1], 1,1
    for i in range(1,100):
        m *= i
        n *= m
        A000178_list.append(n) # Chai Wah Wu, Aug 21 2015
    
  • Python
    from math import prod
    def A000178(n): return prod(i**(n-i+1) for i in range(2,n+1)) # Chai Wah Wu, Nov 26 2023
  • Ruby
    def mono_choices(a,b,n)
        n - [a,b].max
    end
    def comm_mono_choices(n)
        accum =1
        0.upto(n-1) do |i|
            i.upto(n-1) do |j|
                accum = accum * mono_choices(i,j,n)
            end
        end
        accum
    end
    1.upto(12) do |k|
        puts comm_mono_choices(k)
    end # Chad Brewbaker, Nov 03 2013
    

Formula

a(0) = 1, a(n) = n!*a(n-1). - Lee Hae-hwang, May 13 2003, corrected by Ilya Gutkovskiy, Jul 30 2016
a(0) = 1, a(n) = 1^n * 2^(n-1) * 3^(n-2) * ... * n = Product_{r=1..n} r^(n-r+1). - Amarnath Murthy, Dec 12 2003 [Formula corrected by Derek Orr, Jul 27 2014]
a(n) = sqrt(A055209(n)). - Philippe Deléham, Mar 07 2004
a(n) = Product_{i=1..n} Product_{j=0..i-1} (i-j). - Paul Barry, Aug 02 2008
log a(n) = 0.5*n^2*log n - 0.75*n^2 + O(n*log n). - Charles R Greathouse IV, Jan 13 2012
Asymptotic: a(n) ~ exp(zeta'(-1) - 3/4 - (3/4)*n^2 - (3/2)*n)*(2*Pi)^(1/2 + (1/2)*n)*(n+1)^((1/2)*n^2 + n + 5/12). For example, a(100) is approx. 0.270317...*10^6941. (See A213080.) - Peter Luschny, Jun 23 2012
G.f.: 1 + x/(U(0) - x) where U(k) = 1 + x*(k+1)! - x*(k+2)!/U(k+1); (continued fraction). - Sergei N. Gladkovskii, Oct 02 2012
G.f.: G(0)/2, where G(k) = 1 + 1/(1 - 1/(1 + 1/((k+1)!*x*G(k+1)))); (continued fraction). - Sergei N. Gladkovskii, Jun 14 2013
G.f.: 1 = Sum_{n>=0} a(n)*x^n / Product_{k=1..n+1} (1 + k!*x). - Paul D. Hanna, Oct 02 2013
A203227(n+1)/a(n) -> e, as n -> oo. - Daniel Suteu, Jul 30 2016
From Ilya Gutkovskiy, Jul 30 2016: (Start)
a(n) = G(n+2), where G(n) is the Barnes G-function.
a(n) ~ exp(1/12 - n*(3*n+4)/4)*n^(n*(n+2)/2 + 5/12)*(2*Pi)^((n+1)/2)/A, where A is the Glaisher-Kinkelin constant (A074962).
Sum_{n>=0} (-1)^n/a(n) = A137986. (End)
0 = a(n)*a(n+2)^3 + a(n+1)^2*a(n+2)^2 - a(n+1)^3*a(n+3) for all n in Z (if a(-1)=1). - Michael Somos, Mar 11 2020
Sum_{n>=0} 1/a(n) = A287013 = 1/A137987. - Amiram Eldar, Nov 19 2020
a(n) = Wronskian(1, x, x^2, ..., x^n). - Mohammed Yaseen, Aug 01 2023
From Andrea Pinos, Apr 04 2024: (Start)
a(n) = e^(Sum_{k=1..n} (Integral_{x=1..k+1} Psi(x) dx)).
a(n) = e^(Integral_{x=1..n+1} (log(sqrt(2*Pi)) - (x-1/2) + x*Psi(x)) dx).
a(n) = e^(Integral_{x=1..n+1} (log(sqrt(2*Pi)) - (x-1/2) + (n+1)*Psi(x) - log(Gamma(x))) dx).
Psi(x) is the digamma function. (End)

A000400 Powers of 6: a(n) = 6^n.

Original entry on oeis.org

1, 6, 36, 216, 1296, 7776, 46656, 279936, 1679616, 10077696, 60466176, 362797056, 2176782336, 13060694016, 78364164096, 470184984576, 2821109907456, 16926659444736, 101559956668416, 609359740010496, 3656158440062976, 21936950640377856, 131621703842267136
Offset: 0

Views

Author

Keywords

Comments

Same as Pisot sequences E(1, 6), L(1, 6), P(1, 6), T(1, 6). Essentially same as Pisot sequences E(6, 36), L(6, 36), P(6, 36), T(6, 36). See A008776 for definitions of Pisot sequences.
Central terms of the triangle in A036561. - Reinhard Zumkeller, May 14 2006
a(n) = A169604(n)/3; a(n+1) = 2*A169604(n). - Reinhard Zumkeller, May 02 2010
Number of pentagons contained within pentaflakes. - William A. Tedeschi, Sep 12 2010
Sum of coefficients of expansion of (1 + x + x^2 + x^3 + x^4 + x^5)^n.
a(n) is number of compositions of natural numbers into n parts less than 6. For example, a(2) = 36, and there are 36 compositions of natural numbers into 2 parts less than 6.
The compositions of n in which each part is colored by one of p different colors are called p-colored compositions of n. For n >= 1, a(n) equals the number of 5-colored compositions of n such that no adjacent parts have the same color.
Number of words of length n over the alphabet of six letters. - Joerg Arndt, Sep 16 2014
The number of ordered triples (x, y, z) of binary words of length n such that D(x,z) = D(x, y) + D(y, z) where D(a, b) is the Hamming distance from a to b. - Geoffrey Critzer, Mar 06 2017
a(n) is the area of a triangle with vertices at (2^n, 3^n), (2^(n+1), 3^(n+1)), and (2^(n+2), 3^(n+2)); a(n) is also one fifth the area of a triangle with vertices at (2^n, 3^(n+2)), (2^(n+1), 3^(n+1)), and (2^(n+2), 3^n). - J. M. Bergot, May 07 2018
a(n) is the number of possible outcomes of n distinguishable 6-sided dice. - Stefano Spezia, Jul 06 2024

References

  • John H. Conway and Richard K. Guy, The Book of Numbers, New York: Springer-Verlag, 1996. See p. 86.
  • 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 3 of A225816.
Row 6 of A003992.
Row 3 of A329332.

Programs

Formula

a(n) = 6^n.
a(0) = 1; a(n) = 6*a(n-1).
G.f.: 1/(1-6*x). - Simon Plouffe in his 1992 dissertation.
E.g.f.: exp(6*x).
A000005(a(n)) = A000290(n+1). - Reinhard Zumkeller, Mar 04 2007
a(n) = A159991(n)/A011577(n). - Reinhard Zumkeller, May 02 2009
a(n) = det(|s(i+3,j)|, 1 <= i,j <= n), where s(n,k) are Stirling numbers of the first kind. - Mircea Merca, Apr 04 2013

A001047 a(n) = 3^n - 2^n.

Original entry on oeis.org

0, 1, 5, 19, 65, 211, 665, 2059, 6305, 19171, 58025, 175099, 527345, 1586131, 4766585, 14316139, 42981185, 129009091, 387158345, 1161737179, 3485735825, 10458256051, 31376865305, 94134790219, 282412759265, 847255055011, 2541798719465, 7625463267259, 22876524019505
Offset: 0

Views

Author

Keywords

Comments

a(n+1) is the sum of the elements in the n-th row of triangle pertaining to A036561. - Amarnath Murthy, Jan 02 2002
Number of 2 X n binary arrays with a path of adjacent 1's and no path of adjacent 0's from top row to bottom row. - R. H. Hardin, Mar 21 2002
With offset 1, partial sums of A027649. - Paul Barry, Jun 24 2003
Number of distinct lines through the origin in the n-dimensional lattice of side length 2. A049691 has the values for the 2-dimensional lattice of side length n. - Joshua Zucker, Nov 19 2003
a(n+1)/(n+1)=(3*3^n-2*2^n)/(n+1) is the second binomial transform of the harmonic sequence 1/(n+1). - Paul Barry, Apr 19 2005
a(n+1) is the sum of n-th row of A036561. - Reinhard Zumkeller, May 14 2006
The sequence gives the sum of the lengths of the segments in Cantor's dust generating sequence up to the i-th step. Measurement unit = length of the segment of i-th step. - Giorgio Balzarotti, Nov 18 2006
Let T be a binary relation on the power set P(A) of a set A having n = |A| elements such that for every element x, y of P(A), xTy if x is a proper subset of y. Then a(n) = |T|. - Ross La Haye, Dec 22 2006
From Alexander Adamchuk, Jan 04 2007: (Start)
a(n) is prime for n in A057468.
p divides a(p) - 1 for prime p.
Quotients (3^p - 2^p - 1)/p, where p = prime(n), are listed in A127071.
Numbers k such that k divides 3^k - 2^k - 1 are listed in A127072.
Pseudoprimes in A127072(n) include all powers of primes {2,3,7} and some composite numbers that are listed in A127073, which includes all Carmichael numbers A002997.
Numbers n such that n^2 divides 3^n - 2^n - 1 are listed in A127074.
5 divides a(2n).
5^2 divides a(2*5n).
5^3 divides a(2*5^2n).
5^4 divides a(2*5^3n).
7^2 divides a(6*7n).
13 divides a(4n).
13^2 divides a(4*13n).
19 divides a(3n).
19^2 divides a(3*19n).
23^2 divides a(11n).
23^3 divides a(11*23n).
23^4 divides a(11*23^2n).
29 divides a(7n).
p divides a((p-1)n) for prime p>3.
p divides a((p-1)/2) for prime p in A097934. Also primes p such that 6 is a square mod p, except {2,3}, A038876(n).
p^(k+1) divides a(p^k*(p-1)/2*n) for prime p in A097934.
p^(k+1) divides a(p^k*(p-1)*n) for prime p>3.
Note the exception that for p = 23, p^(k+2) divides a(p^k*(p-1)/2*n).
There are no more such exceptions for primes p up to 600000. (End)
a(n) divides a(q*(n+1)-1), for all q integer. Leonardo Sarasua, Apr 15 2024
Final digits of terms follow sequence 1,5,9,5. - Enoch Haga, Nov 26 2007
This is also the second column sequence of the Sheffer triangle A143494 (2-restricted Stirling2 numbers). See the e.g.f. given below. - Wolfdieter Lang, Oct 08 2011
Partial sums give A000392. - Jon Perry, Apr 05 2014
For n >= 1, this is also row 2 of A281890: when consecutive positive integers are written as a product of primes in nondecreasing order, "3" occurs in n-th position a(n) times out of every 6^n. - Peter Munn, May 17 2017
a(n) is the number of ternary sequences of length n which include the digit 2. For example, a(2)=5 since the sequences are 02,20,12,21,22. - Enrique Navarrete, Apr 05 2021
a(n-1) is the number of ways we can form disjoint unions of two nonempty subsets of [n] such that the union contains n. For example, for n = 3, a(2) = 5 since the disjoint unions are {1}U{3}, {1}U{2,3}, {2}U{3}, {2}U{1,3}, and {1,2}U{3}. Cf. A000392 if we drop the requirement that the union contains n. - Enrique Navarrete, Aug 24 2021
Configures as a composite Koch Snowflake Fractal (see illustration in links) based on the five-fold division of the Cantor Square/Cantor Dust Fractal of (9^n-4^n)/5 see my illustration in (A016153). - John Elias, Oct 13 2021
Number of pairs (A,B) where B is a subset of {1,2,...,n} and A is a proper subset of B. - Jianing Song, Jun 18 2022
From Manfred Boergens, Mar 29 2023: (Start)
With regard to the comments by Ross La Haye and Jianing Song: Omitting "proper" gives A000244.
Number of pairs (A,B) where B is a nonempty subset of {1,2,...,n} and A is a nonempty subset of B. For nonempty proper subsets see a(n+1) in A028243. (End)
a(n) is the number of n-digit numbers whose smallest decimal digit is 7. - Stefano Spezia, Nov 15 2023
a(n-1) is the number of all possible player-reduced binary games observed by each player in an nx2 game assuming the individual strategies of k < n - 1 players are fixed and the remaining n - k - 1 player will play as one, either maintaining their status quo strategies or jointly adopting an alternative strategy. - Ambrosio Valencia-Romero, Apr 11 2024

References

  • John H. Conway and Richard K. Guy, The Book of Numbers, New York: Springer-Verlag, 1996. See pp. 86-87.
  • 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

a(n) = row sums of A091913, row 2 of A047969, column 1 of A090888 and column 1 of A038719.
Cf. partitions: A241766, A241759.
A diagonal of A262307.

Programs

  • Haskell
    a001047 n = a001047_list !! n
    a001047_list = map fst $ iterate (\(u, v) -> (3 * u + v, 2 * v)) (0, 1)
    -- Reinhard Zumkeller, Jun 09 2013
  • Magma
    [3^n - 2^n: n in [0..30]]; // Vincenzo Librandi, Jul 17 2011
    
  • Maple
    seq(3^n - 2^n, n=0..40); # Giorgio Balzarotti, Nov 18 2006
    A001047:=1/(3*z-1)/(2*z-1); # Simon Plouffe in his 1992 dissertation, dropping the initial zero
  • Mathematica
    Table[ 3^n - 2^n, {n, 0, 25} ]
    LinearRecurrence[{5, -6}, {0, 1}, 25] (* Harvey P. Dale, Aug 18 2011 *)
    Numerator@NestList[(3#+1)/2&,1/2,100] (* Zak Seidov, Oct 03 2011 *)
  • PARI
    {a(n) = 3^n - 2^n};
    
  • Python
    [3**n - 2**n for n in range(25)] # Ross La Haye, Aug 19 2005; corrected by David Radcliffe, Jun 26 2016
    
  • Sage
    [lucas_number1(n, 5, 6) for n in range(26)]  # Zerinvary Lajos, Apr 22 2009
    

Formula

G.f.: x/((1-2*x)*(1-3*x)).
a(n) = 5*a(n-1) - 6*a(n-2).
a(n) = 3*a(n-1) + 2^(n-1). - Jon Perry, Aug 23 2002
Starting 0, 0, 1, 5, 19, ... this is 3^n/3 - 2^n/2 + 0^n/6, the binomial transform of A086218. - Paul Barry, Aug 18 2003
a(n) = A083323(n)-1 = A056182(n)/2 = (A002783(n)-1)/2 = (A003063(n+2)-A003063(n+1))/2. - Ralf Stephan, Jan 12 2004
Binomial transform of A000225. - Ross La Haye, Feb 07 2005
a(n) = Sum_{k=0..n-1} binomial(n, k)*2^k. - Ross La Haye, Aug 20 2005
a(n) = 2^(2n) - A083324(n). - Ross La Haye, Sep 10 2005
a(n) = A112626(n, 1). - Ross La Haye, Jan 11 2006
E.g.f.: exp(3*x) - exp(2*x). - Mohammad K. Azarian, Jan 14 2009
a(n) = A217764(n,1). - Ross La Haye, Mar 27 2013
a(n) = 2*a(n-1) + 3^(n-1). - Toby Gottfried, Mar 28 2013
a(n) = A000244(n) - A000079(n). - Omar E. Pol, Mar 28 2013
a(n) = Sum_{k=0..2} Stirling1(2,k)*(k+1)^n = c_2^{(-n)}, poly-Cauchy numbers. - Takao Komatsu, Mar 28 2013
a(n) = A227048(n,A098294(n)). - Reinhard Zumkeller, Jun 30 2013
a(n+1) = Sum_{k=0..n} 2^k*3^(n-k). - J. M. Bergot, Mar 27 2018
Sum_{n>=1} 1/a(n) = A329064. - Amiram Eldar, Nov 20 2020
a(n) = (1/2)*Sum_{k=0..n} binomial(n, k)*(2^(n-k) + 2^k - 2).
a(n) = A001117(n) + 2*A000918(n) + 1. - Ambrosio Valencia-Romero, Mar 08 2022
a(n) = A000225(n) + A028243(n+1). - Ambrosio Valencia-Romero, Mar 09 2022
From Peter Bala, Jun 27 2025: (Start)
exp(Sum_{n >=1} a(2*n)/a(n)*x^n/n) = Sum_{n >= 0} a(n+1)*x^n.
exp(Sum_{n >=1} a(3*n)/a(n)*x^n/n) = 1 + 19*x + 247*x^2 + ... is the g.f. of A019443.
exp(Sum_{n >=1} a(4*n)/a(n)*x^n/n) = 1 + 65*x + 2743*x^2 + ... is the g.f. of A383754.
The following are all examples of telescoping series:
Sum_{n >= 1} 6^n/(a(n)*a(n+1)) = 2, since 6^n/(a(n)*a(n+1)) = b(n) - b(n+1), where b(n) = 2^n/a(n);
Sum_{n >= 1} 18^n/(a(n)*a(n+1)*a(n+2)) = 22/75, since 18^n/(a(n)*a(n+1)*a(n+2)) = c(n) - c(n+1), where c(n) = (5*6^n - 2*4^n)/(15*a(n)*a(n+1));
Sum_{n >= 1} 54^n/(a(n)*a(n+1)*a(n+2)*a(n+3)) = 634/48735 since 54^n/(a(n)*a(n+1)*a(n+2)*a(n+3)) = d(n) - d(n+1), where d(n) = (57*18^n - 38*12^n + 8*8^n)/(513*a(n)*a(n+1)*a(n+2)).
Sum_{n >= 1} 6^n/(a(n)*a(n+2)) = 14/25; Sum_{n >= 1} (-6)^n/(a(n)*a(n+2)) = -6/25.
Sum_{n >= 1} 6^n/(a(n)*a(n+3)) = 306/1805.
Sum_{n >= 1} 6^n/(a(n)*a(n+4)) = 4282/80275; Sum_{n >= 1} (-6)^n/(a(n)*a(n+4)) = -1698/80275. (End)

Extensions

Edited by Charles R Greathouse IV, Mar 24 2010

A180662 The Golden Triangle: T(n,k) = A001654(k) for n>=0 and 0<=k<=n.

Original entry on oeis.org

0, 0, 1, 0, 1, 2, 0, 1, 2, 6, 0, 1, 2, 6, 15, 0, 1, 2, 6, 15, 40, 0, 1, 2, 6, 15, 40, 104, 0, 1, 2, 6, 15, 40, 104, 273, 0, 1, 2, 6, 15, 40, 104, 273, 714, 0, 1, 2, 6, 15, 40, 104, 273, 714, 1870, 0, 1, 2, 6, 15, 40, 104, 273, 714, 1870, 4895
Offset: 0

Views

Author

Johannes W. Meijer, Sep 21 2010

Keywords

Comments

The terms in the n-th row of the Golden Triangle are the first (n+1) golden rectangle numbers. The golden rectangle numbers are A001654(n)=F(n)*F(n+1), with F(n) the Fibonacci numbers. The mirror image of the Golden Triangle is A180663.
We define below 24 mostly new triangle sums. The Row1 and Row2 sums are the ordinary and alternating row sums respectively and the Kn11 and Kn12 sums are commonly known as antidiagonal sums. Each of the names of these sums, except for the row sums, comes from a (fairy) chess piece that moves in its own peculiar way over a chessboard, see Hooper and Whyld. All pieces are leapers: knight (sqrt(5) or 1,2), fil (sqrt(8) or 2,2), camel (sqrt(10) or 3,1), giraffe (sqrt(17) or 4,1) and zebra (sqrt(13) or 3,2). Information about the origin of these chess sums can be found in "Famous numbers on a chessboard", see Meijer.
Each triangle or chess sum formula adds up numbers on a chessboard using the moves of its namesake. Converting a number triangle to a square array of numbers shows this most clearly (use the table button!). The formulas given below are for number triangles.
The chess sums of the Golden Triangle lead to six different sequences, see the crossrefs. As could be expected all these sums are related to the golden rectangle numbers.
Some triangles with complete sets of triangle sums are: A002260 (Natural Numbers), A007318 (Pascal), A008288 (Delannoy) A013609 (Pell-Jacobsthal), A036561 (Nicomachus), A104763 (Fibonacci(n)), A158405 (Odd Numbers) and of course A180662 (Golden Triangle).
#..Name....Type..Code....Definition of triangle sums.
1. Row......1....Row1.. a(n) = Sum_{k=0..n} T(n, k).
2. Row Alt..2....Row2.. a(n) = Sum_{k=0..n} (-1)^(n+k)*T(n, k).
3. Knight...1....Kn11.. a(n) = Sum_{k=0..floor(n/2)} T(n-k, k).
4. Knight...1....Kn12.. a(n) = Sum_{k=0..floor(n/2)} T(n-k+1, k+1).
5. Knight...1....Kn13.. a(n) = Sum_{k=0..floor(n/2)} T(n-k+2, k+2).
6. Knight...2....Kn21.. a(n) = Sum_{k=0..floor(n/2)} T(n-k, n-2*k).
7. Knight...2....Kn22.. a(n) = Sum_{k=0..floor(n/2)} T(n-k+1, n-2*k).
8. Knight...2....Kn23.. a(n) = Sum_{k=0..floor(n/2)} T(n-k+2, n-2*k).
9. Knight...3....Kn3... a(n) = Sum_{k=0..n} T(n+k, 2*k).
10. Knight...4....Kn4... a(n) = Sum_{k=0..n} T(n+k, n-k).
11. Fil......1....Fi1... a(n) = Sum_{k=0..floor(n/2)} T(n, 2*k).
12. Fil......2....Fi2... a(n) = Sum_{k=0..floor(n/2)} T(n, n-2*k).
13. Camel....1....Ca1... a(n) = Sum_{k=0..floor(n/3)} T(n-2*k, k).
14. Camel....2....Ca2... a(n) = Sum_{k=0..floor(n/3)} T(n-2*k, n-3*k).
15. Camel....3....Ca3... a(n) = Sum_{k=0..n} T(n+2*k, 3*k).
16. Camel....4....Ca4... a(n) = Sum_{k=0..n} T(n+2*k, n-k).
17. Giraffe..1....Gi1... a(n) = Sum_{k=0..floor(n/4)} T(n-3*k, k).
18. Giraffe..2....Gi2... a(n) = Sum_{k=0..floor(n/4)} T(n-3*k, n-4*k).
19. Giraffe..3....Gi3... a(n) = Sum_{k=0..n} T(n+3*k, 4*k).
20. Giraffe..4....Gi4... a(n) = Sum_{k=0..n} T(n+3*k, n-k).
21. Zebra....1....Ze1... a(n) = Sum_{k=0..floor(n/2)} T(n+k, 3*k).
22. Zebra....2....Ze2... a(n) = Sum_{k=0..floor(n/2)} T(n+k, n-2*k).
23. Zebra....3....Ze3... a(n) = Sum_{k=0..floor(n/3)} T(n-k, 2*k).
24. Zebra....4....Ze4... a(n) = Sum_{k=0..floor(n/3)} T(n-k, n-3*k).

Examples

			The first few rows of the Golden Triangle are:
  0;
  0, 1;
  0, 1, 2;
  0, 1, 2, 6;
  0, 1, 2, 6, 15;
  0, 1, 2, 6, 15, 40;
		

References

  • David Hooper and Kenneth Whyld, The Oxford Companion to Chess, p. 221, 1992.

Crossrefs

Cf. A180663 (Mirror), A001654 (Golden Rectangle), A000045 (F(n)).
Triangle sums: A064831 (Row1, Kn11, Kn12, Kn4, Ca1, Ca4, Gi1, Gi4), A077916 (Row2), A180664 (Kn13), A180665 (Kn21, Kn22, Kn23, Fi2, Ze2), A180665(2*n) (Kn3, Fi1, Ze3), A115730(n+1) (Ca2, Ze4), A115730(3*n+1) (Ca3, Ze1), A180666 (Gi2), A180666(4*n) (Gi3).

Programs

  • Haskell
    import Data.List (inits)
    a180662 n k = a180662_tabl !! n !! k
    a180662_row n = a180662_tabl !! n
    a180662_tabl = tail $ inits a001654_list
    -- Reinhard Zumkeller, Jun 08 2013
    
  • Magma
    [Fibonacci(k)*Fibonacci(k+1): k in [0..n], n in [0..12]]; // G. C. Greubel, May 25 2021
    
  • Maple
    F:= combinat[fibonacci]:
    T:= (n, k)-> F(k)*F(k+1):
    seq(seq(T(n, k), k=0..n), n=0..10); # revised Johannes W. Meijer, Sep 13 2012
  • Mathematica
    Table[Times @@ Fibonacci@ {k, k + 1}, {n, 0, 10}, {k, 0, n}] // Flatten (* Michael De Vlieger, Aug 18 2016 *)
    Module[{nn=20,f},f=Times@@@Partition[Fibonacci[Range[0,nn]],2,1];Table[Take[f,n],{n,nn}]]//Flatten (* Harvey P. Dale, Nov 26 2022 *)
  • PARI
    T(n,k)=fibonacci(k)*fibonacci(k+1) \\ Charles R Greathouse IV, Nov 07 2016
    
  • Sage
    flatten([[fibonacci(k)*fibonacci(k+1) for k in (0..n)] for n in (0..12)]) # G. C. Greubel, May 25 2021

Formula

T(n, k) = F(k)*F(k+1) with F(n) = A000045(n), for n>=0 and 0<=k<=n.
From Johannes W. Meijer, Jun 22 2015: (Start)
Kn1p(n) = Sum_{k=0..floor(n/2)} T(n-k+p-1, k+p-1), p >= 1.
Kn1p(n) = Kn11(n+2*p-2) - Sum_{k=0..p-2} T(n-k+2*p-2, k), p >= 2.
Kn2p(n) = Sum_{k=0..floor(n/2)} T(n-k+p-1, n-2*k), p >= 1.
Kn2p(n) = Kn21(n+2*p-2) - Sum_{k=0..p-2} T(n+k+p, n+2*k+2), p >= 2. (End)
G.f. as triangle: xy/((1-x)(1+xy)(1-3xy+x^2 y^2)). - Robert Israel, Sep 06 2015

A000392 Stirling numbers of second kind S(n,3).

Original entry on oeis.org

0, 0, 0, 1, 6, 25, 90, 301, 966, 3025, 9330, 28501, 86526, 261625, 788970, 2375101, 7141686, 21457825, 64439010, 193448101, 580606446, 1742343625, 5228079450, 15686335501, 47063200806, 141197991025, 423610750290, 1270865805301
Offset: 0

Views

Author

Keywords

Comments

Number of palindromic structures using exactly three different symbols; Mobius transform: A056279. - Marks R. Nester
Number of ways of placing n labeled balls into k=3 indistinguishable boxes. - Thomas Wieder, Nov 30 2004
With two leading zeros, this is the second binomial transform of cosh(x)-1 and the binomial transform of A000225 (with extra leading zero). - Paul Barry, May 13 2003
Let [m] denote the first m positive integers. Then a(n) is the number of functions f from [n] to [n+1] that satisfy (i) f(x) > x for all x, (ii) f(x) = n+1 for exactly 3 elements and (iii) f(f(x)) = n+1 for the remaining n-3 elements of [n]. For example, a(4)=6 since there are exactly 6 functions from {1,2,3,4} to {1,2,3,4,5} such that f(x) > x, f(x) = 5 for 3 elements and f(f(x)) = 5 for the remaining element. The functions are f1 = {(1,5), (2,5), (3,4), (4,5)}, f2 = {(1,5), (2,3), (3,5), (4,5)}, f3 = {(1,5), (2,4), (3,5), (4,5)}, f4 = {(1,2), (2,5), (3,5), (4,5)}, f5 = {(1,3), (2,5), (3,5), (4,5)}, f6 = {(1,4), (2,5), (3,5), (4,5)}. - Dennis P. Walsh, Feb 20 2007
Conjecture. Let S(1)={1} and, for n > 1, let S(n) be the smallest set containing x, 2x and 3x for each element x in S(n-1). Then a(n+2) is the sum of the elements in S(n). (It is easy to prove that the number of elements in S(n) is the n-th triangular number given by A001952.) See A122554 for a sequence defined in this way. - John W. Layman, Nov 21 2007; corrected (a(n) to a(n+2) due to offset change) by Fred Daniel Kline, Oct 02 2014
Let P(A) be the power set of an n-element set A. Then a(n+1) = the number of pairs of elements {x,y} of P(A) for which x and y are disjoint and for which x is not a subset of y and y is not a subset of x. Wieder calls these "disjoint strict 2-combinations". - Ross La Haye, Jan 11 2008; corrected by Ross La Haye, Oct 29 2008
Also, let P(A) be the power set of an n-element set A. Then a(n+2) = the number of pairs of elements {x,y} of P(A) for which either 0) x and y are disjoint and for which either x is a subset of y or y is a subset of x, or 1) x and y are disjoint and for which x is not a subset of y and y is not a subset of x, or 2) x and y are intersecting and for which either x is a proper subset of y or y is a proper subset of x. - Ross La Haye, Jan 11 2008
3 * a(n+1) = p(n+1) where p(x) is the unique degree-n polynomial such that p(k) = a(k+1) for k = 0, 1, ..., n. - Michael Somos, Apr 29 2012
John W. Layman's conjecture that a(n+2) is the sum of elements in S(n) follows from the identification of S(n) with the first n rows of A036561, whose row sums are A001047. - Fred Daniel Kline, Oct 02 2014
From M. Sinan Kul, Sep 08 2016: (Start)
Let m be equal to the product of n-1 distinct primes. Then a(n) is equal to the number of distinct fractions >=1 that may be created by dividing a divisor of m by another divisor. For example for m = 2*3*5 = 30, we would have the following 6 fractions: 6/5, 3/2, 5/3, 5/2, 10/3, 15/2.
Here finding the number of fractions would be equivalent to distributing n-1 balls (distinct primes) to two bins (numerator and denominator) with no empty bins which can be found by Stirling numbers of the second kind. So another definition for a(n) is a(n) = Sum_{i=2..n-1} Stirling2(i,2)*binomial(n-1,i).
Also for n > 0, a(n) = (d(m^2)+1)/2 - d(m) where m is equal to the product of n-1 distinct primes. Example for a(5): m = 2*3*5*7 = 210 (product of four distinct primes) so a(5) = (d(210^2)+1)/2 - d(210) = 41 - 16 = 25. (End)
6*a(n) is the number of ternary strings of length n that contain at least one of each of the 3 symbols on which they are defined. For example, for n=4, the strings are the 12 permutations of 0012, the 12 permutations of 0112, and the 12 permutations of 0122. - Enrique Navarrete, Aug 23 2021
A simpler form of La Haye's first comment is: a(n+1) is the number of ways we can form disjoint unions of two nonempty subsets of [n] (see example below). Cf. A001047 for the requirement that the union contains n. - Enrique Navarrete, Aug 24 2021
As partial sums of the Nicomachus triangle's rows and the differences of the powers of 3 and 2 (A001047), each iteration corresponds to two figurate variations of the Sierpinski triangle (3^n) with cross-correlation to the Nicomachus triangle, see illustrations in links. The Sierpinski half-hexagons of (A001047) stack and conform to the footprint of 2^n - 1 triangular numbers. The 3^n Sierpinski triangle minus its 2^n bottom row, also correlates to the Nicomachus triangle according to each Sierpinski triangular sub-row. - John Elias, Oct 04 2021

Examples

			a(4) = 6. Let denote Z[i] the i-th labeled element = "ball". Then one has for n=4 six different ways to fill sets = "boxes" with the labeled elements:
Set(Set(Z[3], Z[4]), Set(Z[1]), Set(Z[2])), Set(Set(Z[3], Z[1]), Set(Z[4]), Set(Z[2])), Set(Set(Z[4], Z[1]), Set(Z[3]), Set(Z[2])), Set(Set(Z[4]), Set(Z[1]), Set(Z[3], Z[2])), Set(Set(Z[3]), Set(Z[1], Z[2]), Set(Z[4])), Set(Set(Z[3]), Set(Z[1]), Set(Z[4], Z[2])).
G.f. = x^3 + 6*x^4 + 25*x^5 + 90*x^6 + 301*x^7 + 966*x^8 + 3025*x^9 + ...
For example, for n=3, a(4)=6 since the disjoint unions are: {1}U{2}, {1}U{3}, {1}U{2,3}, {2}U{3}, {2}U{1,3}, and {1,2}U{3}. - _Enrique Navarrete_, Aug 24 2021
		

References

  • M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964 (and various reprintings), p. 835.
  • F. N. David, M. G. Kendall and D. E. Barton, Symmetric Function and Allied Tables, Cambridge, 1966, p. 223.
  • M. R. Nester (1999). Mathematical investigations of some plant interaction designs. PhD Thesis. University of Queensland, Brisbane, Australia. [See A056391 for pdf file of Chap. 2]
  • 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

Programs

  • GAP
    List([0..400], n->Stirling2(n,3)); # Muniru A Asiru, Feb 04 2018
  • Maple
    A000392 := n -> 9/2*3^n-4*2^n+1/2;  [ seq(9/2*3^n-4*2^n+1/2,n=0..30) ]; # Thomas Wieder
    A000392:=-1/(z-1)/(3*z-1)/(2*z-1); # Simon Plouffe in his 1992 dissertation
  • Mathematica
    StirlingS2[Range[0,30],3] (* Harvey P. Dale, Dec 29 2011 *)
  • PARI
    {a(n) = 3^(n-1) / 2 - 2^(n-1) + 1/2};
    
  • Sage
    [stirling_number2(i,3) for i in (0..40)] # Zerinvary Lajos, Jun 26 2008
    

Formula

G.f.: x^3/((1-x)*(1-2*x)*(1-3*x)).
E.g.f.: ((exp(x) - 1)^3) / 3!.
Recurrence: a(n+3) = 6*a(n+2) - 11*a(n+1) + 6*a(n), a(3) = 1, a(4) = 6, a(5) = 25. - Thomas Wieder, Nov 30 2004
With offset 0, this is 9*3^n/2 - 4*2^n + 1/2, the partial sums of 3*3^n - 2*2^n = A001047(n+1). - Paul Barry, Jun 26 2003
a(n) = (1 + 3^(n-1) - 2^n)/2, n > 0. - Dennis P. Walsh, Feb 20 2007
For n >= 3, a(n) = 3*a(n-1) + 2^(n-2) - 1. - Geoffrey Critzer, Mar 03 2009
a(n) = 5*a(n-1) - 6*a(n-2) + 1, for n > 3. - Vincenzo Librandi Nov 25 2010
a(n) = det(|s(i+3,j+2)|, 1 <= i,j <= n-3), where s(n,k) are Stirling numbers of the first kind. - Mircea Merca, Apr 06 2013
G.f.: x^3 + 12*x^4/(G(0)-12*x), where G(k) = x + 1 + 9*(3*x+1)*3^k - 8*(2*x+1)*2^k - x*(9*3^k+1-8*2^k)*(81*3^k+1-32*2^k)/G(k+1); (continued fraction). - Sergei N. Gladkovskii, Feb 01 2014
a(n + 2) = (1 - 2^(2 + n) + 3^(1 + n))/2 for n > 0. - Fred Daniel Kline, Oct 02 2014
For n > 0, a(n) = (1/2) * Sum_{k=1..n-1} Sum_{i=1..n-1} C(n-k-1,i) * C(n-1,k). - Wesley Ivan Hurt, Sep 22 2017
a(n) = Sum_{k=0..n-3} 2^(k-1)*(3^(n-2-k) - 1). - J. M. Bergot, Feb 05 2018

Extensions

Offset changed by N. J. A. Sloane, Feb 08 2008

A099884 XOR difference triangle of the powers of 2, read by rows; Square array A(row,col): A(0,col) = 2^col, A(row,col) = A048724(A(row-1, col)) for row > 0, read by descending antidiagonals.

Original entry on oeis.org

1, 2, 3, 4, 6, 5, 8, 12, 10, 15, 16, 24, 20, 30, 17, 32, 48, 40, 60, 34, 51, 64, 96, 80, 120, 68, 102, 85, 128, 192, 160, 240, 136, 204, 170, 255, 256, 384, 320, 480, 272, 408, 340, 510, 257, 512, 768, 640, 960, 544, 816, 680, 1020, 514, 771, 1024, 1536, 1280, 1920
Offset: 0

Views

Author

Paul D. Hanna, Oct 28 2004

Keywords

Comments

Define an "XOR difference triangle" for a sequence A by the following process. Start with A in the leftmost column. Generate the next column by performing the XOR operation between adjacent terms of the prior column. Repeat this process to generate the XOR difference triangle for A. Further, we define the "XOR BINOMIAL transform" of A as the main diagonal in the XOR difference triangle for A. The XOR BINOMIAL transform is its self-inverse. Let a sequence B be the XOR BINOMIAL transform of A, then we may express B by: B(n) = SumXOR_{k=0..n} A047999(n,k)*A(k), which is equivalent to: B(n) = (C(n,0)mod 2)*A(0) XOR (C(n,1)mod 2)*A(1) XOR (C(n,2)mod 2)*A(2) XOR ... XOR (X(n,n)mod 2)*A(n), where the coefficients are C(n,k)(mod 2) = A047999(n,k).
This sequence is a rearrangement of the numbers which are 2^k times distinct Fermat numbers (numbers of the form 2^(2^m) + 1). This matches the sizes of polygons constructible with compass and straightedge (A003401) up to 2^32+1, which is the first nonprime Fermat number. - Franklin T. Adams-Watters, Jun 16 2006

Examples

			The main diagonal equals A001317 (Pascal's triangle mod 2 in decimal):
{1,3,5,15,17,51,85,255,257,771,1285,3855,...}, and defines the XOR BINOMIAL transform of the powers of 2.
Rows begin:
  1;
  2, 3;
  4, 6, 5;
  8, 12, 10, 15;
  16, 24, 20, 30, 17;
  32, 48, 40, 60, 34, 51;
  64, 96, 80, 120, 68, 102, 85;
  128, 192, 160, 240, 136, 204, 170, 255;
  256, 384, 320, 480, 272, 408, 340, 510, 257;
  512, 768, 640, 960, 544, 816, 680, 1020, 514, 771;
  1024, 1536, 1280, 1920, 1088, 1632, 1360, 2040, 1028, 1542, 1285;
  2048, 3072, 2560, 3840, 2176, 3264, 2720, 4080, 2056, 3084, 2570, 3855;
  ...
From _Antti Karttunen_, Sep 19 2016: (Start)
Viewed as a square array, the top left corner looks like this:
     1,    2,     4,     8,    16,     32,     64,    128
     3,    6,    12,    24,    48,     96,    192,    384
     5,   10,    20,    40,    80,    160,    320,    640
    15,   30,    60,   120,   240,    480,    960,   1920
    17,   34,    68,   136,   272,    544,   1088,   2176
    51,  102,   204,   408,   816,   1632,   3264,   6528
    85,  170,   340,   680,  1360,   2720,   5440,  10880
   255,  510,  1020,  2040,  4080,   8160,  16320,  32640
   257,  514,  1028,  2056,  4112,   8224,  16448,  32896
   771, 1542,  3084,  6168, 12336,  24672,  49344,  98688
  1285, 2570,  5140, 10280, 20560,  41120,  82240, 164480
  3855, 7710, 15420, 30840, 61680, 123360, 246720, 493440
  4369, 8738, 17476, 34952, 69904, 139808, 279616, 559232
  ...
(End)
The square array shown above can be viewed as a subtable of a multiplication table with particular relevance to the carryless multiplication defined by A048720, as the first column gives the A048720 powers of 3 (and the first row gives powers of 2, which are the same as in standard arithmetic). - _Peter Munn_, Jan 13 2020
		

Crossrefs

Essentially GF(2)[X] analog of table A036561. - Antti Karttunen, Jan 18 2020
Cf. A047999, A158875 (row sums).
Cf. A000079 (first column of triangular table, the topmost row of square array).
Cf. A001317 (the rightmost diagonal of triangular table, the leftmost column of square array).
Cf. A099885, A117998 (central diagonals).
Cf. A276618 (transpose), A091202, A193231.

Programs

  • Mathematica
    a[n_]:= Sum[Mod[Binomial[n, i], 2]*2^i, {i, 0, n}]; T[n_, k_]:=2^(n - k)a[k]; Table[T[n, k], {n, 0, 20}, {k, 0, n}] // Flatten (* Indranil Ghosh, Apr 11 2017 *)
  • PARI
    {T(n,k)=local(B);B=0;for(i=0,k,B=bitxor(B,binomial(k,i)%2*2^(n-i)));B}
    for(n=0,10,for(k=0,n,print1(T(n,k),", "));print(""))
    
  • Python
    from sympy import binomial
    def a(n):
        return sum((binomial(n, i)%2)*2**i for i in range(n + 1))
    def T(n, k): return 2**(n - k)*a(k)
    for n in range(21): print([T(n, k) for k in range(n + 1)]) # Indranil Ghosh, Apr 11 2017
  • Scheme
    (define (A099884 n) (A099884bi (A002262 n) (A025581 n)))
    ;; Then use either this recurrence:
    (define (A099884bi row col) (if (zero? row) (A000079 col) (A048724 (A099884bi (- row 1) col))))
    ;; or this one:
    (define (A099884bi row col) (if (zero? col) (A001317 row) (* 2 (A099884bi row (- col 1)))))
    ;; Antti Karttunen, Sep 19 2016
    

Formula

T(n, k) = 2^(n-k)*A001317(k). T(n, n) = A001317(n) = SumXOR_{k=0..n} A047999(n, k)*2^k, where SumXOR is the analog of summation under the binary XOR operation.
From Antti Karttunen, Sep 19 2016: (Start)
When viewed as a square array A(row,col), with row >= 0, col >= 0, the following recurrences and formulas are valid:
A(0,col) = A000079(col), for row > 0, A(row,col) = A048724(A(row-1, col)).
A(row,0) = A001317(row), for col > 0, A(row,col) = 2*A(row,col-1).
A(row,col) = A248663(A066117(row+1,col+1)) = A048675(A255483(row,col+1)).
(End)
With the definitions from Antti Karttunen above, A(row+1, col) = A048720(3, A(row, col)). - Peter Munn, Jan 13 2020
A(n,k) = A193231(A(k,n)) = A091202(A036561(n,k)). - Antti Karttunen, Jan 18 2020

Extensions

Square array interpretation added as a second, alternative description by Antti Karttunen, Sep 19 2016

A004197 Triangle read by rows. T(n, k) = n - k if n - k < k, otherwise k.

Original entry on oeis.org

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

Views

Author

Keywords

Comments

Table of min(x,y), where (x,y) = (0,0),(0,1),(1,0),(0,2),(1,1),(2,0),...
Highest power of 6 that divides A036561. - Fred Daniel Kline, May 29 2012
Triangle T(n,k) read by rows: T(n,k) = min(k,n-k). - Philippe Deléham, Feb 25 2014

Examples

			From _Philippe Deléham_, Feb 25 2014: (Start)
Top left corner of table:
  0 0 0 0
  0 1 1 1
  0 1 2 2
  0 1 2 3
Triangle T(n,k) begins:
  0;
  0, 0;
  0, 1, 0;
  0, 1, 1, 0;
  0, 1, 2, 1, 0;
  0, 1, 2, 2, 1, 0;
  0, 1, 2, 3, 2, 1, 0;
  0, 1, 2, 3, 3, 2, 1, 0;
  0, 1, 2, 3, 4, 3, 2, 1, 0;
  0, 1, 2, 3, 4, 4, 3, 2, 1, 0;
  0, 1, 2, 3, 4, 5, 4, 3, 2, 1, 0;
  0, 1, 2, 3, 4, 5, 5, 4, 3, 2, 1, 0;
  0, 1, 2, 3, 4, 5, 6, 5, 4, 3, 2, 1, 0;
  0, 1, 2, 3, 4, 5, 6, 6, 5, 4, 3, 2, 1, 0;
  0, 1, 2, 3, 4, 5, 6, 7, 6, 5, 4, 3, 2, 1, 0;
  0, 1, 2, 3, 4, 5, 6, 7, 7, 6, 5, 4, 3, 2, 1, 0;
  ... (End)
		

Crossrefs

Similar to but strictly different from A087062 and A261684.
Row sums give A002620. - Reinhard Zumkeller, Jul 27 2005
Positions of zero are given in A117142. - Ridouane Oudra, Apr 30 2019

Programs

  • Haskell
    a004197 n k = a004197_tabl !! n !! k
    a004197_tabl = map a004197_row [0..]
    a004197_row n = hs ++ drop (1 - n `mod` 2) (reverse hs)
       where hs = [0..n `div` 2]
    -- Reinhard Zumkeller, Aug 14 2011
    
  • Maple
    T := (n, k) -> if n - k < k then n - k else k fi:
    for n from 0 to 9 do seq(T(n, k), k=0..n) od; # Peter Luschny, May 07 2023
  • Mathematica
    Flatten[Table[IntegerExponent[2^(n - k) 3^k, 6], {n, 0, 20}, {k, 0, n}]] (* Fred Daniel Kline, May 29 2012 *)
  • PARI
    T(x,y)=min(x,y) \\ Charles R Greathouse IV, Feb 07 2017

Formula

a(n) = A003983(n) - 1.
G.f.: x*y/((1-x)*(1-y)*(1-x*y)). - Franklin T. Adams-Watters, Feb 06 2006
2^T(n,k) = A144464(n,k), 3^T(n,k) = A152714(n,k), 4^T(n,k) = A152716(n,k), 5^T(n,k) = A152717(n,k). - Philippe Deléham, Feb 25 2014
a(n) = (1/2)*(t - 1 - abs(t^2 - 2*n - 1)), where t = floor(sqrt(2*n+1)+1/2). - Ridouane Oudra, May 03 2019

Extensions

Mathematica program fixed by Harvey P. Dale, Nov 26 2020
Name edited by Peter Luschny, May 07 2023
Showing 1-10 of 35 results. Next