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.

Previous Showing 11-20 of 23 results. Next

A056477 Number of primitive (aperiodic) palindromic structures using a maximum of three different symbols.

Original entry on oeis.org

1, 1, 0, 1, 1, 4, 3, 13, 12, 39, 36, 121, 116, 364, 351, 1088, 1080, 3280, 3237, 9841, 9800, 29510, 29403, 88573, 88440, 265716, 265356, 797121, 796796, 2391484, 2390352, 7174453, 7173360, 21523238, 21520080, 64570064, 64566684, 193710244, 193700403, 581130368, 581120880
Offset: 0

Views

Author

Keywords

Comments

Permuting the symbols will not change the structure.

References

  • 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]

Crossrefs

Formula

a(n) = Sum_{d|n} mu(d)*A124302(ceiling(n/(2*d))) for n > 0.
a(n) = Sum_{k=1..3} A284826(n, k) for n > 0. - Andrew Howroyd, Oct 02 2019

Extensions

a(0)=1 prepended and terms a(32) and beyond from Andrew Howroyd, Oct 02 2019

A107767 a(n) = (1 + 3^n - 2*3^(n/2))/4 if n is even, (1 + 3^n - 4*3^((n-1)/2))/4 if n odd.

Original entry on oeis.org

0, 1, 4, 16, 52, 169, 520, 1600, 4840, 14641, 44044, 132496, 397852, 1194649, 3585040, 10758400, 32278480, 96845281, 290545684, 871666576, 2615029252, 7845176329, 23535617560, 70607118400, 211821620920, 635465659921
Offset: 1

Views

Author

Emeric Deutsch, Jun 12 2005

Keywords

Comments

a(n-1) is the number of chiral pairs of color patterns (set partitions) for a row of length n using up to 3 colors (subsets). For n=4, a(n-1)=4, the chiral pairs are AAAB-ABBB, AABA-ABAA, AABC-ABCC, and ABAC-ABCB. - Robert A. Russell, Oct 28 2018

References

  • Balaban, A. T., Brunvoll, J., Cyvin, B. N., & Cyvin, S. J. (1988). Enumeration of branched catacondensed benzenoid hydrocarbons and their numbers of Kekulé structures. Tetrahedron, 44(1), 221-228. See Eq. 5.

Crossrefs

Cf. A167993 (first differences).
Column 3 of A320751, offset by 1.
Cf. A124302 (oriented), A001998 (unoriented), A182522 (achiral), varying offsets.

Programs

  • GAP
    a:=[];; for n in [1..30] do if n mod 2 <> 0 then Add(a,(1+3^n-4*3^((n-1)/2))/4); else Add(a,(1+3^n-2*3^(n/2))/4); fi; od; a; # Muniru A Asiru, Oct 30 2018
  • Magma
    I:=[0, 1, 4, 16]; [n le 4 select I[n] else 4*Self(n-1)-12*Self(n-3)+9*Self(n-4): n in [1..30]]; // Vincenzo Librandi, Jun 26 2012
    
  • Maple
    a:=proc(n) if n mod 2 = 0 then (1+3^n-2*3^(n/2))/4 else (1+3^n-4*3^((n-1)/2))/4 fi end: seq(a(n),n=1..32);
  • Mathematica
    CoefficientList[Series[-x/((x-1)*(3*x-1)*(3*x^2-1)),{x,0,40}],x] (* or *) LinearRecurrence[{4,0,-12,9},{0,1,4,16},50] (* Vincenzo Librandi, Jun 26 2012 *)
    Ach[n_, k_] := Ach[n, k] = If[n<2, Boole[n==k && n>=0], k Ach[n-2,k] + Ach[n-2,k-1] + Ach[n-2,k-2]] (* A304972 *)
    k=3; Table[Sum[StirlingS2[n,j]-Ach[n,j],{j,k}]/2,{n,2,40}] (* Robert A. Russell, Oct 28 2018 *)
    CoefficientList[Series[(1/12 E^(-Sqrt[3] x) (-3 + 2 Sqrt[3] - (3 + 2 Sqrt[3]) E^(2 Sqrt[3] x) + 3 E^((3 + Sqrt[3]) x) + 3 E^(x + Sqrt[3] x)))/x, {x, 0, 20}], x]*Table[(k+1)!, {k, 0, 20}] (* Stefano Spezia, Oct 29 2018 *)
  • PARI
    x='x+O('x^50); concat(0, Vec(x^2/((1-x)*(3*x-1)*(3*x^2-1)))) \\ Altug Alkan, Sep 23 2018
    

