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

A145067 Zero followed by partial sums of A008865.

Original entry on oeis.org

0, -1, 1, 8, 22, 45, 79, 126, 188, 267, 365, 484, 626, 793, 987, 1210, 1464, 1751, 2073, 2432, 2830, 3269, 3751, 4278, 4852, 5475, 6149, 6876, 7658, 8497, 9395, 10354, 11376, 12463, 13617, 14840, 16134, 17501, 18943, 20462, 22060, 23739, 25501
Offset: 1

Views

Author

Keywords

Examples

			a(2) = a(1) + 1^2 - 2 = 0 + 1 - 2 = -1; a(3) = a(2) + 2^2 - 2 = -1 + 4 - 2 = 1.
		

Crossrefs

Cf. A008865 (n^2 - 2), A002522 (n^2 + 1), A145066 (partial sums of A002522, starting at n=1), A005563 ((n+1)^2 - 1), A051925 (zero followed by partial sums of A005563), A000330.

Programs

  • Mathematica
    lst={0}; s=0; Do[s+=n^2 - 2; AppendTo[lst, s], {n, 5!}]; lst
    Table[Sum[(i^2 + n - 1), {i, 0, n}], {n, -1, 41}] (* Zerinvary Lajos, Jul 11 2009 *)
    Join[{0},Accumulate[Range[50]^2-2]] (* Harvey P. Dale, Jul 23 2018 *)
  • PARI
    {a=2; for(n=0, 42, print1(a=a+n^2-2, ","))}

Formula

a(1) = 0; a(n) = a(n-1) + (n-1)^2 - 2 for n > 0.
a(n) = Sum_{k=1...n-1} (k^2-2) = A000330(n-1)-2*A000027(n-1) = (n-1)*(2*n^2-n-12)/6. - Christoph Pacher (christoph.pacher(AT)ait.ac.at), Jul 23 2010
G.f.: -x^2*(1-5*x+2*x^2)/(1-x)^4. - Colin Barker, Apr 04 2012

Extensions

Edited by Klaus Brockhaus, Oct 17 2008

A152179 (n^2-2=A008865) mod 9. Period 9: repeat 8,2,7,5,5,7,2,8,7.

Original entry on oeis.org

8, 2, 7, 5, 5, 7, 2, 8, 7, 8, 2, 7, 5, 5, 7, 2, 8, 7, 8, 2, 7, 5, 5, 7, 2, 8, 7, 8, 2, 7, 5, 5, 7, 2, 8, 7, 8, 2, 7, 5, 5, 7, 2, 8, 7, 8, 2, 7, 5, 5, 7, 2, 8, 7
Offset: 0

Views

Author

Paul Curtz, Nov 28 2008

Keywords

A000290 The squares: a(n) = n^2.

Original entry on oeis.org

0, 1, 4, 9, 16, 25, 36, 49, 64, 81, 100, 121, 144, 169, 196, 225, 256, 289, 324, 361, 400, 441, 484, 529, 576, 625, 676, 729, 784, 841, 900, 961, 1024, 1089, 1156, 1225, 1296, 1369, 1444, 1521, 1600, 1681, 1764, 1849, 1936, 2025, 2116, 2209, 2304, 2401, 2500
Offset: 0

Views

Author

Keywords

Comments

To test if a number is a square, see Cohen, p. 40. - N. J. A. Sloane, Jun 19 2011
Zero followed by partial sums of A005408 (odd numbers). - Jeremy Gardiner, Aug 13 2002
Begin with n, add the next number, subtract the previous number and so on ending with subtracting a 1: a(n) = n + (n+1) - (n-1) + (n+2) - (n-2) + (n+3) - (n-3) + ... + (2n-1) - 1 = n^2. - Amarnath Murthy, Mar 24 2004
Sum of two consecutive triangular numbers A000217. - Lekraj Beedassy, May 14 2004
Numbers with an odd number of divisors: {d(n^2) = A048691(n); for the first occurrence of 2n + 1 divisors, see A071571(n)}. - Lekraj Beedassy, Jun 30 2004
See also A000037.
First sequence ever computed by electronic computer, on EDSAC, May 06 1949 (see Renwick link). - Russ Cox, Apr 20 2006
Numbers k such that the imaginary quadratic field Q(sqrt(-k)) has four units. - Marc LeBrun, Apr 12 2006
For n > 0: number of divisors of (n-1)th power of any squarefree semiprime: a(n) = A000005(A006881(k)^(n-1)); a(n) = A000005(A000400(n-1)) = A000005(A011557(n-1)) = A000005(A001023(n-1)) = A000005(A001024(n-1)). - Reinhard Zumkeller, Mar 04 2007
If a 2-set Y and an (n-2)-set Z are disjoint subsets of an n-set X then a(n-2) is the number of 3-subsets of X intersecting both Y and Z. - Milan Janjic, Sep 19 2007
Numbers a such that a^1/2 + b^1/2 = c^1/2 and a^2 + b = c. - Cino Hilliard, Feb 07 2008 (this comment needs clarification, Joerg Arndt, Sep 12 2013)
Numbers k such that the geometric mean of the divisors of k is an integer. - Ctibor O. Zizka, Jun 26 2008
Equals row sums of triangle A143470. Example: 36 = sum of row 6 terms: (23 + 7 + 3 + 1 + 1 + 1). - Gary W. Adamson, Aug 17 2008
Equals row sums of triangles A143595 and A056944. - Gary W. Adamson, Aug 26 2008
Number of divisors of 6^(n-1) for n > 0. - J. Lowell, Aug 30 2008
Denominators of Lyman spectrum of hydrogen atom. Numerators are A005563. A000290-A005563 = A000012. - Paul Curtz, Nov 06 2008
a(n) is the number of all partitions of the sum 2^2 + 2^2 + ... + 2^2, (n-1) times, into powers of 2. - Valentin Bakoev, Mar 03 2009
a(n) is the maximal number of squares that can be 'on' in an n X n board so that all the squares turn 'off' after applying the operation: in any 2 X 2 sub-board, a square turns from 'on' to 'off' if the other three are off. - Srikanth K S, Jun 25 2009
Zero together with the numbers k such that 2 is the number of perfect partitions of k. - Juri-Stepan Gerasimov, Sep 26 2009
Totally multiplicative sequence with a(p) = p^2 for prime p. - Jaroslav Krizek, Nov 01 2009
Satisfies A(x)/A(x^2), A(x) = A173277: (1, 4, 13, 32, 74, ...). - Gary W. Adamson, Feb 14 2010
Positive members are the integers with an odd number of odd divisors and an even number of even divisors. See also A120349, A120359, A181792, A181793, A181795. - Matthew Vandermast, Nov 14 2010
Besides the first term, this sequence is the denominator of Pi^2/6 = 1 + 1/4 + 1/9 + 1/16 + 1/25 + 1/36 + ... . - Mohammad K. Azarian, Nov 01 2011
Partial sums give A000330. - Omar E. Pol, Jan 12 2013
Drmota, Mauduit, and Rivat proved that the Thue-Morse sequence along the squares is normal; see A228039. - Jonathan Sondow, Sep 03 2013
a(n) can be decomposed into the sum of the four numbers [binomial(n, 1) + binomial(n, 2) + binomial(n-1, 1) + binomial(n-1, 2)] which form a "square" in Pascal's Triangle A007318, or the sum of the two numbers [binomial(n, 2) + binomial(n+1, 2)], or the difference of the two numbers [binomial(n+2, 3) - binomial(n, 3)]. - John Molokach, Sep 26 2013
In terms of triangular tiling, the number of equilateral triangles with side length 1 inside an equilateral triangle with side length n. - K. G. Stier, Oct 30 2013
Number of positive roots in the root systems of type B_n and C_n (when n > 1). - Tom Edgar, Nov 05 2013
Squares of squares (fourth powers) are also called biquadratic numbers: A000583. - M. F. Hasler, Dec 29 2013
For n > 0, a(n) is the largest integer k such that k^2 + n is a multiple of k + n. More generally, for m > 0 and n > 0, the largest integer k such that k^(2*m) + n is a multiple of k + n is given by k = n^(2*m). - Derek Orr, Sep 03 2014
For n > 0, a(n) is the number of compositions of n + 5 into n parts avoiding the part 2. - Milan Janjic, Jan 07 2016
a(n), for n >= 3, is also the number of all connected subtrees of a cycle graph, having n vertices. - Viktar Karatchenia, Mar 02 2016
On every sequence of natural continuous numbers with an even number of elements, the summatory of the second half of the sequence minus the summatory of the first half of the sequence is always a square. Example: Sequence from 61 to 70 has an even number of elements (10). Then 61 + 62 + 63 + 64 + 65 = 315; 66 + 67 + 68 + 69 + 70 = 340; 340 - 315 = 25. (n/2)^2 for n = number of elements. - César Aguilera, Jun 20 2016
On every sequence of natural continuous numbers from n^2 to (n+1)^2, the sum of the differences of pairs of elements of the two halves in every combination possible is always (n+1)^2. - César Aguilera, Jun 24 2016
Suppose two circles with radius 1 are tangent to each other as well as to a line not passing through the point of tangency. Create a third circle tangent to both circles as well as the line. If this process is continued, a(n) for n > 0 is the reciprocals of the radii of the circles, beginning with the largest circle. - Melvin Peralta, Aug 18 2016
Does not satisfy Benford's law [Ross, 2012]. - N. J. A. Sloane, Feb 08 2017
Numerators of the solution to the generalization of the Feynman triangle problem, with an offset of 2. 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 denominators of the ratio of the areas is given by A002061. [Cook & Wood, 2004] - Joe Marasco, Feb 20 2017
Equals row sums of triangle A004737, n >= 1. - Martin Michael Musatov, Nov 07 2017
Right-hand side of the binomial coefficient identity Sum_{k = 0..n} (-1)^(n+k+1)*binomial(n,k)*binomial(n + k,k)*(n - k) = n^2. - Peter Bala, Jan 12 2022
Conjecture: For n>0, min{k such that there exist subsets A,B of {0,1,2,...,a(n)-1} such that |A|=|B|=k and A+B contains {0,1,2,...,a(n)-1}} = n. - Michael Chu, Mar 09 2022
Number of 3-permutations of n elements avoiding the patterns 132, 213, 321. See Bonichon and Sun. - Michel Marcus, Aug 20 2022
Number of intercalates in cyclic Latin squares of order 2n (cyclic Latin squares of odd order do not have intercalates). - Eduard I. Vatutin, Feb 15 2024
a(n) is the number of ternary strings of length n with at most one 0, exactly one 1, and no restriction on the number of 2's. For example, a(3)=9, consisting of the 6 permutations of the string 102 and the 3 permutations of the string 122. - Enrique Navarrete, Mar 12 2025

