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.

Previous Showing 31-40 of 135 results. Next

A091449 Array T(n,k) read by antidiagonals, where row n is the increasing sequence of numbers m for which the simple continued fraction of sqrt(m) has period n, n >= 0, k >= 1.

Original entry on oeis.org

1, 2, 4, 3, 5, 9, 41, 6, 10, 16, 7, 130, 8, 17, 25, 13, 14, 269, 11, 26, 36, 19, 29, 23, 370, 12, 37, 49, 58, 21, 53, 28, 458, 15, 50, 64, 31, 73, 22, 74, 32, 697, 18, 65, 81, 106, 44, 202, 45, 85, 33, 986, 20, 82, 100, 43, 113, 69, 250, 52, 89, 34, 1313, 24, 101, 121
Offset: 0

Views

Author

Clark Kimberling, Feb 03 2004

Keywords

Comments

A permutation of the positive integers.

Examples

			Array begins:
  n\k|   1   2   3   4   5   6   7    8    9   10   11
  ---+------------------------------------------------
   0 |   1   4   9  16  25  36  49   64   81  100  121
   1 |   2   5  10  17  26  37  50   65   82  101  122
   2 |   3   6   8  11  12  15  18   20   24   27   30
   3 |  41 130 269 370 458 697 986 1313 1325 1613 1714
   4 |   7  14  23  28  32  33  34   47   55   60   62
   5 |  13  29  53  74  85  89 125  173  185  218  229
   6 |  19  21  22  45  52  54  57   59   70   77   88
   7 |  58  73 202 250 274 314 349  425  538  761 1010
   8 |  31  44  69  71  91  92 108  135  153  158  160
   9 | 106 113 137 149 265 389 493  610  698  754  970
  10 |  43  67  86  93 115 116 118  129  154  159  161
The least n for which CF(sqrt(n)) has period of length 4 is n=7, with CF=[2;1,1,1,4,1,1,1,4,1,1,1,4,...]; thus T(4,1)=7.
[The array T(n,k) is indexed by n=0,1,2,3,..., k=1,2,3... .]
Row 0 consists of squares: 1,4,9,...
		

Crossrefs

Rows 0-100 are: A000290 (except the initial 0), A002522 (except the initial 1), A013642, A013643, A013644, A010337, A020347, A010338, A020348, A010339, A020349-A020439.

Extensions

a(17) = T(3,3) corrected by Pontus von Brömssen, Nov 23 2024

A091451 Array T(n,k) read by antidiagonals: (row 0)=squares, (row 1)={numbers m for which the simple continued fraction (CF) of sqrt(m) has period length 1}; once (row n) is defined, let (row n+1) begin with the least positive integer not already in a row and let the rest of (row n+1) be the other m's for which CF(sqrt(m)) has the same period length.

Original entry on oeis.org

1, 2, 4, 3, 5, 9, 7, 6, 10, 16, 13, 14, 8, 17, 25, 19, 29, 23, 11, 26, 36, 31, 21, 53, 28, 12, 37, 49, 41, 44, 22, 74, 32, 15, 50, 64, 43, 130, 69, 45, 85, 33, 18, 65, 81, 46, 67, 269, 71, 52, 89, 34, 20, 82, 100, 58, 76, 86, 370, 91, 54, 125, 47, 24, 101, 121
Offset: 0

Views

Author

Clark Kimberling, Feb 03 2004

Keywords

Comments

A permutation of the positive integers.
From Pontus von Brömssen, Nov 23 2024: (Start)
Rows of A091449 sorted by the first term.
First column gives indices of new terms of A003285.
(End)

Examples

			7 is the least positive integer not in rows 0,1,2, so 7=T(3,0); the period length of sqrt(7) is 4, as is the case with T(3,1)=14, T(3,2)=23, etc.
Corner:
  1    4    9    16    25    36   49   64
  2    5   10    17    26    37   50   65
  3    6    8    11    12    15   18   20
  7   14   23    28    32    33   34   47
 13   29   53    74    85    89  125  173
 19   21   22    45    52    54   57   59
		

Crossrefs

