login
This site is supported by donations to The OEIS Foundation.

 

Logo


Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A320259 Terms that are on the y-axis of the square spiral built with 2*k, 2*k+1, 2*k+1 for k >= 0. 1
0, 2, 5, 9, 15, 22, 30, 40, 51, 63, 77, 92, 108, 126, 145, 165, 187, 210, 234, 260, 287, 315, 345, 376, 408, 442, 477, 513, 551, 590, 630, 672, 715, 759, 805, 852, 900, 950, 1001, 1053, 1107, 1162, 1218, 1276, 1335 (list; graph; refs; listen; history; text; internal format)
OFFSET

0,2

COMMENTS

a(n) mod 9 is of period 27.

The spiral:

     28--29--29--30--31--31--32

      |

     27  13--14--15--15--16--17

      |   |                   |

     27  13   4---5---5---6  17

      |   |   |           |   |

     26  12   3   0---1   7  18

      |   |   |       |   |   |

     25  11   3---2---1   7  19

      |   |               |   |

     25  11--10---9---9---8  19

      |                       |

     24--23--23--22--21--21--20

LINKS

Colin Barker, Table of n, a(n) for n = 0..1000

Index entries for linear recurrences with constant coefficients, signature (2,-1,1,-2,1).

FORMULA

a(n) = 2*a(n-1) - a(n-2) + a(n-3) - 2*a(n-4) + a(n-5), a(0)=0, a(1)=2, a(2)=5, a(3)=9, a(4)=15.

a(n) = a(n-1) + A004772(n+1), a(0)=0, n>0.

a(n+15) = a(n-15) + 10*A004767(n).

a(-n-1) = ({0} U A000969(n)) = 0, 1, 3, 7, ... = b(n), the full x-axis terms.

a(-n-1) + a(n) = 0, 3, 8, 16, ... = A211480(n+1).

a(n) = b(n) + A004523(n+1).

G.f.: x*(2 + x + x^2) / ((1 - x)^3*(1 + x + x^2)). - Colin Barker, Oct 08 2018

a(n) = A143978(n) + A002264(n+2).

a(n) = A000969(-2-n) for all n in Z. - Michael Somos, Nov 13 2018

EXAMPLE

G.f. = 2*x + 5*x^2 + 9*x^3 + 15*x^4 + 22*x^5 + 30*x^6 + ... - Michael Somos, Nov 13 2018

MAPLE

seq(coeff(series(x^2*(2+x+x^2)/((1-x)^3*(1+x+x^2)), x, n+1), x, n), n = 1 .. 50); # Muniru A Asiru, Oct 08 2018

MATHEMATICA

LinearRecurrence[{2, -1, 1, -2, 1}, {0, 2, 5, 9, 15}, 50] (* or *)

CoefficientList[Series[x*(2 + x + x^2) / ((1 - x)^3*(1 + x + x^2)), {x, 0, 50}], x] (* Stefano Spezia, Oct 09 2018 *)

a[ n_] := Quotient[(n + 1) (2 n + 1), 3]; (* Michael Somos, Nov 13 2018 *)

PROG

(PARI) concat(0, Vec(x*(2 + x + x^2) / ((1 - x)^3*(1 + x + x^2)) + O(x^60))) \\ Colin Barker, Oct 08 2018

(PARI) {a(n) = (n + 1) * (2*n + 1) \ 3}; /* Michael Somos, Nov 13 2018 */

(GAP) a:=[0, 2, 5, 9, 15];; for n in [6..50] do a[n]:=2*a[n-1]-a[n-2]+a[n-3]-2*a[n-4]+a[n-5]; od; a; # Muniru A Asiru, Oct 08 2018

CROSSREFS

Cf. A000969, A004396, A004523, A004767, A004772 (first differences), A211480, A002264, A143978.

Sequence in context: A195014 A152738 A022941 * A007982 A011904 A308265

Adjacent sequences:  A320256 A320257 A320258 * A320260 A320261 A320262

KEYWORD

nonn

AUTHOR

Paul Curtz, Oct 08 2018

STATUS

approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified November 12 21:22 EST 2019. Contains 329079 sequences. (Running on oeis4.)