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

A000930 Narayana's cows sequence: a(0) = a(1) = a(2) = 1; thereafter a(n) = a(n-1) + a(n-3).

Original entry on oeis.org

1, 1, 1, 2, 3, 4, 6, 9, 13, 19, 28, 41, 60, 88, 129, 189, 277, 406, 595, 872, 1278, 1873, 2745, 4023, 5896, 8641, 12664, 18560, 27201, 39865, 58425, 85626, 125491, 183916, 269542, 395033, 578949, 848491, 1243524, 1822473, 2670964, 3914488, 5736961, 8407925
Offset: 0

Views

Author

Keywords

Comments

Named after a 14th-century Indian mathematician. [The sequence first appeared in the book "Ganita Kaumudi" (1356) by the Indian mathematician Narayana Pandita (c. 1340 - c. 1400). - Amiram Eldar, Apr 15 2021]
Number of compositions of n into parts 1 and 3. - Joerg Arndt, Jun 25 2011
A Lamé sequence of higher order.
Could have begun 1,0,0,1,1,1,2,3,4,6,9,... (A078012) but that would spoil many nice properties.
Number of tilings of a 3 X n rectangle with straight trominoes.
Number of ways to arrange n-1 tatami mats in a 2 X (n-1) room such that no 4 meet at a point. For example, there are 6 ways to cover a 2 X 5 room, described by 11111, 2111, 1211, 1121, 1112, 212.
Equivalently, number of compositions (ordered partitions) of n-1 into parts 1 and 2 with no two 2's adjacent. E.g., there are 6 such ways to partition 5, namely 11111, 2111, 1211, 1121, 1112, 212, so a(6) = 6. [Minor edit by Keyang Li, Oct 10 2020]
This comment covers a family of sequences which satisfy a recurrence of the form a(n) = a(n-1) + a(n-m), with a(n) = 1 for n = 0...m-1. The generating function is 1/(1-x-x^m). Also a(n) = Sum_{i=0..floor(n/m)} binomial(n-(m-1)*i, i). This family of binomial summations or recurrences gives the number of ways to cover (without overlapping) a linear lattice of n sites with molecules that are m sites wide. Special case: m=1: A000079; m=4: A003269; m=5: A003520; m=6: A005708; m=7: A005709; m=8: A005710.
a(n+2) is the number of n-bit 0-1 sequences that avoid both 00 and 010. - David Callan, Mar 25 2004 [This can easily be proved by the Cluster Method - see for example the Noonan-Zeilberger article. - N. J. A. Sloane, Aug 29 2013]
a(n-4) is the number of n-bit sequences that start and end with 0 but avoid both 00 and 010. For n >= 6, such a sequence necessarily starts 011 and ends 110; deleting these 6 bits is a bijection to the preceding item. - David Callan, Mar 25 2004
Also number of compositions of n+1 into parts congruent to 1 mod m. Here m=3, A003269 for m=4, etc. - Vladeta Jovovic, Feb 09 2005
Row sums of Riordan array (1/(1-x^3), x/(1-x^3)). - Paul Barry, Feb 25 2005
Row sums of Riordan array (1,x(1+x^2)). - Paul Barry, Jan 12 2006
Starting with offset 1 = row sums of triangle A145580. - Gary W. Adamson, Oct 13 2008
Number of digits in A061582. - Dmitry Kamenetsky, Jan 17 2009
From Jon Perry, Nov 15 2010: (Start)
The family a(n) = a(n-1) + a(n-m) with a(n)=1 for n=0..m-1 can be generated by considering the sums (A102547):
1 1 1 1 1 1 1 1 1 1 1 1 1
1 2 3 4 5 6 7 8 9 10
1 3 6 10 15 21 28
1 4 10 20
1
------------------------------
1 1 1 2 3 4 6 9 13 19 28 41 60
with (in this case 3) leading zeros added to each row.
(End)
Number of pairs of rabbits existing at period n generated by 1 pair. All pairs become fertile after 3 periods and generate thereafter a new pair at all following periods. - Carmine Suriano, Mar 20 2011
The compositions of n in which each natural number is colored by one of p different colors are called p-colored compositions of n. For n>=3, 2*a(n-3) equals the number of 2-colored compositions of n with all parts >= 3, such that no adjacent parts have the same color. - Milan Janjic, Nov 27 2011
For n>=2, row sums of Pascal's triangle (A007318) with triplicated diagonals. - Vladimir Shevelev, Apr 12 2012
Pisano period lengths of the sequence read mod m, m >= 1: 1, 7, 8, 14, 31, 56, 57, 28, 24, 217, 60, 56, 168, ... (A271953) If m=3, for example, the remainder sequence becomes 1, 1, 1, 2, 0, 1, 0, 0, 1, 1, 1, 2, 0, 1, 0, 0, 1, 1, 1, 2, 0, 1, 0, 0, 1, 1, 1, 2, 0, 1, 0, 0, 1, 1, ... with a period of length 8. - R. J. Mathar, Oct 18 2012
Diagonal sums of triangle A011973. - John Molokach, Jul 06 2013
"In how many ways can a kangaroo jump through all points of the integer interval [1,n+1] starting at 1 and ending at n+1, while making hops that are restricted to {-1,1,2}? (The OGF is the rational function 1/(1 - z - z^3) corresponding to A000930.)" [Flajolet and Sedgewick, p. 373] - N. J. A. Sloane, Aug 29 2013
a(n) is the number of length n binary words in which the length of every maximal run of consecutive 0's is a multiple of 3. a(5) = 4 because we have: 00011, 10001, 11000, 11111. - Geoffrey Critzer, Jan 07 2014
a(n) is the top left entry of the n-th power of the 3X3 matrix [1, 0, 1; 1, 0, 0; 0, 1, 0] or of the 3 X 3 matrix [1, 1, 0; 0, 0, 1; 1, 0, 0]. - R. J. Mathar, Feb 03 2014
a(n-3) is the top left entry of the n-th power of any of the 3 X 3 matrices [0, 1, 0; 0, 1, 1; 1, 0, 0], [0, 0, 1; 1, 1, 0; 0, 1, 0], [0, 1, 0; 0, 0, 1; 1, 0, 1] or [0, 0, 1; 1, 0, 0; 0, 1, 1]. - R. J. Mathar, Feb 03 2014
Counts closed walks of length (n+3) on a unidirectional triangle, containing a loop at one of remaining vertices. - David Neil McGrath, Sep 15 2014
a(n+2) equals the number of binary words of length n, having at least two zeros between every two successive ones. - Milan Janjic, Feb 07 2015
a(n+1)/a(n) tends to x = 1.465571... (decimal expansion given in A092526) in the limit n -> infinity. This is the real solution of x^3 - x^2 -1 = 0. See also the formula by Benoit Cloitre, Nov 30 2002. - Wolfdieter Lang, Apr 24 2015
a(n+2) equals the number of subsets of {1,2,..,n} in which any two elements differ by at least 3. - Robert FERREOL, Feb 17 2016
Let T* be the infinite tree with root 0 generated by these rules: if p is in T*, then p+1 is in T* and x*p is in T*. Let g(n) be the set of nodes in the n-th generation, so that g(0) = {0}, g(1) = {1}, g(2) = {2,x}, g(3) = {3,2x,x+1,x^2}, etc. Let T(r) be the tree obtained by substituting r for x. If a positive integer N such that r = N^(1/3) is not an integer, then the number of (not necessarily distinct) integers in g(n) is A000930(n), for n >= 1. (See A274142.) - Clark Kimberling, Jun 13 2016
a(n-3) is the number of compositions of n excluding 1 and 2, n >= 3. - Gregory L. Simay, Jul 12 2016
Antidiagonal sums of array A277627. - Paul Curtz, May 16 2019
a(n+1) is the number of multus bitstrings of length n with no runs of 3 ones. - Steven Finch, Mar 25 2020
Suppose we have a(n) samples, exactly one of which is positive. Assume the cost for testing a mix of k samples is 3 if one of the samples is positive (but you will not know which sample was positive if you test more than 1) and 1 if none of the samples is positive. Then the cheapest strategy for finding the positive sample is to have a(n-3) undergo the first test and then continue with testing either a(n-4) if none were positive or with a(n-6) otherwise. The total cost of the tests will be n. - Ruediger Jehn, Dec 24 2020

