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

A102363 Triangle read by rows, constructed by a Pascal-like rule with left edge = 2^k, right edge = 2^(k+1)-1 (k >= 0).

Original entry on oeis.org

1, 2, 3, 4, 5, 7, 8, 9, 12, 15, 16, 17, 21, 27, 31, 32, 33, 38, 48, 58, 63, 64, 65, 71, 86, 106, 121, 127, 128, 129, 136, 157, 192, 227, 248, 255, 256, 257, 265, 293, 349, 419, 475, 503, 511, 512, 513, 522, 558, 642, 768, 894, 978, 1014, 1023, 1024, 1025, 1035, 1080, 1200, 1410, 1662, 1872, 1992, 2037, 2047
Offset: 0

Views

Author

David Williams, Mar 15 2005, Oct 05 2007

Keywords

Comments

First column right of center divided by 3 equals powers of 4.
Right of left edge, sums of rows are divisible by 3.
Apparently the number of terms per row plus the number of numbers in natural order skipped per row equals a power of 2. - David Williams, Jun 27 2009

Examples

			This triangle begins:
                            1
                         2     3
                      4     5     7
                   8     9    12    15
               16    17    21    27    31
            32    33    38    48    58    63
         64    65    71    86   106   121   127
     128   129   136   157   192   227   248   255
  256   257   265   293   349   419   475   503   511
G.f. of this sequence in flattened form:
A(x) = 1 + 2*x + 3*x^2 + 4*x^3 + 5*x^4 + 7*x^5 + 8*x^6 + 9*x^7 + 12*x^8 + 15*x^9 + 16*x^10 + 17*x^11 + 21*x^12 + 27*x^13 + 31*x^14 + 32*x^15 + ...
such that
A(x) = (1+x) + x*(1+x)^2 + x^2*(1+x)^2 + x^3*(1+x)^3 + x^4*(1+x)^3 + x^5*(1+x)^3 + x^6*(1+x)^4 + x^7*(1+x)^4 + x^8*(1+x)^4 + x^9*(1+x)^4 + x^10*(1+x)^5 + x^11*(1+x)^5 + x^12*(1+x)^5 + x^13*(1+x)^5 + x^14*(1+x)^5 + x^15*(1+x)^6 + ...
		

Crossrefs

Cf. A000079, A053220 (row sums), A265939 (central terms).

Programs

  • Maple
    T:=proc(n,k) if k=0 then 2^n elif k=n then 2^(n+1)-1 else T(n-1,k)+T(n-1,k-1) fi end: for n from 0 to 10 do seq(T(n,k),k=0..n) od; # yields sequence in triangular form - Emeric Deutsch, Mar 26 2005
  • Mathematica
    t[n_, 0] := 2^n; t[n_, n_] := 2^(n+1)-1; t[n_, k_] := t[n, k] = t[n-1, k] + t[n-1, k-1]; Table[t[n, k], {n, 0, 10}, {k, 0, n}] // Flatten (* Jean-François Alcover, May 15 2013 *)
  • PARI
    /* Print in flattened form: Sum_{n>=0} x^n*(1+x)^tr(n) */
    {tr(n) = ceil( (sqrt(8*n+9)-1)/2 )}
    {a(n) = polcoeff( sum(m=0,n, x^m * (1+x +x*O(x^n))^tr(m) ),n)}
    for(n=0,78, print1(a(n),", ")) \\ Paul D. Hanna, Feb 19 2016

Formula

G.f.: Sum_{n>=0} x^n * (1+x)^tr(n) = Sum_{n>=0} a(n)*x^n, where tr(n) = A002024(n+1) = floor(sqrt(2*n+1) + 1/2). - Paul D. Hanna, Feb 19 2016
G.f.: Sum_{n>=1} x^(n*(n-1)/2) * (1-x^n)/(1-x) * (1+x)^n = Sum_{n>=0} a(n)*x^n. - Paul D. Hanna, Feb 20 2016
a(n) = A007318(n-1) + a(n-1). - Jon Maiga, Dec 22 2018

