cp's OEIS Frontend

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.

A226500 Triangular numbers representable as 3 * x^2.

This page as a plain text file.
%I A226500 #24 Mar 03 2016 22:52:13
%S A226500 0,3,300,29403,2881200,282328203,27665282700,2710915376403,
%T A226500 265642041604800,26030209161894003,2550694855824007500,
%U A226500 249942065661590841003,24491771739980078410800,2399943688452386093417403,235169989696593857076494700,23044259046577745607403063203
%N A226500 Triangular numbers representable as 3 * x^2.
%H A226500 Colin Barker, <a href="/A226500/b226500.txt">Table of n, a(n) for n = 1..503</a>
%H A226500 <a href="/index/Rec#order_03">Index entries for linear recurrences with constant coefficients</a>, signature (99,-99,1).
%F A226500 a(n) = 99*a(n-1) - 99*a(n-2) + a(n-3), for n > 3. a(n) = floor((49 + 20*sqrt(6))^(n-1)/32). - _Giovanni Resta_, Jun 09 2013
%F A226500 G.f.: 3*x^2*(1+x)/((1-x)*(1-98*x+x^2)); a(n)=3*A108741(n-1). - _Joerg Arndt_, Jun 10 2013
%F A226500 a(n) = (49+20*sqrt(6))^(-n)*(49+20*sqrt(6)-2*(49+20*sqrt(6))^n+(49-20*sqrt(6))*(49+20*sqrt(6))^(2*n))/32. - _Colin Barker_, Mar 03 2016
%t A226500 a[1]=0; a[2]=3; a[3]=300; a[n_] := a[n] = 99*(a[n-1] - a[n-2]) + a[n-3]; Array[a, 10] (* _Giovanni Resta_, Jun 09 2013 *)
%t A226500 Rest@ CoefficientList[Series[3 x^2 (1 + x)/((1 - x) (1 - 98 x + x^2)), {x, 0, 16}], x] (* or *)
%t A226500 3 LinearRecurrence[{99, -99, 1}, {0, 1, 100}, 16] (* _Michael De Vlieger_, Mar 03 2016, latter after _Vincenzo Librandi_ at A108741 *)
%o A226500 (C)
%o A226500 #include <stdio.h>
%o A226500 #include <math.h>
%o A226500 typedef unsigned long long U64;
%o A226500 U64 isTriangular(U64 a) {   // input must be < 1ULL<<63
%o A226500     U64 r = sqrt(a*2);
%o A226500     return (r*(r+1) == a*2);
%o A226500 }
%o A226500 int main() {
%o A226500   for (U64 j, i = 0; (j=i*i*3) < (1ULL<<63); i++)
%o A226500       if (isTriangular(j)) printf("%llu, ", j);
%o A226500   return 0;
%o A226500 }
%Y A226500 Cf. A029549 (triangular numbers representable as x^2 + x).
%Y A226500 Cf. A000217, A001219, A165892, A069017.
%K A226500 nonn,easy
%O A226500 1,2
%A A226500 _Alex Ratushnyak_, Jun 09 2013
%E A226500 a(12)-a(15) from _Giovanni Resta_, Jun 09 2013