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 31-36 of 36 results.

A332410 a(n) = 2*a(n-1) - a(n-2) + a(n-5) - 2*a(n-6) + a(n-7) with a(0)=0, a(1)=1, a(2)=3, a(3)=6, a(4)=11, a(5)=17, a(6)=24.

Original entry on oeis.org

0, 1, 3, 6, 11, 17, 24, 32, 41, 52, 64, 77, 91, 106, 123, 141, 160, 180, 201, 224, 248, 273, 299, 326, 355, 385, 416, 448, 481, 516, 552, 589, 627, 666, 707, 749, 792, 836, 881, 928, 976, 1025, 1075, 1126, 1179
Offset: 0

Views

Author

Paul Curtz, Feb 11 2020

Keywords

Comments

This sequence occurs twice as a linear spoke in the hexagonal spiral constructed from A002266:
17 17 17 17 17 18 18
16 11 11 11 11 12 12 18
16 11 6 6 7 7 7 12 18
16 10 6 3 3 3 3 7 12 18
16 10 6 3 1 1 1 4 7 12 19
16 10 6 2 0 0 0 1 4 8 13 19
15 10 5 2 0 0 1 4 8 13 19
15 10 5 2 2 2 4 8 13 19
15 9 5 5 5 4 8 13 19
15 9 9 9 9 8 13 20
15 14 14 14 14 14 20
a(-1-n) = 0, 1, 4, 8, 13, 19, 26, 35, 45, ... also occurs twice in the same spiral.
Difference table:
0, 1, 3, 6, 11, 17, 24, 32, 41, 52, ... = a(n)
1, 2, 3, 5, 6, 7, 8, 9, 11, 12, ... = A047256(n+1)
1, 1, 2, 1, 1, 1, 1, 2, 1, 1, ... = A130782.
There is no linear spoke with three copies in this spiral. Compare with the spiral illustrated in sequence A330707 and constructed from A002265 where the same spokes occur three times: A006578, A001859 and A077043, essentially. Strictly, three times from 1, 1, 1 for A006578, from 2, 2, 2 for A001859 and from 7, 7, 7 for A077043.

Crossrefs

Programs

  • Mathematica
    LinearRecurrence[{2, -1, 0, 0, 1, -2, 1}, {0, 1, 3, 6, 11, 17, 24}, 45] (* Amiram Eldar, Feb 12 2020 *)
  • PARI
    concat(0, Vec(x*(1 + x)*(1 + x^2 + x^3) / ((1 - x)^3*(1 + x + x^2 + x^3 + x^4)) + O(x^50))) \\ Colin Barker, Feb 11 2020, Apr 24 2020

Formula

a(8+n) - a(8-n) = 20*n.
G.f.: x*(1 + x)*(1 + x^2 + x^3) / ((1 - x)^3*(1 + x + x^2 + x^3 + x^4)). - Colin Barker, Feb 11 2020

A104568 Triangle of numbers that are 0 or 1 mod 3.

Original entry on oeis.org

1, 3, 1, 4, 3, 1, 6, 4, 3, 1, 7, 6, 4, 3, 1, 9, 7, 6, 4, 3, 1, 10, 9, 7, 6, 4, 3, 1, 12, 10, 9, 7, 6, 4, 3, 1, 13, 12, 10, 9, 7, 6, 4, 3, 1, 15, 13, 12, 10, 9, 7, 6, 4, 3, 1, 16, 15, 13, 12, 10, 9, 7, 6, 4, 3, 1, 18, 16, 15, 13, 12, 10, 9, 7, 6, 4, 3, 1, 19, 18, 16, 15, 13, 12, 10, 9, 7, 6, 4, 3, 1
Offset: 0

Views

Author

Gary W. Adamson, Mar 16 2005

Keywords

Comments

The matrix operations (J * R), (R * J) are commutative since J * R = R * J.
Row sums = A006578.
Rows and columns of the triangle are all 0 or 1 mod 3 terms: A032766.
A104567 row sums also = A006578.
A006578(2n-1) = A001082(2n).

Examples

			The first few rows are:
  1;
  3, 1;
  4, 3, 1;
  6, 4, 3, 1;
  7, 6, 4, 3, 1;
  9, 7, 6, 4, 3, 1;
  ...
		

Crossrefs

Programs

  • Maple
    it:=array(1..1000): i:=1: for n from 1 to 1000 do if n mod 3 <> 2 then it[i]:=n; i:=i+1 fi: od: for j from 1 to 25 do for k from j to 1 by -1 do printf(`%d,`,it[k]) od: od: # James Sellers, Apr 09 2005