Examples

			For n = 8, a(8) = 8 * 15 - (1 + 3 + 5 + 7 + 9 + 11 + 13) - 7 = 8 * 15 - 49 - 7 = 64. - _Bruno Berselli_, May 04 2010
G.f. = x + 4*x^2 + 9*x^3 + 16*x^4 + 25*x^5 + 36*x^6 + 49*x^7 + 64*x^8 + 81*x^9 + ...
a(4) = 16. For n = 4 vertices, the cycle graph C4 is A-B-C-D-A. The subtrees are: 4 singles: A, B, C, D; 4 pairs: A-B, BC, C-D, A-D; 4 triples: A-B-C, B-C-D, C-D-A, D-A-B; 4 quads: A-B-C-D, B-C-D-A, C-D-A-B, D-A-B-C; 4 + 4 + 4 + 4 = 16. - _Viktar Karatchenia_, Mar 02 2016
		

References

  • G. L. Alexanderson et al., The William Lowell Putnam Mathematical Competition, Problems and Solutions: 1965-1984, "December 1967 Problem B4(a)", pp. 8(157) MAA Washington DC 1985.
  • T. M. Apostol, Introduction to Analytic Number Theory, Springer-Verlag, 1976, page 2.
  • Albert H. Beiler, Recreations in the theory of numbers, New York, Dover, (2nd ed.) 1966. See Chapter XV, pp. 135-167.
  • R. P. Burn & A. Chetwynd, A Cascade Of Numbers, "The prison door problem" Problem 4 pp. 5-7; 79-80 Arnold London 1996.
  • H. Cohen, A Course in Computational Algebraic Number Theory, Springer, 1996, p. 40.
  • John H. Conway and Richard K. Guy, The Book of Numbers, New York: Springer-Verlag, 1996. See pp. 31, 36, 38, 63.
  • E. Deza and M. M. Deza, Figurate numbers, World Scientific Publishing (2012), p. 6.
  • M. Gardner, Time Travel and Other Mathematical Bewilderments, Chapter 6 pp. 71-2, W. H. Freeman NY 1988.
  • Granino A. Korn and Theresa M. Korn, Mathematical Handbook for Scientists and Engineers, McGraw-Hill Book Company, New York (1968), p. 982.
  • Jan Gullberg, Mathematics from the Birth of Numbers, W. W. Norton & Co., NY & London, 1997, §8.1 Terminology and §8.6 Figurate Numbers, pp. 264, 290-291.
  • Alfred S. Posamentier, The Art of Problem Solving, Section 2.4 "The Long Cell Block" pp. 10-1; 12; 156-7 Corwin Press Thousand Oaks CA 1996.
  • Alfred S. Posamentier, Math Charmers, Tantalizing Tidbits for the Mind, Prometheus Books, NY, 2003, pages 35, 52-53, 129-132, 244.
  • Michel Rigo, Formal Languages, Automata and Numeration Systems, 2 vols., Wiley, 2014. Mentions this sequence - see "List of Sequences" in Vol. 2.
  • 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).
  • J. K. Strayer, Elementary Number Theory, Exercise Set 3.3 Problems 32, 33, p. 88, PWS Publishing Co. Boston MA 1996.
  • C. W. Trigg, Mathematical Quickies, "The Lucky Prisoners" Problem 141 pp. 40, 141, Dover NY 1985.
  • R. Vakil, A Mathematical Mosaic, "The Painted Lockers" pp. 127;134 Brendan Kelly Burlington Ontario 1996.
  • David Wells, The Penguin Dictionary of Curious and Interesting Numbers. Penguin Books, NY, 1986, Revised edition 1987. See p. 123.

Crossrefs

Cf. A092205, A128200, A005408, A128201, A002522, A005563, A008865, A059100, A143051, A143470, A143595, A056944, A001157 (inverse Möbius transform), A001788 (binomial transform), A228039, A001105, A004159, A159918, A173277, A095794, A162395, A186646 (Pisano periods), A028338 (2nd diagonal).
A row or column of A132191.
This sequence is related to partitions of 2^n into powers of 2, as it is shown in A002577. So A002577 connects the squares and A000447. - Valentin Bakoev, Mar 03 2009
Boustrophedon transforms: A000697, A000745.
Cf. A342819.
Cf. A013661.

Programs

Formula