Formula

G.f.: -x^2 / ( (x-1)*(3*x-1)*(3*x^2-1) ). - R. J. Mathar, Dec 16 2010
a(n) = 4*a(n-1) - 12*a(n-3) + 9*a(n-4). - Vincenzo Librandi, Jun 26 2012
From Robert A. Russell, Oct 28 2018: (Start)
a(n-1) = Sum_{j=0..k} (S2(n,j) - Ach(n,j)) / 2, where k=3 is the maximum number of colors, S2 is the Stirling subset number A008277, and Ach(n,k) = [n>=0 & n<2 & n==k] + [n>1]*(k*Ach(n-2,k) + Ach(n-2,k-1) + Ach(n-2,k-2)).
a(n-1) = (A124302(n) - A182522(n))/2.
a(n-1) = A124302(n) - A001998(n-1).
a(n-1) = A001998(n-1) - A182522(n).
a(n-1) = A122746(n-2) + A320526(n). (End)
E.g.f.: (1/12)*exp(-sqrt(3)*x)*(-3 + 2*sqrt(3) - (3 + 2*sqrt(3))*exp(2*sqrt(3)*x) + 3*exp((3 + sqrt(3))*x) + 3*exp(x + sqrt(3)*x)). - Stefano Spezia, Oct 29 2018
From Bruno Berselli, Oct 31 2018: (Start)
a(n) = (1 + 3^n - 3^((n-1)/2)*(4 + (-2 + sqrt(3))*(1 + (-1)^n)))/4. Therefore:
a(2*k) = (3^k - 1)^2/4;
a(2*k+1) = (3^k - 1)*(3^(k+1) - 1)/4. (End)

Extensions

Entry revised by N. J. A. Sloane, Jul 29 2011

A147746 Riordan array (1, x(1-2x)/(1-3x+x^2)).

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 0, 2, 2, 1, 0, 5, 5, 3, 1, 0, 13, 14, 9, 4, 1, 0, 34, 40, 28, 14, 5, 1, 0, 89, 114, 87, 48, 20, 6, 1, 0, 233, 323, 267, 161, 75, 27, 7, 1, 0, 610, 910, 809, 528, 270, 110, 35, 8, 1
Offset: 0

Views

Author

Paul Barry, Nov 11 2008

Keywords

Comments

Triangle [0,1,1,1,0,0,0,....] DELTA [1,0,0,0,...] with Deléham DELTA as in A084938.
Note that 1/(1-x/(1-x/(1-x))) = (1-2x)/(1-3x+x^2). Row sums are A124302.

Examples

			Triangle begins
  1;
  0,   1;
  0,   1,   1;
  0,   2,   2,   1;
  0,   5,   5,   3,   1;
  0,  13,  14,   9,   4,   1;
  0,  34,  40,  28,  14,   5,   1;
  0,  89, 114,  87,  48,  20,   6,   1;
  ...
		

