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.
%I A033990 #31 Aug 12 2018 21:27:10 %S A033990 0,1,1,8,3,7,6,2,1,5,1,1,6,2,2,1,3,4,0,4,5,3,6,7,0,8,9,1,4,6,1,2,7,1, %T A033990 1,4,4,8,1,7,4,7,2,0,8,8,2,4,4,1,2,8,4,6,3,2,7,3,3,7,3,2,4,1,2,3,4,7, %U A033990 5,6,5,2,0,1,5,8,9,8,6,4,1,7,6,1,7,8,7,7,5,1,8,4,7,6,9,2,2,3,9,0,1,0,1,6,8 %N A033990 Write 0,1,2,... in a clockwise spiral on a square lattice, writing each digit at a separate lattice point, starting with 0 at the origin and 1 at x=0, y=-1; sequence gives the numbers on the negative y-axis. %C A033990 Consider array of digits 0_(1)23456789(1)0111213141516171(8)1920212223...; in this array add to n-th pointer 8*n+1 to get next pointer. E.g., n=1 so n+(8*1+1)=10 -> n=10 so n+(8*2+1)=27 -> n=27 so ... etc. - comment from _Patrick De Geest_. %H A033990 Vincenzo Librandi, <a href="/A033990/b033990.txt">Table of n, a(n) for n = 0..1000</a> %F A033990 a(n) = A033307(4*n^2-3*n-1) for n > 0. - _Andrew Woods_, May 20 2012 %e A033990 The spiral begins %e A033990 2---3---2---4---2---5---2 %e A033990 | | %e A033990 2 1---3---1---4---1 6 %e A033990 | | | | %e A033990 2 2 4---5---6 5 2 %e A033990 | | | | | | %e A033990 1 1 3 0 7 1 7 %e A033990 | | | | | | | %e A033990 2 1 2---1 8 6 2 %e A033990 | | | | | %e A033990 0 1---0---1---9 1 8 %e A033990 | | | %e A033990 2---9---1---8---1---7 2 %e A033990 | %e A033990 3---0---3---9 %e A033990 . %e A033990 We begin with the 0 and wrap the numbers 1 2 3 4 ... around it. Then the sequence is obtained by reading downwards, starting from the initial 0. - _Andrew Woods_, May 20 2012 %t A033990 nmax = 105; A033307 = Flatten[IntegerDigits /@ Range[0, nmax^2 + 10 nmax]]; a[n_] := If[n==0, 0, A033307[[4n^2 - 3n + 1]]]; Table[a[n], {n, 0, nmax}] (* _Jean-François Alcover_, Apr 24 2017, after _Andrew Woods_ *) %Y A033990 Sequences based on the same spiral: A033953, A033988, A033989. Spiral without zero: A033952. %Y A033990 Other sequences from spirals: A001107, A002939, A007742, A033951, A033954, A033991, A002943, A033996, A033988. %K A033990 nonn,base,easy,nice %O A033990 0,4 %A A033990 _N. J. A. Sloane_ %E A033990 More terms from _Patrick De Geest_, Oct 15 1999 %E A033990 Edited by _Charles R Greathouse IV_, Nov 01 2009