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 A045928 #21 Mar 08 2020 04:04:32 %S A045928 1,2,5,8,9,12,15,18,21,22,25,28,31,34,37,40,41,44,47,50,53,56,59,62, %T A045928 65,66,69,72,75,78,81,84,87,90,93,96,97,100,103,106,109,112,115,118, %U A045928 121,124,127,130,133,134,137,140,143,146,149,152,155,158,161,164,167,170,173,176,177 %N A045928 The generalized Connell sequence C_{3,2}. %H A045928 Reinhard Zumkeller, <a href="/A045928/b045928.txt">Table of n, a(n) for n = 1..10000</a> %H A045928 Douglas E. Iannucci and Donna Mills-Taylor, <a href="http://www.cs.uwaterloo.ca/journals/JIS/IANN/iann1.html">On Generalizing the Connell Sequence</a>, J. Integer Sequences, Vol. 2, 1999, #99.1.7. %F A045928 C(n, m, r) = n*m - (m - 1)*floor((3*r - 2 + sqrt(8*r*(n - 1) + (r - 2)^2)) / (2*r)) with m=3 and r=2, thus a(n) = 3*n - 2*floor(1 + sqrt(n-1)). - _Michel Marcus_, Apr 02 2013 %e A045928 From _Michel Marcus_, Apr 02 2013: (Start) %e A045928 As a triangle, sequence begins: %e A045928 1; %e A045928 2, 5, 8; %e A045928 9, 12, 15, 18, 21; %e A045928 ... %e A045928 (End) %t A045928 Table[3*n-2*Floor[1+Sqrt[n-1]],{n,70}] (* _Harvey P. Dale_, Apr 19 2019 *) %o A045928 (PARI) lista(nrow, m=3, r=2) = {a = 1; for (irow = 1, nrow, for (k = 1, 1 + r*(irow -1), print1(a, ", "); a += m;); a += 1 - m;);} \\ _Michel Marcus_, Apr 02 2013 %o A045928 (Haskell) %o A045928 a045928 n = 3 * n - 2 * floor (1 + sqrt (fromIntegral n - 1)) %o A045928 -- _Reinhard Zumkeller_, Aug 09 2015 %K A045928 nonn,easy,nice %O A045928 1,2 %A A045928 _N. J. A. Sloane_ %E A045928 More terms from jeroen.lahousse(AT)icl.com %E A045928 Typo in formula fixed by _Reinhard Zumkeller_, Aug 09 2015