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-10 of 19 results. Next

A002061 Central polygonal numbers: a(n) = n^2 - n + 1.

Original entry on oeis.org

1, 1, 3, 7, 13, 21, 31, 43, 57, 73, 91, 111, 133, 157, 183, 211, 241, 273, 307, 343, 381, 421, 463, 507, 553, 601, 651, 703, 757, 813, 871, 931, 993, 1057, 1123, 1191, 1261, 1333, 1407, 1483, 1561, 1641, 1723, 1807, 1893, 1981, 2071, 2163, 2257, 2353, 2451, 2551, 2653
Offset: 0

Views

Author

Keywords

Comments

These are Hogben's central polygonal numbers denoted by the symbol
...2....
....P...
...2.n..
(P with three attachments).
Also the maximal number of 1's that an n X n invertible {0,1} matrix can have. (See Halmos for proof.) - Felix Goldberg (felixg(AT)tx.technion.ac.il), Jul 07 2001
Maximal number of interior regions formed by n intersecting circles, for n >= 1. - Amarnath Murthy, Jul 07 2001
The terms are the smallest of n consecutive odd numbers whose sum is n^3: 1, 3 + 5 = 8 = 2^3, 7 + 9 + 11 = 27 = 3^3, etc. - Amarnath Murthy, May 19 2001
(n*a(n+1)+1)/(n^2+1) is the smallest integer of the form (n*k+1)/(n^2+1). - Benoit Cloitre, May 02 2002
For n >= 3, a(n) is also the number of cycles in the wheel graph W(n) of order n. - Sharon Sela (sharonsela(AT)hotmail.com), May 17 2002
Let b(k) be defined as follows: b(1) = 1 and b(k+1) > b(k) is the smallest integer such that Sum_{i=b(k)..b(k+1)} 1/sqrt(i) > 2; then b(n) = a(n) for n > 0. - Benoit Cloitre, Aug 23 2002
Drop the first three terms. Then n*a(n) + 1 = (n+1)^3. E.g., 7*1 + 1 = 8 = 2^3, 13*2 + 1 = 27 = 3^3, 21*3 + 1 = 64 = 4^3, etc. - Amarnath Murthy, Oct 20 2002
Arithmetic mean of next 2n - 1 numbers. - Amarnath Murthy, Feb 16 2004
The n-th term of an arithmetic progression with first term 1 and common difference n: a(1) = 1 -> 1, 2, 3, 4, 5, ...; a(2) = 3 -> 1, 3, ...; a(3) = 7 -> 1, 4, 7, ...; a(4) = 13 -> 1, 5, 9, 13, ... - Amarnath Murthy, Mar 25 2004
Number of walks of length 3 between any two distinct vertices of the complete graph K_{n+1} (n >= 1). Example: a(2) = 3 because in the complete graph ABC we have the following walks of length 3 between A and B: ABAB, ACAB and ABCB. - Emeric Deutsch, Apr 01 2004
Narayana transform of [1, 2, 0, 0, 0, ...] = [1, 3, 7, 13, 21, ...]. Let M = the infinite lower triangular matrix of A001263 and let V = the Vector [1, 2, 0, 0, 0, ...]. Then A002061 starting (1, 3, 7, ...) = M * V. - Gary W. Adamson, Apr 25 2006
The sequence 3, 7, 13, 21, 31, 43, 57, 73, 91, 111, ... is the trajectory of 3 under repeated application of the map n -> n + 2 * square excess of n, cf. A094765.
Also n^3 mod (n^2+1). - Zak Seidov, Aug 31 2006
Also, omitting the first 1, the main diagonal of A081344. - Zak Seidov, Oct 05 2006
Ignoring the first ones, these are rectangular parallelepipeds with integer dimensions that have integer interior diagonals. Using Pythagoras: sqrt(a^2 + b^2 + c^2) = d, an integer; then this sequence: sqrt(n^2 + (n+1)^2 + (n(n+1))^2) = 2T_n + 1 is the first and most simple example. Problem: Are there any integer diagonals which do not satisfy the following general formula? sqrt((k*n)^2 + (k*(n+(2*m+1)))^2 + (k*(n*(n+(2*m+1)) + 4*T_m))^2) = k*d where m >= 0, k >= 1, and T is a triangular number. - Marco Matosic, Nov 10 2006
Numbers n such that a(n) is prime are listed in A055494. Prime a(n) are listed in A002383. All terms are odd. Prime factors of a(n) are listed in A007645. 3 divides a(3*k-1), 7 divides a(7*k-4) and a(7*k-2), 7^2 divides a(7^2*k-18) and a(7^2*k+19), 7^3 divides a(7^3*k-18) and a(7^3*k+19), 7^4 divides a(7^4*k+1048) and a(7^4*k-1047), 7^5 divides a(7^5*k+1354) and a(7^5*k-1353), 13 divides a(13*k-9) and a(13*k-3), 13^2 divides a(13^2*k+23) and a(13^2*k-22), 13^3 divides a(13^3*k+1037) and a(13^3*k-1036). - Alexander Adamchuk, Jan 25 2007
Complement of A135668. - Kieren MacMillan, Dec 16 2007
From William A. Tedeschi, Feb 29 2008: (Start)
Numbers (sorted) on the main diagonal of a 2n X 2n spiral. For example, when n=2:
.
7---8---9--10
| |
6 1---2 11
| | |
5---4---3 12
|
16--15--14--13
.
Cf. A137928. (End)
a(n) = AlexanderPolynomial[n] defined as Det[Transpose[S]-n S] where S is Seifert matrix {{-1, 1}, {0, -1}}. - Artur Jasinski, Mar 31 2008
Starting (1, 3, 7, 13, 21, ...) = binomial transform of [1, 2, 2, 0, 0, 0]; example: a(4) = 13 = (1, 3, 3, 1) dot (1, 2, 2, 0) = (1 + 6 + 6 + 0). - Gary W. Adamson, May 10 2008
Starting (1, 3, 7, 13, ...) = triangle A158821 * [1, 2, 3, ...]. - Gary W. Adamson, Mar 28 2009
Starting with offset 1 = triangle A128229 * [1,2,3,...]. - Gary W. Adamson, Mar 26 2009
a(n) = k such that floor((1/2)*(1 + sqrt(4*k-3))) + k = (n^2+1), that is A000037(a(n)) = A002522(n) = n^2 + 1, for n >= 1. - Jaroslav Krizek, Jun 21 2009
For n > 0: a(n) = A170950(A002522(n-1)), A170950(a(n)) = A174114(n), A170949(a(n)) = A002522(n-1). - Reinhard Zumkeller, Mar 08 2010
From Emeric Deutsch, Sep 23 2010: (Start)
a(n) is also the Wiener index of the fan graph F(n). The fan graph F(n) is defined as the graph obtained by joining each node of an n-node path graph with an additional node. The Wiener index of a connected graph is the sum of the distances between all unordered pairs of vertices in the graph. The Wiener polynomial of the graph F(n) is (1/2)t[(n-1)(n-2)t + 2(2n-1)]. Example: a(2)=3 because the corresponding fan graph is a cycle on 3 nodes (a triangle), having distances 1, 1, and 1.
(End)
For all elements k = n^2 - n + 1 of the sequence, sqrt(4*(k-1)+1) is an integer because 4*(k-1) + 1 = (2*n-1)^2 is a perfect square. Building the intersection of this sequence with A000225, k may in addition be of the form k = 2^x - 1, which happens only for k = 1, 3, 7, 31, and 8191. [Proof: Still 4*(k-1)+1 = 2^(x+2) - 7 must be a perfect square, which has the finite number of solutions provided by A060728: x = 1, 2, 3, 5, or 13.] In other words, the sequence A038198 defines all elements of the form 2^x - 1 in this sequence. For example k = 31 = 6*6 - 6 + 1; sqrt((31-1)*4+1) = sqrt(121) = 11 = A038198(4). - Alzhekeyev Ascar M, Jun 01 2011
a(n) such that A002522(n-1) * A002522(n) = A002522(a(n)) where A002522(n) = n^2 + 1. - Michel Lagneau, Feb 10 2012
Left edge of the triangle in A214661: a(n) = A214661(n, 1), for n > 0. - Reinhard Zumkeller, Jul 25 2012
a(n) = A215630(n, 1), for n > 0; a(n) = A215631(n-1, 1), for n > 1. - Reinhard Zumkeller, Nov 11 2012
Sum_{n > 0} arccot(a(n)) = Pi/2. - Franz Vrabec, Dec 02 2012
If you draw a triangle with one side of unit length and one side of length n, with an angle of Pi/3 radians between them, then the length of the third side of the triangle will be the square root of a(n). - Elliott Line, Jan 24 2013
a(n+1) is the number j such that j^2 = j + m + sqrt(j*m), with corresponding number m given by A100019(n). Also: sqrt(j*m) = A027444(n) = n * a(n+1). - Richard R. Forberg, Sep 03 2013
Let p(x) the interpolating polynomial of degree n-1 passing through the n points (n,n) and (1,1), (2,1), ..., (n-1,1). Then p(n+1) = a(n). - Giovanni Resta, Feb 09 2014
The number of square roots >= sqrt(n) and < n+1 (n >= 0) gives essentially the same sequence, 1, 3, 7, 13, 21, 31, 43, 57, 73, 91, 111, 133, 157, 183, 211, ... . - Michael G. Kaarhus, May 21 2014
For n > 1: a(n) is the maximum total number of queens that can coexist without attacking each other on an [n+1] X [n+1] chessboard. Specifically, this will be a lone queen of one color placed in any position on the perimeter of the board, facing an opponent's "army" of size a(n)-1 == A002378(n-1). - Bob Selcoe, Feb 07 2015
a(n+1) is, for n >= 1, the number of points as well as the number of lines of a finite projective plane of order n (cf. Hughes and Piper, 1973, Theorem 3.5., pp. 79-80). For n = 3, a(4) = 13, see the 'Finite example' in the Wikipedia link, section 2.3, for the point-line matrix. - Wolfdieter Lang, Nov 20 2015
Denominators of the solution to the generalization of the Feynman triangle problem. If each vertex of a triangle is joined to the point (1/p) along the opposite side (measured say clockwise), then the area of the inner triangle formed by these lines is equal to (p - 2)^2/(p^2 - p + 1) times the area of the original triangle, p > 2. For example, when p = 3, the ratio of the areas is 1/7. The numerators of the ratio of the areas is given by A000290 with an offset of 2. [Cook & Wood, 2004.] - Joe Marasco, Feb 20 2017
n^2 equal triangular tiles with side lengths 1 X 1 X 1 may be put together to form an n X n X n triangle. For n>=2 a(n-1) is the number of different 2 X 2 X 2 triangles being contained. - Heinrich Ludwig, Mar 13 2017
For n >= 0, the continued fraction [n, n+1, n+2] = (n^3 + 3n^2 + 4n + 2)/(n^2 + 3n + 3) = A034262(n+1)/a(n+2) = n + (n+2)/a(n+2); e.g., [2, 3, 4] = A034262(3)/a(4) = 30/13 = 2 + 4/13. - Rick L. Shepherd, Apr 06 2017
Starting with b(1) = 1 and not allowing the digit 0, let b(n) = smallest nonnegative integer not yet in the sequence such that the last digit of b(n-1) plus the first digit of b(n) is equal to k for k = 1, ..., 9. This defines 9 finite sequences, each of length equal to a(k), k = 1, ..., 9. (See A289283-A289287 for the cases k = 5..9.) For k = 10, the sequence is infinite (A289288). For example, for k = 4, b(n) = 1,3,11,31,32,2,21,33,12,22,23,13,14. These terms can be ordered in the following array of size k*(k-1)+1:
1 2 3
21 22 23
31 32 33
11 12 13 14
.
The sequence ends with the term 1k, which lies outside the rectangular array and gives the term +1 (see link).- Enrique Navarrete, Jul 02 2017
The central polygonal numbers are the delimiters (in parenthesis below) when you write the natural numbers in groups of odd size 2*n+1 starting with the group {2} of size 1: (1) 2 (3) 4,5,6 (7) 8,9,10,11,12 (13) 14,15,16,17,18,19,20 (21) 22,23,24,25,26,27,28,29,30 (31) 32,33,34,35,36,37,38,39,40,41,42 (43) ... - Enrique Navarrete, Jul 11 2017
Also the number of (non-null) connected induced subgraphs in the n-cycle graph. - Eric W. Weisstein, Aug 09 2017
Since (n+1)^2 - (n+1) + 1 = n^2 + n + 1 then from 7 onwards these are also exactly the numbers that are represented as 111 in all number bases: 111(2)=7, 111(3)=13, ... - Ron Knott, Nov 14 2017
Number of binary 2 X (n-1) matrices such that each row and column has at most one 1. - Dmitry Kamenetsky, Jan 20 2018
Observed to be the squares visited by bishop moves on a spirally numbered board and moving to the lowest available unvisited square at each step, beginning at the second term (cf. A316667). It should be noted that the bishop will only travel to squares along the first diagonal of the spiral. - Benjamin Knight, Jan 30 2019
From Ed Pegg Jr, May 16 2019: (Start)
Bound for n-subset coverings. Values in A138077 covered by difference sets.
C(7,3,2), {1,2,4}
C(13,4,2), {0,1,3,9}
C(21,5,2), {3,6,7,12,14}
C(31,6,2), {1,5,11,24,25,27}
C(43,7,2), existence unresolved
C(57,8,2), {0,1,6,15,22,26,45,55}
Next unresolved cases are C(111,11,2) and C(157,13,2). (End)
"In the range we explored carefully, the optimal packings were substantially irregular only for n of the form n = k(k+1)+1, k = 3, 4, 5, 6, 7, i.e., for n = 13, 21, 31, 43, and 57." (cited from Lubachevsky, Graham link, Introduction). - Rainer Rosenthal, May 27 2020
From Bernard Schott, Dec 31 2020: (Start)
For n >= 1, a(n) is the number of solutions x in the interval 1 <= x <= n of the equation x^2 - [x^2] = (x - [x])^2, where [x] = floor(x). For n = 3, the a(3) = 7 solutions in the interval [1, 3] are 1, 3/2, 2, 9/4, 5/2, 11/4 and 3.
This sequence is the answer to the 4th problem proposed during the 20th British Mathematical Olympiad in 1984 (see link B.M.O 1984. and Gardiner reference). (End)
Called "Hogben numbers" after the British zoologist, statistician and writer Lancelot Thomas Hogben (1895-1975). - Amiram Eldar, Jun 24 2021
Minimum Wiener index of 2-degenerate graphs with n+1 vertices (n>0). A maximal 2-degenerate graph can be constructed from a 2-clique by iteratively adding a new 2-leaf (vertex of degree 2) adjacent to two existing vertices. The extremal graphs are maximal 2-degenerate graphs with diameter at most 2. - Allan Bickle, Oct 14 2022
a(n) is the number of parking functions of size n avoiding the patterns 123, 213, and 312. - Lara Pudwell, Apr 10 2023
Repeated iteration of a(k) starting with k=2 produces Sylvester's sequence, i.e., A000058(n) = a^n(2), where a^n is the n-th iterate of a(k). - Curtis Bechtel, Apr 04 2024
a(n) is the maximum number of triangles that can be traversed by starting from a triangle and moving to adjacent triangles via an edge, without revisiting any triangle, in an n X n X n equilateral triangular grid made up of n^2 unit equilateral triangles. - Kiran Ananthpur Bacche, Jan 16 2025

