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 21-30 of 53 results. Next

A152968 a(n) = A139251(n+1)/2.

Original entry on oeis.org

1, 2, 2, 2, 4, 6, 4, 2, 4, 6, 6, 8, 14, 16, 8, 2, 4, 6, 6, 8, 14, 16, 10, 8, 14, 18, 20, 30, 44, 40, 16, 2, 4, 6, 6, 8, 14, 16, 10, 8, 14, 18, 20, 30, 44, 40, 18, 8, 14, 18, 20, 30, 44, 42, 28, 30, 46, 56, 70, 104, 128, 96, 32, 2
Offset: 1

Views

Author

Omar E. Pol, Dec 16 2008, Dec 20 2008

Keywords

Comments

Also, first differences of toothpicks numbers A152998. [From Omar E. Pol, Jan 02 2009]

Examples

			Triangle begins:
.1;
.2,2;
.2,4,6,4;
.2,4,6,6,8,14,16,8;
.2,4,6,6,8,14,16,10,8,14,18,20,30,44,40,16;
....
Rows approach A151688. - _N. J. A. Sloane_, Jun 03 2009
		

Crossrefs

Formula

Write n = 2^i +j, 0 <= j < 2^i; then a(n) = Sum_k 2^(wt(j+k)-k)*binomial(wt(j+k),k). except that a(2^r-1) = 2^(r-1). - N. J. A. Sloane, Jun 03 2009, Jul 16 2009
G.f.: x*(Prod(1+x^(2^k-1)+2*x^(2^k),k=0..oo)-1)/(1+2*x). - N. J. A. Sloane, Jun 05 2009

A151550 Expansion of g.f. Product_{n >= 1} (1 + x^(2^n-1) + 2*x^(2^n)).

Original entry on oeis.org

1, 1, 2, 1, 3, 4, 4, 1, 3, 4, 5, 5, 10, 12, 8, 1, 3, 4, 5, 5, 10, 12, 9, 5, 10, 13, 15, 20, 32, 32, 16, 1, 3, 4, 5, 5, 10, 12, 9, 5, 10, 13, 15, 20, 32, 32, 17, 5, 10, 13, 15, 20, 32, 33, 23, 20, 33, 41, 50, 72, 96, 80, 32, 1, 3, 4, 5, 5, 10, 12, 9, 5, 10, 13, 15, 20, 32, 32, 17, 5, 10, 13
Offset: 0

Views

Author

N. J. A. Sloane, May 19 2009, Jun 17 2009

Keywords

Comments

When convolved with [1, 2, 2, 2, ...] gives the toothpick sequence A153006: (1, 3, 6, 9, ...). - Gary W. Adamson, May 25 2009
This sequence and the Adamson's comment both are mentioned in the Applegate-Pol-Sloane article, see chapter 8 "generating functions". - Omar E. Pol, Sep 20 2011

Examples

			From _Omar E. Pol_, Jun 09 2009, edited by _N. J. A. Sloane_, Jun 17 2009:
May be written as a triangle:
  0;
  1;
  1,2;
  1,3,4,4;
  1,3,4,5,5,10,12,8;
  1,3,4,5,5,10,12,9,5,10,13,15,20,32,32,16;
  1,3,4,5,5,10,12,9,5,10,13,15,20,32,32,17,5,10,13,15,20,32,33,23,20,33,41,...
The rows of the triangle converge to A151555.
		

References

  • D. Applegate, Omar E. Pol and N. J. A. Sloane, The Toothpick Sequence and Other Sequences from Cellular Automata, Congressus Numerantium, Vol. 206 (2010), 157-191

Crossrefs

For generating functions of the form Product_{k>=c} (1+a*x^(2^k-1)+b*x^2^k) for the following values of (a,b,c) see: (1,1,0) A160573, (1,1,1) A151552, (1,1,2) A151692, (2,1,0) A151685, (2,1,1) A151691, (1,2,0) A151688 and A152980, (1,2,1) A151550, (2,2,0) A151693, (2,2,1) A151694.
Cf. A000079. - Omar E. Pol, Jun 09 2009