Extensions

More terms from Emeric Deutsch, Mar 26 2005

A053219 Reverse of triangle A053218, read by rows.

Original entry on oeis.org

1, 3, 2, 8, 5, 3, 20, 12, 7, 4, 48, 28, 16, 9, 5, 112, 64, 36, 20, 11, 6, 256, 144, 80, 44, 24, 13, 7, 576, 320, 176, 96, 52, 28, 15, 8, 1280, 704, 384, 208, 112, 60, 32, 17, 9, 2816, 1536, 832, 448, 240, 128, 68, 36, 19, 10, 6144, 3328, 1792, 960, 512, 272, 144, 76, 40
Offset: 1

Views

Author

Asher Auel, Jan 01 2000

Keywords

Comments

First element in each row gives A001792. Difference between center element of row 2n-1 and row sum of row n (A053220(n+4) - A053221(n+4)) gives A045618(n).
Subtriangle of triangle in A062111. - Philippe Deléham, Nov 21 2011
Can be seen as the transform of 1, 2, 3, 4, 5, ... by a variant of the boustrophedon algorithm (see the Sage implementation). - Peter Luschny, Oct 30 2014

Examples

			Triangle begins:
1
3, 2
8, 5, 3
20, 12, 7, 4
48, 28, 16, 9, 5 ...
		

Crossrefs

Cf. A053218 (reverse of this triangle), A053220 (center elements), A053221 (row sums), A001792, A045618, A062111.