Examples

			G.f. = 1 + x + 3*x^2 + 7*x^3 + 13*x^4 + 21*x^5 + 31*x^6 + 43*x^7 + ...
		

References

  • Archimedeans Problems Drive, Eureka, 22 (1959), 15.
  • Steve Dinh, The Hard Mathematical Olympiad Problems And Their Solutions, AuthorHouse, 2011, Problem 1 of the British Mathematical Olympiad 2007, page 160.
  • Anthony Gardiner, The Mathematical Olympiad Handbook: An Introduction to Problem Solving, Oxford University Press, 1997, reprinted 2011, Problem 4 pp. 64 and 173 (1984).
  • Paul R. Halmos, Linear Algebra Problem Book, MAA, 1995, pp. 75-6, 242-4.
  • Ross Honsberger, Ingenuity in Mathematics, Random House, 1970, p. 87.
  • Daniel R. Hughes and Frederick Charles Piper, Projective Planes, Springer, 1973.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Sequences on the four axes of the square spiral: Starting at 0: A001107, A033991, A007742, A033954; starting at 1: A054552, A054556, A054567, A033951.
Sequences on the four diagonals of the square spiral: Starting at 0: A002939 = 2*A000384, A016742 = 4*A000290, A002943 = 2*A014105, A033996 = 8*A000217; starting at 1: A054554, A053755, A054569, A016754.
Sequences obtained by reading alternate terms on the X and Y axes and the two main diagonals of the square spiral: Starting at 0: A035608, A156859, A002378 = 2*A000217, A137932 = 4*A002620; starting at 1: A317186, A267682, A002061, A080335.
Cf. A010000 (minimum Weiner index of 3-degenerate graphs).