G.f.: x*(1 + x) / (1 - x)^3.
E.g.f.: exp(x)*(x + x^2).
Dirichlet g.f.: zeta(s-2).
a(n) = a(-n).
Multiplicative with a(p^e) = p^(2*e). - David W. Wilson, Aug 01 2001
Sum of all matrix elements M(i, j) = 2*i/(i+j) (i, j = 1..n). a(n) = Sum_{i = 1..n} Sum_{j = 1..n} 2*i/(i + j). - Alexander Adamchuk, Oct 24 2004
a(0) = 0, a(1) = 1, a(n) = 2*a(n-1) - a(n-2) + 2. - Miklos Kristof, Mar 09 2005
From Pierre CAMI, Oct 22 2006: (Start)
a(n) is the sum of the odd numbers from 1 to 2*n - 1.
a(0) = 0, a(1) = 1, then a(n) = a(n-1) + 2*n - 1. (End)
For n > 0: a(n) = A130064(n)*A130065(n). - Reinhard Zumkeller, May 05 2007
a(n) = Sum_{k = 1..n} A002024(n, k). - Reinhard Zumkeller, Jun 24 2007
Left edge of the triangle in A132111: a(n) = A132111(n, 0). - Reinhard Zumkeller, Aug 10 2007
Binomial transform of [1, 3, 2, 0, 0, 0, ...]. - Gary W. Adamson, Nov 21 2007
a(n) = binomial(n+1, 2) + binomial(n, 2).
This sequence could be derived from the following general formula (cf. A001286, A000330): n*(n+1)*...*(n+k)*(n + (n+1) + ... + (n+k))/((k+2)!*(k+1)/2) at k = 0. Indeed, using the formula for the sum of the arithmetic progression (n + (n+1) + ... + (n+k)) = (2*n + k)*(k + 1)/2 the general formula could be rewritten as: n*(n+1)*...*(n+k)*(2*n+k)/(k+2)! so for k = 0 above general formula degenerates to n*(2*n + 0)/(0 + 2) = n^2. - Alexander R. Povolotsky, May 18 2008
From a(4) recurrence formula a(n+3) = 3*a(n+2) - 3*a(n+1) + a(n) and a(1) = 1, a(2) = 4, a(3) = 9. - Artur Jasinski, Oct 21 2008
The recurrence a(n+3) = 3*a(n+2) - 3*a(n+1) + a(n) is satisfied by all k-gonal sequences from a(3), with a(0) = 0, a(1) = 1, a(2) = k. - Jaume Oliver Lafont, Nov 18 2008
a(n) = floor(n*(n+1)*(Sum_{i = 1..n} 1/(n*(n+1)))). - Ctibor O. Zizka, Mar 07 2009
Product_{i >= 2} 1 - 2/a(i) = -sin(A063448)/A063448. - R. J. Mathar, Mar 12 2009
a(n) = A002378(n-1) + n. - Jaroslav Krizek, Jun 14 2009
a(n) = n*A005408(n-1) - (Sum_{i = 1..n-2} A005408(i)) - (n-1) = n*A005408(n-1) - a(n-1) - (n-1). - Bruno Berselli, May 04 2010
a(n) == 1 (mod n+1). - Bruno Berselli, Jun 03 2010
a(n) = a(n-1) + a(n-2) - a(n-3) + 4, n > 2. - Gary Detlefs, Sep 07 2010
a(n+1) = Integral_{x >= 0} exp(-x)/( (Pn(x)*exp(-x)*Ei(x) - Qn(x))^2 +(Pi*exp(-x)*Pn(x))^2 ), with Pn the Laguerre polynomial of order n and Qn the secondary Laguerre polynomial defined by Qn(x) = Integral_{t >= 0} (Pn(x) - Pn(t))*exp(-t)/(x-t). - Groux Roland, Dec 08 2010
Euler transform of length-2 sequence [4, -1]. - Michael Somos, Feb 12 2011
A162395(n) = -(-1)^n * a(n). - Michael Somos, Mar 19 2011
a(n) = A004201(A000217(n)); A007606(a(n)) = A000384(n); A007607(a(n)) = A001105(n). - Reinhard Zumkeller, Feb 12 2011
Sum_{n >= 1} 1/a(n)^k = (2*Pi)^k*B_k/(2*k!) = zeta(2*k) with Bernoulli numbers B_k = -1, 1/6, 1/30, 1/42, ... for k >= 0. See A019673, A195055/10 etc. [Jolley eq 319].
Sum_{n>=1} (-1)^(n+1)/a(n)^k = 2^(k-1)*Pi^k*(1-1/2^(k-1))*B_k/k! [Jolley eq 320] with B_k as above.
A007968(a(n)) = 0. - Reinhard Zumkeller, Jun 18 2011
A071974(a(n)) = n; A071975(a(n)) = 1. - Reinhard Zumkeller, Jul 10 2011
a(n) = A199332(2*n - 1, n). - Reinhard Zumkeller, Nov 23 2011
For n >= 1, a(n) = Sum_{d|n} phi(d)*psi(d), where phi is A000010 and psi is A001615. - Enrique Pérez Herrero, Feb 29 2012
a(n) = A000217(n^2) - A000217(n^2 - 1), for n > 0. - Ivan N. Ianakiev, May 30 2012
a(n) = (A000217(n) + A000326(n))/2. - Omar E. Pol, Jan 11 2013
a(n) = A162610(n, n) = A209297(n, n) for n > 0. - Reinhard Zumkeller, Jan 19 2013
a(A000217(n)) = Sum_{i = 1..n} Sum_{j = 1..n} i*j, for n > 0. - Ivan N. Ianakiev, Apr 20 2013
a(n) = A133280(A000217(n)). - Ivan N. Ianakiev, Aug 13 2013
a(2*a(n)+2*n+1) = a(2*a(n)+2*n) + a(2*n+1). - Vladimir Shevelev, Jan 24 2014
a(n+1) = Sum_{t1+2*t2+...+n*tn = n} (-1)^(n+t1+t2+...+tn)*multinomial(t1+t2 +...+tn,t1,t2,...,tn)*4^(t1)*7^(t2)*8^(t3+...+tn). - Mircea Merca, Feb 27 2014
a(n) = floor(1/(1-cos(1/n)))/2 = floor(1/(1-n*sin(1/n)))/6, n > 0. - Clark Kimberling, Oct 08 2014
a(n) = ceiling(Sum_{k >= 1} log(k)/k^(1+1/n)) = -Zeta'[1+1/n]. Thus any exponent greater than 1 applied to k yields convergence. The fractional portion declines from A073002 = 0.93754... at n = 1 and converges slowly to 0.9271841545163232... for large n. - Richard R. Forberg, Dec 24 2014
a(n) = Sum_{j = 1..n} Sum_{i = 1..n} ceiling((i + j - n + 1)/3). - Wesley Ivan Hurt, Mar 12 2015
a(n) = Product_{j = 1..n-1} 2 - 2*cos(2*j*Pi/n). - Michel Marcus, Jul 24 2015
From Ilya Gutkovskiy, Jun 21 2016: (Start)
Product_{n >= 1} (1 + 1/a(n)) = sinh(Pi)/Pi = A156648.
Sum_{n >= 0} 1/a(n!) = BesselI(0, 2) = A070910. (End)
a(n) = A028338(n, n-1), n >= 1 (second diagonal). - Wolfdieter Lang, Jul 21 2017
For n >= 1, a(n) = Sum_{d|n} sigma_2(d)*mu(n/d) = Sum_{d|n} A001157(d)*A008683(n/d). - Ridouane Oudra, Apr 15 2021
a(n) = Sum_{i = 1..2*n-1} ceiling(n - i/2). - Stefano Spezia, Apr 16 2021
From Richard L. Ollerton, May 09 2021: (Start) For n >= 1,
a(n) = Sum_{k=1..n} psi(n/gcd(n,k)).
a(n) = Sum_{k=1..n} psi(gcd(n,k))*phi(gcd(n,k))/phi(n/gcd(n,k)).
a(n) = Sum_{k=1..n} sigma_2(n/gcd(n,k))*mu(gcd(n,k))/phi(n/gcd(n,k)).
a(n) = Sum_{k=1..n} sigma_2(gcd(n,k))*mu(n/gcd(n,k))/phi(n/gcd(n,k)). (End)
a(n) = (A005449(n) + A000326(n))/3. - Klaus Purath, May 13 2021
Let T(n) = A000217(n), then a(T(n)) + a(T(n+1)) = T(a(n+1)). - Charlie Marion, Jun 27 2022
a(n) = Sum_{k=1..n} sigma_1(k) + Sum_{i=1..n} (n mod i). - Vadim Kataev, Dec 07 2022
a(n^2) + a(n^2+1) + ... + a(n^2+n) + 4*A000537(n) = a(n^2+n+1) + ... + a(n^2+2n). In general, if P(k,n) = the n-th k-gonal number, then P(2k,n^2) + P(2k,n^2+1) + ... + P(2k,n^2+n) + 4*(k-1)*A000537(n) = P(2k,n^2+n+1) + ... + P(2k,n^2+2n). - Charlie Marion, Apr 26 2024
Sum_{n>=1} 1/a(n) = A013661. - Alois P. Heinz, Oct 19 2024
a(n) = 1 + 3^3*((n-1)/(n+1))^2 + 5^3*((n-1)*(n-2)/((n+1)*(n+2)))^2 + 7^3*((n-1)*(n-2)*(n-3)/((n+1)*(n+2)*(n+3)))^2 + ... for n >= 1. - Peter Bala, Dec 09 2024