Examples

			The number of compositions of 11 without any 1's and 2's is a(11-3) = a(8) = 13. The compositions are (11), (8,3), (3,8), (7,4), (4,7), (6,5), (5,6), (5,3,3), (3,5,3), (3,3,5), (4,4,3), (4,3,4), (3,4,4). - _Gregory L. Simay_, Jul 12 2016
The compositions from the above example may be mapped to the a(8) compositions of 8 into 1's and 3's using this (more generally applicable) method: replace all numbers greater than 3 with a 3 followed by 1's to make the same total, then remove the initial 3 from the composition. Maintaining the example's order, they become (1,1,1,1,1,1,1,1), (1,1,1,1,1,3), (3,1,1,1,1,1), (1,1,1,1,3,1), (1,3,1,1,1,1), (1,1,1,3,1,1), (1,1,3,1,1,1), (1,1,3,3), (3,1,1,3), (3,3,1,1), (1,3,1,3), (1,3,3,1), (3,1,3,1). - _Peter Munn_, May 31 2017
		

References

  • A. T. Benjamin and J. J. Quinn, Proofs that really count: the art of combinatorial proof, M.A.A., 2003, id. 8,80.
  • R. K. Guy, "Anyone for Twopins?" in D. A. Klarner, editor, The Mathematical Gardner. Prindle, Weber and Schmidt, Boston, 1981, pp. 2-15. [See p. 12, line 3]
  • H. Langman, Play Mathematics. Hafner, NY, 1962, p. 13.
  • David Sankoff and Lani Haque, Power Boosts for Cluster Tests, in Comparative Genomics, Lecture Notes in Computer Science, Volume 3678/2005, Springer-Verlag. - N. J. A. Sloane, Jul 09 2009
  • 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

For Lamé sequences of orders 1 through 9 see A000045, this sequence, and A017898 - A017904.
Essentially the same as A068921 and A078012.
See also A001609, A145580, A179070, A214551 (same rule except divide by GCD).
A271901 and A271953 give the period of this sequence mod n.
A120562 has the same recurrence for odd n.

