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.

Showing 1-10 of 10 results.

A019433 Continued fraction for tan(1/10).

Original entry on oeis.org

0, 9, 1, 28, 1, 48, 1, 68, 1, 88, 1, 108, 1, 128, 1, 148, 1, 168, 1, 188, 1, 208, 1, 228, 1, 248, 1, 268, 1, 288, 1, 308, 1, 328, 1, 348, 1, 368, 1, 388, 1, 408, 1, 428, 1, 448, 1, 468, 1, 488, 1, 508, 1, 528, 1, 548, 1, 568, 1, 588, 1, 608, 1, 628, 1, 648, 1, 668, 1, 688, 1, 708, 1, 728
Offset: 0

Views

Author

Keywords

Comments

From Peter Bala, Oct 04 2023: (Start)
Related simple continued fractions expansions (see my comments in A019425):
tan(1/(10*k)) = [0; 10*k - 1, 1, 30*k - 2, 1, 50*k - 2, 1, 70*k - 2, 1, 90*k - 2, 1, ...] for k >= 1.
If d is a divisor of 10 with d*d' = 10 then the simple continued fraction expansion of d*tan(1/10) begins [0; d' - 1, 1, 30*d - 2, 1, 5*d' - 2, 1, 70*d - 2, 1, 9*d' - 2, 1, 110*d - 2, 1, 13*d' - 2, ...], while the simple continued fraction expansion of (1/d)*tan(1/10) begins [ 0; 10*d - 1, 1, 3*d'- 2, 1, 50*d - 2, 1, 7*d' - 2, 1, 90*d - 2, 1, 11*d' - 2, 1, 130*d - 2, ...]. (End)

Examples

			0.10033467208545054505808004... = 0 + 1/(9 + 1/(1 + 1/(28 + 1/(1 + ...)))). - _Harry J. Smith_, Jun 14 2009
		

Crossrefs

Cf. A161019 (decimal expansion), A019425 through A019432.