Extensions

Incorrect comment and example removed by Joerg Arndt, Mar 11 2010

A000096 a(n) = n*(n+3)/2.

Original entry on oeis.org

0, 2, 5, 9, 14, 20, 27, 35, 44, 54, 65, 77, 90, 104, 119, 135, 152, 170, 189, 209, 230, 252, 275, 299, 324, 350, 377, 405, 434, 464, 495, 527, 560, 594, 629, 665, 702, 740, 779, 819, 860, 902, 945, 989, 1034, 1080, 1127, 1175, 1224, 1274, 1325, 1377, 1430, 1484, 1539, 1595, 1652, 1710, 1769
Offset: 0

Views

Author

Keywords

Comments

For n >= 1, a(n) is the maximal number of pieces that can be obtained by cutting an annulus with n cuts. See illustration. - Robert G. Wilson v
n(n-3)/2 (n >= 3) is the number of diagonals of an n-gon. - Antreas P. Hatzipolakis (xpolakis(AT)otenet.gr)
n(n-3)/2 (n >= 4) is the degree of the third-smallest irreducible presentation of the symmetric group S_n (cf. James and Kerber, Appendix 1).
a(n) is also the multiplicity of the eigenvalue (-2) of the triangle graph Delta(n+1). (See p. 19 in Biggs.) - Felix Goldberg (felixg(AT)tx.technion.ac.il), Nov 25 2001
For n > 3, a(n-3) = dimension of the traveling salesman polytope T(n). - Benoit Cloitre, Aug 18 2002
Also counts quasi-dominoes (quasi-2-ominoes) on an n X n board. Cf. A094170-A094172. - Jon Wild, May 07 2004
Coefficient of x^2 in (1 + x + 2*x^2)^n. - Michael Somos, May 26 2004
a(n) is the number of "prime" n-dimensional polyominoes. A "prime" n-polyomino cannot be formed by connecting any other n-polyominoes except for the n-monomino and the n-monomino is not prime. E.g., for n=1, the 1-monomino is the line of length 1 and the only "prime" 1-polyominoes are the lines of length 2 and 3. This refers to "free" n-dimensional polyominoes, i.e., that can be rotated along any axis. - Bryan Jacobs (bryanjj(AT)gmail.com), Apr 01 2005
Solutions to the quadratic equation q(m, r) = (-3 +- sqrt(9 + 8(m - r))) / 2, where m - r is included in a(n). Let t(m) = the triangular number (A000217) less than some number k and r = k - t(m). If k is neither prime nor a power of two and m - r is included in A000096, then m - q(m, r) will produce a value that shares a divisor with k. - Andrew S. Plewe, Jun 18 2005
Sum_{k=2..n+1} 4/(k*(k+1)*(k-1)) = ((n+3)*n)/((n+2)*(n+1)). Numerator(Sum_{k=2..n+1} 4/(k*(k+1)*(k-1))) = (n+3)*n/2. - Alexander Adamchuk, Apr 11 2006
Number of rooted trees with n+3 nodes of valence 1, no nodes of valence 2 and exactly two other nodes. I.e., number of planted trees with n+2 leaves and exactly two branch points. - Theo Johnson-Freyd (theojf(AT)berkeley.edu), Jun 10 2007
If X is an n-set and Y a fixed 2-subset of X then a(n-2) is equal to the number of (n-2)-subsets of X intersecting Y. - Milan Janjic, Jul 30 2007
For n >= 1, a(n) is the number of distinct shuffles of the identity permutation on n+1 letters with the identity permutation on 2 letters (12). - Camillia Smith Barnes, Oct 04 2008
If s(n) is a sequence defined as s(1) = x, s(n) = kn + s(n-1) + p for n > 1, then s(n) = a(n-1)*k + (n-1)*p + x. - Gary Detlefs, Mar 04 2010
The only primes are a(1) = 2 and a(2) = 5. - Reinhard Zumkeller, Jul 18 2011
a(n) = m such that the (m+1)-th triangular number minus the m-th triangular number is the (n+1)-th triangular number: (m+1)(m+2)/2 - m(m+1)/2 = (n+1)(n+2)/2. - Zak Seidov, Jan 22 2012
For n >= 1, number of different values that Sum_{k=1..n} c(k)*k can take where the c(k) are 0 or 1. - Joerg Arndt, Jun 24 2012
On an n X n chessboard (n >= 2), the number of possible checkmate positions in the case of king and rook versus a lone king is 0, 16, 40, 72, 112, 160, 216, 280, 352, ..., which is 8*a(n-2). For a 4 X 4 board the number is 40. The number of positions possible was counted including all mirror images and rotations for all four sides of the board. - Jose Abutal, Nov 19 2013
If k = a(i-1) or k = a(i+1) and n = k + a(i), then C(n, k-1), C(n, k), C(n, k+1) are three consecutive binomial coefficients in arithmetic progression and these are all the solutions. There are no four consecutive binomial coefficients in arithmetic progression. - Michael Somos, Nov 11 2015
a(n-1) is also the number of independent components of a symmetric traceless tensor of rank 2 and dimension n >= 1. - Wolfdieter Lang, Dec 10 2015
Numbers k such that 8k + 9 is a square. - Juri-Stepan Gerasimov, Apr 05 2016
Let phi_(D,rho) be the average value of a generic degree D monic polynomial f when evaluated at the roots of the rho-th derivative of f, expressed as a polynomial in the averaged symmetric polynomials in the roots of f. [See the Wojnar et al. link] The "last" term of phi_(D,rho) is a multiple of the product of all roots of f; the coefficient is expressible as a polynomial h_D(N) in N:=D-rho. These polynomials are of the form h_D(N)= ((-1)^D/(D-1)!)*(D-N)*N^chi*g_D(N) where chi = (1 if D is odd, 0 if D is even) and g_D(N) is a monic polynomial of degree (D-2-chi). Then a(n) are the negated coefficients of the next to the highest order term in the polynomials N^chi*g_D(N), starting at D=3. - Gregory Gerard Wojnar, Jul 19 2017
For n >= 2, a(n) is the number of summations required to solve the linear regression of n variables (n-1 independent variables and 1 dependent variable). - Felipe Pedraza-Oropeza, Dec 07 2017
For n >= 2, a(n) is the number of sums required to solve the linear regression of n variables: 5 for two variables (sums of X, Y, X^2, Y^2, X*Y), 9 for 3 variables (sums of X1, X2, Y1, X1^2, X1*X2, X1*Y, X2^2, X2*Y, Y^2), and so on. - Felipe Pedraza-Oropeza, Jan 11 2018
a(n) is the area of a triangle with vertices at (n, n+1), ((n+1)*(n+2)/2, (n+2)*(n+3)/2), ((n+2)^2, (n+3)^2). - J. M. Bergot, Jan 25 2018
Number of terms less than 10^k: 1, 4, 13, 44, 140, 446, 1413, 4471, 14141, 44720, 141420, 447213, ... - Muniru A Asiru, Jan 25 2018
a(n) is also the number of irredundant sets in the (n+1)-path complement graph for n > 2. - Eric W. Weisstein, Apr 11 2018
a(n) is also the largest number k such that the largest Dyck path of the symmetric representation of sigma(k) has exactly n peaks, n >= 1. (Cf. A237593.) - Omar E. Pol, Sep 04 2018
For n > 0, a(n) is the number of facets of associahedra. Cf. A033282 and A126216 and their refinements A111785 and A133437 for related combinatorial and analytic constructs. See p. 40 of Hanson and Sha for a relation to projective spaces and string theory. - Tom Copeland, Jan 03 2021
For n > 0, a(n) is the number of bipartite graphs with 2n or 2n+1 edges, no isolated vertices, and a stable set of cardinality 2. - Christian Barrientos, Jun 13 2022
For n >= 2, a(n-2) is the number of permutations in S_n which are the product of two different transpositions of adjacent points. - Zbigniew Wojciechowski, Mar 31 2023
a(n) represents the optimal stop-number to achieve the highest running score for the Greedy Pig game with an (n-1)-sided die with a loss on a 1. The total at which one should stop is a(s-1), e.g. for a 6-sided die, one should pass the die at 20. See Sparks and Haran. - Nicholas Stefan Georgescu, Jun 09 2024

