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-3 of 3 results.

A168244 a(n) = 1 + 3*n - 2*n^2.

Original entry on oeis.org

1, 2, -1, -8, -19, -34, -53, -76, -103, -134, -169, -208, -251, -298, -349, -404, -463, -526, -593, -664, -739, -818, -901, -988, -1079, -1174, -1273, -1376, -1483, -1594, -1709, -1828, -1951, -2078, -2209, -2344, -2483, -2626, -2773, -2924, -3079, -3238, -3401, -3568, -3739, -3914, -4093, -4276, -4463, -4654, -4849
Offset: 0

Views

Author

A.K. Devaraj, Nov 21 2009

Keywords

Comments

Consider the quadratic cyclotomic polynomial f(x) = x^2+x+1 and the quotients f(x + n*f(x))/f(x), as in A168235 and A168240. a(n) is the real part of the quotient at x = 1+sqrt(-5).
The imaginary part of the quotient is sqrt(5)*A045944(n).
As stated in short description of A168244 the quotient is in two parts: rational integers (cf. A168244) and rational integer multiples of sqrt(-5). It so happens that the sequence of rational integer coefficients of sqrt(-5) is A045944. - A.K. Devaraj, Nov 22 2009
This sequence contains half of all integers m such that -8*m +17 is an odd square. The other half are found in A091823 multiplied by -1. The squares resulting from A168244 are (4*n - 3)^2, those from A091823 are (4*n + 3)^2. - Klaus Purath, Jul 11 2021

Crossrefs

Programs

Formula

a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3).
G.f.: 1 + x*(2-7*x+x^2)/(1-x)^3.
a(-n) = -A091823(n), a(0) = 1. - Michael Somos, May 11 2014
E.g.f.: (1 + x - 2*x^2)*exp(x). - G. C. Greubel, Apr 09 2016
a(n) = a(n-2) + (-2)*sqrt((-8)*a(n-1) + 17), n > 1. - Klaus Purath, Jul 08 2021

Extensions

Edited, definition simplified, sequence extended beyond a(5) by R. J. Mathar, Nov 23 2009
a(0)=1 added by N. J. A. Sloane, Apr 09 2016

A168240 a(n) = 13*n^2 + 7*n + 1.

Original entry on oeis.org

21, 67, 139, 237, 361, 511, 687, 889, 1117, 1371, 1651, 1957, 2289, 2647, 3031, 3441, 3877, 4339, 4827, 5341, 5881, 6447, 7039, 7657, 8301, 8971, 9667, 10389, 11137, 11911, 12711, 13537, 14389, 15267, 16171, 17101, 18057, 19039, 20047, 21081, 22141, 23227
Offset: 1

Views

Author

A.K. Devaraj, Nov 21 2009

Keywords

Comments

Consider the quadratic cyclotomic polynomial f(x) = x^2+x+1 and the quotients defined by f(x + n*f(x))/f(x). a(n) is the quotient at x=3.

Examples

			f(x) = 13 when x = 3. Hence at n = 1, f(x + f(x))/f(x) = 21 = a(1).
		

Crossrefs

Programs

Formula

From R. J. Mathar, Nov 23 2009: (Start)
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3).
G.f.: x*(21+4*x+x^2)/(1-x)^3. (End)
E.g.f.: (13*x^2 + 20*x + 1)*exp(x). - G. C. Greubel, Apr 09 2016

Extensions

Edited, definition simplified, sequence extended beyond a(8) by R. J. Mathar, Nov 23 2009

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
Showing 1-3 of 3 results.