Programs

  • Mathematica
    terms = 100;
    CoefficientList[Product[(1+x^(2^n-1) + 2 x^(2^n)), {n, 1, Log[2, terms] // Ceiling}] + O[x]^terms, x] (* Jean-François Alcover, Aug 05 2018 *)

Formula

To get a nice recurrence, change the offset to 0 and multiply the g.f. by x as in the triangle in the example lines. Then we have: a(0)=0; a(2^i)=1; a(2^i-1)=2^(i-1) for i >= 1; otherwise write n = 2^i+j with 1 <= j <= 2^i-2, then a(n) = a(2^i+j) = 2*a(j) + a(j+1).

A151575 G.f.: (1+x)/(1+x-2*x^2).

Original entry on oeis.org

1, 0, 2, -2, 6, -10, 22, -42, 86, -170, 342, -682, 1366, -2730, 5462, -10922, 21846, -43690, 87382, -174762, 349526, -699050, 1398102, -2796202, 5592406, -11184810, 22369622, -44739242, 89478486, -178956970, 357913942, -715827882, 1431655766, -2863311530, 5726623062
Offset: 0

Views

Author

N. J. A. Sloane, May 25 2009, based on a suggestion from Gary W. Adamson

Keywords

Comments

Or, g.f. = (1+x)/((1-x)*(1-2*x)).
A signed version of A078008, which is the main entry.
[1, 0, 2, -2, 6, -10, 22, -42, 86, ...] = an operator for toothpick sequences. The sequence convolved with A151548 = toothpick sequence A139250. The sequence convolved with A151555 = toothpick sequence A153006. - Gary W. Adamson, May 25 2009

Crossrefs

Programs

  • Mathematica
    CoefficientList[Series[(1+x)/(1+x-2x^2),{x,0,40}],x] (* or *) LinearRecurrence[{-1,2},{1,0},40] (* Harvey P. Dale, May 31 2023 *)

Formula

From R. J. Mathar, Jul 08 2009: (Start)
a(n) = (2 + (-2)^n)/3 = (-1)^n*A078008(n), n>=0.
a(n) = 2*A077925(n-2), n>1. (End)
a(n) = A084247(n+1)/2. - Philippe Deléham, Sep 21 2009
G.f.: 1 + x - x*Q(0), where Q(k) = 1 + 2*x^2 - (2*k+3)*x + x*(2*k+1 - 2*x)/Q(k+1); (continued fraction). - Sergei N. Gladkovskii, Oct 05 2013

A147646 If A139251 is written as a triangle with rows of lengths 1, 2, 4, 8, 16, ..., the n-th row begins with 2^n followed by the first 2^n-1 terms of the present sequence.

Original entry on oeis.org

4, 8, 12, 12, 16, 28, 32, 20, 16, 28, 36, 40, 60, 88, 80, 36, 16, 28, 36, 40, 60, 88, 84, 56, 60, 92, 112, 140, 208, 256, 192, 68, 16, 28, 36, 40, 60, 88, 84, 56, 60, 92, 112, 140, 208, 256, 196, 88, 60, 92, 112, 140, 208, 260, 224, 172, 212, 296, 364, 488, 672, 704, 448, 132
Offset: 1

Views

Author

David Applegate, Apr 30 2009

Keywords

Comments

Limiting behavior of the rows of the triangle in A139251 when the first column of that triangle is omitted.
First differences of A159795. - Omar E. Pol, Jul 24 2009
It appears that a(n) is also the number of new grid points that are covered at n-th stage of A139250 version "Tree", assuming the toothpicks have length 4, 3, and 2 (see also A159795 and A153006). - Omar E. Pol, Oct 25 2011

Examples

			Further comments: A139251 as a triangle is:
. 1
. 2 4
. 4 4 8 12
. 8 4 8 12 12 16 28 32
. 16 4 8 12 12 16 28 32 20 16 28 36 40 60 88 80
. 32 4 8 12 12 16 28 32 20 16 28 36 40 60 88 80 36 16 28 36 40 60 88 84 56 ...
leading to the present sequence:
. 4 8 12 12 16 28 32 20 16 28 36 40 60 88 80 36 16 28 36 40 60 88 84 56 ...
Note that this can also be written as a triangle:
. 4 8
. 12 12 16 28
. 32 20 16 28 36 40 60 88
. 80 36 16 28 36 40 60 88 84 56 60 92 112 140 208 256
. 192 68 16 28 36 40 60 88 84 56 60 92 112 140 208 256 196 88 60 92 112 140 ...
The first column is (n+1)2^n (where n is the row number),
the second column is 2^(n+1)+4,
and the rest exhibits the same constant column behavior,
where the rows converge to:
. 16 28 36 40 60 88 84 56 60 92 112 140 208 256 196 88 60 92 112 140 ...
Once again this can be written as a triangle:
. 16
. 28 36 40 60
. 88 84 56 60 92 112 140 208
. 256 196 88 60 92 112 140 208 260 224 172 212 296 364 488 672
. 704 452 152 60 92 112 140 208 260 224 172 212 296 364 488 672 708 480 236 ...
and this behavior continues ad infinitum.
		

Crossrefs

Equals 2*A151688 and 4*A152980. - N. J. A. Sloane, Jul 16 2009

Programs

  • Maple
    S:=proc(n) option remember; local i,j;
    if n <= 0 then RETURN(0); fi;
    if n <= 2 then RETURN(2^(n+1)); fi;
    i:=floor(log(n)/log(2));
    j:=n-2^i;
    if j=0 then RETURN(2*n+4); fi;
    if j<2^i-1 then RETURN(2*S(j)+S(j+1)); fi;
    if j=2^i-1 then RETURN(2*S(j)+S(j+1)-4); fi;
    -1;
    end; # N. J. A. Sloane, May 18 2009

Formula

Letting n = 2^i + j for 0 <= j < 2^i, we have the recurrence (see A139251 for proof):
a(1) = 4
a(2) = 8
a(n) = 2n+4 = 2*a(n/2) - 4 if j = 0
a(n) = 2*a(j) + a(j+1) - 4 if j = 2^i-1
a(n) = 2*a(j) + a(j+1) if 1 <= j < 2^i-1
It appears that a(n) = A151548(n-1) + A151548(n). - Omar E. Pol, Feb 19 2015

A153003 Toothpick sequence in the first three quadrants.

Original entry on oeis.org

0, 1, 4, 7, 10, 16, 25, 31, 34, 40, 49, 58, 70, 91, 115, 127, 130, 136, 145, 154, 166, 187, 211, 226, 238, 259, 286, 316, 361, 427, 487, 511, 514, 520, 529, 538, 550, 571, 595, 610, 622, 643, 670, 700, 745, 811, 871, 898, 910, 931
Offset: 0

Views

Author

Omar E. Pol, Jan 02 2009

Keywords

Comments

From Omar E. Pol, Oct 01 2011: (Start)
On the infinite square grid, consider only the first three quadrants and count only the toothpicks of length 2.
At stage 0, we start from a vertical half toothpick at [(0,0),(0,1)]. This half toothpick represents one of the two components of the first toothpick placed in the toothpick structure of A139250, so a(0) = 0.
At stage 1, we place an orthogonal toothpick of length 2 centered at the end, so a(1) = 1. Also we place half toothpick at [(0,-1),(1,-1)]. This last half toothpick represents one of the two components of the third toothpick placed in the toothpick structure of A139250.
At stage 2, we place three toothpicks, so a(2) = 1+3 = 4.
In each subsequent stage, for every exposed toothpick end, place an orthogonal toothpick centered at that end.
The sequence gives the number of toothpicks after n stages. A153004 (the first differences) gives the number of toothpicks added to the structure at n-th stage.
Note that this sequence is different from the toothpick "corner" sequence A153006. For more information see A139250. (End)

Crossrefs

Programs

  • Mathematica
    A139250[n_] := A139250[n] = Module[{m, k}, If[n == 0, Return[0]]; m = 2^(Length[IntegerDigits[n, 2]] - 1); k = (2 m^2 + 1)/3; If[n == m, k, k + 2 A139250[n - m] + A139250[n - m + 1] - 1]];
    a[n_] := If[n == 0, 0, (3/4)(A139250[n + 1] - 3) + 1];
    a /@ Range[0, 49] (* Jean-François Alcover, Apr 06 2020 *)
  • Python
    def msb(n):
        t=0
        while n>>t>0: t+=1
        return 2**(t - 1)
    def a139250(n):
        k=(2*msb(n)**2 + 1)/3
        return 0 if n==0 else k if n==msb(n) else k + 2*a139250(n - msb(n)) + a139250(n - msb(n) + 1) - 1
    def a(n): return 0 if n==0 else (a139250(n + 1) - 3)*3/4 + 1
    [a(n) for n in range(51)] # Indranil Ghosh, Jul 01 2017

Formula

a(n) = (A139250(n+1)-3)*3/4 + 1, if n >= 1.
From Omar E. Pol, Oct 01 2011: (Start)
a(n) = A139250(n+1) - A152998(n) + A153000(n-1) - 1, if n >= 1.
a(n) = A139250(n+1) - A153000(n-1) - 2, if n >= 1.
a(n) = A152998(n) + A153000(n-1), if n >= 1.
(End)

A169708 First differences of A169707.

Original entry on oeis.org

1, 4, 4, 12, 4, 12, 20, 28, 4, 12, 20, 28, 20, 44, 68, 60, 4, 12, 20, 28, 20, 44, 68, 60, 20, 44, 68, 76, 84, 156, 196, 124, 4, 12, 20, 28, 20, 44, 68, 60, 20, 44, 68, 76, 84, 156, 196, 124, 20, 44, 68, 76, 84, 156, 196, 140, 84, 156, 212, 236, 324, 508, 516, 252, 4, 12, 20, 28, 20
Offset: 0

Views

Author

N. J. A. Sloane, Apr 17 2010

Keywords

Examples

			From _Omar E. Pol_, Feb 13 2015: (Start)
Written as an irregular triangle in which row lengths are 1,1,2,4,8,16,32,... the sequence begins:
1;
4;
4,12;
4,12,20,28;
4,12,20,28,20,44,68,60;
4,12,20,28,20,44,68,60,20,44,68,76,84,156,196,124;
4,12,20,28,20,44,68,60,20,44,68,76,84,156,196,124,20,44,68,76,84,156,196,140,84,156,212,236,324,508,516,252;
It appears that the row sums give A000302.
It appears that the right border gives A173033.
(End)
		

Crossrefs

Formula

It appears that a(n) = 4*A160552(n), n >= 1. - Omar E. Pol, Feb 13 2015

Extensions

Initial 1 added by Omar E. Pol, Feb 13 2015

A160412 Number of "ON" cells at n-th stage in simple 2-dimensional cellular automaton (see Comments for precise definition).

Original entry on oeis.org

0, 3, 12, 21, 48, 57, 84, 111, 192, 201, 228, 255, 336, 363, 444, 525, 768, 777, 804, 831, 912, 939, 1020, 1101, 1344, 1371, 1452, 1533, 1776, 1857, 2100, 2343, 3072, 3081, 3108, 3135, 3216, 3243, 3324, 3405, 3648, 3675, 3756, 3837, 4080, 4161, 4404, 4647
Offset: 0

Views

Author

Omar E. Pol, May 20 2009, Jun 01 2009

Keywords

Comments

From Omar E. Pol, Nov 10 2009: (Start)
On the infinite square grid, consider the outside corner of an infinite square.
We start at round 0 with all cells in the OFF state.
The rule: A cell in turned ON iff exactly one of its four vertices is a corner vertex of the set of ON cells. So in each generation every exposed vertex turns on three new cells.
At round 1, we turn ON three cells around the corner of the infinite square, forming a concave-convex hexagon with three exposed vertices.
At round 2, we turn ON nine cells around the hexagon.
At round 3, we turn ON nine other cells. Three cells around of every corner of the hexagon.
And so on.
Shows a fractal-like behavior similar to the toothpick sequence A153006.
For the first differences see the entry A162349.
For more information see A160410, which is the main entry for this sequence.
(End)

Examples

			If we label the generations of cells turned ON by consecutive numbers we get the cell pattern shown below:
...77..77..77..77
...766667..766667
....6556....6556.
....654444444456.
...76643344334667
...77.43222234.77
......44211244...
00000000001244...
00000000002234.77
00000000004334667
0000000000444456.
0000000000..6556.
0000000000.766667
0000000000.77..77
0000000000.......
0000000000.......
0000000000.......
		

Crossrefs

Programs

  • Mathematica
    a[n_] := 3*Sum[3^DigitCount[k, 2, 1], {k, 0, n - 1}]; Array[a, 48, 0] (* Michael De Vlieger, Nov 01 2022 *)

Formula

From Omar E. Pol, Nov 10 2009: (Start)
a(n) = A160410(n)*3/4.
a(0) = 0, a(n) = A130665(n-1)*3, for n>0.
(End)

Extensions

More terms from Omar E. Pol, Nov 10 2009
Edited by Omar E. Pol, Nov 11 2009
More terms from Nathaniel Johnston, Nov 06 2010
More terms from Colin Barker, Apr 19 2015

A153001 Rows of A152980 when written as a triangle converge to this sequence.

Original entry on oeis.org

4, 7, 9, 10, 15, 22, 21, 14, 15, 23, 28, 35, 52, 64, 49, 22, 15, 23, 28, 35, 52, 65, 56, 43, 53, 74, 91, 122, 168, 176, 113, 38, 15, 23, 28, 35, 52, 65, 56, 43, 53, 74, 91, 122, 168, 177, 120, 59, 53, 74, 91, 122, 169, 186, 155, 139, 180, 239, 304, 412, 512, 464, 257, 70, 15
Offset: 0

Views

Author

Omar E. Pol, Dec 16 2008, Dec 21 2008

Keywords

Crossrefs

Extensions

Edited by N. J. A. Sloane, Jun 07 2009, Jul 18 2009

A323649 Corner sequence of the cellular automaton of A323650.

Original entry on oeis.org

1, 3, 6, 12, 15, 21, 30, 48, 51, 57, 66, 84, 93, 111, 138, 192, 195, 201, 210, 228, 237, 255, 282, 336, 345, 363, 390, 444, 471, 525, 606, 768
Offset: 1

Views

Author

Omar E. Pol, Mar 03 2019

Keywords

Crossrefs

Partial sums of A323642.

A151555 G.f.: (1 + 2x) * Product_{n>=1} (1 + x^(2^n-1) + 2*x^(2^n)).

Original entry on oeis.org

1, 3, 4, 5, 5, 10, 12, 9, 5, 10, 13, 15, 20, 32, 32, 17, 5, 10, 13, 15, 20, 32, 33, 23, 20, 33, 41, 50, 72, 96, 80, 33, 5, 10, 13, 15, 20, 32, 33, 23, 20, 33, 41, 50, 72, 96, 81, 39, 20, 33, 41, 50, 72, 97, 89, 66, 73, 107, 132, 172, 240, 272, 192, 65, 5, 10, 13, 15, 20, 32, 33, 23
Offset: 0

Views

Author

N. J. A. Sloane, May 20 2009

Keywords

Comments

From Gary W. Adamson, May 25 2009: (Start)
Convolved with A078008 signed (A151575) [1, 0, 2, -2, 6, -10, 22, -42, 86, -170, ...]
equals the toothpick sequence A153006: (1, 3, 6, 9, 13, 20, 28, ...). (End)
If A151550 is written as a triangle then the rows converge to this sequence. - N. J. A. Sloane, Jun 16 2009

Examples

			From _Omar E. Pol_, Jun 19 2009: (Start)
May be written as a triangle:
1;
3;
4,5;
5,10,12,9;
5,10,13,15,20,32,32,17;
5,10,13,15,20,32,33,23,20,33,41,50,72,96,80,33;
5,10,13,15,20,32,33,23,20,33,41,50,72,96,81,39,20,33,41,50,72,97,89,66,73,...
(End)
		

Crossrefs

Previous Showing 21-30 of 53 results. Next