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.

A008865 a(n) = n^2 - 2.

Original entry on oeis.org

-1, 2, 7, 14, 23, 34, 47, 62, 79, 98, 119, 142, 167, 194, 223, 254, 287, 322, 359, 398, 439, 482, 527, 574, 623, 674, 727, 782, 839, 898, 959, 1022, 1087, 1154, 1223, 1294, 1367, 1442, 1519, 1598, 1679, 1762, 1847, 1934, 2023, 2114, 2207, 2302, 2399, 2498
Offset: 1

Views

Author

Keywords

Comments

For n >= 2, least m >= 1 such that f(m, n) = 0 where f(m,n) = Sum_{i=0..m} Sum_{k= 0..i} (-1)^k*(floor(i/n^k) - n*floor(i/n^(k+1))). - Benoit Cloitre, May 02 2004
For n >= 3, the a(n)-th row of Pascal's triangle always contains a triple forming an arithmetic progression. - Lekraj Beedassy, Jun 03 2004
Let C = 1 + sqrt(2) = 2.414213...; and 1/C = 0.414213... Then a(n) = (n + 1 + 1/C) * (n + 1 - C). Example: a(6) = 34 = (7 + 0.414...) * (7 - 2.414...). - Gary W. Adamson, Jul 29 2009
The sequence (n-4)^2-2, n = 7, 8, ... enumerates the number of non-isomorphic sequences of length n, with entries from {1, 2, 3} and no two adjacent entries the same, that minimally contain each of the thirteen rankings of three players (111, 121, 112, 211, 122, 212, 221, 123, 132, 213, 231, 312, 321) as embedded order isomorphic subsequences. By "minimally", we mean that the n-th symbol is necessary for complete inclusion of all thirteen words. See the arXiv paper below for proof. If n = 7, these sequences are 1213121, 1213212, 1231213, 1231231, 1231321, 1232123, and 1232132, and for each case, there are 3! = 6 isomorphs. - Anant Godbole, Feb 20 2013
a(n), n >= 0, with a(0) = -2, gives the values for a*c of indefinite binary quadratic forms [a, b, c] of discriminant D = 8 for b = 2*n. In general D = b^2 - 4*a*c > 0 and the form [a, b, c] is a*x^2 + b*x*y + c*y^2. - Wolfdieter Lang, Aug 15 2013
With a different offset, this is 2*n^2 - (n + 1)^2, which arises in one explanation of why Bertrand's postulate does not automatically prove Legendre's conjecture: as n gets larger, so does the range of numbers that can have primes that satisfy Bertrand's postulate yet do nothing for Legendre's conjecture. - Alonso del Arte, Nov 06 2013
x*(x + r*y)^2 + y*(y + r*x)^2 can be written as (x + y)*(x^2 + s*x*y + y^2). For r >= 0, the sequence gives the values of s: in fact, s = (r + 1)^2 - 2. - Bruno Berselli, Feb 20 2019
For n >= 2, the continued fraction expansion of sqrt(a(n)) is [n-1; {1, n-2, 1, 2n-2}]. For n=2, this collapses to [1; {2}]. - Magus K. Chu, Sep 06 2022

Examples

			G.f. = -x + 2*x^2 + 7*x^3 + 14*x^4 + 23*x^5 + 34*x^6 + 47*x^7 + 62*x^8 + 79*x^9 + ...
		

Crossrefs

Cf. A145067 (Zero followed by partial sums of A008865).
Cf. A028871 (primes).
Cf. A263766 (partial products).
Cf. A270109. [Bruno Berselli, Mar 17 2016]

Programs

  • Haskell
    a008865 = (subtract 2) . (^ 2) :: Integral t => t -> t
    a008865_list = scanl (+) (-1) [3, 5 ..]
    -- Reinhard Zumkeller, May 06 2013
    
  • Magma
    [n^2 - 2: n in [1..60]]; // Vincenzo Librandi, May 01 2014
  • Mathematica
    Range[50]^2 - 2 (* Harvey P. Dale, Mar 14 2011 *)
  • PARI
    {for(n=1, 47, print1(n^2-2, ","))} \\ Klaus Brockhaus, Oct 17 2008
    

Formula