Programs

  • GAP
    List([0..50], n->n^2-n+1); # Muniru A Asiru, May 27 2018
  • Haskell
    a002061 n = n * (n - 1) + 1  -- Reinhard Zumkeller, Dec 18 2013
    
  • Magma
    [ n^2 - n + 1 : n in [0..50] ]; // Wesley Ivan Hurt, Jun 12 2014
    
  • Maple
    A002061 := proc(n)
        numtheory[cyclotomic](6,n) ;
    end proc:
    seq(A002061(n), n=0..20); # R. J. Mathar, Feb 07 2014
  • Mathematica
    FoldList[#1 + #2 &, 1, 2 Range[0, 50]] (* Robert G. Wilson v, Feb 02 2011 *)
    LinearRecurrence[{3, -3, 1}, {1, 1, 3}, 60] (* Harvey P. Dale, May 25 2011 *)
    Table[n^2 - n + 1, {n, 0, 50}] (* Wesley Ivan Hurt, Jun 12 2014 *)
    CoefficientList[Series[(1 - 2x + 3x^2)/(1 - x)^3, {x, 0, 52}], x] (* Robert G. Wilson v, Feb 18 2018 *)
    Cyclotomic[6, Range[0, 100]] (* Paolo Xausa, Feb 09 2024 *)
  • Maxima
    makelist(n^2 - n + 1,n,0,55); /* Martin Ettl, Oct 16 2012 */
    
  • PARI
    a(n) = n^2 - n + 1
    

Formula

G.f.: (1 - 2*x + 3*x^2)/(1-x)^3. - Simon Plouffe in his 1992 dissertation
a(n) = -(n-5)*a(n-1) + (n-2)*a(n-2).
a(n) = Phi_6(n) = Phi_3(n-1), where Phi_k is the k-th cyclotomic polynomial.
a(1-n) = a(n). - Michael Somos, Sep 04 2006
a(n) = a(n-1) + 2*(n-1) = 2*a(n-1) - a(n-2) + 2 = 1+A002378(n-1) = 2*A000124(n-1) - 1. - Henry Bottomley, Oct 02 2000 [Corrected by N. J. A. Sloane, Jul 18 2010]
a(n) = A000217(n) + A000217(n-2) (sum of two triangular numbers).
From Paul Barry, Mar 13 2003: (Start)
x*(1+x^2)/(1-x)^3 is g.f. for 0, 1, 3, 7, 13, ...
a(n) = 2*C(n, 2) + C(n-1, 0).
E.g.f.: (1+x^2)*exp(x). (End)
a(n) = ceiling((n-1/2)^2). - Benoit Cloitre, Apr 16 2003. [Hence the terms are about midway between successive squares and so (except for 1) are not squares. - N. J. A. Sloane, Nov 01 2005]
a(n) = 1 + Sum_{j=0..n-1} (2*j). - Xavier Acloque, Oct 08 2003
a(n) = floor(t(n^2)/t(n)), where t(n) = A000217(n). - Jon Perry, Feb 14 2004
a(n) = leftmost term in M^(n-1) * [1 1 1], where M = the 3 X 3 matrix [1 1 1 / 0 1 2 / 0 0 1]. E.g., a(6) = 31 since M^5 * [1 1 1] = [31 11 1]. - Gary W. Adamson, Nov 11 2004
a(n+1) = n^2 + n + 1. a(n+1)*a(n) = (n^6-1)/(n^2-1) = n^4 + n^2 + 1 = a(n^2+1) (a product of two consecutive numbers from this sequence belongs to this sequence). (a(n+1) + a(n))/2 = n^2 + 1. (a(n+1) - a(n))/2 = n. a((a(n+1) + a(n))/2) = a(n+1)*a(n). - Alexander Adamchuk, Apr 13 2006
a(n+1) is the numerator of ((n + 1)! + (n - 1)!)/ n!. - Artur Jasinski, Jan 09 2007
a(n) = A132111(n-1, 1), for n > 1. - Reinhard Zumkeller, Aug 10 2007
a(n) = Det[Transpose[{{-1, 1}, {0, -1}}] - n {{-1, 1}, {0, -1}}]. - Artur Jasinski, Mar 31 2008
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3), n >= 3. - Jaume Oliver Lafont, Dec 02 2008
a(n) = A176271(n,1) for n > 0. - Reinhard Zumkeller, Apr 13 2010
a(n) == 3 (mod n+1). - Bruno Berselli, Jun 03 2010
a(n) = (n-1)^2 + (n-1) + 1 = 111 read in base n-1 (for n > 2). - Jason Kimberley, Oct 18 2011
a(n) = A228643(n, 1), for n > 0. - Reinhard Zumkeller, Aug 29 2013
a(n) = sqrt(A058031(n)). - Richard R. Forberg, Sep 03 2013
G.f.: 1 / (1 - x / (1 - 2*x / (1 + x / (1 - 2*x / (1 + x))))). - Michael Somos, Apr 03 2014
a(n) = A243201(n - 1) / A003215(n - 1), n > 0. - Mathew Englander, Jun 03 2014
For n >= 2, a(n) = ceiling(4/(Sum_{k = A000217(n-1)..A000217(n) - 1}, 1/k)). - Richard R. Forberg, Aug 17 2014
A256188(a(n)) = 1. - Reinhard Zumkeller, Mar 26 2015
Sum_{n>=0} 1/a(n) = 1 + Pi*tanh(Pi*sqrt(3)/2)/sqrt(3) = 2.79814728056269018... . - Vaclav Kotesovec, Apr 10 2016
a(n) = A101321(2,n-1). - R. J. Mathar, Jul 28 2016
a(n) = A000217(n-1) + A000124(n-1), n > 0. - Torlach Rush, Aug 06 2018
Sum_{n>=1} arctan(1/a(n)) = Pi/2. - Amiram Eldar, Nov 01 2020
Sum_{n=1..M} arctan(1/a(n)) = arctan(M). - Lee A. Newberg, May 08 2024
From Amiram Eldar, Jan 20 2021: (Start)
Product_{n>=1} (1 + 1/a(n)) = cosh(sqrt(7)*Pi/2)*sech(sqrt(3)*Pi/2).
Product_{n>=2} (1 - 1/a(n)) = Pi*sech(sqrt(3)*Pi/2). (End)
For n > 1, sqrt(a(n)+sqrt(a(n)-sqrt(a(n)+sqrt(a(n)- ...)))) = n. - Diego Rattaggi, Apr 17 2021
a(n) = (1 + (n-1)^4 + n^4) / (1 + (n-1)^2 + n^2) [see link B.M.O. 2007 and Steve Dinh reference]. - Bernard Schott, Dec 27 2021

