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

A002315 NSW numbers: a(n) = 6*a(n-1) - a(n-2); also a(n)^2 - 2*b(n)^2 = -1 with b(n) = A001653(n+1).

Original entry on oeis.org

1, 7, 41, 239, 1393, 8119, 47321, 275807, 1607521, 9369319, 54608393, 318281039, 1855077841, 10812186007, 63018038201, 367296043199, 2140758220993, 12477253282759, 72722761475561, 423859315570607, 2470433131948081, 14398739476117879, 83922003724759193
Offset: 0

Views

Author

Keywords

Comments

Named after the Newman-Shanks-Williams reference.
Also numbers k such that A125650(3*k^2) is an odd perfect square. Such numbers 3*k^2 form a bisection of A125651. - Alexander Adamchuk, Nov 30 2006
For positive n, a(n) corresponds to the sum of legs of near-isosceles primitive Pythagorean triangles (with consecutive legs). - Lekraj Beedassy, Feb 06 2007
Also numbers m such that m^2 is a centered 16-gonal number; or a number of the form 8k(k+1)+1, where k = A053141(m) = {0, 2, 14, 84, 492, 2870, ...}. - Alexander Adamchuk, Apr 21 2007
The lower principal convergents to 2^(1/2), beginning with 1/1, 7/5, 41/29, 239/169, comprise a strictly increasing sequence; numerators=A002315 and denominators=A001653. - Clark Kimberling, Aug 27 2008
The upper intermediate convergents to 2^(1/2) beginning with 10/7, 58/41, 338/239, 1970/1393 form a strictly decreasing sequence; essentially, numerators=A075870, denominators=A002315. - Clark Kimberling, Aug 27 2008
General recurrence is a(n) = (a(1)-1)*a(n-1) - a(n-2), a(1) >= 4, lim_{n->oo} a(n) = x*(k*x+1)^n, k = (a(1)-3), x = (1+sqrt((a(1)+1)/(a(1)-3)))/2. Examples in OEIS: a(1)=4 gives A002878. a(1)=5 gives A001834. a(1)=6 gives A030221. a(1)=7 gives A002315. a(1)=8 gives A033890. a(1)=9 gives A057080. a(1)=10 gives A057081. - Ctibor O. Zizka, Sep 02 2008
Numbers k such that (ceiling(sqrt(k*k/2)))^2 = (1+k*k)/2. - Ctibor O. Zizka, Nov 09 2009
A001109(n)/a(n) converges to cos^2(Pi/8) = 1/2 + 2^(1/2)/4. - Gary Detlefs, Nov 25 2009
The values 2(a(n)^2+1) are all perfect squares, whose square root is given by A075870. - Neelesh Bodas (neelesh.bodas(AT)gmail.com), Aug 13 2010
a(n) represents all positive integers K for which 2(K^2+1) is a perfect square. - Neelesh Bodas (neelesh.bodas(AT)gmail.com), Aug 13 2010
For positive n, a(n) equals the permanent of the (2n) X (2n) tridiagonal matrix with sqrt(8)'s along the main diagonal, and i's along the superdiagonal and subdiagonal (i is the imaginary unit). - John M. Campbell, Jul 08 2011
Integers k such that A000217(k-2) + A000217(k-1) + A000217(k) + A000217(k+1) is a square (cf. A202391). - Max Alekseyev, Dec 19 2011
Integer square roots of floor(k^2/2 - 1) or A047838. - Richard R. Forberg, Aug 01 2013
Remark: x^2 - 2*y^2 = +2*k^2, with positive k, and X^2 - 2*Y^2 = +2 reduce to the present Pell equation a^2 - 2*b^2 = -1 with x = k*X = 2*k*b and y = k*Y = k*a. (After a proposed solution for k = 3 by Alexander Samokrutov.) - Wolfdieter Lang, Aug 21 2015
If p is an odd prime, a((p-1)/2) == 1 (mod p). - Altug Alkan, Mar 17 2016
a(n)^2 + 1 = 2*b(n)^2, with b(n) = A001653(n), is the necessary and sufficient condition for a(n) to be a number k for which the diagonal of a 1 X k rectangle is an integer multiple of the diagonal of a 1 X 1 square. If squares are laid out thus along one diagonal of a horizontal 1 X a(n) rectangle, from the lower left corner to the upper right, the number of squares is b(n), and there will always be a square whose top corner lies exactly within the top edge of the rectangle. Numbering the squares 1 to b(n) from left to right, the number of the one square that has a corner in the top edge of the rectangle is c(n) = (2*b(n) - a(n) + 1)/2, which is A055997(n). The horizontal component of the corner of the square in the edge of the rectangle is also an integer, namely d(n) = a(n) - b(n), which is A001542(n). - David Pasino, Jun 30 2016
(a(n)^2)-th triangular number is a square; a(n)^2 = A008843(n) is a subsequence of A001108. - Jaroslav Krizek, Aug 05 2016
a(n-1)/A001653(n) is the closest rational approximation of sqrt(2) with a numerator not larger than a(n-1). These rational approximations together with those obtained from the sequences A001541 and A001542 give a complete set of closest rational approximations of sqrt(2) with restricted numerator or denominator. a(n-1)/A001653(n) < sqrt(2). - A.H.M. Smeets, May 28 2017
Consider the quadrant of a circle with center (0,0) bounded by the positive x and y axes. Now consider, as the start of a series, the circle contained within this quadrant which kisses both axes and the outer bounding circle. Consider further a succession of circles, each kissing the x-axis, the outer bounding circle, and the previous circle in the series. See Holmes link. The center of the n-th circle in this series is ((A001653(n)*sqrt(2)-1)/a(n-1), (A001653(n)*sqrt(2)-1)/a(n-1)^2), the y-coordinate also being its radius. It follows that a(n-1) is the cotangent of the angle subtended at point (0,0) by the center of the n-th circle in the series with respect to the x-axis. - Graham Holmes, Aug 31 2019
There is a link between the two sequences present at the numerator and at the denominator of the fractions that give the coordinates of the center of the kissing circles. A001653 is the sequence of numbers k such that 2*k^2 - 1 is a square, and here, we have 2*A001653(n)^2 - 1 = a(n-1)^2. - Bernard Schott, Sep 02 2019
Let G be a sequence satisfying G(i) = 2*G(i-1) + G(i-2) for arbitrary integers i and without regard to the initial values of G. Then a(n) = (G(i+4*n+2) - G(i))/(2*G(i+2*n+1)) as long as G(i+2*n+1) != 0. - Klaus Purath, Mar 25 2021
All of the positive integer solutions of a*b+1=x^2, a*c+1=y^2, b*c+1=z^2, x+z=2*y, 0 < a < b < c are given by a=A001542(n), b=A005319(n), c=A001542(n+1), x=A001541(n), y=A001653(n+1), z=A002315(n) with 0 < n. - Michael Somos, Jun 26 2022
3*a(n-1) is the n-th almost Lucas-cobalancing number of second type (see Tekcan and Erdem). - Stefano Spezia, Nov 26 2022
In Moret-Blanc (1881) on page 259 some solution of m^2 - 2n^2 = -1 are listed. The values of m give this sequence, and the values of n give A001653. - Michael Somos, Oct 25 2023
From Klaus Purath, May 11 2024: (Start)
For any two consecutive terms (a(n), a(n+1)) = (x,y): x^2 - 6xy + y^2 = 8 = A028884(1). In general, the following applies to all sequences (t) satisfying t(i) = 6t(i-1) - t(i-2) with t(0) = 1 and two consecutive terms (x,y): x^2 - 6xy + y^2 = A028884(t(1)-6). This includes and interprets the Feb 04 2014 comment on A001541 by Colin Barker as well as the Mar 17 2021 comment on A054489 by John O. Oladokun and the Sep 28 2008 formula on A038723 by Michael Somos. By analogy to this, for three consecutive terms (x,y,z) y^2 - xz = A028884(t(1)-6) always applies.
If (t) is a sequence satisfying t(k) = 7t(k-1) - 7t(k-2) + t(k-3) or t(k) = 6t(k-1) - t(k-2) without regard to initial values and including this sequence itself, then a(n) = (t(k+2n+1) - t(k))/(t(k+n+1) - t(k+n)) always applies, as long as t(k+n+1) - t(k+n) != 0 for integer k and n >= 0. (End)