Formula

All columns (with offset); and all rows (starting from the right) are 0 or 1 mod 3 (A032766). Extract the triangle from the product J * R; J = [1; 2, 1; 1, 2, 1; 2, 1, 2, 1; ...]; R = [1; 1, 1; 1, 1, 1; ...] (infinite lower triangular matrices, with the rest zeros).

Extensions

More terms from James Sellers, Apr 09 2005

A266086 Alternating sum of 9-gonal (or nonagonal) numbers.

Original entry on oeis.org

0, -1, 8, -16, 30, -45, 66, -88, 116, -145, 180, -216, 258, -301, 350, -400, 456, -513, 576, -640, 710, -781, 858, -936, 1020, -1105, 1196, -1288, 1386, -1485, 1590, -1696, 1808, -1921, 2040, -2160, 2286, -2413, 2546, -2680, 2820, -2961, 3108, -3256, 3410
Offset: 0

Views

Author

Ilya Gutkovskiy, Dec 21 2015

Keywords

Crossrefs

Programs

  • Magma
    [(14*(-1)^n*n^2 + 4*(-1)^n*n - 5*(-1)^n + 5)/8: n in [0..50]]; // Vincenzo Librandi, Dec 21 2015
    
  • Mathematica
    Table[((14 n^2 + 4 n - 5) (-1)^n + 5)/8, {n, 0, 44}]
    CoefficientList[Series[(x - 6 x^2)/(x^4 + 2 x^3 - 2 x - 1), {x, 0, 50}], x] (* Vincenzo Librandi, Dec 21 2015 *)
  • PARI
    x='x+O('x^100); concat(0, Vec(-x*(1-6*x)/((1-x)*(1+x)^3))) \\ Altug Alkan, Dec 21 2015

Formula

G.f.: -x*(1 - 6*x)/((1 - x)*(1 + x)^3).
a(n) = ((14*n^2 + 4*n - 5)*(-1)^n + 5)/8.
a(n) = Sum_{k = 0..n} (-1)^k*A001106(k).
Lim_{n -> infinity} a(n + 1)/a(n) = -1.

A266087 Alternating sum of 11-gonal (or hendecagonal) numbers.

Original entry on oeis.org

0, -1, 10, -20, 38, -57, 84, -112, 148, -185, 230, -276, 330, -385, 448, -512, 584, -657, 738, -820, 910, -1001, 1100, -1200, 1308, -1417, 1534, -1652, 1778, -1905, 2040, -2176, 2320, -2465, 2618, -2772, 2934, -3097, 3268, -3440, 3620, -3801, 3990, -4180
Offset: 0

Views

Author

Ilya Gutkovskiy, Dec 21 2015

Keywords

Crossrefs

Programs

  • Magma
    [(18*(-1)^n*n^2 + 4*(-1)^n*n - 7*(-1)^n + 7)/8: n in [0..50]]; // Vincenzo Librandi, Dec 21 2015
    
  • Mathematica
    Table[((18 n^2 + 4 n - 7) (-1)^n + 7)/8, {n, 0, 43}]
    CoefficientList[Series[(x - 8 x^2)/(x^4 + 2 x^3 - 2 x - 1), {x, 0, 50}], x] (* Vincenzo Librandi, Dec 21 2015 *)
    Accumulate[Times@@@Partition[Riffle[PolygonalNumber[11,Range[0,50]],{1,-1},{2,-1,2}],2]] (* Requires Mathematica version 10 or later *) (* or *) LinearRecurrence[{-2,0,2,1},{0,-1,10,-20},50] (* Harvey P. Dale, Aug 27 2019 *)
  • PARI
    x='x+O('x^100); concat(0, Vec(-x*(1-8*x)/((1-x)*(1+x)^3))) \\ Altug Alkan, Dec 21 2015

Formula

G.f.: -x*(1 - 8*x)/((1 - x)*(1 + x)^3).
a(n) = ((18*n^2 + 4*n - 7)*(-1)^n + 7)/8.
a(n) = Sum_{k = 0..n} (-1)^k*A051682(k).
Lim_{n -> infinity} a(n + 1)/a(n) = -1.
E.g.f.: (1/4)*(9*x^2 - 11*x)*cosh(x) - (1/4)*(9*x^2 - 11*x - 7)*sinh(x). - G. C. Greubel, Jan 27 2016

A266088 Alternating sum of 12-gonal (or dodecagonal) numbers.

Original entry on oeis.org