Extensions

Partially edited by Joerg Arndt, Mar 11 2010
Partially edited by Bruno Berselli, Dec 19 2013

A059100 a(n) = n^2 + 2.

Original entry on oeis.org

2, 3, 6, 11, 18, 27, 38, 51, 66, 83, 102, 123, 146, 171, 198, 227, 258, 291, 326, 363, 402, 443, 486, 531, 578, 627, 678, 731, 786, 843, 902, 963, 1026, 1091, 1158, 1227, 1298, 1371, 1446, 1523, 1602, 1683, 1766, 1851, 1938, 2027, 2118, 2211, 2306, 2403, 2502, 2603
Offset: 0

Views

Author

Henry Bottomley, Feb 13 2001

Keywords

Comments

Let s(n) = Sum_{k>=1} 1/n^(2^k). Then I conjecture that the maximum element in the continued fraction for s(n) is n^2 + 2. - Benoit Cloitre, Aug 15 2002
Binomial transformation yields A081908, with A081908(0)=1 dropped. - R. J. Mathar, Oct 05 2008
1/a(n) = R(n)/r with R(n) the n-th radius of the Pappus chain of the symmetric arbelos with semicircle radii r, r1 = r/2 = r2. See the MathWorld link for Pappus chain (there are two of them, a left and a right one. In this case these two chains are congruent). - Wolfdieter Lang, Mar 01 2013
a(n) is the number of election results for an election with n+2 candidates, say C1, C2, ..., and C(n+2), and with only two voters (each casting a single vote) that have C1 and C2 receiving the same number of votes. See link below. - Dennis P. Walsh, May 08 2013
This sequence gives the set of values such that for sequences b(k+1) = a(n)*b(k) - b(k-1), with initial values b(0) = 2, b(1) = a(n), all such sequences are invariant under this transformation: b(k) = (b(j+k) + b(j-k))/b(j), except where b(j) = 0, for all integer values of j and k, including negative values. Examples are: at n=0, b(k) = 2 for all k; at n=1, b(k) = A005248; at n=2, b(k) = 2*A001541; at n=3, b(k)= A057076; at n=4, b(k) = 2*A023039. This b(k) family are also the transformation results for all related b'(k) (i.e., those with different initial values) including non-integer values. Further, these b(k) are also the bisections of the transformations of sequences of the form G(k+1) = n * G(k) + G(k-1), and those bisections are invariant for all initial values of g(0) and g(1), including non-integer values. For n = 1 this g(k) family includes Fibonacci and Lucas, where the invariant bisection is b(k) = A005248. The applicable bisection for this transformation of g(k) is for the odd values of k, and applies for all n. Also see A000032 for a related family of sequences. - Richard R. Forberg, Nov 22 2014
Also the number of maximum matchings in the n-gear graph. - Eric W. Weisstein, Dec 31 2017
Also the Wiener index of the n-dipyramidal graph. - Eric W. Weisstein, Jun 14 2018
Numbers of the form n^2+2 have no factors that are congruent to 7 (mod 8). - Gordon E. Michaels, Sep 12 2019
For n >= 1, the continued fraction expansion of sqrt(a(n)) is [n; {n, 2n}]. - Magus K. Chu, Sep 10 2022