For n > 1: a(n) = A143053(A000290(n)), A143054(a(n)) = A000290(n). - Reinhard Zumkeller, Jul 20 2008
G.f.: (x-5*x^2+2*x^3)/(-1+3*x-3*x^2+x^3). - Klaus Brockhaus, Oct 17 2008
E.g.f.: (x^2 + x -2)*exp(x) + 2. - G. C. Greubel, Aug 19 2017
a(n+1) = A101986(n) - A101986(n-1) = A160805(n) - A160805(n-1). - Reinhard Zumkeller, May 26 2009
For n > 1, a(n) = floor(n^5/(n^3 + n + 1)). - Gary Detlefs, Feb 10 2010
a(n) = a(n-1) + 2*n - 1 for n > 1, a(1) = -1. - Vincenzo Librandi, Nov 18 2010
Right edge of the triangle in A195437: a(n) = A195437(n-2, n-2). - Reinhard Zumkeller, Nov 23 2011
a(n)*a(n-1) + 2 = (a(n) - n)^2 = A028552(n-2)^2. - Bruno Berselli, Dec 07 2011
a(n+1) = A000096(n) + A000096(n-1) for all n in Z. - Michael Somos, Nov 11 2015
From Amiram Eldar, Jul 13 2020: (Start)
Sum_{n>=1} 1/a(n) = (1 - sqrt(2)*Pi*cot(sqrt(2)*Pi))/4.
Sum_{n>=1} (-1)^n/a(n) = (1 - sqrt(2)*Pi*cosec(sqrt(2)*Pi))/4. (End)
Assume offset 0. Then a(n) = 2*LaguerreL(2, 1 - n). - Peter Luschny, May 09 2021
From Amiram Eldar, Feb 05 2024: (Start)
Product_{n>=1} (1 - 1/a(n)) = sqrt(2/3)*sin(sqrt(3)*Pi)/sin(sqrt(2)*Pi).
Product_{n>=2} (1 + 1/a(n)) = -Pi/(sqrt(2)*sin(sqrt(2)*Pi)). (End)

A102538 Numbers n not of form k(k+2) that have a single '1' in the periodic part of the continued fraction of sqrt(n).

Original entry on oeis.org

175, 176, 208, 551, 799, 1035, 1247, 1403, 1872, 2856, 2967, 3395, 3496, 3503, 3531, 3731, 3864, 3999, 4136, 4387, 4416, 4512, 4543, 5343, 5368, 5499, 5520, 6099, 6160, 6608, 6751, 7791, 8855, 9048, 10439, 10664, 10904, 11323, 11935, 12208, 13299
Offset: 1

Views

Author

Ralf Stephan, Jan 14 2005

Keywords

Comments

Members of A013648 not in A005563.
No prime numbers? - Zak Seidov, Feb 28 2012

Programs

  • Mathematica
    fQ[n_] := Block[{k = Floor[Sqrt[n]]}, If[ k(k + 2) != n && !IntegerQ[ Sqrt[n]], cof = Sort[ ContinuedFraction[ Sqrt[n]] [[2]]]; If[ cof[[1]] == 1 && cof[[2]] != 1, True]]]; Select[ Range[ 13986], fQ[ # ] &] (* Robert G. Wilson v, Jan 25 2005 *)

Extensions

More terms from Robert G. Wilson v, Jan 25 2005

A121164 Triangle, real terms extracted from squares of paired terms in arithmetic sequences.

Original entry on oeis.org

-3, -8, -5, -15, -16, -7, -24, -33, -24, -9, -35, -56, -51, -32, -11, -48, -85, -88, -69, -40, -13, -63, -120, -135, -120, -87, -48, -15, -80, -161, -192, -185, -152, -105, -56, -17, -99, -208, -259, -264, -235, -184, -123, -19, -120, -261, -336, -357, -336, -285, -216, -141
Offset: 1

Views

Author

Gary W. Adamson, Aug 13 2006

Keywords

Comments

Left border (-3, -8, -15, -24, ...) unsigned = A013648. Next column (-5, -16, -33, ...) unsigned = A045944.

Examples

			Array of the extracted real terms:
   -3,  -5,  -7,   -9, ...
   -8, -16, -24,  -32, ...
  -15, -33, -51,  -69, ...
  -24, -56, -88, -120, ...
  ...
Taking antidiagonals we get the triangle:
   -3;
   -8,  -5;
  -15, -16,  -7;
  -24, -33, -24,  -9;
  -35, -56, -51, -32, -11;
  -48, -85, -88, -69, -40, -13;
  ...
(3,2) = -16 since (taken from the arithmetic sequence 1, 3, 5, ...), (3 + 5i)^2 = (-16 + 30i).
		

Crossrefs

Formula

Form an array of the arithmetic sequences: (1, 2, 3, ...); (1, 3, 5, ...); (1, 4, 7, ...); and consider each pair as a complex term; e.g., (1 + 2i), (2 + 3i), then square each complex term and extract the real integer. Antidiagonals become rows of the triangle.
Showing 1-3 of 3 results.