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.

A262242 Triangular numbers representable as 2^x + 2^y.

This page as a plain text file.
%I A262242 #14 May 05 2021 16:55:05
%S A262242 3,6,10,36,66,136,528,2080,8256,32896,131328,524800,2098176,8390656,
%T A262242 33558528,134225920,536887296,2147516416,8590000128,34359869440,
%U A262242 137439215616,549756338176,2199024304128,8796095119360,35184376283136,140737496743936,562949970198528
%N A262242 Triangular numbers representable as 2^x + 2^y.
%H A262242 Chai Wah Wu, <a href="/A262242/b262242.txt">Table of n, a(n) for n = 1..502</a>
%F A262242 Conjectures from _Colin Barker_, Sep 16 2015: (Start)
%F A262242 a(n) = 2^(n-5)*(2^n+4) for n>5.
%F A262242 a(n) = 6*a(n-1)-8*a(n-2) for n>7.
%F A262242 G.f.: x*(240*x^6+28*x^5-70*x^4+24*x^3-2*x^2-12*x+3) / ((2*x-1)*(4*x-1)).
%F A262242 (End)
%o A262242 (Python)
%o A262242 def isTriangular(a):
%o A262242     sr = 1 << (int.bit_length(a) >> 1)
%o A262242     a += a
%o A262242     while a < sr*(sr+1):  sr>>=1
%o A262242     b = sr>>1
%o A262242     while b:
%o A262242       s = sr+b
%o A262242       if a >= s*(s+1):  sr = s
%o A262242       b>>=1
%o A262242     return (a==sr*(sr+1))
%o A262242 for a in range(1,200):
%o A262242     for b in range(a):
%o A262242         c = (1<<a) + (1<<b)
%o A262242         if isTriangular(c): print(str(c), end=',')
%Y A262242 Cf. A000217, A225390, A226499, A227027, A259745, A259746.
%K A262242 nonn
%O A262242 1,1
%A A262242 _Alex Ratushnyak_, Sep 15 2015