Examples

			G.f. = 1 + 7*x + 41*x^2 + 239*x^3 + 1393*x^4 + 8119*x^5 + 17321*x^6 + ... - _Michael Somos_, Jun 26 2022
		

References

  • Julio R. Bastida, Quadratic properties of a linearly recurrent sequence. Proceedings of the Tenth Southeastern Conference on Combinatorics, Graph Theory and Computing (Florida Atlantic Univ., Boca Raton, Fla., 1979), pp. 163-166, Congress. Numer., XXIII-XXIV, Utilitas Math., Winnipeg, Man., 1979. MR0561042 (81e:10009)
  • A. H. Beiler, Recreations in the Theory of Numbers, Dover, NY, 1964, p. 256.
  • Paulo Ribenboim, The Book of Prime Number Records. Springer-Verlag, NY, 2nd ed., 1989, p. 288.
  • Paulo Ribenboim, The Little Book of Bigger Primes, Springer-Verlag NY 2004. See p. 247.
  • 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).
  • P.-F. Teilhet, Reply to Query 2094, L'Intermédiaire des Mathématiciens, 10 (1903), 235-238.
  • P.-F. Teilhet, Query 2376, L'Intermédiaire des Mathématiciens, 11 (1904), 138-139. - N. J. A. Sloane, Mar 08 2022

Crossrefs

Bisection of A001333. Cf. A001109, A001653. A065513(n)=a(n)-1.
First differences of A001108 and A055997. Bisection of A084068 and A088014. Cf. A077444.
Row sums of unsigned triangle A127675.
Cf. A053141, A075870. Cf. A000045, A002878, A004146, A026003, A100047, A119915, A192425, A088165 (prime subsequence), A057084 (binomial transform), A108051 (inverse binomial transform).
See comments in A301383.
Cf. similar sequences of the type (1/k)*sinh((2*n+1)*arcsinh(k)) listed in A097775.