Programs

  • Mathematica
    Map[Map[#[[1]] &, #] &,
     GatherBy[Map[{#, Flatten[ContinuedFraction[Sqrt[#]]]} &, Range[500]],
       Length[#[[2]]] &]]  (* Peter J. C. Moses, May 11 2023 *)

Extensions

a(47) = T(7,2) corrected by Clark Kimberling, May 20 2023
More terms from Pontus von Brömssen, Nov 23 2024

A096495 Number of distinct terms in the periodic part of the continued fraction for sqrt(prime(n)).

Original entry on oeis.org

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

Views

Author

Labos Elemer, Jun 29 2004

Keywords

Examples

			n = 31: prime(31) = 127, and the periodic part is {3,1,2,2,7,11,7,2,2,1,3,22}, so a(31) = 6.
		

Crossrefs

Programs

  • Mathematica
    {te=Table[0, {m}], u=1}; Do[s=Length[Union[Last[ContinuedFraction[Prime[n]^(1/2)]]]]; te[[u]]=s;u=u+1, {n, 1, m}];te
    Table[Length[Union[ContinuedFraction[Sqrt[Prime[n]]][[2]]]],{n,110}] (* Harvey P. Dale, Jun 22 2017 *)

Formula

a(n) = A028832(A000040(n)). - Amiram Eldar, Nov 10 2021

A096496 Number of distinct primes in the periodic part of the continued fraction for sqrt(prime(n)).

Original entry on oeis.org

1, 1, 0, 0, 1, 0, 0, 2, 1, 1, 2, 0, 1, 2, 1, 1, 2, 2, 3, 2, 1, 1, 0, 2, 1, 0, 1, 1, 2, 1, 4, 2, 1, 4, 2, 4, 3, 4, 1, 0, 4, 1, 3, 2, 0, 3, 4, 1, 0, 1, 1, 2, 2, 2, 0, 0, 1, 1, 3, 1, 1, 0, 4, 3, 3, 1, 5, 3, 2, 2, 2, 1, 3, 2, 4, 2, 1, 2, 0, 3, 4, 5, 5, 3, 1, 0, 3, 4, 1, 4, 1, 3, 3, 2, 1, 1, 2, 2, 2, 4, 4, 0, 2, 3, 4
Offset: 1

Views

Author

Labos Elemer, Jun 29 2004

Keywords

Examples

			n=31: prime(31) = 127, and the periodic part of the continued fraction of sqrt(127) is {3,1,2,2,7,11,7,2,2,1,3,22}, so a(31) = 4.
		

Crossrefs

Programs

  • Mathematica
    {te=Table[0, {m}], u=1}; Do[s=Count[PrimeQ[Union[Last[ContinuedFraction[f[n]^(1/2)]]]], True]; te[[u]]=s;u=u+1, {n, 1, m}];te
    Count[Union[ContinuedFraction[Sqrt[#]][[2]]],?PrimeQ]&/@Prime[ Range[ 110]] (* _Harvey P. Dale, Apr 27 2016 *)

A130272 Primes p for which the period of the continued fraction of sqrt(p) increases.

Original entry on oeis.org

2, 3, 7, 13, 19, 31, 43, 61, 103, 109, 139, 151, 181, 211, 331, 421, 541, 571, 631, 751, 919, 1291, 1381, 1549, 1579, 1621, 1759, 1831, 2011, 2311, 2671, 3019, 3469, 3691, 3931, 4909, 4951, 4999, 5119, 6211, 6451, 6679, 8269, 8719, 8779, 8941, 9739, 9949
Offset: 1

Views

Author

T. D. Noe, May 19 2007

Keywords

Crossrefs

Programs

  • Mathematica
    mx=0; n=0; t=Table[n++; While[p=Prime[n]; len=Length[Last[ContinuedFraction[Sqrt[p]]]]; len<=mx, n++ ]; mx=len; p, {50}]

Formula

Where records occur in A054269.

A288186 Numbers k such that the continued fractions for sqrt(k) and sqrt(k+1) have the same period.

Original entry on oeis.org

11, 21, 32, 33, 38, 39, 78, 83, 91, 95, 104, 111, 115, 140, 141, 146, 147, 161, 164, 204, 205, 206, 219, 222, 227, 230, 242, 245, 299, 310, 320, 321, 326, 327, 340, 344, 371, 383, 395, 404, 413, 428, 434, 438, 443, 447, 451, 452, 464, 471, 498, 504, 515, 539, 545, 572, 573, 578, 579, 594, 596, 644, 654, 659, 695
Offset: 1

Views

Author

Ilya Gutkovskiy, Jun 06 2017

Keywords

Comments

Numbers k such that A003285(k) = A003285(k+1).

Examples

			11 is in the sequence because sqrt(11) = 3 + 1/(3 + 1/(6 + 1/(3 + 1/(6 + 1/...)))), period 2: [3, 6] and sqrt(12) = 3 + 1/(2 + 1/(6 + 1/(2 + 1/(6 + 1/...)))), period  2: [2, 6].
		

Crossrefs

A020406 Numbers k such that the continued fraction for sqrt(k) has period 67.

Original entry on oeis.org

1381, 1789, 2521, 3754, 3994, 5953, 6389, 7349, 7765, 7801, 8297, 8842, 9274, 10253, 12413, 14458, 15349, 15749, 16073, 16229, 19073, 21485, 22433, 24106, 24317, 24506, 24538, 24929, 25577, 25706, 26170, 26773, 26954, 28018, 28345, 30197, 32218, 32290
Offset: 1

Views

Author

Keywords

Crossrefs

Cf. A003285.

Programs

  • Mathematica
    cf67Q[n_]:=Module[{s=Sqrt[n]},If[IntegerQ[s],1,Length[ ContinuedFraction[ s][[2]]]]==67]; Select[Range[33000],cf67Q] (* Harvey P. Dale, Sep 21 2018 *)

A020640 Successive record periods of continued fraction for sqrt(k) (period of continued fraction for sqrt(A013645(n+1))).

Original entry on oeis.org

1, 2, 4, 5, 6, 8, 10, 12, 16, 18, 20, 22, 26, 34, 37, 40, 42, 44, 48, 52, 54, 60, 62, 64, 70, 76, 79, 88, 94, 96, 102, 104, 108, 114, 118, 122, 130, 136, 152, 156, 158, 170, 172, 174, 194, 196, 202, 207, 210, 217, 228, 234, 238, 239, 248, 262, 268, 280, 281
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    per[n_] := ContinuedFraction[Sqrt[n]][[2]] // Length; record = 0; t = Reap[For[n = 1, n < 2*10^4, n++, If[ !IntegerQ[Sqrt[n]], p = per[n]; If[p > record, record = p; Print[{n, p}]; Sow[{n, p}]]]]][[2, 1]]; A020640 = t[[All, 2]] (* Jean-François Alcover, Dec 27 2012 *)
    DeleteDuplicates[Table[If[IntegerQ[Sqrt[n]],Nothing,Length[ContinuedFraction[Sqrt[n]][[2]]]],{n,20000}],GreaterEqual] (* Harvey P. Dale, Dec 28 2023 *)

Formula

a(n) = A003285(A013645(n+1)). - Pontus von Brömssen, Nov 24 2024

A059904 Periodic part of continued fraction for sqrt(n), encoded by recursively interleaving the bits in the binary expansions of the repeating terms.

Original entry on oeis.org

0, 4, 33, 0, 16, 516, 549755813899, 513, 0, 20, 549, 548, 604462909948052075708555, 549764202537, 545, 0, 64, 8208, 13479973333575319897333507543509815336818572211270286381289293482126
Offset: 1

Views

Author

Marc LeBrun, Feb 07 2001

Keywords

Comments

Could be made less gigantic by omitting final terms in continued fraction, which are always 2*c0.

Examples

			sqrt(3)=1+[1,2] so a(3) is encoded as:
.....0 0 0 0 1 -> 1
....... 1 . 0 .-> 2
--------------
.....000100001 = 33.
		

Crossrefs

Formula

a(n) = A059884(A059903(n)).

A064025 Length of period of the continued fraction for sqrt(n!).

Original entry on oeis.org

1, 2, 2, 2, 4, 2, 16, 48, 8, 4, 56, 180, 44, 156, 300, 7936, 10388, 11516, 9104, 13469268, 2684084, 2418800, 28468692, 143007944, 85509116, 402570696, 2287868888, 204306960, 48715166536, 147160740856, 317585614148
Offset: 2

Views

Author

Labos Elemer, Sep 18 2001

Keywords

Examples

			Quotients for 10! are [[1904], [1, 15, 1, 13, 1, 15, 1, 3808]], so period length of 10! is 8.
		

Crossrefs

Programs

  • Maple
    with(numtheory): [seq(nops(cfrac(sqrt(k!),'periodic','quotients')[2]),k=2..16)];
  • Mathematica
    Do[ Print[ Length[ Last[ ContinuedFraction[ Sqrt[ n! ]]]]], {n, 2, 24} ]

Formula

a(n) = A003285(A000142(n)). - Michel Marcus, Sep 25 2019

Extensions

More terms from Robert G. Wilson v, Oct 01 2001
a(25)-a(28) from Daniel Suteu, Jan 24 2019
a(29) from Chai Wah Wu, Sep 23 2019
a(30) from Chai Wah Wu, Sep 25 2019
a(31) from Chai Wah Wu, Jan 27 2021
a(32) from Chai Wah Wu, Feb 02 2021
Previous Showing 31-40 of 135 results. Next