login
Squares (A000290) which are also centered triangular numbers (A005448).
3

%I #17 Sep 08 2022 08:46:10

%S 1,4,64,361,6241,35344,611524,3463321,59923081,339370084,5871850384,

%T 33254804881,575381414521,3258631508224,56381506772644,

%U 319312633001041,5524812282304561,31289379402593764,541375222159074304,3066039868821187801,53049246959306977201

%N Squares (A000290) which are also centered triangular numbers (A005448).

%C Apart from the first term the same as A165516. - _R. J. Mathar_, Jan 20 2015

%H Colin Barker, <a href="/A249483/b249483.txt">Table of n, a(n) for n = 1..1000</a>

%H <a href="/index/Rec#order_05">Index entries for linear recurrences with constant coefficients</a>, signature (1,98,-98,-1,1).

%F a(n) = a(n-1)+98*a(n-2)-98*a(n-3)-a(n-4)+a(n-5).

%F G.f.: -x*(x^2-5*x+1)*(x^2+8*x+1) / ((x-1)*(x^2-10*x+1)*(x^2+10*x+1)).

%e 64 is in the sequence because the 8th square is 64, which is also the 7th centered triangular number.

%t CoefficientList[Series[(x^2 - 5 x + 1) (x^2 + 8 x + 1) / ((1 - x) (x^2 - 10 x + 1) (x^2 + 10 x + 1)), {x, 0, 70}], x] (* _Vincenzo Librandi_, Jan 20 2015 *)

%o (PARI) Vec(-x*(x^2-5*x+1)*(x^2+8*x+1)/((x-1)*(x^2-10*x+1)*(x^2+10*x+1)) + O(x^100))

%o (Magma) I:=[1,4,64,361,6241]; [n le 5 select I[n] else Self(n-1)+98*Self(n-2)-98*Self(n-3)-Self(n-4)+Self(n-5): n in [1..50]]; // _Vincenzo Librandi_, Jan 20 2015

%Y Cf. A000290, A005448, A129444, A129445.

%K nonn,easy

%O 1,2

%A _Colin Barker_, Jan 13 2015