Programs

  • Mathematica
    LinearRecurrence[{0,2,0,-1},{0,9,1,28,1,48},80] (* or *) Join[{0,9},Riffle[NestList[20+#&,28,40],1,{1,-1,2}]] (* Harvey P. Dale, Jul 23 2023 *)
  • PARI
    { allocatemem(932245000); default(realprecision, 99000); x=contfrac(tan(1/10)); for (n=0, 20000, write("b019433.txt", n, " ", x[n+1])); } \\ Harry J. Smith, Jun 14 2009
    
  • PARI
    Vec(x*(x^4-x^3+10*x^2+x+9)/((x-1)^2*(x+1)^2) + O(x^100)) \\ Colin Barker, Sep 08 2013

Formula

From Colin Barker, Sep 08 2013: (Start)
a(n) = -1/2+(3*(-1)^n)/2+5*n-5*(-1)^n*n for n>1.
a(n) = 2*a(n-2)-a(n-4) for n>5.
G.f.: x*(x^4-x^3+10*x^2+x+9) / ((x-1)^2*(x+1)^2). (End)

A019426 Continued fraction for tan(1/3).

Original entry on oeis.org

0, 2, 1, 7, 1, 13, 1, 19, 1, 25, 1, 31, 1, 37, 1, 43, 1, 49, 1, 55, 1, 61, 1, 67, 1, 73, 1, 79, 1, 85, 1, 91, 1, 97, 1, 103, 1, 109, 1, 115, 1, 121, 1, 127, 1, 133, 1, 139, 1, 145, 1, 151, 1, 157, 1, 163, 1, 169, 1, 175, 1, 181, 1, 187, 1, 193, 1, 199, 1, 205, 1, 211, 1, 217, 1, 223, 1
Offset: 0

Views

Author

Keywords

Comments

The simple continued fraction expansion of 3*tan(1/3) is [1; 25, 1, 3, 1, 61, 1, 7, 1, 97, 1, 11, 1, ..., 36*n + 25, 1, 4*n + 3, 1, ...], while the simple continued fraction expansion of (1/3)*tan(1/3) is [0; 8, 1, 1, 1, 43, 1, 5, 1, 79, 1, 9, 1, 115, 1, 13, 1, ..., 36*n + 7, 1, 4*n + 1, 1, ...]. See my comment in A019425. - Peter Bala, Sep 30 2023

Examples

			0.346253549510575491038543565... = 0 + 1/(2 + 1/(1 + 1/(7 + 1/(1 + ...)))). - _Harry J. Smith_, Jun 13 2009
		

Crossrefs

Cf. A161012 (decimal expansion of tan(1/3)).
Cf. continued fractions for tan(1/m): A019425 (m=2), A019427 (m=4), A019428 (m=5), A019429 (m=6), A019430 (m=7), A019431 (m=8), A019432 (m=9), A019433 (m=10), A093178 (m=1).

Programs

  • Magma
    [n le 1 select 2*n else 1+3*(1-(-1)^n)*(n-1)/2: n in [0..80]]; // Bruno Berselli, Sep 21 2012
  • Mathematica
    ContinuedFraction[Tan[1/3], 80] (* Bruno Berselli, Sep 21 2012 *)
  • PARI
    { allocatemem(932245000); default(realprecision, 88000); x=contfrac(tan(1/3)); for (n=0, 20000, write("b019426.txt", n, " ", x[n+1])); } \\ Harry J. Smith, Jun 13 2009
    

Formula

From Bruno Berselli, Sep 21 2012: (Start)
G.f.: x*(2+x+3*x^2-x^3+x^4)/(1-x^2)^2.
a(n) = 2*a(n-2)-a(n-4) with n>4, a(0)=0, a(1)=2, a(2)=1, a(3)=7, a(4)=1.
a(n) = 1+3*(1-(-1)^n)*(n-1)/2 with n>1, a(0)=0, a(1)=2.
For k>0: a(2k) = 1, a(4k+1) = 2*a(2k+1)-1 and a(4k+3) = 2*a(2k+1)+5, with a(0)=0, a(1)=2. (End)

A019430 Continued fraction for tan(1/7).

Original entry on oeis.org

0, 6, 1, 19, 1, 33, 1, 47, 1, 61, 1, 75, 1, 89, 1, 103, 1, 117, 1, 131, 1, 145, 1, 159, 1, 173, 1, 187, 1, 201, 1, 215, 1, 229, 1, 243, 1, 257, 1, 271, 1, 285, 1, 299, 1, 313, 1, 327, 1, 341, 1, 355, 1, 369, 1, 383, 1, 397, 1, 411, 1, 425, 1, 439, 1, 453, 1, 467, 1, 481, 1, 495, 1, 509, 1
Offset: 0

Views

Author

Keywords

Examples

			0.14383695943619093528003059... = 0 + 1/(6 + 1/(1 + 1/(19 + 1/(1 + ...)))). - _Harry J. Smith_, Jun 14 2009
		

Crossrefs

Cf. A161016 (decimal expansion), A019425 through A019433.

Programs

  • Magma
    [0, 6] cat [(-1+3*(-1)^n-7*(-1+(-1)^n)*n)/2: n in [2..80]]; // Vincenzo Librandi, Jan 03 2016
  • Mathematica
    Block[{$MaxExtraPrecision=1000},ContinuedFraction[Tan[1/7],80]] (* Harvey P. Dale, Feb 01 2013 *)
    Join[{0, 6}, LinearRecurrence[{0, 2, 0, -1}, {1, 19, 1, 33}, 100]] (* Vincenzo Librandi, Jan 03 2016 *)
  • PARI
    { allocatemem(932245000); default(realprecision, 96000); x=contfrac(tan(1/7)); for (n=0, 20000, write("b019430.txt", n, " ", x[n+1])); } \\ Harry J. Smith, Jun 14 2009
    
  • PARI
    Vec(x*(x^4-x^3+7*x^2+x+6)/((x-1)^2*(x+1)^2) + O(x^100)) \\ Colin Barker, Sep 08 2013
    

Formula

From Colin Barker, Sep 08 2013: (Start)
a(n) = (-1+3*(-1)^n-7*(-1+(-1)^n)*n)/2 for n>1.
a(n) = 2*a(n-2)-a(n-4) for n>5.
G.f.: x*(x^4-x^3+7*x^2+x+6) / ((x-1)^2*(x+1)^2). (End)

A019432 Continued fraction for tan(1/9).

Original entry on oeis.org

0, 8, 1, 25, 1, 43, 1, 61, 1, 79, 1, 97, 1, 115, 1, 133, 1, 151, 1, 169, 1, 187, 1, 205, 1, 223, 1, 241, 1, 259, 1, 277, 1, 295, 1, 313, 1, 331, 1, 349, 1, 367, 1, 385, 1, 403, 1, 421, 1, 439, 1, 457, 1, 475, 1, 493, 1, 511, 1, 529, 1, 547, 1, 565, 1, 583, 1, 601, 1, 619, 1, 637, 1, 655
Offset: 0

Views

Author

Keywords

Comments

The odd-indexed terms from and after a(3) are equal to 18n+7. - Harvey P. Dale, Sep 26 2021

Examples

			0.11157062783380058372650480... = 0 + 1/(8 + 1/(1 + 1/(25 + 1/(1 + ...)))). - _Harry J. Smith_, Jun 14 2009
		

Crossrefs

Cf. A161018 (decimal expansion), A019425 through A019433.

Programs

  • Mathematica
    Block[{$MaxExtraPrecision=1000}, ContinuedFraction[Tan[1/9],100]] (* or *) LinearRecurrence[{0,2,0,-1},{0,8,1,25,1,43},80] (* Harvey P. Dale, Sep 26 2021 *)
  • PARI
    { allocatemem(932245000); default(realprecision, 98000); x=contfrac(tan(1/9)); for (n=0, 20000, write("b019432.txt", n, " ", x[n+1])); } \\ Harry J. Smith, Jun 14 2009
    
  • PARI
    Vec(x*(x^4-x^3+9*x^2+x+8)/((x-1)^2*(x+1)^2) + O(x^100)) \\ Colin Barker, Sep 08 2013

Formula

From Colin Barker, Sep 08 2013: (Start)
a(n) = (-1+3*(-1)^n-9*(-1+(-1)^n)*n)/2 for n>1.
a(n) = 2*a(n-2)-a(n-4) for n>5.
G.f.: x*(x^4-x^3+9*x^2+x+8) / ((x-1)^2*(x+1)^2). (End)

A133265 Diagonal of the A135356 triangle.

Original entry on oeis.org

2, 2, 2, 4, 2, 6, 2, 8, 2, 10, 2, 12, 2, 14, 2, 16, 2, 18, 2, 20, 2, 22, 2, 24, 2, 26, 2, 28, 2, 30, 2, 32, 2, 34, 2, 36, 2, 38, 2, 40, 2, 42, 2, 44, 2, 46, 2, 48, 2, 50, 2, 52, 2, 54, 2, 56, 2, 58, 2, 60, 2, 62, 2, 64, 2, 66, 2, 68, 2, 70, 2, 72, 2, 74, 2, 76, 2, 78, 2, 80
Offset: 0

Views

Author

Paul Curtz, Dec 20 2007

Keywords

Comments

Regular continued fraction expansion of 2*sin(1/2)/( cos(1/2) - sin(1/2) ) = 2.40822 34423 35827 84841 ... = 2 + 1/(2 + 1/(2 + 1/(4 + 1/(2 + 1/(6 + 1/(2 + 1/(8 + 1/(2 + ... )))))))). Cf. A019425. - Peter Bala, Feb 15 2015

Crossrefs

Cf. A019425.

Programs

  • Magma
    [(n+3+(n-1)*(-1)^(n+1))/2: n in [0..80]]; // Vincenzo Librandi, Aug 30 2011
    
  • Maple
    A133265 := n -> (n+2+(n-2)*(-1)^n)/2: # Peter Luschny, Aug 30 2011
  • Mathematica
    Table[(n + 3 + (n - 1) (-1)^(n + 1))/2, {n, 0, 79}] (* or *)
    Table[Mod[(2 n + 5), (n (3 + (-1)^n) - (-1)^n + 7)/2], {n, 0, 79}] (* or *)
    CoefficientList[Series[2 (1 + x - x^2)/((1 - x)^2*(1 + x)^2), {x, 0, 79}], x] (* Michael De Vlieger, Nov 18 2016 *)
  • PARI
    Vec(2*(1 + x - x^2) / ((1 - x)^2 * (1 + x)^2) + O(x^100)) \\ Colin Barker, Nov 17 2016

Formula

2*(A057979 without 1, 0, first two terms).
a(n) = (n+3+(n-1)*(-1)^(n+1))/2. - Vincenzo Librandi, Aug 30 2011
a(n) = (2*n + 5) mod (n*(3 + (-1)^n) - (-1)^n + 7)/2. - Lechoslaw Ratajczak, Nov 17 2016
From Colin Barker, Nov 17 2016: (Start)
a(n) = 2*a(n-2) - a(n-4) for n>3.
G.f.: 2*(1 + x - x^2) / ((1 - x)^2 * (1 + x)^2).
(End)

A161011 Decimal expansion of tan(1/2).

Original entry on oeis.org

5, 4, 6, 3, 0, 2, 4, 8, 9, 8, 4, 3, 7, 9, 0, 5, 1, 3, 2, 5, 5, 1, 7, 9, 4, 6, 5, 7, 8, 0, 2, 8, 5, 3, 8, 3, 2, 9, 7, 5, 5, 1, 7, 2, 0, 1, 7, 9, 7, 9, 1, 2, 4, 6, 1, 6, 4, 0, 9, 1, 3, 8, 5, 9, 3, 2, 9, 0, 7, 5, 1, 0, 5, 1, 8, 0, 2, 5, 8, 1, 5, 7, 1, 5, 1, 8, 0, 6, 4, 8, 2, 7, 0, 6, 5, 6, 2, 1, 8, 5, 8, 9, 1, 0, 4
Offset: 0

Views

Author

Harry J. Smith, Jun 13 2009

Keywords

Comments

By the Lindemann-Weierstrass theorem, this constant is transcendental. - Charles R Greathouse IV, May 13 2019

Examples

			0.546302489843790513255179465780285383297551720179791246164091385932907...
		

Crossrefs

Cf. A019425 (continued fraction). Cf. A049471, A161011 through A161019.

Programs

  • Mathematica
    RealDigits[N[Tan[1/2],6! ]][[1]] (* Vladimir Joseph Stephan Orlovsky, Jun 13 2009 *)
  • PARI
    default(realprecision, 20080); x=10*tan(1/2); for (n=0, 20000, d=floor(x); x=(x-d)*10; write("b161011.txt", n, " ", d));

Formula

From Peter Bala, Nov 17 2019: (Start)
Related simple continued fraction expansions:
tan(1/2) = [0; 1, 1, 4, 1, 8, 1, 12, 1, 16, 1, 20, 1, ...]. See A019425.
2*tan(1/2) = [1, 10, 1, 3, 1, 26, 1, 7, 1, 42, 1, 11, 1, 58, 1, 15, 1, 74, 1, 19, 1, 90, ...]
(1/2)*tan(1/2) = [0; 3, 1, 1, 1, 18, 1, 5, 1, 34, 1, 9, 1, 50, 1, 13, 1, 66, 1, 17, 1, 82, ...].
tan(1/2)/(1 - tan(1/2)) = [1, 4, 1, 8, 1, 12, 1, 16, 1, 20, 1, 24, ...]
2*tan(1/2)/(1 - tan(1/2)) = [2, 2, 2, 4, 2, 6, 2, 8, 2, 10, 2, 12, ...]
4*tan(1/2)/(1 - tan(1/2)) = [4, 1, 4, 2, 4, 3, 4, 4, 4, 5, 4, 6, 4, 7, ...]. (End)

A019428 Continued fraction for tan(1/5).

Original entry on oeis.org

0, 4, 1, 13, 1, 23, 1, 33, 1, 43, 1, 53, 1, 63, 1, 73, 1, 83, 1, 93, 1, 103, 1, 113, 1, 123, 1, 133, 1, 143, 1, 153, 1, 163, 1, 173, 1, 183, 1, 193, 1, 203, 1, 213, 1, 223, 1, 233, 1, 243, 1, 253, 1, 263, 1, 273, 1, 283, 1, 293, 1, 303, 1, 313, 1, 323, 1, 333, 1, 343, 1, 353, 1, 363, 1
Offset: 0

Views

Author

Keywords

Comments

The simple continued fraction expansion of 5*tan(1/5) begins [1; 73, 1, 3, 1, 173, 1, 7, 1, 273, 1, 11, 1, 373, 1, 15, 1, 473, 1, 19, 1, 573, ...], while the simple continued fraction expansion of (1/5)*tan(1/5) begins [0; 24, 1, 1, 1, 123, 1, 5, 1, 223, 1, 9, 1, 323, 1, 13, 1, 423, 1, 17, 1, 523, ...]. See my comment in A019425. - Peter Bala, Sep 30 2023

Examples

			0.20271003550867248332135827... = 0 + 1/(4 + 1/(1 + 1/(13 + 1/(1 + ...)))). - _Harry J. Smith_, Jun 13 2009
		

Crossrefs

Cf. A161014 (decimal expansion), A019425 through A019433.

Programs

  • Magma
    [0,4] cat [(-1+3*(-1)^n-5*(-1+(-1)^n)*n)/2: n in [2..80]]; // Vincenzo Librandi, Jan 03 2016
  • Mathematica
     Join[{0, 4}, LinearRecurrence[{0, 2, 0, -1}, {1, 13, 1, 23}, 100]] (* Vincenzo Librandi, Jan 03 2016 *)
  • PARI
    { allocatemem(932245000); default(realprecision, 93000); x=contfrac(tan(1/5)); for (n=0, 20000, write("b019428.txt", n, " ", x[n+1])); } \\ Harry J. Smith, Jun 13 2009
    
  • PARI
    Vec(x*(x^4-x^3+5*x^2+x+4)/((x-1)^2*(x+1)^2) + O(x^100)) \\ Colin Barker, Sep 08 2013
    

Formula

From Colin Barker, Sep 08 2013: (Start)
a(n) = (-1 + 3*(-1)^n - 5*(-1 + (-1)^n)*n)/2 for n > 1.
a(n) = 2*a(n-2) - a(n-4) for n > 5.
G.f.: x*(x^4-x^3+5*x^2+x+4) / ((x-1)^2*(x+1)^2). (End)

A019431 Continued fraction for tan(1/8).

Original entry on oeis.org

0, 7, 1, 22, 1, 38, 1, 54, 1, 70, 1, 86, 1, 102, 1, 118, 1, 134, 1, 150, 1, 166, 1, 182, 1, 198, 1, 214, 1, 230, 1, 246, 1, 262, 1, 278, 1, 294, 1, 310, 1, 326, 1, 342, 1, 358, 1, 374, 1, 390, 1, 406, 1, 422, 1, 438, 1, 454, 1, 470, 1, 486, 1, 502, 1, 518, 1, 534, 1, 550, 1, 566, 1, 582
Offset: 0

Views

Author

Keywords

Examples

			0.12565513657513096779267821... = 0 + 1/(7 + 1/(1 + 1/(22 + 1/(1 + ...)))). - _Harry J. Smith_, Jun 14 2009
		

Crossrefs

Cf. A161017 (decimal expansion), A019425 through A019433.

Programs

  • Magma
    [0,7] cat [(-1+3*(-1)^n-8*(-1+(-1)^n)*n)/2: n in [2..80]]; // Vincenzo Librandi, Jan 03 2016
  • Mathematica
    Join[{0, 7}, LinearRecurrence[{0, 2, 0, -1}, {1, 22, 1, 38}, 100]] (* Vincenzo Librandi, Jan 03 2016 *)
    Block[{$MaxExtraPrecision=1000}, ContinuedFraction[Tan[1/8],100]] (* Harvey P. Dale, Jul 14 2025 *)
  • PARI
    { allocatemem(932245000); default(realprecision, 97000); x=contfrac(tan(1/8)); for (n=0, 20000, write("b019431.txt", n, " ", x[n+1])); } \\ Harry J. Smith, Jun 14 2009
    
  • PARI
    Vec(x*(x^4-x^3+8*x^2+x+7)/((x-1)^2*(x+1)^2) + O(x^100)) \\ Colin Barker, Sep 08 2013
    

Formula

From Colin Barker, Sep 08 2013: (Start)
a(n) = (-1+3*(-1)^n-8*(-1+(-1)^n)*n)/2 for n>1.
a(n) = 2*a(n-2)-a(n-4) for n>5.
G.f.: x*(x^4-x^3+8*x^2+x+7) / ((x-1)^2*(x+1)^2). (End)

A265722 Number of ON (black) cells in the n-th iteration of the "Rule 1" elementary cellular automaton starting with a single ON (black) cell.

Original entry on oeis.org

1, 0, 1, 4, 1, 8, 1, 12, 1, 16, 1, 20, 1, 24, 1, 28, 1, 32, 1, 36, 1, 40, 1, 44, 1, 48, 1, 52, 1, 56, 1, 60, 1, 64, 1, 68, 1, 72, 1, 76, 1, 80, 1, 84, 1, 88, 1, 92, 1, 96, 1, 100, 1, 104, 1, 108, 1, 112, 1, 116, 1, 120, 1, 124, 1, 128, 1, 132, 1, 136, 1, 140
Offset: 0

Views

Author

Robert Price, Dec 14 2015

Keywords

Examples

			From _Michael De Vlieger_, Dec 14 2015: (Start)
First 12 rows, replacing zeros with "." for better visibility of ON cells, followed by the total number of 1's per row at right:
                      1                        =   1
                    . . .                      =   0
                  . . 1 . .                    =   1
                1 1 . . . 1 1                  =   4
              . . . . 1 . . . .                =   1
            1 1 1 1 . . . 1 1 1 1              =   8
          . . . . . . 1 . . . . . .            =   1
        1 1 1 1 1 1 . . . 1 1 1 1 1 1          =  12
      . . . . . . . . 1 . . . . . . . .        =   1
    1 1 1 1 1 1 1 1 . . . 1 1 1 1 1 1 1 1      =  16
  . . . . . . . . . . 1 . . . . . . . . . .    =   1
1 1 1 1 1 1 1 1 1 1 . . . 1 1 1 1 1 1 1 1 1 1  =  20
(End)
		

References

  • S. Wolfram, A New Kind of Science, Wolfram Media, 2002; p. 55.

Crossrefs

Programs

  • Mathematica
    rule = 1; rows = 30; Table[Total[Table[Take[CellularAutomaton[rule, {{1},0},rows-1,{All,All}][[k]], {rows-k+1, rows+k-1}], {k,1,rows}][[k]]], {k,1,rows}]

Formula

Conjectures from Colin Barker, Dec 14 2015 and Apr 16 2019: (Start)
a(n) = 1/2*(-2*(-1)^n*n+2*n+3*(-1)^n-1).
a(n) = 2*a(n-2) - a(n-4) for n>3.
G.f.: (1-x^2+4*x^3) / ((1-x)^2*(1+x)^2).
(End)
a(n) = A019425(n), n>1. - R. J. Mathar, Jan 10 2016

A158496 Expansion of (1-4x+x^2)/(1+x^2)^2.

Original entry on oeis.org

1, -4, -1, 8, 1, -12, -1, 16, 1, -20, -1, 24, 1, -28, -1, 32, 1, -36, -1, 40, 1, -44, -1, 48, 1, -52, -1, 56, 1, -60, -1, 64, 1, -68, -1, 72, 1, -76, -1, 80, 1, -84, -1, 88, 1, -92, -1, 96, 1, -100, -1, 104, 1, -108, -1, 112, 1, -116, -1, 120, 1, -124, -1, 128, 1, -132, -1
Offset: 0

Views

Author

Paul Barry, Mar 20 2009

Keywords

Comments

Hankel transform of A158495.

Crossrefs

Cf. A019425.

Programs

  • Mathematica
    CoefficientList[Series[(1-4x+x^2)/(1+x^2)^2,{x,0,70}],x] (* or *) LinearRecurrence[{0,-2,0,-1},{1,-4,-1,8},70] (* Harvey P. Dale, Mar 06 2012 *)
  • PARI
    Vec((1-4*x+x^2)/(1+x^2)^2 + O(x^100)) \\ Altug Alkan, Jan 10 2016

Formula

a(n) = (n+3/2-(n+1/2)*(-1)^n)*(-1)^C(n+1,2).
a(0)=1, a(1)=-4, a(2)=-1, a(3)=8, a(n) = -2*a(n-2)-a(n-4). - Harvey P. Dale, Mar 06 2012
Showing 1-10 of 10 results.