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.

A316671 Squares visited by moving diagonally one square on a diagonally numbered board and moving to the lowest available unvisited square at each step.

This page as a plain text file.
%I A316671 #14 Jul 18 2018 20:05:00
%S A316671 1,5,4,12,11,23,22,38,37,57,56,80,79,107,106,138,137,173,172,212,211,
%T A316671 255,254,302,301,353,352,408,407,467,466,530,529,597,596,668,667,743,
%U A316671 742,822,821,905,904,992,991,1083,1082,1178,1177,1277,1276,1380,1379
%N A316671 Squares visited by moving diagonally one square on a diagonally numbered board and moving to the lowest available unvisited square at each step.
%C A316671 Board is numbered as follows:
%C A316671    1  2  4  7 11 16  .
%C A316671    3  5  8 12 17  .
%C A316671    6  9 13 18  .
%C A316671   10 14 19  .
%C A316671   15 20  .
%C A316671   21  .
%C A316671    .
%H A316671 Daniël Karssen, <a href="/A316671/b316671.txt">Table of n, a(n) for n = 1..10000</a>
%H A316671 Daniël Karssen, <a href="/A316671/a316671.svg">Figure showing the first 6 steps of the sequence</a>
%H A316671 <a href="/index/Rec#order_05">Index entries for linear recurrences with constant coefficients</a>, signature (1,2,-2,-1,1).
%F A316671 From _Colin Barker_, Jul 18 2018: (Start)
%F A316671 G.f.: x*(1 + 4*x - 3*x^2 + 2*x^4) / ((1 - x)^3*(1 + x)^2).
%F A316671 a(n) = a(n-1) + 2*a(n-2) - 2*a(n-3) - a(n-4) + a(n-5) for n>5.
%F A316671 a(n) = (n^2 + n + 4)/2 for n even.
%F A316671 a(n) = (n^2 - n + 2)/2 for n odd.
%F A316671 (End)
%t A316671 CoefficientList[ Series[-(2x^4 - 3x^2 + 4x + 1)/((x - 1)^3 (x + 1)^2), {x, 0, 52}], x] (* or *)
%t A316671 LinearRecurrence[{1, 2, -2, -1, 1}, {1, 5, 4, 12, 11}, 53] (* _Robert G. Wilson v_, Jul 18 2018 *)
%o A316671 (PARI) Vec(x*(1 + 4*x - 3*x^2 + 2*x^4) / ((1 - x)^3*(1 + x)^2) + O(x^40)) \\ _Colin Barker_, Jul 18 2018
%Y A316671 Cf. A316588, A316668, A316669, A316670.
%K A316671 nonn,easy
%O A316671 1,2
%A A316671 _Daniël Karssen_, Jul 15 2018