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 A179054 #15 Feb 11 2024 11:44:51 %S A179054 1,1,1,4,1,1,1,6,1,1,1,8,1,1,1,10,1,1,1,12,1,1,1,14,1,1,1,16,1,1,1,18, %T A179054 1,1,1,20,1,1,1,22,1,1,1,24,1,1,1,26,1,1,1,28,1,1,1,30,1,1,1,32,1,1,1, %U A179054 34,1,1,1,36,1,1,1,38,1,1,1,40,1,1,1,42,1,1,1,44,1,1,1,46,1,1,1,48,1,1,1 %N A179054 a(n) = (1^k + 2^k + ... + n^k) modulo (n+2), where k is any odd integer greater than or equal to 3. %H A179054 Robert Israel, <a href="/A179054/b179054.txt">Table of n, a(n) for n = 1..10000</a> %H A179054 <a href="/index/Rec#order_08">Index entries for linear recurrences with constant coefficients</a>, signature (0,0,0,2,0,0,0,-1). %F A179054 a(n) = 2m+2, if n = 4m for some integer m; a(n) = 1 otherwise. %F A179054 G.f.: (x+x^2+x^3+4*x^4-x^5-x^6-x^7-2*x^8)/(1-2*x^4+x^8). - _Robert Israel_, Dec 05 2016 %e A179054 a(4) = (1^3 + 2^3 + 3^3 + 4^3) mod 6 = 100 mod 6 = 4. %p A179054 seq(op([1,1,1,2*k]),k=2..50); # _Robert Israel_, Dec 05 2016 %t A179054 f[n_] := Mod[n^2(n + 1)^2/4, n + 2]; Array[f, 100] (* _Robert G. Wilson v_, Jul 01 2010 *) %t A179054 LinearRecurrence[{0, 0, 0, 2, 0, 0, 0, -1}, {1, 1, 1, 4, 1, 1, 1, 6}, 100] (* _Vincenzo Librandi_, Dec 05 2016 *) %o A179054 (PARI) s=0; for(n=1, 100, s+=n^3; print(s%(n+2))) %o A179054 (Magma) &cat [[1,1,1,2*n]: n in [1..30]]; // _Vincenzo Librandi_, Dec 05 2016 %K A179054 easy,nonn %O A179054 1,4 %A A179054 _Nick Hobson_, Jun 27 2010 %E A179054 Typo in name of sequence corrected and formula added by _Nick Hobson_, Jun 27 2010 %E A179054 More terms from _Robert G. Wilson v_, Jul 01 2010