0, -1, 11, -22, 42, -63, 93, -124, 164, -205, 255, -306, 366, -427, 497, -568, 648, -729, 819, -910, 1010, -1111, 1221, -1332, 1452, -1573, 1703, -1834, 1974, -2115, 2265, -2416, 2576, -2737, 2907, -3078, 3258, -3439, 3629, -3820, 4020, -4221, 4431, -4642
Offset: 0

Views

Author

Ilya Gutkovskiy, Dec 21 2015

Keywords

Comments

More generally, the ordinary generating function for the alternating sum of k-gonal numbers is -x*(1 - (k - 3)*x)/((1 - x)*(1 + x)^3).

Crossrefs

Programs

  • Magma
    [1+(-1)^n*(5*n^2+n-2)/2: n in [0..50]]; // Vincenzo Librandi, Dec 21 2015
    
  • Mathematica
    Table[1 + (-1)^n (5 n^2 + n - 2)/2, {n, 0, 43}]
    CoefficientList[Series[-x (1 - 9 x)/((1 - x) (1 + x)^3), {x, 0, 50}], x] (* Vincenzo Librandi, Dec 21 2015 *)
  • PARI
    x='x+O('x^100); concat(0, Vec(-x*(1-9*x)/((1-x)*(1+x)^3))) \\ Altug Alkan, Dec 21 2015

Formula

G.f.: -x*(1 - 9*x)/((1 - x)*(1 + x)^3).
a(n) = 1 + (-1)^n*(5*n^2 + n - 2)/2.
a(n) = Sum_{k = 0..n} (-1)^k*A051624(k).
Lim_{n -> infinity} a(n + 1)/a(n) = -1.

A271937 a(n) = (7/4)*n^2 + (5/2)*n + (7 + (-1)^n)/8.

Original entry on oeis.org

1, 5, 13, 24, 39, 57, 79, 104, 133, 165, 201, 240, 283, 329, 379, 432, 489, 549, 613, 680, 751, 825, 903, 984, 1069, 1157, 1249, 1344, 1443, 1545, 1651, 1760, 1873, 1989, 2109, 2232, 2359, 2489, 2623, 2760, 2901, 3045, 3193, 3344, 3499, 3657, 3819, 3984, 4153
Offset: 0

Views

Author

Vincenzo Librandi, Apr 20 2016

Keywords

Comments

Let P be a polygon with vertices (0,0), (0,2), (1,1) and (0,3/2). The number of integer points in nP is counted by this quasi-polynomial (nP is the n-fold dilation of P). See Wikipedia in Links section.
From Bob Selcoe, Sep 10 2016: (Start)
a(n) = the number of partitions in reverse lexicographic order starting with n 3's followed by n 2's; i.e., the number of partitions summing to 5n such that no part > 3 and the number of 3's digits <= the number of 2's digits.
First differences are A047346(n+1); second differences are 4 when n is even and 3 when n is odd (i.e., A010702(n+1)); third differences are 1 when n is even and -1 when n is odd. (End)

Examples

			a(1) = 5; the 5 partitions are: {3,2}; {3,1,1}; {2,2,1}; {2,1,1,1}; {1,1,1,1,1}.
a(3) = 24: floor(8/2) + floor(11/2) + floor(14/2) + floor(17/2) = 4+5+7+8 = 24.
		

Crossrefs

First bisection (after 1) is A168235.
Second bisection is A135703 (without 0).

Programs

  • Magma
    [(7/4)*n^2+(5/2)*n+(7+(-1)^n)/8: n in [0..50]];
    
  • Mathematica
    Table[(7/4) n^2 + (5/2) n + (7 + (-1)^n)/8, {n, 0, 50}]
    LinearRecurrence[{2,0,-2,1},{1,5,13,24},50] (* Harvey P. Dale, Mar 23 2025 *)
  • PARI
    Vec((1+3*x+3*x^2)/((1-x)^3*(1+x)) + O(x^99)) \\ Altug Alkan, Sep 10 2016

Formula

O.g.f.: (1 + 3*x + 3*x^2)/((1 - x)^3*(1 + x)).
E.g.f.: (7 + 34*x + 14*x^2)*exp(x)/8 + exp(-x)/8.
a(n) = 2*a(n-1) - 2*a(n-3) + a(n-4).
a(2*k) = k*(7*k + 5) + 1, a(2*k+1) = (k + 1)*(7*k + 5).
From Bob Selcoe, Sep 10 2016 (Start):
a(n) = (n+1)^2 + A006578(n).
a(n) = a(n-1) + A047346(n+1).
a(n) = Sum_{j=0..n} floor((2n+3j+2)/2).
(End)

Extensions

Edited and extended by Bruno Berselli, Apr 20 2016
Previous Showing 31-36 of 36 results.