Examples

			For n = 2, a(2) = 6 since there are 6 election results in a 4-candidate, 2-voter election that have candidates c1 and c2 tied. Letting <i,j> denote voter 1 voting for candidate i and voter 2 voting for candidate j, the six election results are <1,2>, <2,1>, <3,3>, <3,4>, <4,3>, and <4,4>. - _Dennis P. Walsh_, May 08 2013
		

Crossrefs

Apart from initial terms, same as A010000.
2nd row/column of A295707.

Programs

Formula

G.f.: (2 - 3*x + 3*x^2)/(1 - x)^3. - R. J. Mathar, Oct 05 2008
a(n) = ((n - 2)^2 + 2*(n + 1)^2)/3. - Reinhard Zumkeller, Feb 13 2009
a(n) = A000196(A156798(n) - A000290(n)). - Reinhard Zumkeller, Feb 16 2009
a(n) = 2*n + a(n-1) - 1 with a(0) = 2. - Vincenzo Librandi, Aug 07 2010
a(n+3) = (A166464(n+5) - A166464(n))/20. - Paul Curtz, Nov 07 2012
From Paul Curtz, Nov 07 2012: (Start)
a(3*n) mod 9 = 2.
a(3*n+1) = 3*A056109(n).
a(3*n+2) = 3*A056105(n+1). (End)
Sum_{n >= 1} 1/a(n) = Pi * coth(sqrt(2)*Pi) / 2^(3/2) - 1/4. - Vaclav Kotesovec, May 01 2018
From Amiram Eldar, Jan 29 2021: (Start)
Sum_{n>=0} (-1)^n/a(n) = (1 + sqrt(2)*Pi*(csch(sqrt(2)*Pi)))/4.
Product_{n>=0} (1 + 1/a(n)) = sqrt(3/2)*csch(sqrt(2)*Pi)*sinh(sqrt(3)*Pi).
Product_{n>=0} (1 - 1/a(n)) = csch(sqrt(2)*Pi)*sinh(Pi)/sqrt(2). (End)
E.g.f.: exp(x)*(2 + x + x^2). - Stefano Spezia, Aug 07 2024

