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 A276599 #21 Sep 08 2022 08:46:17 %S A276599 1,4,10,25,59,146,344,851,2005,4960,11686,28909,68111,168494,396980, %T A276599 982055,2313769,5723836,13485634,33360961,78600035,194441930, %U A276599 458114576,1133290619,2670087421,6605301784,15562409950,38498520085,90704372279,224385818726 %N A276599 Values of n such that n^2 + 5 is a triangular number (A000217). %H A276599 Colin Barker, <a href="/A276599/b276599.txt">Table of n, a(n) for n = 1..1000</a> %H A276599 <a href="/index/Rec#order_04">Index entries for linear recurrences with constant coefficients</a>, signature (0,6,0,-1). %F A276599 a(n) = 6*a(n-2) - a(n-4) for n>4. %F A276599 G.f.: x*(1+x)*(1+3*x+x^2) / ((1+2*x-x^2)*(1-2*x-x^2)). %F A276599 a(n) = (1/4)*(P(n+2) + P(n+1) + (-1)^n*(3*P(n) - 7*P(n-1))), where P(n) = A000129(n). - _G. C. Greubel_, Sep 15 2021 %e A276599 4 is in the sequence because 4^2 + 5 = 21, which is a triangular number. %t A276599 CoefficientList[Series[(1+x)*(1+3*x+x^2)/((1+2*x-x^2)*(1-2*x-x^2)), {x, 0, 30}], x] (* _Wesley Ivan Hurt_, Sep 07 2016 *) %t A276599 LinearRecurrence[{0,6,0,-1},{1,4,10,25},30] (* _Harvey P. Dale_, Feb 13 2017 *) %o A276599 (PARI) Vec(x*(1+x)*(1+3*x+x^2)/((1+2*x-x^2)*(1-2*x-x^2)) + O(x^40)) %o A276599 (PARI) a(n)=([0,1;-1,6]^(n\2)*if(n%2,[1;10],[-1;4]))[1,1] \\ _Charles R Greathouse IV_, Sep 07 2016 %o A276599 (Magma) I:=[1,4,10,25]; [n le 4 select I[n] else 6*Self(n-2) - Self(n-4): n in [1..31]]; // _G. C. Greubel_, Sep 15 2021 %o A276599 (Sage) %o A276599 def P(n): return lucas_number1(n, 2, -1) %o A276599 [(1/4)*(P(n+2) + P(n+1) + (-1)^n*(3*P(n) - 7*P(n-1))) for n in (1..30)] # _G. C. Greubel_, Sep 15 2021 %Y A276599 Cf. A000129, A000217, A230044. %Y A276599 Cf. A001109 (k=0), A106328 (k=1), A077241 (k=2), A276598 (k=3), A276600 (k=6), A276601 (k=9), A276602 (k=10), where k is the value added to n^2. %K A276599 nonn,easy %O A276599 1,2 %A A276599 _Colin Barker_, Sep 07 2016