Examples

			G.f. = 2*x + 5*x^2 + 9*x^3 + 14*x^4 + 20*x^5 + 27*x^6 + 35*x^7 + 44*x^8 + 54*x^9 + ...
		

References

  • M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964 (and various reprintings), Table 22.7, p. 797.
  • Norman Biggs, Algebraic Graph Theory, 2nd ed. Cambridge University Press, 1993.
  • G. James and A. Kerber, The Representation Theory of the Symmetric Group, Encyclopedia of Maths. and its Appls., Vol. 16, Addison-Wesley, 1981, Reading, MA, U.S.A.
  • D. G. Kendall et al., Shape and Shape Theory, Wiley, 1999; see p. 4.
  • 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

Complement of A007401. Column 2 of A145324. Column of triangle A014473, first skew subdiagonal of A033282, a diagonal of A079508.
Occurs as a diagonal in A074079/A074080, i.e., A074079(n+3, n) = A000096(n-1) for all n >= 2. Also A074092(n) = 2^n * A000096(n-1) after n >= 2.
Cf. numbers of the form n*(n*k-k+4)/2 listed in A226488.
Similar sequences are listed in A316466.

Programs

Formula

G.f.: A(x) = x*(2-x)/(1-x)^3. a(n) = binomial(n+1, n-1) + binomial(n, n-1).
Connection with triangular numbers: a(n) = A000217(n+1) - 1.
a(n) = a(n-1) + n + 1. - Bryan Jacobs (bryanjj(AT)gmail.com), Apr 01 2005
a(n) = 2*t(n) - t(n-1) where t() are the triangular numbers, e.g., a(5) = 2*t(5) - t(4) = 2*15 - 10 = 20. - Jon Perry, Jul 23 2003
a(-3-n) = a(n). - Michael Somos, May 26 2004
2*a(n) = A008778(n) - A105163(n). - Creighton Dement, Apr 15 2005
a(n) = C(3+n, 2) - C(3+n, 1). - Zerinvary Lajos, Dec 09 2005
a(n) = A067550(n+1) / A067550(n). - Alexander Adamchuk, May 20 2006
a(n) = A126890(n,1) for n > 0. - Reinhard Zumkeller, Dec 30 2006
a(n) = 3*a(n-1) - 3*a(n-2) + a(n-3). - Paul Curtz, Jan 02 2008
Starting (2, 5, 9, 14, ...) = binomial transform of (2, 3, 1, 0, 0, 0, ...). - Gary W. Adamson, Jul 03 2008
For n >= 0, a(n+2) = b(n+1) - b(n), where b(n) is the sequence A005586. - K.V.Iyer, Apr 27 2009
A002262(a(n)) = n. - Reinhard Zumkeller, May 20 2009
Let A be the Toeplitz matrix of order n defined by: A[i,i-1]=-1, A[i,j]=Catalan(j-i), (i<=j), and A[i,j]=0, otherwise. Then, for n>=1, a(n-1)=coeff(charpoly(A,x),x^(n-2)). - Milan Janjic, Jul 08 2010
a(n) = Sum_{k=1..n} (k+1)!/k!. - Gary Detlefs, Aug 03 2010
a(n) = n(n+1)/2 + n = A000217(n) + n. - Zak Seidov, Jan 22 2012
E.g.f.: F(x) = 1/2*x*exp(x)*(x+4) satisfies the differential equation F''(x) - 2*F'(x) + F(x) = exp(x). - Peter Bala, Mar 14 2012
a(n) = binomial(n+3, 2) - (n+3). - Robert G. Wilson v, Mar 15 2012
a(n) = A181971(n+1, 2) for n > 0. - Reinhard Zumkeller, Jul 09 2012
a(n) = A214292(n+2, 1). - Reinhard Zumkeller, Jul 12 2012
G.f.: -U(0) where U(k) = 1 - 1/((1-x)^2 - x*(1-x)^4/(x*(1-x)^2 - 1/U(k+1))); (continued fraction, 3-step). - Sergei N. Gladkovskii, Sep 27 2012
A023532(a(n)) = 0. - Reinhard Zumkeller, Dec 04 2012
a(n) = A014132(n,n) for n > 0. - Reinhard Zumkeller, Dec 12 2012
a(n-1) = (1/n!)*Sum_{j=0..n} binomial(n,j)*(-1)^(n-j)*j^n*(j-1). - Vladimir Kruchinin, Jun 06 2013
a(n) = 2n - floor(n/2) + floor(n^2/2). - Wesley Ivan Hurt, Jun 15 2013
a(n) = Sum_{i=2..n+1} i. - Wesley Ivan Hurt, Jun 28 2013
Sum_{n>0} 1/a(n) = 11/9. - Enrique Pérez Herrero, Nov 26 2013
a(n) = Sum_{i=1..n} (n - i + 2). - Wesley Ivan Hurt, Mar 31 2014
A023531(a(n)) = 1. - Reinhard Zumkeller, Feb 14 2015
For n > 0: a(n) = A101881(2*n-1). - Reinhard Zumkeller, Feb 20 2015
a(n) + a(n-1) = A008865(n+1) for all n in Z. - Michael Somos, Nov 11 2015
a(n+1) = A127672(4+n, n), n >= 0, where A127672 gives the coefficients of the Chebyshev C polynomials. See the Abramowitz-Stegun reference. - Wolfdieter Lang, Dec 10 2015
a(n) = (n+1)^2 - A000124(n). - Anton Zakharov, Jun 29 2016
Dirichlet g.f.: (zeta(s-2) + 3*zeta(s-1))/2. - Ilya Gutkovskiy, Jun 30 2016
a(n) = 2*A000290(n+3) - 3*A000217(n+3). - J. M. Bergot, Apr 04 2018
a(n) = Stirling2(n+2, n+1) - 1. - Peter Luschny, Jan 05 2021
Sum_{n>=1} (-1)^(n+1)/a(n) = 4*log(2)/3 - 5/9. - Amiram Eldar, Jan 10 2021
From Amiram Eldar, Jan 20 2021: (Start)
Product_{n>=1} (1 + 1/a(n)) = 3.
Product_{n>=1} (1 - 1/a(n)) = 3*cos(sqrt(17)*Pi/2)/(4*Pi). (End)
Product_{n>=0} a(4*n+1)*a(4*n+4)/(a(4*n+2)*a(4*n+3)) = Pi/6. - Michael Jodl, Apr 05 2025

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

