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.

A209492 a(0)=1; for n >= 1, let k = floor((1 + sqrt(8*n-7))/2), m = n - (k^2 - k+2)/2. Then a(n) = 2^k + 2^(m+1) - 1.

This page as a plain text file.
%I A209492 #23 Aug 17 2023 11:05:56
%S A209492 1,3,5,7,9,11,15,17,19,23,31,33,35,39,47,63,65,67,71,79,95,127,129,
%T A209492 131,135,143,159,191,255,257,259,263,271,287,319,383,511,513,515,519,
%U A209492 527,543,575,639,767,1023,1025,1027,1031,1039,1055,1087,1151,1279,1535,2047,2049,2051,2055,2063,2079,2111,2175,2303,2559,3071
%N A209492 a(0)=1; for n >= 1, let k = floor((1 + sqrt(8*n-7))/2), m = n - (k^2 - k+2)/2. Then a(n) = 2^k + 2^(m+1) - 1.
%C A209492 The sequence is concatenation of rows of triangle which begins
%C A209492   i\j |   0     1     2     3     4     5     6     7     8
%C A209492 ======+====================================================
%C A209492   0   |   1
%C A209492   1   |   3     5
%C A209492   2   |   7     9    11
%C A209492   3   |  15    17    19    23
%C A209492   4   |  31    33    35    39    47
%C A209492   5   |  63    65    67    71    79    95
%C A209492   6   | 127   129   131   135   143   159   191
%C A209492   7   | 255   257   259   263   271   287   319   383
%C A209492   8   | 511   513   515   519   527   543   575   639   767
%H A209492 G. C. Greubel, <a href="/A209492/b209492.txt">Table of n, a(n) for n = 0..1000</a>
%F A209492 For i=0,1,..., the i-th row is 2^(i+1)-1, if j=0, and 2^(i+1)+2^j-1, if j=1,...,i.
%e A209492 Consider n=19. Then k = floor((1 + sqrt(145))/2) = 6 and m = 19 - 16 = 3. Thus a(19) = 2^6 + 2^4 - 1 = 79.
%t A209492 k = Floor[(1 + Sqrt[8*n - 7])/2]; m = n - (k^2 - k + 2)/2; a[n_] = If[n == 0, 1, 2^k + 2^(m + 1) - 1]; Table[a[n], {n, 0, 100}]
%Y A209492 Cf. A000225, A224195 (binary reversal).
%K A209492 nonn,easy,tabl
%O A209492 0,2
%A A209492 _Vladimir Shevelev_, Mar 09 2012