A206399 a(0) = 1; for n > 0, a(n) = 41*n^2 + 2.

Original entry on oeis.org

1, 43, 166, 371, 658, 1027, 1478, 2011, 2626, 3323, 4102, 4963, 5906, 6931, 8038, 9227, 10498, 11851, 13286, 14803, 16402, 18083, 19846, 21691, 23618, 25627, 27718, 29891, 32146, 34483, 36902, 39403, 41986, 44651, 47398, 50227, 53138, 56131, 59206, 62363, 65602
Offset: 0

Views

Author

Bruno Berselli, Feb 07 2012

Keywords

Comments

Apart from the first term, numbers of the form (r^2 + 2*s^2)*n^2 + 2 = (r*n)^2 + (s*n - 1)^2 + (s*n + 1)^2: in this case is r = 3, s = 4. After 1, all terms are in A000408.

Crossrefs

Programs

  • Magma
    [n eq 0 select 1 else 41*n^2+2: n in [0..39]];
    
  • Magma
    I:=[1,43,166,371]; [n le 4 select I[n] else 3*Self(n-1)-3*Self(n-2)+Self(n-3): n in [1..41]]; // Vincenzo Librandi, Aug 18 2013
    
  • Mathematica
    Join[{1}, 41 Range[39]^2 + 2]
    CoefficientList[Series[(1 + x) (1 + 39 x + x^2) / (1 - x)^3, {x, 0, 40}], x] (* Vincenzo Librandi, Aug 18 2013 *)
  • PARI
    a(n)=if(n,41*n^2+2,1) \\ Charles R Greathouse IV, Sep 24 2015

Formula

O.g.f.: (1 + x)*(1 + 39*x + x^2)/(1 - x)^3.
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3) for n >= 4. - Wesley Ivan Hurt, Dec 18 2020
E.g.f.: exp(x)*(41*x^2 + 41*x + 2) - 1. - Elmo R. Oliveira, Nov 29 2024

A068527 Difference between smallest square >= n and n.

Original entry on oeis.org

0, 0, 2, 1, 0, 4, 3, 2, 1, 0, 6, 5, 4, 3, 2, 1, 0, 8, 7, 6, 5, 4, 3, 2, 1, 0, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0, 14, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0, 16, 15, 14, 13, 12, 11, 10, 9, 8, 7, 6, 5, 4, 3, 2, 1, 0, 18, 17, 16, 15, 14, 13, 12, 11, 10, 9
Offset: 0

Views

Author

Vladeta Jovovic, Mar 21 2002

Keywords

Comments

The greedy inverse (sequence of the smallest k such that a(k)=n) starts 0, 3, 2, 6, 5, 11, 10, 18, 17, 27, 26, 38, 37, 51, 50, ... and appears to be given by A010000 and A002522, interleaved. - R. J. Mathar, Nov 17 2014

Crossrefs

Bisections: A348596, A350962.

Programs

Formula

a(n) = A048761(n) - n = ceiling(sqrt(n))^2 - n.
G.f.: (-x^2 + (x-x^2)*Sum_{m>=1} (1+2*m)*x^(m^2))/(1-x)^2. This sum is related to Jacobi Theta functions. - Robert Israel, Nov 17 2014

A064801 Take 1, skip 2, take 2, skip 3, take 3, etc.

Original entry on oeis.org

1, 4, 5, 9, 10, 11, 16, 17, 18, 19, 25, 26, 27, 28, 29, 36, 37, 38, 39, 40, 41, 49, 50, 51, 52, 53, 54, 55, 64, 65, 66, 67, 68, 69, 70, 71, 81, 82, 83, 84, 85, 86, 87, 88, 89, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 121, 122, 123, 124, 125, 126, 127, 128
Offset: 1

Views

Author

Robert G. Wilson v, Oct 21 2001

Keywords

Comments

A253607(a(n)) < 0. - Reinhard Zumkeller, Jan 05 2015
Integers m such that A000196(m) = A079643(m). - Firas Melaih, Dec 10 2020
Also possible values of floor(x*floor(x)) for real x >= 1. - Jianing Song, Feb 16 2021

Crossrefs

Cf. A061885 (complement), A253607.
Cf. A136272.