Programs

  • GAP
    a:=[1,1,1];; for n in [4..50] do a[n]:=a[n-1]+a[n-3]; od; a; # Muniru A Asiru, Aug 13 2018
    
  • Haskell
    a000930 n = a000930_list !! n
    a000930_list = 1 : 1 : 1 : zipWith (+) a000930_list (drop 2 a000930_list)
    -- Reinhard Zumkeller, Sep 25 2011
    
  • Magma
    [1,1] cat [ n le 3 select n else Self(n-1)+Self(n-3): n in [1..50] ]; // Vincenzo Librandi, Apr 25 2015
    
  • Maple
    f := proc(r) local t1,i; t1 := []; for i from 1 to r do t1 := [op(t1),0]; od: for i from 1 to r+1 do t1 := [op(t1),1]; od: for i from 2*r+2 to 50 do t1 := [op(t1),t1[i-1]+t1[i-1-r]]; od: t1; end; # set r = order
    with(combstruct): SeqSetU := [S, {S=Sequence(U), U=Set(Z, card > 2)}, unlabeled]: seq(count(SeqSetU, size=j), j=3..40); # Zerinvary Lajos, Oct 10 2006
    A000930 := proc(n)
        add(binomial(n-2*k,k),k=0..floor(n/3)) ;
    end proc: # Zerinvary Lajos, Apr 03 2007
    a:= n-> (<<1|1|0>, <0|0|1>, <1|0|0>>^n)[1,1]:
    seq(a(n), n=0..50); # Alois P. Heinz, Jun 20 2008
  • Mathematica
    a[0] = 1; a[1] = a[2] = 1; a[n_] := a[n] = a[n - 1] + a[n - 3]; Table[ a[n], {n, 0, 40} ]
    CoefficientList[Series[1/(1 - x - x^3), {x, 0, 45}], x] (* Zerinvary Lajos, Mar 22 2007 *)
    LinearRecurrence[{1, 0, 1}, {1, 1, 1}, 80] (* Vladimir Joseph Stephan Orlovsky, Feb 11 2012 *)
    a[n_] := HypergeometricPFQ[{(1 - n)/3, (2 - n)/3, -n/3}, {(1 - n)/ 2, -n/2}, -27/4]; Table[a[n], {n, 0, 43}] (* Jean-François Alcover, Feb 26 2013 *)
    Table[-RootSum[1 + #^2 - #^3 &, 3 #^(n + 2) - 11 #^(n + 3) + 2 #^(n + 4) &]/31, {n, 20}] (* Eric W. Weisstein, Feb 14 2025 *)
  • Maxima
    makelist(sum(binomial(n-2*k,k),k,0,n/3),n,0,18); /* Emanuele Munarini, May 24 2011 */
    
  • PARI
    a(n)=polcoeff(exp(sum(m=1,n,((1+sqrt(1+4*x))^m + (1-sqrt(1+4*x))^m)*(x/2)^m/m)+x*O(x^n)),n) \\ Paul D. Hanna, Oct 08 2009
    
  • PARI
    x='x+O('x^66); Vec(1/(1-(x+x^3))) \\ Joerg Arndt, May 24 2011
    
  • PARI
    a(n)=([0,1,0;0,0,1;1,0,1]^n*[1;1;1])[1,1] \\ Charles R Greathouse IV, Feb 26 2017
    
  • Python
    from itertools import islice
    def A000930_gen(): # generator of terms
        blist = [1]*3
        while True:
            yield blist[0]
            blist = blist[1:]+[blist[0]+blist[2]]
    A000930_list = list(islice(A000930_gen(),30)) # Chai Wah Wu, Feb 04 2022
    
  • SageMath
    @CachedFunction
    def a(n): # A000930
        if (n<3): return 1
        else: return a(n-1) + a(n-3)
    [a(n) for n in (0..80)] # G. C. Greubel, Jul 29 2022

Formula

G.f.: 1/(1-x-x^3). - Simon Plouffe in his 1992 dissertation
a(n) = Sum_{i=0..floor(n/3)} binomial(n-2*i, i).
a(n) = a(n-2) + a(n-3) + a(n-4) for n>3.
a(n) = floor(d*c^n + 1/2) where c is the real root of x^3-x^2-1 and d is the real root of 31*x^3-31*x^2+9*x-1 (c = 1.465571... = A092526 and d = 0.611491991950812...). - Benoit Cloitre, Nov 30 2002
a(n) = Sum_{k=0..n} binomial(floor((n+2k-2)/3), k). - Paul Barry, Jul 06 2004
a(n) = Sum_{k=0..n} binomial(k, floor((n-k)/2))(1+(-1)^(n-k))/2. - Paul Barry, Jan 12 2006
a(n) = Sum_{k=0..n} binomial((n+2k)/3,(n-k)/3)*(2*cos(2*Pi*(n-k)/3)+1)/3. - Paul Barry, Dec 15 2006
a(n) = term (1,1) in matrix [1,1,0; 0,0,1; 1,0,0]^n. - Alois P. Heinz, Jun 20 2008
G.f.: exp( Sum_{n>=1} ((1+sqrt(1+4*x))^n + (1-sqrt(1+4*x))^n)*(x/2)^n/n ).
Logarithmic derivative equals A001609. - Paul D. Hanna, Oct 08 2009
a(n) = a(n-1) + a(n-2) - a(n-5) for n>4. - Paul Weisenhorn, Oct 28 2011
For n >= 2, a(2*n-1) = a(2*n-2)+a(2*n-4); a(2*n) = a(2*n-1)+a(2*n-3). - Vladimir Shevelev, Apr 12 2012
INVERT transform of (1,0,0,1,0,0,1,0,0,1,...) = (1, 1, 1, 2, 3, 4, 6, ...); but INVERT transform of (1,0,1,0,0,0,...) = (1, 1, 2, 3, 4, 6, ...). - Gary W. Adamson, Jul 05 2012
G.f.: 1/(G(0)-x) where G(k) = 1 - x^2/(1 - x^2/(x^2 - 1/G(k+1) )); (continued fraction). - Sergei N. Gladkovskii, Dec 16 2012
G.f.: 1 + x/(G(0)-x) where G(k) = 1 - x^2*(2*k^2 + 3*k +2) + x^2*(k+1)^2*(1 - x^2*(k^2 + 3*k +2))/G(k+1); (continued fraction). - Sergei N. Gladkovskii, Dec 27 2012
a(2*n) = A002478(n), a(2*n+1) = A141015(n+1), a(3*n) = A052544(n), a(3*n+1) = A124820(n), a(3*n+2) = A052529(n+1). - Johannes W. Meijer, Jul 21 2013, corrected by Greg Dresden, Jul 06 2020
G.f.: Q(0)/2, where Q(k) = 1 + 1/(1 - x*(4*k+1 + x^2)/( x*(4*k+3 + x^2) + 1/Q(k+1) )); (continued fraction). - Sergei N. Gladkovskii, Sep 08 2013
a(n) = v1*w1^n+v3*w2^n+v2*w3^n, where v1,2,3 are the roots of (-1+9*x-31*x^2+31*x^3): [v1=0.6114919920, v2=0.1942540040 - 0.1225496913*I, v3=conjugate(v2)] and w1,2,3 are the roots of (-1-x^2+x^3): [w1=1.4655712319, w2=-0.2327856159 - 0.7925519925*I, w3=conjugate(w2)]. - Gerry Martens, Jun 27 2015
a(n) = (6*A001609(n+3) + A001609(n-7))/31 for n>=7. - Areebah Mahdia, Jun 07 2020
a(n+6)^2 + a(n+1)^2 + a(n)^2 = a(n+5)^2 + a(n+4)^2 + 3*a(n+3)^2 + a(n+2)^2. - Greg Dresden, Jul 07 2021
a(n) = Sum_{i=(n-7)..(n-1)} a(i) / 2. - Jules Beauchamp, May 10 2025

Extensions

Name expanded by N. J. A. Sloane, Sep 07 2012

A175595 Square array A(n,t), n>=0, t>=0, read by antidiagonals: A(n,t) is the number of t-core partitions of n.

Original entry on oeis.org

1, 1, 1, 1, 0, 2, 1, 1, 0, 3, 1, 1, 0, 0, 5, 1, 1, 2, 1, 0, 7, 1, 1, 2, 0, 0, 0, 11, 1, 1, 2, 3, 2, 0, 0, 15, 1, 1, 2, 3, 1, 1, 1, 0, 22, 1, 1, 2, 3, 5, 3, 2, 0, 0, 30, 1, 1, 2, 3, 5, 2, 3, 0, 0, 0, 42, 1, 1, 2, 3, 5, 7, 6, 3, 1, 0, 0, 56, 1, 1, 2, 3, 5, 7, 5, 5, 4, 2, 1, 0, 77, 1, 1, 2, 3, 5, 7, 11, 9, 7, 4, 2, 0, 0, 101
Offset: 0

Views

Author

Alois P. Heinz, Dec 03 2010

Keywords

Comments

A partition of n is a t-core partition if none of the hook numbers associated to the Ferrers-Young diagram is a multiple of t. See Chen reference for definitions.

Examples

			A(4,3) = 2, because there are 2 partitions of 4 such that no hook number is a multiple of 3:
   (1)  2 | 4 1
       +1 | 2
       +1 | 1
   -------+-----
   (2)  3 | 4 2 1
       +1 | 1
Square array A(n,t) begins:
   1,  1,  1,  1,  1,  1,  1,  1,  ...
   1,  0,  1,  1,  1,  1,  1,  1,  ...
   2,  0,  0,  2,  2,  2,  2,  2,  ...
   3,  0,  1,  0,  3,  3,  3,  3,  ...
   5,  0,  0,  2,  1,  5,  5,  5,  ...
   7,  0,  0,  1,  3,  2,  7,  7,  ...
  11,  0,  1,  2,  3,  6,  5, 11,  ...
  15,  0,  0,  0,  3,  5,  9,  8,  ...
		

References

  • Garvan, F. G., A number-theoretic crank associated with open bosonic strings. In Number Theory and Cryptography (Sydney, 1989), 221-226, London Math. Soc. Lecture Note Ser., 154, Cambridge Univ. Press, Cambridge, 1990.
  • James, Gordon; and Kerber, Adalbert, The Representation Theory of the Symmetric Group. Addison-Wesley Publishing Co., Reading, Mass., 1981.

Crossrefs

Rows n=0-1 give A000012, A060576.
Diagonal gives A000094(n+1) for n>0.
Upper diagonal gives A000041.
Lower diagonal (conjectured) gives A086642 for n>0.

Programs

  • Maple
    with(numtheory):
    A:= proc(n, t) option remember; `if`(n=0, 1,
          add(add(`if`(t=0 or irem(d, t)=0, d-d*t, d),
                  d=divisors(j))*A(n-j, t), j=1..n)/n)
        end:
    seq(seq(A(n, d-n), n=0..d), d=0..14);
    (From N. J. A. Sloane, Jun 21 2011: to get M terms of the series for t-core partitions:)
    M:=60;
    f:=proc(t) global M; local q,i,t1;
    t1:=1;
    for i from 1 to M+1 do
    t1:=series(t1*(1-q^(i*t))^t,q,M);
    t1:=series(t1/(1-q^i),q,M);
    od;
    t1;
    end;
    # then for example seriestolist(f(5));
  • Mathematica
    n = 13; f[t_] = (1-x^(t*k))^t/(1-x^k); f[0] = 1/(1-x^k);
    s[t_] := CoefficientList[ Series[ Product[ f[t], {k, 1, n}], {x, 0, n}], x]; m = Table[ PadRight[ s[t], n+1], {t, 0, n}]; Flatten[ Table[ m[[j+1-k, k]], {j, n+1}, {k, j}]] (* Jean-François Alcover, Jul 25 2011, after g.f. *)

Formula

G.f. of column t: Product_{i>=1} (1-x^(t*i))^t/(1-x^i).
Column t is the Euler transform of period t sequence [1, .., 1, 1-t, ..].

Extensions

Additional references from N. J. A. Sloane, Jun 21 2011

A175788 Square array A(n,k), n>=0, k>=0, read by antidiagonals: A(n,k) is the number of partitions of n that do not contain k as a part.

Original entry on oeis.org

1, 1, 1, 1, 0, 2, 1, 1, 1, 3, 1, 1, 1, 1, 5, 1, 1, 2, 2, 2, 7, 1, 1, 2, 2, 3, 2, 11, 1, 1, 2, 3, 4, 4, 4, 15, 1, 1, 2, 3, 4, 5, 6, 4, 22, 1, 1, 2, 3, 5, 6, 8, 8, 7, 30, 1, 1, 2, 3, 5, 6, 9, 10, 11, 8, 42, 1, 1, 2, 3, 5, 7, 10, 12, 15, 15, 12, 56
Offset: 0

Views

Author

Alois P. Heinz, Dec 04 2010

Keywords

Examples

			Square array A(n,k) begins:
  1, 1, 1, 1, 1, 1, ...
  1, 0, 1, 1, 1, 1, ...
  2, 1, 1, 2, 2, 2, ...
  3, 1, 2, 2, 3, 3, ...
  5, 2, 3, 4, 4, 5, ...
  7, 2, 4, 5, 6, 6, ...
		

Crossrefs

Rows n=0-1 give: A000012, A060576.
Main diagonal gives A000065 (for n>0).

Programs

  • Maple
    A41:= n-> `if`(n<0, 0, combinat[numbpart](n)):
    A:= (n,k)-> A41(n) -`if`(k>0, A41(n-k), 0):
    seq(seq(A(n,d-n), n=0..d), d=0..11);
  • Mathematica
    A41[n_] := If[n<0, 0, PartitionsP[n]]; A[n_, k_] := A41[n]-If[k>0, A41[n-k], 0]; Table[A[n, d-n], {d, 0, 11}, {n, 0, d}] // Flatten (* Jean-François Alcover, Feb 18 2017, translated from Maple *)

Formula

G.f. of column 0: Product_{m>0} 1/(1-x^m).
G.f. of column k>0: (1-x^k) * Product_{m>0} 1/(1-x^m).
A(n,0) = A000041(n); A(n,k) = A000041(n) - A000041(n-k) for k>0.
For fixed k>0, A(n,k) ~ k*Pi * exp(sqrt(2*n/3)*Pi) / (12*sqrt(2)*n^(3/2)) * (1 - (3*sqrt(3/2)/Pi + Pi/(24*sqrt(6)) + k*Pi/(2*sqrt(6)))/sqrt(n) + (1/8 + 3*k/2 + 9/(2*Pi^2) + Pi^2/6912 + k*Pi^2/288 + k^2*Pi^2/36)/n). - Vaclav Kotesovec, Nov 04 2016

A060581 Number of homeomorphically irreducible general graphs on 6 labeled node and with n edges.

Original entry on oeis.org

1, 15, 81, 441, 2151, 9957, 43122, 174162, 666267, 2403987, 8183601, 26281065, 79660856, 228180456, 618992466, 1595081266, 3918506466, 9211519476, 20797923546, 45258309066, 95225448306, 194283668576, 385361919996
Offset: 0

Views

Author

Vladeta Jovovic, Apr 03 2001

Keywords

Comments

A homeomorphically irreducible general graph is a graph with multiple edges and loops and without nodes of degree 2.

References

  • I. P. Goulden and D. M. Jackson, Combinatorial Enumeration, Wiley, N.Y., 1983.

Crossrefs

Formula

G.f.: (6*x^30 - 30*x^29 - 90*x^28 + 898*x^27 - 5703*x^26 + 67854*x^25 - 552925*x^24 + 2795730*x^23 - 9663357*x^22 + 24476292*x^21 - 47540991*x^20 + 73129860*x^19 - 91373250*x^18 + 94675608*x^17 - 82549758*x^16 + 60794764*x^15 - 37293240*x^14 + 18277860*x^13 - 6426742*x^12 + 945252*x^11 + 680499*x^10 - 726250*x^9 + 423825*x^8 - 187536*x^7 + 66981*x^6 - 19092*x^5 + 4065*x^4 - 560*x^3 + 24*x^2 + 6*x - 1)/(x - 1)^21. E.g.f. for homeomorphically irreducible general graphs with n nodes and k edges is (1 + x*y)^( - 1/2)*exp( - x*y/2 + x^2*y^2/4)*Sum_{k >= 0} 1/(1 - x)^binomial(k + 1, 2)*exp( - x^2*y*k^2/(2*(1 + x*y)) - x^2*y*k/2)*y^k/k!.

A130102 E.g.f.: (e^x - x)^2.

Original entry on oeis.org

1, 0, 2, 2, 8, 22, 52, 114, 240, 494, 1004, 2026, 4072, 8166, 16356, 32738, 65504, 131038, 262108, 524250, 1048536, 2097110, 4194260, 8388562, 16777168, 33554382, 67108812, 134217674, 268435400, 536870854, 1073741764, 2147483586
Offset: 0

Views

Author

Paul Barry, May 07 2007

Keywords

Comments

a(n) is the number of length n binary sequences in which no symbol occurs exactly once. (The Rosenthal formula takes 2^n for the total number of binary sequences and subtracts n for each sequence of length n with a single 0 or 1.) - Geoffrey Critzer, Dec 03 2011
From Ambrosio Valencia-Romero, Mar 08 2022: (Start)
a(n), for n > 1, is the number of pure Nash equilibria in the symmetric n-player two-strategy normal-form unanimity game. Let i be a player in set N = {1, 2, 3, ..., n} and s(i) in set S = {0, 1} be i's strategy. Then i's payoff, u(i), in this game is given by:
u(i) = 1 if s(1) = s(2) = ... = s(n-1) = s(n); otherwise, u(i) = 0.
Only two of the a(n) pure equilibria in this unanimity game are strict: s = <0, 0, ..., 0, 0> and s = <1, 1, ..., 1, 1>; these are the diagonal collective strategies where all actors obtain the payoff u(i) = 1.
The other a(n)-2 pure equilibria are weak and produce an individual payoff of u(i) = 0; these correspond to the collective strategy outcomes where more than one and fewer than n-1 individual strategies differ. For instance, for n = 4, the a(4)-2 = 6 weak pure equilibria are <0, 0, 1, 1>, <0, 1, 0, 1>, <0, 1, 1, 0>, <1, 0, 0, 1>, <1, 0, 1, 0>, and <1, 1, 0, 0>. (End)

Examples

			a(4) = 8 because there are 8 sequences on {0,1} such that neither 0 nor 1 occurs exactly once: {0,0,0,0}, {0,0,1,1}, {0,1,0,1}, {0,1,1,0}, {1,0,0,1}, {1,0,1,0}, {1,1,0,0}, {1,1,1,1}. - _Geoffrey Critzer_, Dec 03 2011
		

Crossrefs

Programs

  • Magma
    I:=[1, 0, 2, 2, 8, 22]; [n le 6 select I[n] else 4*Self(n-1)-5*Self(n-2)+2*Self(n-3): n in [1..40]]; // Vincenzo Librandi, Jun 28 2012
  • Mathematica
    a=Exp[x]-x; Range[0,20]! CoefficientList[Series[a^2, {x,0,20}], x] (* Geoffrey Critzer, Dec 03 2011 *)
    CoefficientList[Series[1+2*x^2-2*x^3/((2*x-1)*(x-1)^2),{x,0,40}],x] (* Vincenzo Librandi, Jun 28 2012 *)

Formula

a(n) = 2^n - 2*n for n <> 2 (cf. A005803). - Rainer Rosenthal, Feb 14 2010.
E.g.f.: e^(2*x) - 2*x*e^x + x^2.
a(n) = Sum_{k=0..n} binomial(n,k)*A060576(k)*A060576(n-k).
G.f. 1 + 2*x^2 - 2*x^3/((2*x - 1)*(x - 1)^2). - R. J. Mathar, Dec 04 2011

A332977 Triangle T(n,k) read by rows in which n-th row lists in increasing order all integers m satisfying Omega(m) + pi(gpf(m)) - [m<>1] = n; n>=0, 1<=k<=A011782(n).

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 8, 9, 7, 10, 12, 15, 16, 18, 25, 27, 11, 14, 20, 21, 24, 30, 32, 35, 36, 45, 49, 50, 54, 75, 81, 125, 13, 22, 28, 33, 40, 42, 48, 55, 60, 63, 64, 70, 72, 77, 90, 98, 100, 105, 108, 121, 135, 147, 150, 162, 175, 225, 243, 245, 250, 343, 375, 625
Offset: 0

Views

Author

Alois P. Heinz, Mar 04 2020

Keywords

Comments

Integer m > 0 is listed in row n if the index of the largest prime factor of m (or 0 for empty prime factor set) plus the cardinality of the other prime factors of m (counted with multiplicity) equals n.
Row n+k-1 contains prime(n)^k (for all n, k >= 1).
The concatenation of all rows (with offset 1) gives a permutation of the natural numbers A000027 with fixed points 1, 2, 3, 4, 5, 6, 10, ... and inverse permutation A332990.
This is a variant with sorted rows of A005940 (offset differs) or A163511.

Examples

			Triangle T(n,k) begins:
   1;
   2;
   3,  4;
   5,  6,  8,  9;
   7, 10, 12, 15, 16, 18, 25, 27;
  11, 14, 20, 21, 24, 30, 32, 35, 36, 45, 49, 50, 54, 75, 81, 125;
  ...
		

Crossrefs

Columns k=1-2 give: A008578(n+1), A100484(n-1) for n>1.
Last elements of rows give A332979.
Row sums give A252737.
Product of row elements give A252738.
Row lengths give A011782.
Cf. A000027, A000040, A000720 (pi), A001222 (Omega), A006530 (GPF), A060576 ([n<>1]), A061395 (pi(gpf(n))), A215366, A332990.

Programs

  • Maple
    b:= proc(n, i) option remember; `if`(n=0, [1], sort([seq(map(x-> x*
          ithprime(j), b(n-`if`(i=0, j, 1), j))[], j=1..`if`(i=0, n, i))]))
        end:
    T:= n-> b(n, 0)[]:
    seq(T(n), n=0..7);
  • Mathematica
    b[n_, i_] := b[n, i] = If[n == 0, {1}, Sort[Flatten[Table[#*
        Prime[j]& /@ b[n-If[i == 0, j, 1], j], {j, 1, If[i == 0, n, i]}]]]];
    T[n_] := b[n, 0];
    T /@ Range[0, 7] // Flatten (* Jean-François Alcover, Mar 30 2021, after Alois P. Heinz *)

A332979 Largest integer m satisfying Omega(m) + pi(gpf(m)) - [m<>1] = n.

Original entry on oeis.org

1, 2, 4, 9, 27, 125, 625, 3125, 16807, 161051, 1771561, 19487171, 214358881, 2357947691, 25937424601, 285311670611, 3138428376721, 34522712143931, 582622237229761, 9904578032905937, 168377826559400929, 2862423051509815793, 48661191875666868481
Offset: 0

Views

Author

Alois P. Heinz, Mar 04 2020

Keywords

Comments

From Michael De Vlieger, Aug 22 2022: (Start)
Subset of A000961.
Maxima of row n of A005940.
Maxima of row n of A182944 and row n of A182945. (End)

Crossrefs

Cf. A000720 (pi), A001222 (Omega), A006530 (GPF), A011782, A060576 ([n<>1]), A061395 (pi(gpf(n))), A332977.

Programs

  • Maple
    b:= proc(n, i) option remember; `if`(n=0, 1, max(seq(b(n-
         `if`(i=0, j, 1), j)*ithprime(j), j=1..`if`(i=0, n, i))))
        end:
    a:= n-> b(n, 0):
    seq(a(n), n=0..23);
  • Mathematica
    b[n_, i_] := b[n, i] = If[n == 0, 1, Max[Table[
         b[n - If[i == 0, j, 1], j] Prime[j], {j, 1, If[i == 0, n, i]}]]];
    a[n_] := b[n, 0];
    a /@ Range[0, 23] (* Jean-François Alcover, May 03 2021, after Alois P. Heinz *)
    (* Second program: extract data from the concise a-file of 10000 terms: *)
    With[{nn = 23 (* set nn <= 10000 as desired *)}, Prime[#1]^#2 & @@ # & /@ Map[ToExpression /@ {StringTrim[#1, "p"], #2} & @@ StringSplit[#, "^"] &, Import["https://oeis.org/A332979/a332979.txt", "Data"][[1 ;; nn, -1]] ] ] (* Michael De Vlieger, Aug 22 2022 *)

Formula

a(n) = A332977(A011782(n)).

A060577 Number of homeomorphically irreducible general graphs on 2 labeled nodes and with n edges.

Original entry on oeis.org

1, 1, 4, 6, 11, 17, 24, 32, 41, 51, 62, 74, 87, 101, 116, 132, 149, 167, 186, 206, 227, 249, 272, 296, 321, 347, 374, 402, 431, 461, 492, 524, 557, 591, 626, 662, 699, 737, 776, 816, 857, 899, 942, 986, 1031, 1077, 1124, 1172, 1221, 1271, 1322, 1374, 1427
Offset: 0

Views

Author

Vladeta Jovovic, Apr 04 2001

Keywords

Comments

A homeomorphically irreducible general graph is a graph with multiple edges and loops and without nodes of degree 2.

References

  • I. P. Goulden and D. M. Jackson, Combinatorial Enumeration, Wiley, N.Y., 1983.

Crossrefs

Programs

  • Maple
    gf := (2*x^5 - 4*x^4 + 4*x^3 - 4*x^2 + 2*x - 1)/(x - 1)^3: s := series(gf, x, 100): for i from 0 to 100 do printf(`%d,`,coeff(s,x,i)) od:
  • Mathematica
    Join[{1, 1, 4}, Table[n (n + 3)/2 - 3, {n, 3, 60}]] (* Bruno Berselli, Aug 20 2015 *)

Formula

G.f.: (2*x^5 - 4*x^4 + 4*x^3 - 4*x^2 + 2*x - 1)/(x - 1)^3.
E.g.f. for homeomorphically irreducible general graphs with n nodes and k edges is (1 + x*y)^( - 1/2)*exp( - x*y/2 + x^2*y^2/4)*Sum_{k >= 0} 1/(1 - x)^binomial(k + 1, 2)*exp( - x^2*y*k^2/(2*(1 + x*y)) - x^2*y*k/2)*y^k/k!.
From Marco Ripà, Aug 20 2015: (Start)
a(n) = ceiling( (1/2)*(3*n^2 - 10*n + 9)/(n - 2) ) + floor( (3/2)*(n-1)^2 ) - n^2 + 3*n - 3 with n > 2, a(0) = a(1) = 1, a(2) = 4.
a(n) = n*(n + 3)/2 - 3 for n > 2.
a(n) = A046691(n-1) for n > 2. (End)

Extensions

More terms from James Sellers, Apr 04 2001

A271573 Numerator of (0 followed by A005126(n)= 2, 4, 7, ...)/2^n.

Original entry on oeis.org

0, 1, 1, 7, 3, 21, 19, 71, 17, 265, 261, 1035, 515, 4109, 4103, 16399, 2049, 65553, 65545, 262163, 131077, 1048597, 1048587, 4194327, 1048579, 16777241, 16777229, 67108891, 33554439, 268435485, 268435471, 1073741855, 67108865, 4294967329, 4294967313
Offset: 0

Views

Author

Paul Curtz, Apr 10 2016

Keywords

Comments

Reduced fractions: f(n) = 0, 1, 1, 7/8, 3/4, 21/32, 19/32, 71/128, 17/32, 265/512, 261/512, ... .
f(n) is an autosequence of the first kind.

Examples

			a(0), a(1), a(2), a(3), a(4), are the numerators of reduced fractions 0/1, 2/2, 4/4, 7/8, 12/16, ... .
		

Crossrefs

Cf. A000004, A000079, A005126, A006519, A060576(n+1), A075101, A198631, A279635 (denominator).

Programs

  • Magma
    [0] cat [Numerator((2^(n-1)+n)/2^n): n in [1..40]]; // Vincenzo Librandi, Oct 13 2017
  • Mathematica
    Prepend[Table[Numerator[(2^n + n + 1)/2^(n + 1)], {n, 0, 100}], 0] (* Robert Price, Apr 10 2016 *)
    (* Computation from Oresme numbers n/2^n: *) a[n_] := Numerator[n/2^n + If[n < 2, 0, 1]/2]; (* Jean-François Alcover, Apr 28 2016, after Paul Curtz *)
  • PARI
    a(n) = if(n==0, 0, numerator((2^(n-1)+n)/2^n)); \\ Altug Alkan, Apr 10 2016
    

Formula

a(n) = numerator(n/2^n + (if n<2 0 else 1)/2), a formula using Oresme numbers n/2^n. - Jean-François Alcover, Apr 28 2016 after Paul Curtz

A277627 Square array read by antidiagonals downwards: T(n,k), n>=0, k>=0, in which column 0 is equal to A057427: 0, 1, 1, 1, ..., and for k > 0 column k lists two zeros followed by the partial sums of column k-1.

Original entry on oeis.org

0, 0, 1, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 1, 0, 0, 0, 0, 2, 1, 0, 0, 0, 0, 0, 3, 1, 0, 0, 0, 0, 0, 1, 4, 1, 0, 0, 0, 0, 0, 0, 3, 5, 1, 0, 0, 0, 0, 0, 0, 0, 6, 6, 1, 0, 0, 0, 0, 0, 0, 0, 1, 10, 7, 1, 0, 0, 0, 0, 0, 0, 0, 0, 4, 15, 8, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 10, 21, 9, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 20, 28, 10, 1
Offset: 0

Views

Author

Paul Curtz, Oct 24 2016

Keywords

Comments

In other words, for n > 0 the column k lists 2*k+1 zeros together with the partial sums of the positive terms of column k-1. - Omar E. Pol, Oct 25 2016
Comments from the author:
1) ZSPEC =
0, 0, 0, 0, 0, 0, 0, 0, ...
1, 0, 0, 0, 0, 0, 0, 0, ...
1, 0, 0, 0, 0, 0, 0, 0, ...
1, 1, 0, 0, 0, 0, 0, 0, ...
1, 2, 0, 0, 0, 0, 0, 0, ...
1, 3, 1, 0, 0, 0, 0, 0, ...
1, 4, 3, 0, 0, 0, 0, 0, ...
1, 5, 6, 1, 0, 0, 0, 0, ...
etc.
The columns are the autosequences of the first kind of the title (column 1: 0, 0, followed by A001477(n); column 2: 0, 0, 0, 0, followed by A000217(n), etc) .
The positive terms are the Pascal triangle written by diagonals (A011973).
First column: A060576(n+1). Or A057427(n), n>-1, thanks to Omar E. Pol.
Row sums: A000045(n), autosequence of the first kind.
Alternated row sums and subtractions: 0, 1, 1, 0, -1, -1, 0 = A128834(n), autosequence of the first kind.
Antidiagonal sums: 0, 1, 1, 1, 2, 3, 4, 6, ... = A078012(n+2).
Application.
Numbers in triangle leading to the Genocchi numbers -A226158(n).
We multiply the columns of ZSPEC by d(n) = 1, -1, 2, -8, 56, -608, ... from A005439.
Hence, with only the first 0,
0,
1,
1,
1, -1,
1, -2,
1, -3, 2,
1, -4, 6,
1, -5, 12, -8,
1, -6, 20, -32,
1, -7, 30, -80, 56,
1, -8, 42, -160, 280,
etc.
The row sums is -A226158(n).
2) Now consider the case of the autosequences of the second kind.
First step.
2, 1, 1, 1, 1, 1, ... = A054977(n)
0, 0, 2, 3, 4, 5, 6, 7, ... = A199969(n) with offset 0
0, 0, 0, 0, 2, 5, 9, 14, 20, 27, ... see A000096
etc.
The positive terms are ASPEC in A191302. By triangle, they are either A029653(n) with A029653(0) = 2 instead of 1 or A029635(n).
Second step. YSPEC =
2, 0, 0, 0, 0, 0, ...
1, 0, 0, 0, 0, 0, ...
1, 2, 0, 0, 0, 0, ...
1, 3, 0, 0, 0, 0, ...
1, 4, 2, 0, 0, 0, ...
1, 5, 5, 0, 0, 0, ...
1, 6, 9, 2, 0, 0, ...
1, 7, 14, 7, 0, 0, ...
etc.
Diagonals by triangle: A029635(n).
This is the companion to ZSPEC.
Row sums: A000032(n), autosequence of the second kind.
Alternated row sums and subtractions: period 6 repeat 2, 1, -1, -2, -1, 1 = A087204(n), autosequence of the second kind.
Application.
Numbers in triangle leading to A230324(n), a companion to -A226158(n).
We multiply the columns of YSPEC by d(n) 1, -1, 2, -8, 56, ... (see above).
Hence, without zeros:
2,
1,
1, -2,
1, -3,
1, -4, 4,
1, -5, 10,
1, -6, 18, -16,
1, -7, 28, -56,
1, -8, 40, -128, 112,
1, -9, 54, -240, 504,
etc.
The row sum is A230324(n).

Crossrefs

Cf. A011973 (without 0's), A007318 (Pascal's triangle).
Cf. A000045 (row sums), A078012 (antidiagonal sums).
Columns: A060576 or A057427 (k=0), A001477 (k=1), A000217 (k=2).

Programs

  • Mathematica
    kMax = 13; col[0] = Join[{0}, Array[1&, kMax]]; col[k_] := col[k] = Join[{0, 0}, col[k-1][[1 ;; -3]] // Accumulate]; T[n_, k_] := col[k][[n+1]]; Table[T[n-k, k], {n, 0, kMax}, {k, n, 0, -1}] // Flatten (* Jean-François Alcover, Nov 15 2016 *)

Extensions

Better definition from Omar E. Pol, Oct 25 2016
Showing 1-10 of 20 results. Next