Programs

  • Haskell
    a002315 n = a002315_list !! n
    a002315_list = 1 : 7 : zipWith (-) (map (* 6) (tail a002315_list)) a002315_list
    -- Reinhard Zumkeller, Jan 10 2012
    
  • Magma
    I:=[1,7]; [n le 2 select I[n] else 6*Self(n-1)-Self(n-2): n in [1..30]]; // Vincenzo Librandi, Mar 22 2015
  • Maple
    A002315 := proc(n)
        option remember;
        if n = 0 then
            1 ;
        elif n = 1 then
            7;
        else
            6*procname(n-1)-procname(n-2) ;
        end if;
    end proc: # Zerinvary Lajos, Jul 26 2006, modified R. J. Mathar, Apr 30 2017
    a:=n->abs(Im(simplify(ChebyshevT(2*n+1,I)))):seq(a(n),n=0..20); # Leonid Bedratyuk, Dec 17 2017
    # third Maple program:
    a:= n-> (<<0|1>, <-1|6>>^n. <<1, 7>>)[1, 1]:
    seq(a(n), n=0..22);  # Alois P. Heinz, Aug 25 2024
  • Mathematica
    a[0] = 1; a[1] = 7; a[n_] := a[n] = 6a[n - 1] - a[n - 2]; Table[ a[n], {n, 0, 20}] (* Robert G. Wilson v, Jun 09 2004 *)
    Transpose[NestList[Flatten[{Rest[#],ListCorrelate[{-1,6},#]}]&, {1,7},20]][[1]]  (* Harvey P. Dale, Mar 23 2011 *)
    Table[ If[n>0, a=b; b=c; c=6b-a, b=-1; c=1], {n, 0, 20}] (* Jean-François Alcover, Oct 19 2012 *)
    LinearRecurrence[{6, -1}, {1, 7}, 20] (* Bruno Berselli, Apr 03 2018 *)
    a[ n_] := -I*(-1)^n*ChebyshevT[2*n + 1, I]; (* Michael Somos, Jun 26 2022 *)
  • PARI
    {a(n) = subst(poltchebi(abs(n+1)) - poltchebi(abs(n)), x, 3)/2};
    
  • PARI
    {a(n) = if(n<0, -a(-1-n), polsym(x^2-2*x-1, 2*n+1)[2*n+2]/2)};
    
  • PARI
    {a(n) = my(w=3+quadgen(32)); imag((1+w)*w^n)};
    
  • PARI
    for (i=1,10000,if(Mod(sigma(i^2+1,2),2)==1,print1(i,",")))
    
  • PARI
    {a(n) = -I*(-1)^n*polchebyshev(2*n+1, 1, I)}; /* Michael Somos, Jun 26 2022 */
    

Formula

a(n) = (1/2)*((1+sqrt(2))^(2*n+1) + (1-sqrt(2))^(2*n+1)).
a(n) = A001109(n)+A001109(n+1).
a(n) = (1+sqrt(2))/2*(3+sqrt(8))^n+(1-sqrt(2))/2*(3-sqrt(8))^n. - Ralf Stephan, Feb 23 2003
a(n) = sqrt(2*(A001653(n+1))^2-1), n >= 0. [Pell equation a(n)^2 - 2*Pell(2*n+1)^2 = -1. - Wolfdieter Lang, Jul 11 2018]
G.f.: (1 + x)/(1 - 6*x + x^2). - Simon Plouffe in his 1992 dissertation
a(n) = S(n, 6)+S(n-1, 6) = S(2*n, sqrt(8)), S(n, x) = U(n, x/2) are Chebyshev's polynomials of the 2nd kind. Cf. A049310. S(n, 6)= A001109(n+1).
a(n) ~ (1/2)*(sqrt(2) + 1)^(2*n+1). - Joe Keane (jgk(AT)jgk.org), May 15 2002
Limit_{n->oo} a(n)/a(n-1) = 3 + 2*sqrt(2). - Gregory V. Richardson, Oct 06 2002
Let q(n, x) = Sum_{i=0..n} x^(n-i)*binomial(2*n-i, i); then (-1)^n*q(n, -8) = a(n). - Benoit Cloitre, Nov 10 2002
With a=3+2*sqrt(2), b=3-2*sqrt(2): a(n) = (a^((2n+1)/2)-b^((2n+1)/2))/2. a(n) = A077444(n)/2. - Mario Catalani (mario.catalani(AT)unito.it), Mar 31 2003
a(n) = Sum_{k=0..n} 2^k*binomial(2*n+1, 2*k). - Zoltan Zachar (zachar(AT)fellner.sulinet.hu), Oct 08 2003
Same as: i such that sigma(i^2+1, 2) mod 2 = 1. - Mohammed Bouayoun (bouyao(AT)wanadoo.fr), Mar 26 2004
a(n) = L(n, -6)*(-1)^n, where L is defined as in A108299; see also A001653 for L(n, +6). - Reinhard Zumkeller, Jun 01 2005
a(n) = A001652(n)+A046090(n); e.g., 239=119+120. - Charlie Marion, Nov 20 2003
A001541(n)*a(n+k) = A001652(2n+k) + A001652(k)+1; e.g., 3*1393 = 4069 + 119 + 1; for k > 0, A001541(n+k)*a(n) = A001652(2n+k) - A001652(k-1); e.g., 99*7 = 696 - 3. - Charlie Marion, Mar 17 2003
a(n) = Jacobi_P(n,1/2,-1/2,3)/Jacobi_P(n,-1/2,1/2,1). - Paul Barry, Feb 03 2006
P_{2n}+P_{2n+1} where P_i are the Pell numbers (A000129). Also the square root of the partial sums of Pell numbers: P_{2n}+P_{2n+1} = sqrt(Sum_{i=0..4n+1} P_i) (Santana and Diaz-Barrero, 2006). - David Eppstein, Jan 28 2007
a(n) = 2*A001652(n) + 1 = 2*A046729(n) + (-1)^n. - Lekraj Beedassy, Feb 06 2007
a(n) = sqrt(A001108(2*n+1)). - Anton Vrba (antonvrba(AT)yahoo.com), Feb 14 2007
a(n) = sqrt(8*A053141(n)*(A053141(n) + 1) + 1). - Alexander Adamchuk, Apr 21 2007
a(n+1) = 3*a(n) + sqrt(8*a(n)^2 + 8), a(1)=1. - Richard Choulet, Sep 18 2007
a(n) = A001333(2*n+1). - Ctibor O. Zizka, Aug 13 2008
a(n) = third binomial transform of 1, 4, 8, 32, 64, 256, 512, ... . - Al Hakanson (hawkuu(AT)gmail.com), Aug 15 2009
a(n) = (-1)^(n-1)*(1/sqrt(-1))*cos((2*n - 1)*arcsin(sqrt(2)). - Artur Jasinski, Feb 17 2010 *WRONG*
a(n+k) = A001541(k)*a(n) + 4*A001109(k)*A001653(n); e.g., 8119 = 17*239 + 4*6*169. - Charlie Marion, Feb 04 2011
In general, a(n+k) = A001541(k)*a(n)) + sqrt(A001108(2k)*(a(n)^2+1)). See Sep 18 2007 entry above. - Charlie Marion, Dec 07 2011
a(n) = floor((1+sqrt(2))^(2n+1))/2. - Thomas Ordowski, Jun 12 2012
(a(2n-1) + a(2n) + 8)/(8*a(n)) = A001653(n). - Ignacio Larrosa Cañestro, Jan 02 2015
(a(2n) + a(2n-1))/a(n) = 2*sqrt(2)*( (1 + sqrt(2))^(4*n) - (1 - sqrt(2))^(4*n))/((1 + sqrt(2))^(2*n+1) + (1 - sqrt(2))^(2*n+1)). [This was my solution to problem 5325, School Science and Mathematics 114 (No. 8, Dec 2014).] - Henry Ricardo, Feb 05 2015
From Peter Bala, Mar 22 2015: (Start)
The aerated sequence (b(n))n>=1 = [1, 0, 7, 0, 41, 0, 239, 0, ...] is a fourth-order linear divisibility sequence; that is, if n | m then b(n) | b(m). It is the case P1 = 0, P2 = -4, Q = -1 of the 3-parameter family of divisibility sequences found by Williams and Guy. See A100047.
b(n) = 1/2*((-1)^n - 1)*Pell(n) + 1/2*(1 + (-1)^(n+1))*Pell(n+1). The o.g.f. is x*(1 + x^2)/(1 - 6*x^2 + x^4).
Exp( Sum_{n >= 1} 2*b(n)*x^n/n ) = 1 + Sum_{n >= 1} 2*A026003(n-1)*x^n.
Exp( Sum_{n >= 1} (-2)*b(n)*x^n/n ) = 1 + Sum_{n >= 1} 2*A026003(n-1)*(-x)^n.
Exp( Sum_{n >= 1} 4*b(n)*x^n/n ) = 1 + Sum_{n >= 1} 4*Pell(n)*x^n.
Exp( Sum_{n >= 1} (-4)*b(n)*x^n/n ) = 1 + Sum_{n >= 1} 4*Pell(n)*(-x)^n.
Exp( Sum_{n >= 1} 8*b(n)*x^n/n ) = 1 + Sum_{n >= 1} 8*A119915(n)*x^n.
Exp( Sum_{n >= 1} (-8)*b(n)*x^n/n ) = 1 + Sum_{n >= 1} 8*A119915(n)*(-x)^n. Cf. A002878, A004146, A113224, and A192425. (End)
E.g.f.: (sqrt(2)*sinh(2*sqrt(2)*x) + cosh(2*sqrt(2)*x))*exp(3*x). - Ilya Gutkovskiy, Jun 30 2016
a(n) = Sum_{k=0..n} binomial(n,k) * 3^(n-k) * 2^k * 2^ceiling(k/2). - David Pasino, Jul 09 2016
a(n) = A001541(n) + 2*A001542(n). - A.H.M. Smeets, May 28 2017
a(n+1) = 3*a(n) + 4*b(n), b(n+1) = 2*a(n) + 3*b(n), with b(n)=A001653(n). - Zak Seidov, Jul 13 2017
a(n) = |Im(T(2n-1,i))|, i=sqrt(-1), T(n,x) is the Chebyshev polynomial of the first kind, Im is the imaginary part of a complex number, || is the absolute value. - Leonid Bedratyuk, Dec 17 2017
a(n) = sinh((2*n + 1)*arcsinh(1)). - Bruno Berselli, Apr 03 2018
a(n) = 5*a(n-1) + A003499(n-1), a(0) = 1. - Ivan N. Ianakiev, Aug 09 2019
From Klaus Purath, Mar 25 2021: (Start)
a(n) = A046090(2*n)/A001541(n).
a(n+1)*a(n+2) = a(n)*a(n+3) + 48.
a(n)^2 + a(n+1)^2 = 6*a(n)*a(n+1) + 8.
a(n+1)^2 = a(n)*a(n+2) + 8.
a(n+1) = a(n) + 2*A001541(n+1).
a(n) = 2*A046090(n) - 1. (End)
3*a(n-1) = sqrt(8*b(n)^2 + 8*b(n) - 7), where b(n) = A358682(n). - Stefano Spezia, Nov 26 2022
a(n) = -(-1)^n - 2 + Sum_{i=0..n} A002203(i)^2. - Adam Mohamed, Aug 22 2024
From Peter Bala, May 09 2025: (Start)
a(n) = Dir(n, 3), where Dir(n, x) denotes the n-th row polynomial of the triangle A244419.
For arbitrary x, a(n+x)^2 - 6*a(n+x)*a(n+x+1) + a(n+x+1)^2 = 8 with a(n) := (1/2)*((1+sqrt(2))^(2*n+1) + (1-sqrt(2))^(2*n+1)) as above. The particular case x = 0 is noted above,
a(n+1/2) = sqrt(2) * A001542(n+1).
Sum_{n >= 1} (-1)^(n+1)/(a(n) - 1/a(n)) = 1/8 (telescoping series: for n >= 1, 1/(a(n) - 1/a(n)) = 1/A081554(n) + 1/A081554(n+1)).
Product_{n >= 1} (a(n) + 1)/(a(n) - 1) = sqrt(2) (telescoping product: Product_{n = 1..k} ((a(n) + 1)/(a(n) - 1))^2 = 2*(1 - 1/A055997(k+2))). (End)

A212959 Number of (w,x,y) such that w,x,y are all in {0,...,n} and |w-x| = |x-y|.

Original entry on oeis.org

1, 4, 11, 20, 33, 48, 67, 88, 113, 140, 171, 204, 241, 280, 323, 368, 417, 468, 523, 580, 641, 704, 771, 840, 913, 988, 1067, 1148, 1233, 1320, 1411, 1504, 1601, 1700, 1803, 1908, 2017, 2128, 2243, 2360, 2481, 2604, 2731, 2860, 2993, 3128, 3267
Offset: 0

Views

Author

Clark Kimberling, Jun 01 2012

Keywords

Comments

In the following guide to related sequences: M=max(x,y,z), m=min(x,y,z), and R=range=M-m. In some cases, it is an offset of the listed sequence which fits the conditions shown for w,x,y. Each sequence satisfies a linear recurrence relation, some of which are identified in the list by the following code (signature):
A: 2, 0, -2, 1, i.e., a(n) = 2*a(n-1) - 2*a(n-3) + a(n-4);
B: 3, -2, -2, 3, -1;
C: 4, -6, 4, -1;
D: 1, 2, -2, -1, 1;
E: 2, 1, -4, 1, 2, -1;
F: 2, -1, 1, -2, 1;
G: 2, -1, 0, 1, -2, 1;
H: 2, -1, 2, -4, 2, -1, 2, -1;
I: 3, -3, 2, -3, 3, -1;
J: 4, -7, 8, -7, 4, -1.
...
A212959 ... |w-x|=|x-y| ...... recurrence type A
A212960 ... |w-x| != |x-y| ................... B
A212683 ... |w-x| < |x-y| .................... B
A212684 ... |w-x| >= |x-y| ................... B
A212963 ... see entry for definition ......... B
A212964 ... |w-x| < |x-y| < |y-w| ............ B
A006331 ... |w-x| < y ........................ C
A005900 ... |w-x| <= y ....................... C
A212965 ... w = R ............................ D
A212966 ... 2*w = R
A212967 ... w < R ............................ E
A212968 ... w >= R ........................... E
A077043 ... w = x > R ........................ A
A212969 ... w != x and x > R ................. E
A212970 ... w != x and x < R ................. E
A055998 ... w = x + y - 1
A011934 ... w < floor((x+y)/2) ............... B
A182260 ... w > floor((x+y)/2) ............... B
A055232 ... w <= floor((x+y)/2) .............. B
A011934 ... w >= floor((x+y)/2) .............. B
A212971 ... w < floor((x+y)/3) ............... B
A212972 ... w >= floor((x+y)/3) .............. B
A212973 ... w <= floor((x+y)/3) .............. B
A212974 ... w > floor((x+y)/3) ............... B
A212975 ... R is even ........................ E
A212976 ... R is odd ......................... E
A212978 ... R = 2*n - w - x
A212979 ... R = average{w,x,y}
A212980 ... w < x + y and x < y .............. B
A212981 ... w <= x+y and x < y ............... B
A212982 ... w < x + y and x <= y ............. B
A212983 ... w <= x + y and x <= y ............ B
A002623 ... w >= x + y and x <= y ............ B
A087811 ... w = 2*x + y ...................... A
A008805 ... w = 2*x + 2*y .................... D
A000982 ... 2*w = x + y ...................... F
A001318 ... 2*w = 2*x + y .................... F
A001840 ... w = 3*x + y
A212984 ... 3*w = x + y
A212985 ... 3*w = 3*x + y
A001399 ... w = 2*x + 3*y
A212986 ... 2*w = 3*x + y
A008810 ... 3*x = 2*x + y .................... F
A212987 ... 3*w = 2*x + 2*y
A001972 ... w = 4*x + y ...................... G
A212988 ... 4*w = x + y ...................... G
A212989 ... 4*w = 4*x + y
A008812 ... 5*w = 2*x + 3*y
A016061 ... n < w + x + y <= 2*n ............. C
A000292 ... w + x + y <=n .................... C
A000292 ... 2*n < w + x + y <= 3*n ........... C
A212977 ... n/2 < w + x + y <= n
A143785 ... w < R < x ........................ E
A005996 ... w < R <= x ....................... E
A128624 ... w <= R <= x ...................... E
A213041 ... R = 2*|w - x| .................... A
A213045 ... R < 2*|w - x| .................... B
A087035 ... R >= 2*|w - x| ................... B
A213388 ... R <= 2*|w - x| ................... B
A171218 ... M < 2*m .......................... B
A213389 ... R < 2|w - x| ..................... E
A213390 ... M >= 2*m ......................... E
A213391 ... 2*M < 3*m ........................ H
A213392 ... 2*M >= 3*m ....................... H
A213393 ... 2*M > 3*m ........................ H
A213391 ... 2*M <= 3*m ....................... H
A047838 ... w = |x + y - w| .................. A
A213396 ... 2*w < |x + y - w| ................ I
A213397 ... 2*w >= |x + y - w| ............... I
A213400 ... w < R < 2*w
A069894 ... min(|w-x|,|x-y|) = 1
A000384 ... max(|w-x|,|x-y|) = |w-y|
A213395 ... max(|w-x|,|x-y|) = w
A213398 ... min(|w-x|,|x-y|) = x ............. A
A213399 ... max(|w-x|,|x-y|) = x ............. D
A213479 ... max(|w-x|,|x-y|) = w+x+y ......... D
A213480 ... max(|w-x|,|x-y|) != w+x+y ........ E
A006918 ... |w-x| + |x-y| > w+x+y ............ E
A213481 ... |w-x| + |x-y| <= w+x+y ........... E
A213482 ... |w-x| + |x-y| < w+x+y ............ E
A213483 ... |w-x| + |x-y| >= w+x+y ........... E
A213484 ... |w-x|+|x-y|+|y-w| = w+x+y
A213485 ... |w-x|+|x-y|+|y-w| != w+x+y ....... J
A213486 ... |w-x|+|x-y|+|y-w| > w+x+y ........ J
A213487 ... |w-x|+|x-y|+|y-w| >= w+x+y ....... J
A213488 ... |w-x|+|x-y|+|y-w| < w+x+y ........ J
A213489 ... |w-x|+|x-y|+|y-w| <= w+x+y ....... J
A213490 ... w,x,y,|w-x|,|x-y| distinct
A213491 ... w,x,y,|w-x|,|x-y| not distinct
A213493 ... w,x,y,|w-x|,|x-y|,|w-y| distinct
A213495 ... w = min(|w-x|,|x-y|,|w-y|)
A213492 ... w != min(|w-x|,|x-y|,|w-y|)
A213496 ... x != max(|w-x|,|x-y|)
A213498 ... w != max(|w-x|,|x-y|,|w-y|)
A213497 ... w = min(|w-x|,|x-y|)
A213499 ... w != min(|w-x|,|x-y|)
A213501 ... w != max(|w-x|,|x-y|)
A213502 ... x != min(|w-x|,|x-y|)
...
A211795 includes a guide for sequences that count 4-tuples (w,x,y,z) having all terms in {0,...,n} and satisfying selected properties. Some of the sequences indexed at A211795 satisfy recurrences that are represented in the above list.
Partial sums of the numbers congruent to {1,3} mod 6 (see A047241). - Philippe Deléham, Mar 16 2014

Examples

			a(1)=4 counts these (x,y,z): (0,0,0), (1,1,1), (0,1,0), (1,0,1).
Numbers congruent to {1, 3} mod 6: 1, 3, 7, 9, 13, 15, 19, ...
a(0) = 1;
a(1) = 1 + 3 = 4;
a(2) = 1 + 3 + 7 = 11;
a(3) = 1 + 3 + 7 + 9 = 20;
a(4) = 1 + 3 + 7 + 9 + 13 = 33;
a(5) = 1 + 3 + 7 + 9 + 13 + 15 = 48; etc. - _Philippe Deléham_, Mar 16 2014
		

References

  • A. Barvinok, Lattice Points and Lattice Polytopes, Chapter 7 in Handbook of Discrete and Computational Geometry, CRC Press, 1997, 133-152.
  • P. Gritzmann and J. M. Wills, Lattice Points, Chapter 3.2 in Handbook of Convex Geometry, vol. B, North-Holland, 1993, 765-797.

Crossrefs

Programs

  • Mathematica
    t = Compile[{{n, _Integer}}, Module[{s = 0},
    (Do[If[Abs[w - x] == Abs[x - y], s = s + 1],
    {w, 0, n}, {x, 0, n}, {y, 0, n}]; s)]];
    m = Map[t[#] &, Range[0, 50]]   (* A212959 *)
  • PARI
    a(n)=(6*n^2+8*n+3)\/4 \\ Charles R Greathouse IV, Jul 28 2015

Formula

a(n) = 2*a(n-1) - 2*a(n-3) + a(n-4).
G.f.: (1+2*x+3*x^2)/((1+x)*(1-x)^3).
a(n) + A212960(n) = (n+1)^3.
a(n) = (6*n^2 + 8*n + 3 + (-1)^n)/4. - Luce ETIENNE, Apr 05 2014
a(n) = 2*A069905(3*(n+1)+2) - 3*(n+1). - Ayoub Saber Rguez, Aug 31 2021

A099392 a(n) = floor((n^2 - 2*n + 3)/2).

Original entry on oeis.org

1, 1, 3, 5, 9, 13, 19, 25, 33, 41, 51, 61, 73, 85, 99, 113, 129, 145, 163, 181, 201, 221, 243, 265, 289, 313, 339, 365, 393, 421, 451, 481, 513, 545, 579, 613, 649, 685, 723, 761, 801, 841, 883, 925, 969, 1013, 1059, 1105, 1153, 1201, 1251, 1301, 1353, 1405
Offset: 1

Views

Author

Ralf Stephan following a suggestion from Luke Pebody, Oct 20 2004

Keywords

Crossrefs

Differs from A085913 at n = 61. Apart from leading term, identical to A080827.
Cf. A000217, A001844, A002522, A007494, A007590, A058331 (bisections).
From Guenther Schrack, Apr 17 2018: (Start)
First differences: A052928.
Partial sums: A212964(n) + n for n > 0.
Also A058331 and A001844 interleaved. (End)

Programs

  • Mathematica
    Array[Floor[(#^2 - 2 # + 3)/2] &, 54] (* or *)
    Rest@ CoefficientList[Series[x (-1 + x - x^2 - x^3)/((1 + x) (x - 1)^3), {x, 0, 54}], x] (* Michael De Vlieger, Apr 21 2018 *)
  • PARI
    a(n)=(n^2+3)\2-n \\ Charles R Greathouse IV, Aug 01 2013

Formula

a(n) = ceiling(n^2/2)-n+1. - Paul Barry, Jul 16 2006; index shifted by R. J. Mathar, Jul 29 2007
a(n) = ceiling(A002522(n-1)/2). - Branko Curgus, Sep 02 2007
From R. J. Mathar, Feb 20 2011: (Start)
G.f.: x *( -1+x-x^2-x^3 ) / ( (1+x)*(x-1)^3 ).
a(n) = 2*a(n-1) - 2*a(n-3) + a(n-4).
a(n+1) = (3 + 2*n^2 + (-1)^n)/4. (End)
a(n) = A007590(n-1) + 1 for n >= 2. - Richard R. Forberg, Aug 01 2013
a(n) = A000217(n) - A007494(n-1). - Bui Quang Tuan, Mar 27 2015
From Guenther Schrack, Apr 17 2018: (Start)
a(n) = (2*n^2 - 4*n + 5 -(-1)^n)/4.
a(n+2) = a(n) + 2*n for n > 0.
a(n) = 2*A033683(n-1) - 1 for n > 0.
a(n) = A047838(n-1) + 2 for n > 2.
a(n) = A074148(n-1) - n + 2 for n > 1.
a(n) = A183575(n-3) + 3 for n > 3.
a(n) = 2*A290743(n-1) - 3 for n > 0.
a(n) = 2*A290743(n-2) + A109613(n-5) for n > 4.
a(n) = A074148(n) - A014601(n-1) for n > 0. (End)
Sum_{n>=1} 1/a(n) = tanh(Pi/2)*Pi/2 + coth(Pi/sqrt(2))*Pi/(2*sqrt(2)) + 1/2. - Amiram Eldar, Sep 16 2022
E.g.f.: ((2 - x + x^2)*cosh(x) + (3 - x + x^2)*sinh(x) - 2)/2. - Stefano Spezia, Jan 28 2024

A008514 4-dimensional centered cube numbers.

Original entry on oeis.org

1, 17, 97, 337, 881, 1921, 3697, 6497, 10657, 16561, 24641, 35377, 49297, 66977, 89041, 116161, 149057, 188497, 235297, 290321, 354481, 428737, 514097, 611617, 722401, 847601, 988417, 1146097, 1321937, 1517281, 1733521, 1972097, 2234497, 2522257, 2836961, 3180241
Offset: 0

Views

Author

Keywords

Comments

Summation of n^4 taken two at a time. - Al Hakanson (hawkuu(AT)gmail.com), May 27 2009
The primes in this sequence are given by A152913. - Jonathan Vos Post, Aug 17 2011

Crossrefs

Programs

  • GAP
    List([0..30],n->n^4+(n+1)^4); # Muniru A Asiru, Aug 02 2018
  • Magma
    [(n+1)^4+n^4: n in [0..30]]; // Vincenzo Librandi, Aug 27 2011
    
  • Maple
    seq(n^4+(n+1)^4, n=0..40);
  • Mathematica
    Total/@Partition[Range[0, 30]^4, 2, 1] (* or *) LinearRecurrence[{5,-10, 10,-5,1}, {1,17,97,337,881}, 30] (* Harvey P. Dale, Jan 28 2013 *)
  • PARI
    a(n) = n^4 + (n+1)^4; \\ Altug Alkan, Aug 01 2018
    
  • Sage
    [i^4+(i+1)^4 for i in range(0,36)] # Zerinvary Lajos, Jul 03 2008
    

Formula

a(n) = n^4 + (n+1)^4.
a(n) = 2*n^4 + 4*n^3 + 6*n^2 + 4*n + 1. - Al Hakanson (hawkuu(AT)gmail.com), May 27 2009, corrected R. J. Mathar, May 29 2009
G.f.: (1+10*x+x^2)*(1+x)^2/(1-x)^5. - Maksym Voznyy (voznyy(AT)mail.ru), Aug 09 2009
a(n) = 5*a(n-1) - 10*a(n-2) + 10*a(n-3) - 5*a(n-4) + a(n-5), with a(0) = 1, a(1) = 17, a(2) = 97, a(3) = 337, a(4) = 881. - Harvey P. Dale, Jan 28 2013
a(n) = 4*(n+n^2) + 2*(n+n^2)^2 + 1. - Avi Friedlich, Mar 31 2015
a(n) = 2*A002061(n+1)^2 - 1. - Bruce J. Nicholson, Apr 14 2017
a(n) = A047838(2*(n^2+n+1)). - David James Sycamore, Aug 01 2018
E.g.f.: (1 + 16*x + 32*x^2 + 16*x^3 + 2*x^4)*exp(x). - G. C. Greubel, Nov 09 2019
Sum_{n>=0} 1/a(n) = (tanh((sqrt(2)-1)*Pi/2)*Pi*(2+sqrt(2)) - tanh((sqrt(2)+1)*Pi/2)*Pi*(2-sqrt(2)))/4. - Amiram Eldar, Sep 20 2022

A331968 Maximum number of unit squares of a snake-like polyomino in an n X n square box.

Original entry on oeis.org

1, 3, 7, 11, 17, 24, 33, 42, 53, 64, 77, 92, 107, 123, 142, 162, 182
Offset: 1

Views

Author

Alain Goupil, Feb 02 2020

Keywords

Comments

These are similar to the snake-in-the-box problem for the hypercube Q_n (See A099155).
The number of solutions is given by A331986(n).
Equivalently, a(n) is the maximum number of vertices in a path without chords in the n X n grid graph. A path without chords is an induced subgraph that is a path.
These numbers are part of the result of a computer program that counts the snake-like polyominoes in a rectangle of given size b X h by their length.
a(16) >= 161.

Examples

			For n=4, the maximum length of a snake-like polyomino that fits in a square of side 4 is 11 and there are 84 such snakes.
Maximum-length snakes for n = 1 to 4 are shown below.
   X    X X    X X X    X X X X
        X      X   X    X     X
               X   X    X     X
                        X   X X
		

Crossrefs

Formula

a(n) >= A047838(n+1).
For n > 2: a(n) >= 2*floor(n/3)*(2n-3*floor(n/3)-2)+5. - Elijah Beregovsky, May 11 2020
a(n) <= (2*n*(n+1)-1)/3. - Elijah Beregovsky, Nov 09 2020
a(n) = 2*n^2/3 + O(n) (Beluhov 2023). - Pontus von Brömssen, Jan 30 2023

Extensions

a(15) from Andrew Howroyd, Feb 04 2020
a(16)-a(17) from Yi Yang, Oct 03 2022

A302337 Triangle read by rows: T(n,k) is the number of 2k-cycles in the n X n grid graph (2 <= k <= floor(n^2/2), n >= 2).

Original entry on oeis.org

1, 4, 4, 5, 9, 12, 26, 52, 76, 32, 6, 16, 24, 61, 164, 446, 1100, 2102, 2436, 1874, 900, 226, 25, 40, 110, 332, 1070, 3504, 11144, 32172, 77874, 146680, 217470, 255156, 233786, 158652, 69544, 13732, 1072, 36, 60, 173, 556, 1942, 7092, 26424, 97624, 346428, 1136164, 3313812, 8342388, 18064642, 33777148, 54661008, 76165128, 89790912, 86547168, 64626638, 34785284, 12527632, 2677024, 255088
Offset: 2

Views

Author

Eric W. Weisstein, Apr 05 2018

Keywords

Examples

			Triangle begins:
   1;
   4,  4,  5;
   9, 12, 26,  52,  76,   32,    6;
  16, 24, 61, 164, 446, 1100, 2102, 2436, 1874, 900, 226;
  ...
So for example, the 3 X 3 grid graph has 4 4-cycles, 4 6-cycles, and 5 8-cycles.
		

Crossrefs

Cf. A003763 (number of Hamiltonian cycles in 2n X 2n grid graph).
Cf. A140517 (number of cycles).
Cf. A301648 (number of longest cycles).

Programs

  • Mathematica
    Flatten[Table[Tally[Length /@ FindCycle[GridGraph[{n, n}], Infinity, All]][[All, 2]], {n, 6}]] (* Eric W. Weisstein, Mar 26 2021 *)
  • Python
    # Using graphillion
    from graphillion import GraphSet
    import graphillion.tutorial as tl
    def A302337(n):
        universe = tl.grid(n - 1, n - 1)
        GraphSet.set_universe(universe)
        cycles = GraphSet.cycles()
        return [cycles.len(2 * k).len() for k in range(2, n * n // 2 + 1)]
    print([i for n in range(2, 8) for i in A302337(n)])  # Seiichi Manyama, Mar 29 2020

Formula

Row sums equal A140517(n).
Length of row n equals A047838(n) = floor(n^2/2) - 1.
T(n,2) = 1 - 2*n + n^2 = (n-1)^2.
T(n,3) = 4 - 6*n + 2*n^2 = A046092(n-2).
T(n,4) = 26 - 28*n + 7*n^2 for n > 2.
T(n,5) = 164 - 140*n + 28*n^2 for n > 3.
T(n,6) = 1046 - 740*n + 124*n^2 for n > 4.
T(n,k) = A302335(k) - A302336(k)*n + A002931(k)*n^2 for n > k-2.
T(n,floor(n^2/2)) = A301648(n).
T(n,n^2/2) = A003763(n) for n even.

A188653 Second differences of A000463; first differences of A188652.

Original entry on oeis.org

1, 1, -3, 7, -11, 17, -23, 31, -39, 49, -59, 71, -83, 97, -111, 127, -143, 161, -179, 199, -219, 241, -263, 287, -311, 337, -363, 391, -419, 449, -479, 511, -543, 577, -611, 647, -683, 721, -759, 799, -839, 881, -923, 967, -1011, 1057, -1103, 1151, -1199, 1249, -1299, 1351, -1403, 1457, -1511, 1567, -1623, 1681, -1739, 1799, -1859, 1921, -1983, 2047, -2111, 2177, -2243, 2311, -2379, 2449, -2519, 2591, -2663, 2737, -2811
Offset: 1

Views

Author

Reinhard Zumkeller, Apr 13 2011

Keywords

Crossrefs

Programs

  • Haskell
    a188653 n = a188653_list !! (n-1)
    a188653_list = zipWith (-) (tail a188652_list) a188652_list
  • Mathematica
    LinearRecurrence[{-2, 0, 2, 1}, {1, 1, -3, 7}, 75] (* Jean-François Alcover, Dec 16 2021 *)
    Differences[Flatten[Table[{n,n^2},{n,50}]],2] (* Harvey P. Dale, Aug 03 2025 *)

Formula

a(2*n) = a(2*n-1)+4*n^2-2*n-2, a(2*n+1) = -a(2*n)-2*n.
a(2*n) = A056220(n), a(2*n-1) = -A142463(n).
Abs(a(n)) = A047838(n) for n > 1.
a(n) = A188652(n+1)-A188652(n) = A000463(n+2)-2*A000463(n+1)+A000463(n).
G.f.: x*(-1-3*x+x^2+x^3) / ((x-1)*(1+x)^3). - R. J. Mathar, Apr 14 2011
a(n) = a(-n) = ((2*n^2-5)*(-1)^n+1)/4. - Bruno Berselli, Sep 14 2011
E.g.f.: 1 + ((x^2 - x - 2)*cosh(x) - (x^2 - x - 3)*sinh(x))/2. - Stefano Spezia, Jul 08 2023
Sum_{n>=1} 1/a(n) = 1/2 - cot(Pi/sqrt(2))*Pi/(2*sqrt(2)) - tan(sqrt(3)*Pi/2)*Pi/(2*sqrt(3)). - Amiram Eldar, May 11 2025

A179207 a(n) = n - 1 + ceiling((-3 + n^2)/2) if n > 1 with a(1)=1, complement of A182835.

Original entry on oeis.org

1, 2, 5, 10, 15, 22, 29, 38, 47, 58, 69, 82, 95, 110, 125, 142, 159, 178, 197, 218, 239, 262, 285, 310, 335, 362, 389, 418, 447, 478, 509, 542, 575, 610, 645, 682, 719, 758, 797, 838, 879, 922, 965, 1010, 1055, 1102, 1149, 1198, 1247, 1298, 1349, 1402, 1455
Offset: 1

Views

Author

Clark Kimberling, Jan 07 2011

Keywords

Crossrefs

First differences: A109613(n) for n > 2. - Guenther Schrack, Jun 06 2018

Programs

  • GAP
    a:=[2,5,10,15];; for n in [5..60] do a[n]:=2*a[n-1]-2*a[n-3]+a[n-4]; od; a:=Concatenation([1],a); # Muniru A Asiru, Aug 05 2018
  • Maple
    a:=n->n-1+ceil((-3+n^2)/2): 1,seq(a(n),n=2..60); # Muniru A Asiru, Aug 05 2018
  • Mathematica
    Table[n-1+Ceiling[(n*n-3)/2], {n,60}] (* Vladimir Joseph Stephan Orlovsky, Apr 02 2011 *)
    Join[{1},LinearRecurrence[{2,0,-2,1},{2,5,10,15},52]] (* Ray Chandler, Jul 15 2015 *)

Formula

a(n) = n - 1 + ceiling((-3 + n^2)/2) if n > 1.
a(n) = 2*a(n-1) - 2*a(n-3) + a(n-4). - Joerg Arndt, Apr 02 2011
From Guenther Schrack, Jun 06 2018: (Start)
a(n) = (2*n^2 + 4*n - 9 + (-1)^n)/4 for n > 1.
a(n) = a(n-2) + 2*n for n > 3.
a(-n) = a(n-2) for n > 1.
a(n) = n - 1 + A047838(n) for n > 1. (End)
G.f.: x * (1 + x^2 + 2*x^3 - 2*x^4) / (1 - 2*x + 2*x^3 - x^4). - Michael Somos, Oct 28 2018
Sum_{n>=1} 1/a(n) = 8/3 + tan(sqrt(5)*Pi/2)*Pi/(2*sqrt(5)) - cot(sqrt(3/2)*Pi)*Pi/(2*sqrt(6)). - Amiram Eldar, Sep 16 2022

A246696 Triangle t(n,k) = t(n,k-2) + 2 if n > 1 and 2 <= k <= n; t(0,0) = 1, t(1,0) = 2, t(1,1) = 3; if n > 1 is odd, then t(n,0) = t(n-1,n-2) + 2 and t(n,1) = t(n-1,n-1) + 2; if n > 1 is even, then t(n,0) = t(n-1,n-1) + 2 and t(n,1) = t(n-1,n-2) + 2.

Original entry on oeis.org

1, 2, 3, 5, 4, 7, 6, 9, 8, 11, 13, 10, 15, 12, 17, 14, 19, 16, 21, 18, 23, 25, 20, 27, 22, 29, 24, 31, 26, 33, 28, 35, 30, 37, 32, 39, 41, 34, 43, 36, 45, 38, 47, 40, 49, 42, 51, 44, 53, 46, 55, 48, 57, 50, 59, 61, 52, 63, 54, 65, 56, 67, 58, 69, 60, 71, 62
Offset: 0

Views

Author

Clark Kimberling, Sep 17 2014

Keywords

Comments

As an array, for each m, row 2*m has m even numbers and [(m+1)/2] odd numbers, and row 2*m-1 has m odds and m evens. Every positive number occurs exactly once, so that as a sequence (with offset 1), this is a permutation of the positive integers, with inverse A246698.

Examples

			First 8 rows:
1
2 ... 3
5 ... 4 ... 7
6 ... 9 ... 8 ... 11
13 .. 10 .. 15 .. 12 .. 17
14 .. 19 .. 16 .. 21 .. 18 .. 23
25 .. 20 .. 27 .. 22 .. 29 .. 24 .. 31
26 .. 33 .. 28 .. 35 .. 30 .. 37 .. 32 .. 39
		

Crossrefs

Cf. A246697 (row sums), A246698 (inverse permutation), A246694.
Cf. A001844, A047838 (main diagonal), A128174 (parity).

Programs

  • Mathematica
    z = 25; t[0, 0] = 1; t[1, 0] = 2; t[1, 1] = 3; t[n_, 0] := t[n, 0] = If[OddQ[n], t[n - 1, n - 2] + 2, t[n - 1, n - 1] + 2]; t[n_, 1] := t[n, 1] = If[OddQ[n], t[n - 1, n - 1] + 2, t[n - 1, n - 2] + 2]; t[n_, k_] := t[n, k] = t[n, k - 2] + 2;
    u = Flatten[Table[t[n, k], {n, 0, z}, {k, 0, n}]] (* A246696 *)

Formula

For m >= 0, {t(2*m,0)} = A001844. - Ruud H.G. van Tol, Sep 30 2024

Extensions

Edited by M. F. Hasler, Nov 17 2014

A195241 Expansion of (1-x+19*x^3-3*x^4)/(1-x)^3.

Original entry on oeis.org

1, 2, 3, 23, 59, 111, 179, 263, 363, 479, 611, 759, 923, 1103, 1299, 1511, 1739, 1983, 2243, 2519, 2811, 3119, 3443, 3783, 4139, 4511, 4899, 5303, 5723, 6159, 6611, 7079, 7563, 8063, 8579, 9111, 9659, 10223, 10803, 11399, 12011, 12639, 13283, 13943
Offset: 0

Views

Author

Bruno Berselli, Sep 13 2011 - based on remarks and sequences by Omar E. Pol

Keywords

Comments

Sequence found by reading the line 1, 2, 3, 23,.. in the square spiral whose vertices are the triangular numbers (A000217) - see Pol's comments in other sequences visible in this numerical spiral.
This is a subsequence of A110326 (without signs) and A047838 (apart from the second term, 2).

Crossrefs

Programs

  • Magma
    m:=44; R:=PowerSeriesRing(Integers(), m); Coefficients(R!((1-x+19*x^3-3*x^4)/(1-x)^3));
    
  • Mathematica
    CoefficientList[Series[(1 - x + 19 x^3 - 3 x^4)/(1 - x)^3, {x, 0, 50}], x] (* Vincenzo Librandi, Mar 26 2013 *)
    LinearRecurrence[{3,-3,1},{1,2,3,23,59},50] (* Harvey P. Dale, Dec 04 2022 *)
  • Maxima
    makelist(coeff(taylor((1-x+19*x^3-3*x^4)/(1-x)^3, x, 0, n), x, n), n, 0, 43);
  • PARI
    Vec((1-x+19*x^3-3*x^4)/(1-x)^3+O(x^44))
    

Formula

G.f.: (1-x+19*x^3-3*x^4)/(1-x)^3.
a(n) = 8*n^2-20*n+11 for n>1; a(0)=1, a(1)=2.
Showing 1-10 of 22 results. Next