A038873 Primes p such that 2 is a square mod p; or, primes congruent to {1, 2, 7} mod 8.

Original entry on oeis.org

2, 7, 17, 23, 31, 41, 47, 71, 73, 79, 89, 97, 103, 113, 127, 137, 151, 167, 191, 193, 199, 223, 233, 239, 241, 257, 263, 271, 281, 311, 313, 337, 353, 359, 367, 383, 401, 409, 431, 433, 439, 449, 457, 463, 479, 487, 503, 521, 569, 577, 593, 599, 601, 607, 617
Offset: 1

Views

Author

Keywords

Comments

Same as A001132 except for initial term.
Primes p such that x^2 = 2 has a solution mod p.
The primes of the form x^2 + 2xy - y^2 coincide with this sequence. These are also primes of the form u^2 - 2v^2. - Tito Piezas III, Dec 28 2008
Therefore these are composite in Z[sqrt(2)], as they can be factored as (u^2 - 2v^2)*(u^2 + 2v^2). - Alonso del Arte, Oct 03 2012
After a(1) = 2, these are the primes p such that p^4 == 1 (mod 96). - Gary Detlefs, Jan 22 2014
Also primes of the form 2v^2 - u^2. For example, 23 = 2*4^2 - 3^2. - Jerzy R Borysowicz, Oct 27 2015
Prime factors of A008865 and A028884. - Klaus Purath, Dec 07 2020

References

  • W. J. LeVeque, Topics in Number Theory. Addison-Wesley, Reading, MA, 2 vols., 1956, Vol. 1, Theorem 5-5, p. 68.

Crossrefs

Cf. A057126, A087780, A226523, A003629 (complement).
Primes in A035251.
For primes p such that x^m == 2 mod p has a solution for m = 2,3,4,5,6,7,... see A038873, A040028, A040098, A040159, A040992, A042966, ...

Programs

  • Magma
    [ p: p in PrimesUpTo(617) | IsSquare(R!2) where R:=ResidueClassRing(p) ]; // Klaus Brockhaus, Dec 02 2008
    
  • Maple
    seq(`if`(member(ithprime(n) mod 8, {1,2,7}),ithprime(n),NULL),n=1..113); # Nathaniel Johnston, Jun 26 2011
  • Mathematica
    fQ[n_] := MemberQ[{1, 2, 7}, Mod[n, 8]]; Select[ Prime[Range[114]], fQ] (* Robert G. Wilson v, Oct 18 2011 *)
  • PARI
    is(n)=isprime(n) && issquare(Mod(2,n)) \\ Charles R Greathouse IV, Apr 23 2015
    
  • PARI
    is(n)=abs(centerlift(Mod(n,8)))<3 && isprime(n) \\ Charles R Greathouse IV, Nov 14 2017

Formula

a(n) ~ 2n log n. - Charles R Greathouse IV, Nov 29 2016

A028871 Primes of the form k^2 - 2.

Original entry on oeis.org

2, 7, 23, 47, 79, 167, 223, 359, 439, 727, 839, 1087, 1223, 1367, 1847, 2207, 2399, 3023, 3719, 3967, 4759, 5039, 5623, 5927, 7919, 8647, 10607, 11447, 13687, 14159, 14639, 16127, 17159, 18223, 19319, 21023, 24023, 25919, 28559, 29927
Offset: 1

Views

Author

Keywords

Comments

Except for the initial term, primes equal to the product of two consecutive even numbers minus 1. - Giovanni Teofilatto, Sep 24 2004
With exception of the first term 2, primes p such that continued fraction of (1+sqrt(p))/2 have period 4. - Artur Jasinski, Feb 03 2010
Subsequence of A094786. First primes q that are in A094786 but not here are 241, 3373, 6857, 19681, 29789, 50651, 300761, 371291, ...; q+2 are perfect powers m^k with odd k>1. - Zak Seidov, Dec 09 2014

References

  • D. Shanks, Solved and Unsolved Problems in Number Theory, 2nd. ed., Chelsea, 1978, p. 31.

Crossrefs

Cf. A028870, A089623, A010051, A094786; subsequence of A008865.