Programs

  • Haskell
    a064801 n = a064801_list !! (n-1)
    a064801_list = f 1 [1..] where
       f k xs = us ++ f (k + 1) (drop (k + 1) vs)
                where (us, vs) = splitAt k xs
    -- Reinhard Zumkeller, May 16 2014
    
  • Maple
    seq(`if`(floor(sqrt(k)) * (floor(sqrt(k)) + 1) > k, k, NULL), k = 0..2034); # a(1)..a(1000), Rainer Rosenthal, Jul 19 2024
  • Mathematica
    a = Table[n, {n, 0, 200} ]; b = {}; Do[a = Drop[a, {1, n} ]; b = Append[b, Take[a, {1, n} ]]; a = Drop[a, {1, n} ], {n, 1, 14} ]; Flatten[b]
    Flatten[Table[Range[n^2,n^2+n-1],{n,12}]] (* Harvey P. Dale, Dec 18 2015 *)
  • PARI
    { n=0; for (m=1, 10^9, s=m^2; a=0; for (k=0, m - 1, a=s+k; write("b064801.txt", n++, " ", a); if (n==1000, return)) ) } \\ Harry J. Smith, Sep 26 2009
    
  • Python
    from math import isqrt  # after Rainer Rosenthal
    def isA(k: int): return k < ((s:=isqrt(k)) * (s + 1))
    print([k for k in range(129) if isA(k)]) # Peter Luschny, Jul 19 2024

Formula

a(n) = A004202(n) - 1.
Can be interpreted as a table read by rows: T(n,k) = n^2 + k, 0 <= k < n. T(n,k) = 0 iff k > A000196(n); T(n,0) = A000290(n); T(n,1) = A002522(n) for n > 1; T(n,2) = A010000(n) = A059100(n) for n > 2; T(n, n-3) = A014209(n-1) for n > 2; T(n, n-2) = A028552(n) for n > 1; T(n, n-1) = A028387(n-1); T(2*n+1, n) = A001107(n+1). - Reinhard Zumkeller, Nov 18 2003
Numbers k such that floor(sqrt(k)) * (floor(sqrt(k)) + 1) > k. - Rainer Rosenthal, Jul 19 2024

A102305 a(n) = n^2 + 2*n + 3.

Original entry on oeis.org

6, 11, 18, 27, 38, 51, 66, 83, 102, 123, 146, 171, 198, 227, 258, 291, 326, 363, 402, 443, 486, 531, 578, 627, 678, 731, 786, 843, 902, 963, 1026, 1091, 1158, 1227, 1298, 1371, 1446, 1523, 1602, 1683, 1766, 1851, 1938, 2027, 2118, 2211, 2306, 2403
Offset: 1

Views

Author

Ralf Stephan, Jan 03 2005

Keywords

Comments

Essentially a duplicate of A059100.

Crossrefs

Programs

Formula

a(n) = (1/5) * A027578(n-1).
a(n) = 2*n + a(n-1) + 1 (with a(1)=6). - Vincenzo Librandi, Nov 16 2010
a(n) = A059100(n+1). - Reinhard Zumkeller, Mar 21 2008
a(n) = A010000(n+1) for n >= 1. - Georg Fischer, Nov 02 2018
From Amiram Eldar, Sep 14 2022: (Start)
Sum_{n>=1} 1/a(n) = Pi * coth(sqrt(2)*Pi)/(2*sqrt(2)) - 7/12.
Sum_{n>=1} (-1)^(n+1)/a(n) = cosech(sqrt(2)*Pi)*Pi/(2*sqrt(2)) + 1/12. (End)
From G. C. Greubel, Feb 03 2024: (Start)
G.f.: (3 - 3*x + 2*x^2)/(1-x)^3.
E.g.f.: (3 + 3*x + x^2)*exp(x). (End)

A197603 a(n) = floor((n+1/n)^4).

Original entry on oeis.org

16, 39, 123, 326, 731, 1446, 2603, 4358, 6891, 10406, 15131, 21318, 29243, 39206, 51531, 66566, 84683, 106278, 131771, 161606, 196251, 236198, 281963, 334086, 393131, 459686, 534363, 617798, 710651, 813606, 927371, 1052678, 1190283, 1340966, 1505531, 1684806, 1879643, 2090918, 2319531, 2566406, 2832491, 3118758
Offset: 1

Views

Author

Vincenzo Librandi, Oct 17 2011

Keywords

Crossrefs

Programs

  • Magma
    [Floor((n+1/n)^4): n in [1..60]];
    
  • Mathematica
    Table[Floor[(n+1/n)^4],{n,50}] (* or *) LinearRecurrence[{5,-10,10,-5,1},{16,39,123,326,731,1446,2603},50] (* Harvey P. Dale, Jun 03 2015 *)
  • PARI
    a(n)=floor((n+1/n)^4) \\ Charles R Greathouse IV, Oct 07 2015

Formula

From Bruno Berselli, Oct 17 2011: (Start)
G.f.: x*(16-41*x+88*x^2-59*x^3+21*x^4-x^6)/(1-x)^5.
a(n) = (n^2+2)^2+2 for n>2, a(1)=16, a(2)=39.
a(n) = 5*a(n-1)-10*a(n-2)+10*a(n-3)-5*a(n-4)+a(n-5) for n=6 and n>7.
a(n) = A010000(A010000(n)) for n>2. (End)

A085691 Triangle read by rows: T(n,k) is the number of triangles of side k in triangular matchstick arrangement of side n; n>=1 and k>=1.

Original entry on oeis.org

1, 4, 1, 9, 3, 1, 16, 7, 3, 1, 25, 13, 6, 3, 1, 36, 21, 11, 6, 3, 1, 49, 31, 18, 10, 6, 3, 1, 64, 43, 27, 16, 10, 6, 3, 1, 81, 57, 38, 24, 15, 10, 6, 3, 1, 100, 73, 51, 34, 22, 15, 10, 6, 3, 1, 121, 91, 66, 46, 31, 21, 15, 10, 6, 3, 1, 144, 111, 83, 60, 42, 29, 21, 15, 10, 6, 3, 1
Offset: 1