Programs

  • Mathematica
    (* The function RiordanArray is defined in A256893. *)
    RiordanArray[1&, # (1-2#)/(1-3#+#^2)&, 10] // Flatten (* Jean-François Alcover, Jul 19 2019 *)

Formula

Sum_{k=0..n} T(n,k)*2^k = A147748(n). - Philippe Deléham, Oct 30 2011
Sum_{k=0..n} T(n,k)*(-1)^(n-k) = A215936(n). - Philippe Deléham, Aug 30 2012
G.f.: (1 - 3*x + x^2)/(1 - 3*x + x^2 - x*y + 2*x^2*y). - R. J. Mathar, Aug 11 2015

A216238 Square array T, read by antidiagonals: T(n,k) = 0 if n-k>=1 or if k-n>=5, T(0,0) = T(0,1) = T(0,2) = T(0,3) = T(0,4) = 1, T(n,k) = T(n-1,k) + T(n,k-1).

Original entry on oeis.org

1, 1, 0, 1, 1, 0, 1, 2, 0, 0, 1, 3, 2, 0, 0, 0, 4, 5, 0, 0, 0, 0, 4, 9, 5, 0, 0, 0, 0, 0, 13, 14, 0, 0, 0, 0, 0, 0, 13, 27, 14, 0, 0, 0, 0, 0, 0, 0, 40, 41, 0, 0, 0, 0, 0, 0, 0, 0, 40, 81, 41, 0, 0, 0, 0, 0, 0, 0, 0, 0, 121, 122, 0, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Philippe Deléham, Mar 14 2013

Keywords

Comments

Hexagon arithmetic of E. Lucas.

Examples

			Square array begins:
1, 1, 1, 1,  1,  0,   0,   0,   0,    0,    0, ... row n=0
0, 1, 2, 3,  4,  4,   0,   0,   0,    0,    0, ... row n=1
0, 0, 2, 5,  9, 13,  13,   0,   0,    0,    0, ... row n=2
0, 0, 0, 5, 14, 27,  40,  40,   0,    0,    0, ... row n=3
0, 0, 0, 0, 14, 41,  81, 121, 121,    0,    0, ... row n=4
0, 0, 0, 0,  0, 41, 122, 243, 364,  364,    0, ... row n=5
0, 0, 0, 0,  0,  0, 122, 365, 729, 1093, 1093, ... row n=6
...
		

References

  • E. Lucas, Théorie des nombres, Albert Blanchard, Paris, 1958, Tome1, p.89

Crossrefs

Formula

T(n,n) = A124302(n).
T(n,n+1) = A124302(n+1).
T(n,n+2) = 3^n = A000244(n).
T(n,n+3) = T(n,n+4) = A003462(n+1).
Sum_{k, 0<=k<=n} T(n-k,k) = A182522(n).

A262600 Number of Dyck paths of semilength n and height exactly 4.

Original entry on oeis.org

0, 0, 0, 0, 1, 7, 33, 132, 484, 1684, 5661, 18579, 59917, 190696, 600744, 1877256, 5828185, 17998783, 55342617, 169552428, 517884748, 1577812060, 4796682165, 14555626635, 44100374341, 133436026192, 403279293648, 1217616622992, 3673214880049, 11072960931319
Offset: 0

Views

Author

Ran Pan, Sep 25 2015

Keywords

Examples

			a(4) = 1 because the only favorable path is UUUUDDDD.
		

Crossrefs

Column k=4 of A080936.

Programs

  • Magma
    [((3^(n-1)+1)/2)-Fibonacci(2*n-1): n in [1.. 35]]; // Vincenzo Librandi, Sep 26 2015
    
  • Mathematica
    CoefficientList[ Series[x^4/((x-1) (3 x-1) (x^2-3 x+1)), {x, 0, 30}], x]
  • PARI
    a(n) = if( n<1, n==0, (3^(n-1) + 1) / 2) - fibonacci(2*n-1); vector(30, n, a(n-1)) \\ Altug Alkan, Sep 25 2015
    
  • PARI
    concat(vector(4), Vec(x^4/((1-x)*(1-3*x)*(1-3*x+x^2)) + O(x^100))) \\ Colin Barker, Feb 08 2016

Formula

a(n) = A124302(n) - A001519(n).
G.f.: x^4/((x-1)*(3*x-1)*(x^2-3*x+1)).
a(n) = A080936(n,4).
From Colin Barker, Feb 08 2016: (Start)
a(n) = 7*a(n-1)-16*a(n-2)+13*a(n-3)-3*a(n-4) for n>4.
a(n) = 2^(-1-n)*(5*2^n*(3+3^n)+3*(-5+sqrt(5))*(3+sqrt(5))^n-3*(3-sqrt(5))^n*(5+sqrt(5)))/15 for n>0. (End)
E.g.f.: (2 + 3*exp(x) + exp(3*x))/6 - exp(3*x/2)*(5*cosh(sqrt(5)*x/2) - sqrt(5)*sinh(sqrt(5)*x/2))/5. - Stefano Spezia, May 21 2024

A092807 Expansion of (1-6*x+4*x^2)/((1-2*x)*(1-6*x)).

Original entry on oeis.org

1, 2, 8, 40, 224, 1312, 7808, 46720, 280064, 1679872, 10078208, 60467200, 362799104, 2176786432, 13060702208, 78364180480, 470185017344, 2821109972992, 16926659575808, 101559956930560, 609359740534784
Offset: 0

Views

Author

Paul Barry, Mar 06 2004

Keywords

Comments

Second binomial transform of A054881 (closed walks at a vertex of an octahedron) With interpolated zeros, counts closed walks of length n at a vertex of the edge-vertex incidence graph of K_4 associated with the edges of K_4.
This also gives the number of noncrossing, nonnesting, 2-colored permutations on {1, 2, ..., n}. - Lily Yen, Apr 22 2013

Crossrefs

Programs

  • Magma
    [1] cat [6^(n-1) + 2^(n-1): n in [1..40]]; // G. C. Greubel, Jan 04 2023
    
  • Mathematica
    CoefficientList[Series[(1-6x+4x^2)/((1-2x)(1-6x)),{x,0,40}],x] (* or *) LinearRecurrence[{8,-12},{1,2,8},41] (* Harvey P. Dale, Aug 23 2011 *)
  • SageMath
    [(6^n + 3*2^n + 2*0^n)/6 for n in range(41)] # G. C. Greubel, Jan 04 2023

Formula

G.f.: (1-6*x+4*x^2)/((1-2*x)*(1-6*x)).
a(n) = (6^n + 3*2^n + 2*0^n)/6.
a(n) = A074601(n-1), n>0. - R. J. Mathar, Sep 08 2008
a(0)=1, a(1)=2, a(2)=8, a(n) = 8*a(n-1)-12*a(n-2). - Harvey P. Dale, Aug 23 2011
a(n) = A124302(n)*2^n. - Philippe Deléham, Nov 01 2011
E.g.f.: (1/6)*( 1 + 3*exp(2*x) + exp(6*x) ). - G. C. Greubel, Jan 04 2023

A123183 a(1)=-1; a(2)=-1; a(3)=-2; a(n) = 4*a(n-1) - 3*a(n-2) for n >= 4.

Original entry on oeis.org

-1, -1, -2, -5, -14, -41, -122, -365, -1094, -3281, -9842, -29525, -88574, -265721, -797162, -2391485, -7174454, -21523361, -64570082, -193710245, -581130734, -1743392201, -5230176602, -15690529805, -47071589414, -141214768241, -423644304722, -1270932914165, -3812798742494
Offset: 1

Views

Author

Roger L. Bagula, Oct 02 2006

Keywords

Comments

Essentially the same as A124302: a(n) = -A124302(n-1).

Crossrefs

Cf. A124302.

Programs

  • Maple
    a[1]:=-1: a[2]:=-1: a[3]:=-2: for n from 4 to 29 do a[n]:=4*a[n-1]-3*a[n-2] od: seq(a[n],n=1..29);
  • Mathematica
    M = {{1, -1, 0}, {-1, 2, -1}, {0, -1, 1}} v[1] = {1, 0, 0} v[n_] := v[n] = M.v[n - 1] a1 = Table[ -v[n][[1]], {n, 1, 50}]

Formula

From Philippe Deléham, Dec 05 2008 [corrected by Sergei N. Gladkovskii, Dec 10 2012]: (Start)
a(n) = -A124302(n-1).
G.f.: -(1-3*x+x^2)/(1-4*x+3*x^2). (End)
G.f.: -1-x*G(0) where G(k) = 1 + 2*x/(1 - 2*x - x*(1-2*x)/(x + (1-2*x)*2/G(k+1))); (continued fraction). - Sergei N. Gladkovskii, Dec 10 2012

Extensions

Edited by N. J. A. Sloane, Oct 08 2006

A135293 Differences between successive numbers whose sum of digits in base 3 is 2.

Original entry on oeis.org

2, 2, 2, 4, 2, 6, 10, 2, 6, 18, 28, 2, 6, 18, 54, 82, 2, 6, 18, 54, 162, 244, 2, 6, 18, 54, 162, 486, 730, 2, 6, 18, 54, 162, 486, 1458, 2188, 2, 6, 18, 54, 162, 486, 1458, 4374, 6562, 2, 6, 18, 54, 162, 486, 1458, 4374, 13122
Offset: 0

Views

Author

Adam Shelly (adam.shelly(AT)gmail.com), Dec 04 2007, Dec 05 2007

Keywords

Comments

First differences of A052216 when the entries in that sequence are interpreted as base 3 numbers.
Can be regarded as a triangle, where T(0,0)=2, T(n+1,0) = T(n,0)+T(n,n), T(n+1,m) = T(n,m) for 0 < m <= n and T(n+1,n+1) = sum of T(n+1,0..n)

Examples

			triangle begins:
2
2 2
4 2 6
10 2 6 18
28 2 6 18 54
82 2 6 18 54 162
244 2 6 18 54 162 486.
		

Crossrefs

Cf. A052216.

Programs

  • Mathematica
    T[0, 0] := 2; T[n_, 0] := 3^(n - 1) + 1; T[n_, m_] := 2*3^(m - 1); Table[T[n, m], {n, 0, 5}, {m, 0, n}] (* G. C. Greubel, Oct 09 2016 *)
    Join[{2},Differences[Select[Range[50000],Total[IntegerDigits[#,3]]==2&]]] (* Harvey P. Dale, Jul 04 2019 *)

Formula

T(n,m) = 2*3^(m-1) = A025192(m) for m>0. T(n,0) = 2*A124302(n). - Franklin T. Adams-Watters, Sep 29 2011

Extensions

Edited by Franklin T. Adams-Watters, Sep 29 2011

A198792 Triangle T(n,k), read by rows, given by (0,1,1,0,0,0,0,0,0,0,...) DELTA (1,0,0,1,0,0,0,0,0,0,0,...) where DELTA is the operator defined in A084938.

Original entry on oeis.org

1, 0, 1, 0, 1, 1, 0, 2, 2, 1, 0, 4, 6, 3, 1, 0, 8, 16, 12, 4, 1, 0, 16, 40, 40, 20, 5, 1, 0, 32, 96, 120, 80, 30, 6, 1, 0, 64, 224, 336, 280, 140, 42, 7, 1, 0, 128, 512, 896, 896, 560, 224, 56, 8, 1, 0, 256, 1152, 2304, 2688, 2016, 1008, 336, 72, 9, 1
Offset: 0

Views

Author

Philippe Deléham, Oct 30 2011

Keywords

Comments

Row sums are A124302.
Variant of A119468.

Examples

			Triangle begins :
1
0, 1
0, 1, 1
0, 2, 2, 1
0, 4, 6, 3, 1
0, 8, 16, 12, 4, 1
0, 16, 40, 40, 20, 5, 1
		

Crossrefs

Formula

T(n,k) = A097805(n,k)*A011782(n-k).
Sum_{0<=k<=n} T(n,k)*2^k = A063376(n-1).
G.f.: (1-(y+2)*x+y*x^2)/((1-x*y)*(1-x*(y+2))).
T(n,k) = 2*T(n-1,k) + 2*T(n-1,k-1) - 2*T(n-2,k-1) - T(n-2,k-2) for n>2, T(0,0) = T(1,1) = T(2,2) = T(2,1) = 1, T(1,0) = T(2,0) = 0, T(n,k) = 0 if k<0 or if k>n. - Philippe Deléham, Nov 10 2013

A208736 Number of nonisomorphic graded posets with 0 and 1 and non-uniform Hasse graph of rank n, with exactly 2 elements of each rank level between 0 and 1.

Original entry on oeis.org

0, 0, 0, 1, 5, 22, 91, 361, 1392, 5265, 19653, 72694, 267179, 977593, 3565600, 12975457, 47142021, 171075606, 620303547, 2247803785, 8141857808, 29481675889, 106728951109, 386314552438, 1398132674955, 5059626441177, 18308871648576, 66249898660801
Offset: 0

Views

Author

David Nacin, Mar 01 2012

Keywords

Comments

Uniform used in the sense of Retakh, Serconek and Wilson. We use Stanley's definition of graded poset: all maximal chains have the same length n (which also implies all maximal elements have maximal rank.)

References

  • R. Stanley, Enumerative combinatorics. Vol. 1, Cambridge University Press, Cambridge, 1997, pp. 96-100.

Crossrefs

Programs

  • Mathematica
    Join[{0, 0}, LinearRecurrence[{8, -21, 20, -5}, {0, 1, 5, 22}, 40]]
  • Python
    def a(n, d={0:0,1:0,2:0,3:1,4:5,5:22}):
        if n in d:
            return d[n]
        d[n]=8*a(n-1) - 21*a(n-2) + 20*a(n-3) - 5*a(n-4)
        return d[n]

Formula

a(n) = 8*a(n-1) - 21*a(n-2) + 20*a(n-3) - 5*a(n-4), a(2) = 0, a(3) = 1, a(4) = 5, a(5) = 22.
G.f.: (x^3 - 3*x^4 + 3*x^5)/(1 - 8*x + 21*x^2 - 20*x^3 + 5*x^4); (x^3 * (1 - 3*x + 3*x^2))/((1 - 3*x + x^2)*(1 - 5*x + 5*x^2)) .
a(n) = A081567(n-2) - A001519(n-1).
Previous Showing 11-20 of 23 results. Next