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.

A024810 a(n) = floor( tan(m*Pi/2) ), where m = 1 - 2^(-n).

Original entry on oeis.org

1, 2, 5, 10, 20, 40, 81, 162, 325, 651, 1303, 2607, 5215, 10430, 20860, 41721, 83443, 166886, 333772, 667544, 1335088, 2670176, 5340353, 10680707, 21361414, 42722829, 85445659, 170891318, 341782637, 683565275, 1367130551, 2734261102, 5468522204, 10937044409
Offset: 1

Views

Author

Keywords

Comments

Geometrically, each term of the sequence represents the integer part of the distance between opposite vertices and also edges of even sided polygons, each of which has double the number of sides of the previous, starting with a square of unit length. - Torlach Rush, Feb 21 2014
a(n) is the greatest integer k such that k/2^n < 2/Pi. - Clark Kimberling, Oct 10 2017
Number of roots of sin(1/x) = 0 in interval 1/2^(n+1) < x < 1. - Hugo Pfoertner, Oct 24 2019
Or simply: number of zeros of sin(x) in the range [1, 2^(n+1)]. - M. F. Hasler, Oct 25 2019

Crossrefs

Cf. A127266 (mod 2), A172265 (partial sums).

Programs

Formula

a(n) = floor( 1 / tan( Pi / 2^(n+1) )). - Michael Somos, Feb 24 2014
a(n) = floor(2^(n+1)/Pi). - Clark Kimberling, Oct 10 2017 [Corrected by Michel Marcus, Oct 25 2019]
From Sanjar Abrarov, Jun 20 2024: (Start)
a(n) = floor(c_n/sqrt(2-c_{n-1})), where c_n=sqrt(2+c_{n-1}) and c_0 = 0.
a(n) = 2*a(n-1)+A127266(n). (End)

Extensions

a(30)-a(33) corrected by Michel Marcus, Mar 23 2013