Views

Author

Philippe Deléham, Jul 18 2003

Keywords

Comments

Sub-triangles can be oriented in one of two ways. The number of sub-triangles that are oriented in the same way as the full triangle is binomial(n-k+2, 2). For k <= n/2, there are also sub-triangles oriented at 180 degrees and the number of these is binomial(n-2*k+2, 2). - Andrew Howroyd, Jan 06 2020
The matchstick arrangement consists of 3*A000217(n) matchsticks. One can also consider it as a tower of cards with n base cards. - Wolfdieter Lang, Apr 06 2020

Examples

			Triangle begins:
    1;
    4,  1;
    9,  3,  1;
   16,  7,  3,  1;
   25, 13,  6,  3,  1;
   36, 21, 11,  6,  3,  1;
   49, 31, 18, 10,  6,  3,  1;
   64, 43, 27, 16, 10,  6,  3, 1;
   81, 57, 38, 24, 15, 10,  6, 3, 1;
  100, 73, 51, 34, 22, 15, 10, 6, 3, 1;
  ...
From _Andrew Howroyd_, Jan 05 2020: (Start)
Row n=3: In the triangle illustrated below there are 9 small triangles, 3 triangles with side length 2 and 1 with side length 3.
            o
           / \
          o---o
         / \ / \
        o---o---o
       / \ / \ / \
      o---o---o---o
(End)
		

References

  • J. H. Conway and R. K. Guy, The Book of Numbers, Copernicus Press, NY, 1996, p. 83.

Crossrefs

Row sums are A002717.
Columns k=1..3 are A000290, A002061, A010000.

Programs

  • PARI
    T(n, k)={binomial(n-k+2, 2) + if(2*k<=n, binomial(n-2*k+2, 2), 0)} \\ Andrew Howroyd, Jan 06 2020
    
  • PARI
    T(n, k)={if(k>n, 0, if(2*k > n, (n-k+1)*(n-k+2)/2, n^2 - 3*(k-1)*n + (5*k-4)*(k-1)/2))} \\ Andrew Howroyd, Jan 06 2020

Formula

T(n, k) = 0 for n < k; T(n, k) = (n-k+1)*(n-k+2)/2 for k <= n < 2*k; T(n, k) = n^2 - 3*(k-1)*n + (5*k-4)*(k-1)/2 for 2*k <= n.
T(n, k) = Tup(n, k) + Tdown(n, k), with Tup(n, k) = (-1)*(n-k)*A122432(n-1, k-1) and Tdown(n, k) = A332442(n, k), for n >= 1, and k = 1, 2, ..., n. - Wolfdieter Lang, Apr 06 2020

Extensions

Offset corrected and terms a(37) and beyond from Andrew Howroyd, Jan 05 2020

A160842 Number of lines through at least 2 points of a 2 X n grid of points.

Original entry on oeis.org

0, 1, 6, 11, 18, 27, 38, 51, 66, 83, 102, 123, 146, 171, 198, 227, 258, 291, 326, 363, 402, 443, 486, 531, 578, 627, 678, 731, 786, 843, 902, 963, 1026, 1091, 1158, 1227, 1298, 1371, 1446, 1523, 1602, 1683, 1766, 1851, 1938, 2027, 2118, 2211, 2306, 2403, 2502
Offset: 0

Views

Author

Seppo Mustonen, May 28 2009

Keywords

Crossrefs

Programs

  • Magma
    [0,1] cat [n^2 + 2: n in [2..100]]; // G. C. Greubel, Apr 30 2018
  • Mathematica
    a[n_]:=If[n<2,n,n^2+2] Table[a[n],{n,0,50}]
    Join[{0,1},Range[2,50]^2+2] (* Harvey P. Dale, Feb 06 2015 *)
  • PARI
    Vec(-x*(2*x^3-4*x^2+3*x+1) / (x-1)^3 + O(x^100)) \\ Colin Barker, May 24 2015
    

Formula

a(n) = n^2 + 2 = A059100(n) = A010000(n) for n > 1.
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3) for n > 4. - Colin Barker, May 24 2015
G.f.: -x*(2*x^3 - 4*x^2 + 3*x + 1) / (x-1)^3. - Colin Barker, May 24 2015
Sum_{n>=1} 1/a(n) = Pi * coth(sqrt(2)*Pi) / 2^(3/2) - 1/4. - Vaclav Kotesovec, May 01 2018

A097292 Rectangular array T, by antidiagonals: T(n,k) = rank of n in A097291 at which the pair (n,k) occurs.

Original entry on oeis.org

1, 2, 4, 5, 3, 9, 10, 8, 7, 16, 17, 13, 6, 12, 25, 26, 20, 15, 14, 19, 36, 37, 29, 22, 11, 21, 28, 49, 50, 40, 31, 24, 23, 30, 39, 64, 65, 53, 42, 33, 18, 32, 41, 52, 81, 82, 68, 55, 44, 35, 34, 43, 54, 67, 100, 101, 85, 70, 57, 46, 27, 45, 56, 69, 84, 121
Offset: 1

Views

Author

Clark Kimberling, Aug 05 2004

Keywords

Comments

Row 1 is A002522.
Column 1 (squares) is A002900.
Main diagonal is 2+(n-1)^2 for n>1, cf. A010000.

Examples

			Northwest corner:
   1  2  5  10
   4  3  8  13
   9  7  6  15
  16 12 14  11
T(3,4) = 15 because in A097291, the pair 3,4 occurs at positions 15,16.
		

Crossrefs

Showing 1-10 of 19 results. Next