Programs

  • Mathematica
    Map[Reverse,NestList[FoldList[Plus,#[[1]]+1,#]&,{1},10]]//Grid (* Geoffrey Critzer, Jun 27 2013 *)
  • Sage
    def u():
        for n in PositiveIntegers():
            yield n
    def bous_variant(f):
        k = 0
        am = next(f)
        a = [am]
        while True:
            yield list(a)
            am = next(f)
            a.append(am)
            for m in range(k,-1,-1):
                am += a[m]
                a[m] = am
            k += 1
    b = bous_variant(u())
    [next(b) for  in range(8)] # _Peter Luschny, Oct 30 2014

A105851 Binomial transform triangle, read by rows.

Original entry on oeis.org

1, 2, 1, 4, 3, 1, 8, 8, 4, 1, 16, 20, 12, 5, 1, 32, 48, 32, 16, 6, 1, 64, 112, 80, 44, 20, 7, 1, 128, 256, 192, 112, 56, 24, 8, 1, 256, 576, 448, 272, 144, 68, 28, 9, 1, 512, 1280, 1024, 640, 352, 176, 80, 32, 10, 1, 1024, 2816, 2304, 1472, 832, 432, 208, 92, 36, 11, 1
Offset: 0

Views

Author

Gary W. Adamson, Apr 23 2005

Keywords

Comments

Let P = Pascal's triangle as an infinite lower triangular matrix and A is the infinite array of arithmetic sequences as shown in A077028:
1, 1, 1, 1, 1, ...
1, 2, 3, 4, 5, ...
1, 3, 5, 7, 9, ...
1, 4, 7, 10, 13, ...
1, 5, 9, 13, 17, ...
Perform the operation P * A, getting a new array with each column being the binomial transform of an arithmetic sequence. Take antidiagonals of the new array, then by rows = the triangle of A105851.

Examples

			Column 3: 1, 5, 16, 44, 112, ... (A053220) is the binomial transform of 3k+1 (A016777: 1, 4, 7, ...).
Triangle begins:
     1;
     2,    1;
     4,    3,    1;
     8,    8,    4,    1;
    16,   20,   12,    5,   1;
    32,   48,   32,   16,   6,   1;
    64,  112,   80,   44,  20,   7,   1;
   128,  256,  192,  112,  56,  24,   8,  1;
   256,  576,  448,  272, 144,  68,  28,  9,  1;
   512, 1280, 1024,  640, 352, 176,  80, 32, 10,  1;
  1024, 2816, 2304, 1472, 832, 432, 208, 92, 36, 11, 1;
  ...
		

Crossrefs

Programs

  • Magma
    /* As triangle */ [[(2+k*(n-k))*2^(n-k-1): k in [0..n]]: n in [0.. 15]]; // Vincenzo Librandi, Jul 26 2015
  • Maple
    seq(seq((2 + k*(n - k))*2^(n-k-1),k=0..n),n=0..10); # Peter Bala, Jul 26 2015
  • Mathematica
    t[n_, k_]:=(2 + k (n - k)) 2^(n - k - 1); Table[t[n - 1, k - 1], {n, 10}, {k, n}]//Flatten (* Vincenzo Librandi, Jul 26 2015 *)

Formula

n-th column of the triangle is the binomial transform of the arithmetic sequence (n*k + 1), (k = 0, 1, 2, ...).
From Peter Bala, Jul 26 2015: (Start)
T(n,k) = (2 + k*(n - k))*2^(n-k-1) for 0 <= k <= n.
O.g.f.: (1 - x*(2 + t) + 3*t*x^2)/((1 - 2*x)^2*(1 - t*x)^2) = 1 + (2 + t)*x + (4 + 3*t + t^2)*x^2 + ....
k-th column g.f.: (1 + (k - 2)*x)/(1 - 2*x)^2. Cf. A077028. (End)

Extensions

More terms from Philippe Deléham, Mar 31 2007

A121574 Riordan array (1/(1-2*x), x*(1+x)/(1-2*x)).

Original entry on oeis.org

1, 2, 1, 4, 5, 1, 8, 16, 8, 1, 16, 44, 37, 11, 1, 32, 112, 134, 67, 14, 1, 64, 272, 424, 305, 106, 17, 1, 128, 640, 1232, 1168, 584, 154, 20, 1, 256, 1472, 3376, 3992, 2641, 998, 211, 23, 1, 512, 3328, 8864, 12592, 10442, 5221, 1574, 277, 26, 1
Offset: 0

Views

Author

Paul Barry, Aug 08 2006

Keywords

Comments

Row sums are A006190(n+1); diagonal sums are A077939.
Inverse is A121575.
A generalized Delannoy number triangle.
Antidiagonal sums are A002478. - Philippe Deléham, Nov 10 2011.
From Peter Bala, Feb 07 2024: (Start)
The following remarks assume the row indexing starts at n = 1.
The sequence of row polynomials R(n,x), beginning R(1,x) = 1, R(2,x) = 2 + x, R(3,x) = 4 + 5*x + x^2 , ..., is a strong divisibility sequence of polynomials in the ring Z[x]; that is, for all positive integers n and m, poly_gcd( R(n,x), R(m,x)) = R(gcd(n, m), x) - apply Norfleet (2005), Theorem 3. Consequently, the polynomial sequence {R(n,x): n >= 1} is a divisibility sequence; that is, if n divides m then R(n,x) divides R(m,x) in Z[x]. (End)

Examples

			Triangle begins
   1;
   2,   1;
   4,   5,   1;
   8,  16,   8,   1;
  16,  44,  37,  11,   1;
  32, 112, 134,  67,  14,  1;
  64, 272, 424, 305, 106, 17, 1;
		

Crossrefs

Cf. Diagonals: A000012, A016789, A080855, A000079, A053220.

Programs

  • GAP
    T:=Flat(List([0..9],n->List([0..n],k->Sum([0..n-k],j->Binomial(k,j)*Binomial(n-j,k)*2^(n-k-j))))); # Muniru A Asiru, Nov 02 2018
  • Magma
    [[(&+[ Binomial(k, j)*Binomial(n-j, k)*2^(n-k-j): j in [0..(n-k)]]): k in [0..n]]: n in [0..10]]; // G. C. Greubel, Nov 02 2018
    
  • Maple
    T:=(n,k)->add(binomial(k,j)*binomial(n-j,k)*2^(n-k-j),j=0..n-k): seq(seq(T(n,k),k=0..n),n=0..9); # Muniru A Asiru, Nov 02 2018
  • Mathematica
    Table[Sum[Binomial[k, j] Binomial[n-j, k] 2^(n-k-j), {j, 0, n-k}], {n, 0, 15}, {k, 0, n}]//Flatten (* G. C. Greubel, Nov 02 2018 *)
  • PARI
    for(n=0,10, for(k=0,n, print1(sum(j=0, n-k, binomial(k, j)* binomial(n-j, k)*2^(n-k-j)), ", "))) \\ G. C. Greubel, Nov 02 2018
    

Formula

Number array T(n,k) = Sum_{j=0..n-k} C(k,j)*C(n-j,k)*2^(n-k-j).
T(n,k) = 2*T(n-1,k) + T(n-1,k-1) + T(n-2,k-1). - Philippe Deléham, Nov 10 2011
Recurrence for row polynomials (with row indexing starting at n = 1): R(n,x) = (x + 2)*R(n-1,x) + x*R(n-2,x) with R(1,x) = 1 and R(2,x) = x + 2. - Peter Bala, Feb 07 2024

A132776 A128064 (unsigned) * A007318.

Original entry on oeis.org

1, 3, 2, 5, 8, 3, 7, 18, 15, 4, 9, 32, 42, 24, 5, 11, 50, 90, 80, 35, 6, 13, 72, 165, 200, 135, 48, 7, 15, 98, 273, 420, 385, 210, 63, 8, 17, 128, 420, 784, 910, 672, 308, 80, 9, 19, 162, 612, 1344, 1890, 1764, 1092, 432, 99, 10
Offset: 0

Views

Author

Gary W. Adamson, Aug 29 2007

Keywords

Comments

Row sums = A053220: (1, 5, 16, 44, 112, 272, ...).
A003506 = A007318 * A128064 (unsigned).

Examples

			First few rows of the triangle:
   1;
   3,  2;
   5,  8,  3;
   7, 18, 15,  4;
   9, 32, 42, 24,  5;
  11, 50, 90, 80, 35,  6;
  ...
		

Crossrefs

Formula

A128064 (unsigned) * A007318 as infinite lower triangular matrices.

A169585 A000004 preceded by 1, 3.

Original entry on oeis.org

1, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Klaus Brockhaus, Dec 02 2009

Keywords

Comments

Inverse binomial transform of A016777; second inverse binomial transform of A053220; third inverse binomial transform of A027471 without first term; fourth inverse binomial transform of A081039.

Crossrefs

Cf. A000004 (zero sequence), A016777 (3*n+1), A053220 ((3*n-1)*2^(n-2)), A027471 ((n-1)*3^(n-2)), A081039 ((3*n+4)*4^(n-1), a(0)=1, a(1)=7), A130706 (1, 2, 0, 0, 0, ...), A166926 (1, 2, 4, 0, 0, 0, ...), A130779 (1, 1, 2, 0, 0, 0, ...).

Programs

  • PARI
    {concat([1, 3], vector(103))}

Formula

a(0) = 1, a(1) = 3, a(n) = 0 for n > 1.
G.f.: 1+3*x.
a(n) = 3^n mod 9. - Ridouane Oudra, Apr 09 2025

A183264 Number of singly defective permutations of 1..n with exactly 1 maximum.

Original entry on oeis.org

0, 2, 15, 64, 220, 672, 1904, 5120, 13248, 33280, 81664, 196608, 465920, 1089536, 2519040, 5767168, 13090816, 29491200, 65994752, 146800640, 324796416, 715128832, 1567621120, 3422552064, 7444889600, 16139681792, 34879832064, 75161927680, 161531035648, 346281738240
Offset: 1

Views

Author

R. H. Hardin, Jan 03 2011

Keywords

Comments

A singly defective permutation omits one value and repeats another value.
a(1) is zero because there are no defective permutations of a single element.

Examples

			Some solutions for n=3 with 1 maximum:
(3,3,2) (1,3,3) (1,1,2) (2,1,1) (3,3,1) (1,3,1) (1,2,2) (2,2,1) (2,2,3).
		

Crossrefs

Column 1 of A183270.
Cf. A053220.

Formula

Conjecture: a(n) = n * (3*n-4) * 2^(n-3) for n > 1. - Andrew Howroyd, May 12 2020

Extensions

Terms a(16) and beyond from Andrew Howroyd, May 12 2020

A116924 Triangle T(n,k) = B(k,n) - B(k-1,n) where B(n,m) = Sum_{i=0..n} binomial(m,i) (3*i+1).

Original entry on oeis.org

1, 1, 4, 1, 8, 7, 1, 12, 21, 10, 1, 16, 42, 40, 13, 1, 20, 70, 100, 65, 16, 1, 24, 105, 200, 195, 96, 19, 1, 28, 147, 350, 455, 336, 133, 22, 1, 32, 196, 560, 910, 896, 532, 176, 25, 1, 36, 252, 840, 1638, 2016, 1596, 792, 225, 28, 1, 40, 315, 1200
Offset: 0

Views

Author

Gary W. Adamson, Feb 26 2006

Keywords

Comments

The auxiliary array B(n,m) contains the binomial transform of the finite sequence of the first n+1 terms of 1, 4, 7, ... = A016777(.) in row n.
First few rows of the array B(n,m) are from row n=0 on:
1, 1, 1, 1, 1, ... (binomial transform of 1,0,0,0,...)
1, 5, 9, 13, 17, ... (binomial transform of 1,4,0,0,...)
1, 5, 16, 34, 59, ... (binomial transform of 1,4,7,0,...)
1, 5, 16, 44, 99, ... (binomial transform of 1,4,7,10,0,0,...)
The n-th row of triangle T contains the first differences of the n-th column of B.

Examples

			First few rows of the triangle T(n,k):
  1;
  1,  4;
  1,  8,   7;
  1, 12,  21,  10;
  1, 16,  42,  40,  13;
  1, 20,  70, 100,  65, 16;
  1, 24, 105, 200, 195, 96, 19;
  ...
		

Crossrefs

Programs

  • Maple
    B := proc(n,m) add(binomial(m,i)*(3*i+1),i=0..n) ; end proc:
    A116924 := proc(n,k) if k = 0 then 1; else B(k,n)-B(k-1,n) ; end if; end proc:
    seq(seq(A116924(n,k),k=0..n),n=0..15) ; # R. J. Mathar, Mar 27 2010

Formula

Sum_{k=0..n} T(n,k) = A053220(n+1).

Extensions

Replaced definition with formula, corrected from 5th row on by R. J. Mathar, Mar 27 2010

A185342 Triangle of successive recurrences in columns of A117317(n).

Original entry on oeis.org

2, 4, -4, 6, -12, 8, 8, -24, 32, -16, 10, -40, 80, -80, 32, 12, -60, 160, -240, 192, -64, 14, -84, 280, -560, 672, -448, 128, 16, -112, 448, -1120, 1792, -1792, 1024, -256, 18, -144, 672, -2016, 4032, -5376, 4608, -2304, 512, 20, -180, 960, -3360, 8064
Offset: 0

Views

Author

Paul Curtz, Jan 26 2012

Keywords

Comments

A117317 (A):
1
2 1
4 5 1
8 16 9 1
16 44 41 14 1
32 112 146 85 20 1
64 272 456 377 155 27 1
have for their columns successive signatures
(2) (4,-4) (6,-12,8) (8,-24, 32, -16) (10,-40,80,-80,32) i.e. a(n).
Take based on abs(A133156) (B):
1
2 0
4 1 0
8 4 0 0
16 12 1 0 0
32 32 6 0 0 0
64 80 24 1 0 0 0.
The recurrences of successive columns are also a(n). a(n) columns: A005843(n+1), A046092(n+1), A130809, A130810, A130811, A130812, A130813.

Examples

			Triangle T(n,k),for 1<=k<=n, begins :
2                                         (1)
4    -4                                   (2)
6   -12   8                               (3)
8   -24  32   -16                         (4)
10  -40  80   -80   32                    (5)
12  -60 160  -240  192   -64              (6)
14  -84 280  -560  672  -448  128         (7)
16 -112 448 -1120 1792 -1792 1024 -256    (8)
Successive rows can be divided by A171977.
		

Crossrefs

Cf. For (A): A053220, A056243. For (B): A000079, A001787, A001788, A001789. For A193862: A115068 (a Coxeter group). For (2): A014480 (also (3),(4),(5),..); also A053220 and A001787.
Cf. A007318.

Programs

  • Mathematica
    Table[(-1)*Binomial[n, k]*(-2)^k, {n, 1, 20}, {k, 1, n}] // Flatten (* G. C. Greubel, Jun 27 2017 *)
  • PARI
    for(n=1,20, for(k=1,n, print1((-2)^(k+1)*binomial(n,k)/2, ", "))) \\ G. C. Greubel, Jun 27 2017

Formula

Take A133156(n) without 1's or -1's double triangle (C)=
2
4
8 -4
16 -12
32 -32 6
64 -80 24
128 -192 80 -8
256 -448 240 -40
512 -1024 672 -160 10;
a(n) is increasing odd diagonals and increasing (sign changed) even diagonals. Rows sum of (C) = A201629 (?) Another link between Chebyshev polynomials and cos( ).
Absolute values: A013609(n) without 1's. Also 2*A193862 = (2*A002260)*A135278.
T(n,k) = T(n-1,k) - 2*T(n-1,k-1) for k>1, T(n,1) = 2*n = 2*T(n-1,1) - T(n-2,1). - Philippe Deléham, Feb 11 2012
T(n,k) = (-1)* Binomial(n,k)*(-2)^k, 1<=k<=n. - Philippe Deléham, Feb 11 2012

A203150 (n-1)-st elementary symmetric function of the first n terms of (1,2,1,2,1,2,1,2,1,2,...)=A000034.

Original entry on oeis.org

1, 3, 5, 12, 16, 36, 44, 96, 112, 240, 272, 576, 640, 1344, 1472, 3072, 3328, 6912, 7424, 15360, 16384, 33792, 35840, 73728, 77824, 159744, 167936, 344064, 360448, 737280, 770048, 1572864, 1638400, 3342336, 3473408, 7077888, 7340032
Offset: 1

Views

Author

Clark Kimberling, Dec 29 2011

Keywords

Examples

			Let esf abbreviate "elementary symmetric function".  Then
0th esf of {1}:  1
1st esf of {1,2}:  1+2=3
2nd esf of {1,2,1} is 1*2+1*1+2*1=5
		

Crossrefs

Cf. A000034, A167667 (bisection?), A053220 (bisection?)

Programs

  • Mathematica
    f[k_] := 1 + Mod[k + 1, 2];
    t[n_] := Table[f[k], {k, 1, n}]
    a[n_] := SymmetricPolynomial[n - 1, t[n]]
    Table[a[n], {n, 1, 33}]  (* A203150 *)

Formula

Empirical G.f.: x*(1+3*x+x^2)/(1-4*x^2+4*x^4). - Colin Barker, Jan 03 2012
Conjecture: a(n) = (6*r*n+(1+3*(1-r)*n)*(1-(-1)^n))*r^(n-1)/8, where r=sqrt(2). - Bruno Berselli, Jan 03 2011
Previous Showing 11-20 of 25 results. Next