Programs

  • Haskell
    a028871 n = a028871_list !! (n-1)
    a028871_list = filter ((== 1) . a010051') a008865_list
    -- Reinhard Zumkeller, May 06 2013
    
  • Magma
    [p: p in PrimesUpTo(100000)| IsSquare(p+2)]; // Vincenzo Librandi, Jun 19 2014
  • Maple
    select(isprime, [2,seq((2*n+1)^2-2, n=1..1000)]); # Robert Israel, Dec 09 2014
  • Mathematica
    lst={};Do[s=n^2;If[PrimeQ[p=s-2], AppendTo[lst, p]], {n, 6!}];lst (* Vladimir Joseph Stephan Orlovsky, Sep 26 2008 *)
    aa = {}; Do[If[4 == Length[ContinuedFraction[(1 + Sqrt[Prime[m]])/2][[2]]], AppendTo[aa, Prime[m]]], {m, 1, 1000}]; aa (* Artur Jasinski, Feb 03 2010 *)
    Select[Table[n^2 - 2, {n, 400}], PrimeQ] (* Vincenzo Librandi, Jun 19 2014 *)
  • PARI
    list(lim)=select(n->isprime(n),vector(sqrtint(floor(lim)+2),k,k^2-2)) \\ Charles R Greathouse IV, Jul 25 2011
    

Formula

a(n) = A028870(n)^2 -2. - R. J. Mathar, Dec 12 2023

A001614 Connell sequence: 1 odd, 2 even, 3 odd, ...

Original entry on oeis.org

1, 2, 4, 5, 7, 9, 10, 12, 14, 16, 17, 19, 21, 23, 25, 26, 28, 30, 32, 34, 36, 37, 39, 41, 43, 45, 47, 49, 50, 52, 54, 56, 58, 60, 62, 64, 65, 67, 69, 71, 73, 75, 77, 79, 81, 82, 84, 86, 88, 90, 92, 94, 96, 98, 100, 101, 103, 105, 107, 109, 111, 113, 115, 117, 119, 121, 122
Offset: 1

Views

Author

Keywords

Comments

Next (2n-1) odd numbers alternating with next 2n even numbers. Squares (A000290(n)) occur at the A000217(n)-th entry. - Lekraj Beedassy, Aug 06 2004. - Comment corrected by Daniel Forgues, Jul 18 2009
a(t_n) = a(n(n+1)/2) = n^2 relates squares to triangular numbers. - Daniel Forgues
The natural numbers not included are A118011(n) = 4n - a(n) as n=1,2,3,... - Paul D. Hanna, Apr 10 2006
As a triangle with row sums = A069778 (1, 6, 21, 52, 105, ...): /Q 1;/Q 2, 4;/Q 5, 7, 9;/Q 10, 12, 14, 16;/Q ... . - Gary W. Adamson, Sep 01 2008
The triangle sums, see A180662 for their definitions, link the Connell sequence A001614 as a triangle with six sequences, see the crossrefs. - Johannes W. Meijer, May 20 2011
a(n) = A122797(n) + n - 1. - Reinhard Zumkeller, Feb 12 2012

Examples

			From _Omar E. Pol_, Aug 13 2013: (Start)
Written as a triangle the sequence begins:
   1;
   2,  4;
   5,  7,  9;
  10, 12, 14, 16;
  17, 19, 21, 23, 25;
  26, 28, 30, 32, 34, 36;
  37, 39, 41, 43, 45, 47, 49;
  50, 52, 54, 56, 58, 60, 62, 64;
  65, 67, 69, 71, 73, 75, 77, 79, 81;
  82, 84, 86, 88, 90, 92, 94, 96, 98, 100;
  ...
Right border gives A000290, n >= 1.
(End)
		

References

  • C. Pickover, Computers and the Imagination, St. Martin's Press, NY, 1991, p. 276.
  • C. A. Pickover, The Mathematics of Oz, Chapter 39, Camb. Univ. Press UK 2002.
  • 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

Cf. A117384, A118011 (complement), A118012.
Cf. A069778. - Gary W. Adamson, Sep 01 2008
From Johannes W. Meijer, May 20 2011: (Start)
Triangle columns: A002522, A117950 (n>=1), A117951 (n>=2), A117619 (n>=3), A154533 (n>=5), A000290 (n>=1), A008865 (n>=2), A028347 (n>=3), A028878 (n>=1), A028884 (n>=2), A054569 [T(2*n,n)].
Triangle sums (see the comments): A069778 (Row1), A190716 (Row2), A058187 (Related to Kn11, Kn12, Kn13, Kn21, Kn22, Kn23, Fi1, Fi2, Ze1 and Ze2), A000292 (Related to Kn3, Kn4, Ca3, Ca4, Gi3 and Gi4), A190717 (Related to Ca1, Ca2, Ze3, Ze4), A190718 (Related to Gi1 and Gi2). (End)

Programs

  • Haskell
    a001614 n = a001614_list !! (n-1)
    a001614_list = f 0 0 a057211_list where
       f c z (x:xs) = z' : f x z' xs where z' = z + 1 + 0 ^ abs (x - c)
    -- Reinhard Zumkeller, Dec 30 2011
    
  • Magma
    [2*n-Round(Sqrt(2*n)): n in [1..80]]; // Vincenzo Librandi, Apr 17 2015
    
  • Maple
    A001614:=proc(n): 2*n - floor((1+sqrt(8*n-7))/2) end: seq(A001614(n),n=1..67); # Johannes W. Meijer, May 20 2011
  • Mathematica
    lst={};i=0;For[j=1, j<=4!, a=i+1;b=j;k=0;For[i=a, i<=9!, k++;AppendTo[lst, i];If[k>=b, Break[]];i=i+2];j++ ];lst (* Vladimir Joseph Stephan Orlovsky, Aug 29 2008 *)
    row[n_] := 2*Range[n+1]+n^2-1; Table[row[n], {n, 0, 11}] // Flatten (* Jean-François Alcover, Oct 25 2013 *)
  • PARI
    a(n)=2*n - round(sqrt(2*n)) \\ Charles R Greathouse IV, Apr 20 2015
    
  • Python
    from math import isqrt
    def A001614(n): return (m:=n<<1)-(k:=isqrt(m))-int((m<<2)>(k<<2)*(k+1)+1) # Chai Wah Wu, Jul 26 2022

Formula

a(n) = 2*n - floor( (1+ sqrt(8*n-7))/2 ).
a(n) = A005843(n) - A002024(n). - Lekraj Beedassy, Aug 06 2004
a(n) = A118012(A118011(n)). A117384( a(n) ) = n; A117384( 4*n - a(n) ) = n. - Paul D. Hanna, Apr 10 2006
a(1) = 1; then a(n) = a(n-1)+1 if a(n-1) is a square, a(n) = a(n-1)+2 otherwise. For example, a(21)=36 is a square therefore a(22)=36+1=37 which is not a square so a(23)=37+2=39 ... - Benoit Cloitre, Feb 07 2007
T(n,k) = (n-1)^2 + 2*k - 1. - Omar E. Pol, Aug 13 2013
a(n)^2 = a(n*(n+1)/2). - Ivan N. Ianakiev, Aug 15 2013
Let the sequence be written in the form of the triangle in the EXAMPLE section below and let a(n) and a(n+1) belong to the same row of the triangle. Then a(n)*a(n+1) + 1 = a(A000217(A118011(n))) = A000290(A118011(n)). - Ivan N. Ianakiev, Aug 16 2013
a(n) = 2*n-round(sqrt(2*n)). - Gerald Hillier, Apr 15 2015
From Robert Israel, Apr 20 2015 (Start):
G.f.: 2*x/(1-x)^2 - (x/(1-x))*Sum_{n>=0} x^(n*(n+1)/2) = 2*x/(1-x)^2 - (Theta2(0,x^(1/2)))*x^(7/8)/(2*(1-x)) where Theta2 is a Jacobi theta function.
a(n) = 2*n-1 - Sum_{i=0..n-2} A023531(i). (End)
a(n) = 3*n-A014132(n). - Chai Wah Wu, Oct 19 2024

Extensions

More terms from Larry Reeves (larryr(AT)acm.org), Mar 16 2001

A016061 a(n) = n*(n+1)*(4*n+5)/6.

Original entry on oeis.org

0, 3, 13, 34, 70, 125, 203, 308, 444, 615, 825, 1078, 1378, 1729, 2135, 2600, 3128, 3723, 4389, 5130, 5950, 6853, 7843, 8924, 10100, 11375, 12753, 14238, 15834, 17545, 19375, 21328, 23408, 25619, 27965, 30450, 33078, 35853, 38779, 41860
Offset: 0

Views

Author

Keywords

Comments

Number of ZnS molecules in cluster of n layers in zinc blende crystal.
(Zinc sulfide crystallizes in two different forms: wurtzite and zinc blende, the latter is also spelled zincblende.) - Jonathan Vos Post, Jan 22 2013
The Kn4 triangle sums of the Connell-Pol triangle A159797 lead to the sequence given above. For the definitions of the Kn4 and other triangle sums see A180662. - Johannes W. Meijer, May 20 2011
If one generated primitive Pythagorean triangles (2n+1, 2n+3) the collective sum of their perimeters for each n is four times the numbers listed in this sequence. - J. M. Bergot, Jul 18 2011
a(n) is the number of 3-tuples (w,x,y) having all terms in {0,...,n} and nA000292(n)+A000292(n+1)=n^3. - Clark Kimberling, Jun 04 2012
Degrees of the Hilbert polynomials for B_3 and C_3, per p. 13 of Gashi et al. - Jonathan Vos Post, Dec 14 2013
Number of solutions to a + b = c + d when 0 < a <= k, 0 <= b, c, d <= k, k = 0, 1, 2, 3.... Taken from Step 1 2007 problem #1(i) using 4 digit balanced numbers. - Bobby Milazzo, Mar 09 2013
From J. M. Bergot, Jun 18 2013: (Start)
Consider the lower half, including the main diagonal, of the array in A144216 as a triangle. The rows begin:
0;
1, 2;
3, 4, 6;
6, 7, 9, 12, ...
The sum of the terms in row(n) is a(n). (End)
This sequence is related to A008865 by a(n) = n*A008865(n+1) - Sum_{i=1..n} A008865(i) for n>0. - Bruno Berselli, Aug 06 2015

References

  • P. Jena and S. N. Behera, Clusters and Nanostructured Materials, Nova Science Publishers, 1996.

Crossrefs

Bisection of A002623.
Row sums of triangle A120070.

Programs

  • Magma
    I:=[0,3,13,34]; [n le 4 select I[n] else 4*Self(n-1)-6*Self(n-2)+4*Self(n-3)-Self(n-4): n in [1..40]]; // Vincenzo Librandi, Jul 25 2013
  • Maple
    A016061 := proc(n)
        n*(n+1)*(4*n+5)/6 ;
    end proc: # R. J. Mathar, Sep 26 2013
  • Mathematica
    CoefficientList[Series[x (3 + x) / (1 - x)^4, {x, 0, 40}], x] (* Vincenzo Librandi, Jul 25 2013 *)
    Table[n(n+1)(4*n+5)/6, {n,0,100}] (* Wesley Ivan Hurt, Sep 25 2013 *)
  • PARI
    v=vector(40,i,t(i)); s=0; forstep(i=2,40,2,s+=v[i]; print1(s","))
    

Formula

G.f.: x*(3+x)/(1-x)^4. - Paul Barry, Feb 27 2003
Partial sums of A014105. - Jon Perry, Jul 23 2003
a(n) = Sum_{i=0..n-1} 2*i^2 + i. - Jani Nurminen (slinky(AT)iki.fi), May 14 2006
a(n) = 2*n^3/3 +3*n^2/2 + 5*n/6. - Jonathan Vos Post, Dec 14 2013
a(n) = (4*n+5)/(2*n+1)*A000330(n). - Alexander R. Povolotsky, Mar 09 2013
a(n) = 4*a(n-1) -6*a(n-2) +4*a(n-3) -a(n-4). - Bobby Milazzo, Mar 10 2013
Sum_{n>=1} 1/a(n) = 12*Pi/5 + 72*log(2)/5 - 426/25. - Amiram Eldar, Jan 04 2022
E.g.f.: exp(x)*x*(18 + 21*x + 4*x^2)/6. - Stefano Spezia, Jul 31 2022

A165900 a(n) = n^2 - n - 1.

Original entry on oeis.org

-1, -1, 1, 5, 11, 19, 29, 41, 55, 71, 89, 109, 131, 155, 181, 209, 239, 271, 305, 341, 379, 419, 461, 505, 551, 599, 649, 701, 755, 811, 869, 929, 991, 1055, 1121, 1189, 1259, 1331, 1405, 1481, 1559, 1639, 1721, 1805, 1891, 1979, 2069, 2161, 2255
Offset: 0

Views

Author

Philippe Deléham, Sep 29 2009

Keywords

Comments

Previous name was: Values of Fibonacci polynomial n^2 - n - 1.
Shifted version of the array denoted rB(0,2) in A132382, whose e.g.f. is exp(x)(1-x)^2. Taking the derivative gives the e.g.f. of this sequence. - Tom Copeland, Dec 02 2013
The Fibonacci numbers are generated by the series x/(1 - x - x^2). - T. D. Noe, Dec 04 2013
Absolute value of expression f(k)*f(k+1) - f(k-1)*f(k+2) where f(1)=1, f(2)=n. Sign is alternately +1 and -1. - Carmine Suriano, Jan 28 2014 [Can anybody clarify what is meant here? - Joerg Arndt, Nov 24 2014]
Carmine's formula is a special case related to 4 consecutive terms of a Fibonacci sequence. A generalization of this formula is |a(n)| = |f(k+i)*f(k+j) - f(k)*f(k+i+j)|/F(i)*F(j), where f denotes a Fibonacci sequence with the initial values 1 and n, and F denotes the original Fibonacci sequence A000045. The same results can be obtained with the simpler formula |a(n)| = |f(k+1)^2 - f(k)^2 - f(k+1)*f(k)|. Everything said so far is also valid for Fibonacci sequences f with the initial values f(1) = n - 2, f(2) = 2*n - 3. - Klaus Purath, Jun 27 2022
a(n) is the total number of dollars won when using the Martingale method (bet $1, if win then continue to bet $1, if lose then double next bet) for n trials of a wager with exactly one loss, n-1 wins. For the case with exactly one win, n-1 losses, see A070313. - Max Winnick, Jun 28 2022
Numbers m such that 4*m+5 is a square b^2, where b = 2*n -1, for m = a(n). - Klaus Purath, Jul 23 2022

Examples

			G.f. = -1 - x + x^2 + 5*x^3 + 11*x^4 + 19*x^5 + 29*x^6 + 41*x^7 + ... - _Michael Somos_, Mar 23 2023
		

Crossrefs

A028387 and A110331 are very similar sequences.

Programs

Formula

a(n+2) = (n+1)*a(n+1) - (n+2)*a(n).
G.f.: (x^2+2*x-1)/(1-x)^3.
E.g.f.: exp(x)*(x^2-1).
a(n) = - A188652(2*n) for n > 0. - Reinhard Zumkeller, Apr 13 2011
a(n) = A214803(A015614(n+1)) for n > 0. - Reinhard Zumkeller, Jul 29 2012
a(n+1) = a(n) + A005843(n) = A002378(n) - 1. - Ivan N. Ianakiev, Feb 18 2013
a(n+2) = A028387(n). - Michael B. Porter, Sep 26 2018
From Klaus Purath, Aug 25 2022: (Start)
a(2*n) = n*(a(n+1) - a(n-1)) -1.
a(2*n+1) = (2*n+1)*(a(n+1) - a(n)) - 1.
a(n+2) = a(n) + 4*n + 2.
a(n) = A014206(n-1) - 3 = A002061(n-1) - 2.
a(n) = A028552(n-2) + 1 = A014209(n-2) + 2 = 2* A034856(n-2) + 3.
a(n) = A008865(n-1) + n = A005563(n-1) - n.
a(n) = A014209(n-3) + 2*n = A028387(n-1) - 2*n.
a(n) = A152015(n)/n, n != 0.
(a(n+k) - a(n-k))/(2*k) = 2*n-1, for any k.
(End)
For n > 1, 1/a(n) = Sum_{k>=1} F(k)/n^(k+1), where F(n) = A000045(n). - Diego Rattaggi, Nov 01 2022
a(n) = a(1-n) for all n in Z. - Michael Somos, Mar 23 2023
For n > 1, 1/a(n) = Sum_{k>=1} F(2k)/((n+1)^(k+1)), where F(2n) = A001906(n). - Diego Rattaggi, Jan 20 2025
From Amiram Eldar, May 11 2025: (Start)
Sum_{n>=1} 1/a(n) = tan(sqrt(5)*Pi/2)*Pi/sqrt(5).
Product_{n>=3} 1 - 1/a(n) = -sec(sqrt(5)*Pi/2)*Pi/6.
Product_{n>=2} 1 + 1/a(n) = -sec(sqrt(5)*Pi/2)*Pi. (End)

Extensions

a(22) corrected by Reinhard Zumkeller, Apr 13 2011
Better name from Joerg Arndt, Oct 26 2024
Showing 1-10 of 63 results. Next