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 14 results. Next

A242830 For p = prime(n), a(n) = number of bases 1 < b < p such that b^(p-1) == 1 (mod p^2).

Original entry on oeis.org

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

Views

Author

Felix Fröhlich, Jul 12 2014

Keywords

Comments

a(n) > 0 if and only if p is in A134307.

Crossrefs

Programs

  • Maple
    A242830:= proc(n) local p;
      p:= ithprime(n);
      numboccur(1,[seq(b &^ (p-1) mod p^2, b=2..p-1)]);
    end proc;
    seq(A242830(n),n=1..1000); # Robert Israel, Jul 16 2014
  • Mathematica
    a[n_] := With[{p = Prime[n]}, Length@Select[Range[2, p-1], PowerMod[#, p-1, p^2] == 1&]];
    Table[a[n], {n, 1, 100}] (* Jean-François Alcover, Jan 27 2023 *)
  • PARI
    i=0; forprime(p=2, 10^3, a=2; while(a
    				

A244752 Square array read by antidiagonals in which rows are indexed by composite numbers w and row w gives n such that n^(w-1) == 1 (mod w^2).

Original entry on oeis.org

17, 33, 37, 49, 73, 65, 65, 109, 129, 80, 81, 145, 193, 82, 101, 97, 181, 257, 161, 201, 145, 113, 217, 321, 163, 301, 289, 197, 129, 253, 385, 242, 401, 433, 393, 26, 145, 289, 449, 244, 501, 577, 589, 199, 257, 161, 325, 513, 323, 601, 721, 785, 224, 513
Offset: 2

Views

Author

Felix Fröhlich, Jul 05 2014

Keywords

Comments

We can say that "w is a Wieferich pseudoprime to base n".
Any prime factor of w is a Wieferich prime to base n.

Examples

			Table starts
w=4: 17, 33, 49, 65, 81, 97, 113, ....
w=6: 37, 73, 109, 145, 181, 217, ....
w=8: 65, 129, 193, 257, 321, 385, ....
w=9: 80, 82, 161, 163, 242, 244, ....
w=10: 101, 201, 301, 401, 501, 601, ....
w=12: 145, 289, 433, 577, 721, 865, ....
w=14: 197, 393, 589, 785, 981, ....
....
		

Crossrefs

Programs

  • Mathematica
    T = {};
    For[w = 4, w <= 100, w++,
      If[PrimeQ[w], Continue[]];
      t = {};
      For [n = 2, n <= 10^5, n++,
       If[Mod[n^(w - 1), w^2] == 1, AppendTo[t, n]]];
      AppendTo[T, t]];
    Print[TableForm[T]];
    A244752 = {};
    For[c = 1, c <= 50, c++,
      For[r = 1, r <= c, r++, AppendTo[A244752, T[[r]][[c - r + 1]]]]];
    A244752 (* Robert Price, Sep 07 2019 *)
  • PARI
    forcomposite(w=2, 20, print1("w=", w, ": "); for(n=2, 10^3, if(Mod(n, w^2)^(w-1)==1, print1(n, ", "))); print(""))

Extensions

a(17)-a(55) from Robert Price, Sep 07 2019

A319059 A(n, k) is the k-th number b > 1 such that b^(prime(n+i)-1) == 1 (mod prime(n+i)^2) for each i = 0..1, with k running over the positive integers; square array, read by antidiagonals, downwards.

Original entry on oeis.org

17, 37, 26, 53, 82, 18, 73, 107, 68, 148, 89, 118, 99, 215, 239, 109, 143, 226, 362, 360, 249, 125, 199, 276, 606, 485, 577, 423, 145, 224, 293, 717, 596, 653, 653, 28, 161, 226, 324, 753, 606, 868, 2098, 784, 63, 181, 251, 374, 766, 699, 1520, 2526, 1921, 571
Offset: 1

Views

Author

Felix Fröhlich, Sep 09 2018

Keywords

Examples

			The array starts as follows:
    17,   37,   53,    73,    89,   109,   125,   145,   161,   181,   197,   217
    26,   82,  107,   118,   143,   199,   224,   226,   251,   307,   332,   343
    18,   68,   99,   226,   276,   293,   324,   374,   393,   557,   607,   618
   148,  215,  362,   606,   717,   753,   766,  1207,  1304,  1322,  1371,  1451
   239,  360,  485,   596,   606,   699,   844,   846,   995,  1330,  1371,  1451
   249,  577,  653,   868,  1520,  1948,  1958,  2098,  2178,  2446,  2536,  2850
   423,  653, 2098,  2526,  2889,  3180,  4270,  4400,  4625,  4755,  5416,  5531
    28,  784, 1921,  2234,  2293,  3004,  4233,  4566,  4631,  4762,  4938,  5353
    63,  571, 1545,  3304,  3585,  3969,  4204,  5420,  6995,  7583,  7765,  7805
   374, 1492, 2509,  3323,  3405,  4472,  5651,  6154,  6492,  7805, 12348, 13040
   117, 1693, 2157,  4431,  4688,  6154,  6728,  6844,  6962,  9089, 11533, 13689
   787, 1368, 3214,  4106,  4895,  5552,  5830,  5900,  8892,  9229, 11389, 14272
  2059, 2152, 5548,  8354, 10557, 14368, 20320, 27657, 29296, 29945, 31434, 31452
  1085, 1771, 2210, 17902, 18793, 19679, 23670, 23676, 24298, 24928, 25885, 31800
   655, 1586, 1914,  3330,  3818,  7772,  8765,  9436,  9459, 12087, 13183, 24501
		

Crossrefs

Cf. A244249, A256236, A259075 (column 1).
Cf. analog for i = 0..t: A319060 (t=2), A319061 (t=3), A319062 (t=4), A319063 (t=5), A319064 (t=6), A319065 (t=7).

Programs

  • Mathematica
    rows = 10; t = 1;
    T = Table[lst = {}; b = 2;
       While[Length[lst] < rows,
        p = Prime[n + Range[0, t]];
        If[AllTrue[PowerMod[b, (p - 1), p^2], # == 1 &], AppendTo[lst, b]]; b++];
       lst, {n, rows}];
    T // TableForm (* Print the A(n,k) table *)
    Flatten[Table[T[[j, i - j + 1]], {i, 1, rows}, {j, 1, i}]] (* Robert Price, Sep 30 2019 *)
  • PARI
    printrow(n, terms) = my(c=0); for(b=2, oo, my(j=0); for(i=0, 1, my(p=prime(n+i)); if(Mod(b, p^2)^(p-1)==1, j++)); if(j==2, print1(b, ", "); c++); if(c==terms, break))
    array(rows, cols) = for(x=1, rows, printrow(x, cols); print(""))
    array(8, 10) \\ print initial 8 rows and 10 columns of array

A319060 A(n, k) is the k-th number b > 1 such that b^(prime(n+i)-1) == 1 (mod prime(n+i)^2) for each i = 0..2, with k running over the positive integers; square array, read by antidiagonals, downwards.

Original entry on oeis.org

449, 557, 226, 593, 557, 1207, 649, 901, 1451, 606, 701, 1126, 2743, 1371, 3469, 757, 1207, 2774, 1451, 5938, 653, 793, 1243, 3657, 1667, 7624, 2098, 5649, 901, 1324, 4232, 2175, 11980, 4755, 10538, 26645, 1349, 1549, 4607, 2774, 12248, 5845, 11137, 35973
Offset: 1

Views

Author

Felix Fröhlich, Sep 09 2018

Keywords

Examples

			The array starts as follows:
    449,   557,    593,    649,    701,    757,    793,    901,   1349,   1457
    226,   557,    901,   1126,   1207,   1243,   1324,   1549,   2224,   2449
   1207,  1451,   2743,   2774,   3657,   4232,   4607,   5176,   6682,   7251
    606,  1371,   1451,   1667,   2175,   2774,   4244,   8201,  13543,  13670
   3469,  5938,   7624,  11980,  12248,  13543,  17554,  20809,  23344,  24675
    653,  2098,   4755,   5845,  24314,  24675,  25876,  30270,  39016,  40133
   5649, 10538,  11137,  18049,  18710,  21426,  23158,  39016,  50902,  55134
  26645, 35973,  44710,  49556,  78991,  85972,  89283, 101540, 131466, 157641
   7805, 41854, 155349, 165407, 190906, 215029, 235210, 245586, 271376, 296832
   6154, 18488,  65788, 104520, 136463, 178863, 263429, 335829, 394854, 399254
		

Crossrefs

Cf. analog for i = 0..t: A319059 (t=1), A319061 (t=3), A319062 (t=4), A319063 (t=5), A319064 (t=6), A319065 (t=7).

Programs

  • Mathematica
    rows = 10; t = 2;
    T = Table[lst = {}; b = 2;
       While[Length[lst] < rows,
         p = Prime[n + Range[0, t]];
        If[AllTrue[PowerMod[b, (p-1), p^2], # == 1 &], AppendTo[lst, b]]; b++];
       lst, {n, rows}];
    T // TableForm (* Print the A(n,k) table *)
    Flatten[Table[T[[j, i - j + 1]], {i, 1, rows}, {j, 1, i}]] (* Robert Price, Sep 30 2019 *)
  • PARI
    printrow(n, terms) = my(c=0); for(b=2, oo, my(j=0); for(i=0, 2, my(p=prime(n+i)); if(Mod(b, p^2)^(p-1)==1, j++)); if(j==3, print1(b, ", "); c++); if(c==terms, break))
    array(rows, cols) = for(x=1, rows, printrow(x, cols); print(""))
    array(8, 10) \\ print initial 8 rows and 10 columns of array

A319061 A(n, k) is the k-th number b > 1 such that b^(prime(n+i)-1) == 1 (mod prime(n+i)^2) for each i = 0..3, with k running over the positive integers; square array, read by antidiagonals, downwards.

Original entry on oeis.org

557, 901, 1207, 1549, 4607, 1451, 2449, 5176, 2774, 13543, 4049, 10124, 8201, 42269, 24675, 5293, 19601, 13543, 91110, 45124, 39016, 5849, 20924, 24482, 91678, 95236, 302947, 217682, 6193, 22049, 30949, 101399, 188872, 387587, 928423, 165407, 7057, 26018
Offset: 1

Views

Author

Felix Fröhlich, Sep 09 2018

Keywords

Examples

			The array starts as follows:
     557,    901,    1549,    2449,    4049,    5293,    5849,    6193
    1207,   4607,    5176,   10124,   19601,   20924,   22049,   26018
    1451,   2774,    8201,   13543,   24482,   30949,   31457,   40199
   13543,  42269,   91110,   91678,  101399,  132576,  142148,  210258
   24675,  45124,   95236,  188872,  236915,  273971,  296449,  298117
   39016, 302947,  387587,  609436,  637111,  962525, 1015033, 1074751
  217682, 928423, 1546225, 1666084, 1756986, 2105290, 2673538, 2733520
  165407, 215029, 1008933, 1370816, 1487743, 1493395, 1624207, 2998943
		

Crossrefs

Cf. analog for i = 0..t: A319059 (t=1), A319060 (t=2), A319062 (t=4), A319063 (t=5), A319064 (t=6), A319065 (t=7).

Programs

  • Mathematica
    rows = 8; t = 3;
    T = Table[lst = {}; b = 2;
       While[Length[lst] < rows,
         p = Prime[n + Range[0, t]];
        If[AllTrue[PowerMod[b,(p-1) p^2], #==1 &], AppendTo[lst, b]]; b++];
       lst, {n, rows}];
    T // TableForm (* Print the A(n,k) table *)
    Flatten[Table[T[[j, i - j + 1]], {i, 1, rows}, {j, 1, i}]] (* Robert Price, Sep 30 2019 *)
  • PARI
    printrow(n, terms) = my(c=0); for(b=2, oo, my(j=0); for(i=0, 3, my(p=prime(n+i)); if(Mod(b, p^2)^(p-1)==1, j++)); if(j==4, print1(b, ", "); c++); if(c==terms, break))
    array(rows, cols) = for(x=1, rows, printrow(x, cols); print(""))
    array(8, 10) \\ print initial 8 rows and 10 columns of array

A319062 A(n, k) is the k-th number b > 1 such that b^(prime(n+i)-1) == 1 (mod prime(n+i)^2) for each i = 0..4, with k running over the positive integers; square array, read by antidiagonals, downwards.

Original entry on oeis.org

19601, 22049, 54568, 48149, 57968, 13543, 52057, 132857, 101399, 296449, 67357, 171793, 132576, 298117, 3414284, 84457, 223568, 296449, 380827, 4029059, 14380864, 85193, 261593, 338168, 1096112, 7040291, 14461231, 3727271, 93493, 282907, 1098599, 1761679
Offset: 1

Views

Author

Felix Fröhlich, Sep 09 2018

Keywords

Examples

			The array starts as follows:
     19601,    22049,    48149,    52057,    67357,    84457,    85193
     54568,    57968,   132857,   171793,   223568,   261593,   282907
     13543,   101399,   132576,   296449,   338168,  1098599,  1244324
    296449,   298117,   380827,  1096112,  1761679,  2498247,  2500716
   3414284,  4029059,  7040291, 10858059, 12249190, 17134811, 19603812
  14380864, 14461231, 18366174, 22811283, 26295533, 33674748, 34998229
   3727271, 27936608, 29998045, 31239565, 34998229, 45331852, 56029298
		

Crossrefs

Cf. analog for i = 0..t: A319059 (t=1), A319060 (t=2), A319061 (t=3), A319063 (t=5), A319064 (t=6), A319065 (t=7).

Programs

  • Mathematica
    rows = 7; t = 4;
    T = Table[lst = {}; b = 2;
       While[Length[lst] < rows,
         p = Prime[n + Range[0, t]];
        If[AllTrue[PowerMod[b, (p - 1), p^2], # == 1 &],
         AppendTo[lst, b]]; b++];
       lst, {n, rows}];
    T // TableForm (* Print the A(n,k) table *)
    Flatten[Table[T[[j, i - j + 1]], {i, 1, rows}, {j, 1, i}]] (* Robert Price, Sep 30 2019 *)
  • PARI
    printrow(n, terms) = my(c=0); for(b=2, oo, my(j=0); for(i=0, 4, my(p=prime(n+i)); if(Mod(b, p^2)^(p-1)==1, j++)); if(j==5, print1(b, ", "); c++); if(c==terms, break))
    array(rows, cols) = for(x=1, rows, printrow(x, cols); print(""))
    array(8, 10) \\ print initial 8 rows and 10 columns of array

A319063 A(n, k) is the k-th number b > 1 such that b^(prime(n+i)-1) == 1 (mod prime(n+i)^2) for each i = 0..5, with k running over the positive integers; square array, read by antidiagonals, downwards.

Original entry on oeis.org

132857, 171793, 2006776, 261593, 3091832, 296449, 618301, 3420818, 9654224, 17134811, 700993, 3524932, 11002557, 23250274, 36763941, 997757, 4108582, 16616568, 26073470, 195603158, 34998229, 1211201, 4349699, 20512643, 26646377, 307849316, 71724464
Offset: 1

Views

Author

Felix Fröhlich, Sep 09 2018

Keywords

Examples

			The array starts as follows:
    132857,    171793,    261593,    618301,    700993,    997757,   1211201
   2006776,   3091832,   3420818,   3524932,   4108582,   4349699,   4416499
    296449,   9654224,  11002557,  16616568,  20512643,  20950343,  21184318
  17134811,  23250274,  26073470,  26646377,  44247410,  49287925,  49975689
  36763941, 195603158, 307849316, 364769263, 366974980, 395009864, 428594624
  34998229,  71724464, 124024853, 279238292, 709701384, 710808570
		

Crossrefs

Cf. analog for i = 0..t: A319059 (t=1), A319060 (t=2), A319061 (t=3), A319062 (t=4), A319064 (t=6), A319065 (t=7).

Programs

  • Mathematica
    rows = 6; t = 5;
    T = Table[lst = {}; b = 2;
       While[Length[lst] < rows,
         p = Prime[n + Range[0, t]];
        If[AllTrue[PowerMod[b, (p - 1), p^2], # == 1 &],
         AppendTo[lst, b]]; b++];
       lst, {n, rows}];
    T // TableForm (* Print the A(n,k) table *)
    Flatten[Table[T[[j, i - j + 1]], {i, 1, rows}, {j, 1, i}]] (* Robert Price, Oct 01 2019 *)
  • PARI
    printrow(n, terms) = my(c=0); for(b=2, oo, my(j=0); for(i=0, 5, my(p=prime(n+i)); if(Mod(b, p^2)^(p-1)==1, j++)); if(j==6, print1(b, ", "); c++); if(c==terms, break))
    array(rows, cols) = for(x=1, rows, printrow(x, cols); print(""))
    array(8, 8) \\ print initial 8 rows and 8 columns of array

A319064 A(n, k) is the k-th number b > 1 such that b^(prime(n+i)-1) == 1 (mod prime(n+i)^2) for each i = 0..6, with k running over the positive integers; square array, read by antidiagonals, downwards.

Original entry on oeis.org

4486949, 4651993, 20950343, 4941649, 21184318, 23250274, 5571593, 33538051, 163075007, 741652533, 11903257, 78868324, 189850207, 882345432, 710808570, 19397501, 86892632, 230695118, 1528112512, 5126829291, 2380570527, 19841257, 111899224, 421883318, 1701241810
Offset: 1

Views

Author

Felix Fröhlich, Sep 11 2018

Keywords

Examples

			The array starts as follows:
    4486949,    4651993,    4941649,    5571593,   11903257,   19397501,   19841257
   20950343,   21184318,   33538051,   78868324,   86892632,  111899224,  126664001
   23250274,  163075007,  189850207,  230695118,  421883318,  422771099,  497941351
  741652533,  882345432, 1528112512, 1701241810, 1986592318, 2005090271, 2596285385
  710808570, 5126829291
  2380570527
		

Crossrefs

Cf. analog for i = 0..t: A319059 (t=1), A319060 (t=2), A319061 (t=3), A319062 (t=4), A319063 (t=5), A319065 (t=7).

Programs

  • Mathematica
    rows = 6; t = 6;T = Table[lst = {}; b = 2;
       While[Length[lst] < rows - n + 1,
         p = Prime[n + Range[0, t]];
        If[AllTrue[PowerMod[b, (p - 1), p^2], # == 1 &],
         AppendTo[lst, b]]; b++];
       lst, {n, rows}];
    T // TableForm (* Print the A(n,k) table *)
    Flatten[Table[T[[j, i - j + 1]], {i, 1, rows}, {j, 1, i}]] (* Robert Price, Oct 03 2019 *)
  • PARI
    printrow(n, terms) = my(c=0); for(b=2, oo, my(j=0); for(i=0, 6, my(p=prime(n+i)); if(Mod(b, p^2)^(p-1)==1, j++)); if(j==7, print1(b, ", "); c++); if(c==terms, break))
    array(rows, cols) = for(x=1, rows, printrow(x, cols); print(""))
    array(5, 7) \\ print initial 5 rows and 7 columns of array

A319065 A(n, k) is the k-th number b > 1 such that b^(prime(n+i)-1) == 1 (mod prime(n+i)^2) for each i = 0..7, with k running over the positive integers; square array, read by antidiagonals, downwards.

Original entry on oeis.org

126664001, 133487693, 230695118, 141313157, 633266299, 882345432, 236176001, 1221760151, 1986592318, 12106746963, 242883757, 1575527851, 2715632968, 12709975396, 93732236423, 356977349, 1881738424, 3726163057, 38456038702, 122728381675, 66888229817
Offset: 1

Views

Author

Felix Fröhlich, Sep 12 2018

Keywords

Examples

			The array starts as follows:
   126664001,    133487693,    141313157,   236176001,  242883757,  356977349, 358254649
  230695118,    633266299,   1221760151,  1575527851, 1881738424, 2118321224
  882345432,   1986592318,   2715632968,  3726163057, 5229752849
12106746963,  12709975396,  38456038702, 66479920578
93732236423, 122728381675, 143904477566
66888229817,  79246182226
84391291750
		

Crossrefs

Cf. analog for i = 0..t: A319059 (t=1), A319060 (t=2), A319061 (t=3), A319062 (t=4), A319063 (t=5), A319064 (t=6).

Programs

  • Mathematica
    rows = 7; t = 7;
    T = Table[lst = {}; b = 2;
       While[Length[lst] < rows - n + 1,
        fnd = True;
        For[i = 0, i <= t, i++,
         p = Prime[n + i];
         If[PowerMod[b, (p - 1), p^2] != 1 , fnd = False;  Break[]]];
        If[fnd, AppendTo[lst, b]]; b++];
       lst, {n, rows}];
    T // TableForm (* Print the A(n,k) table *)
    Flatten[Table[T[[j, i - j + 1]], {i, 1, rows}, {j, 1, i}]] (* Robert Price, Oct 07 2019 *)
  • PARI
    printrow(n, terms) = my(c=0); for(b=2, oo, my(j=0); for(i=0, 7, my(p=prime(n+i)); if(Mod(b, p^2)^(p-1)==1, j++)); if(j==8, print1(b, ", "); c++); if(c==terms, break))
    array(rows, cols) = for(x=1, rows, printrow(x, cols); print(""))
    array(3, 3) \\ print initial 3 rows and 3 columns of array

Extensions

a(7)-a(21) from Robert Price, Oct 07 2019

A249162 Square array A(p, b) read by antidiagonals in which rows are indexed by successive prime numbers p_i and row b(p_i) gives the smallest prime base b_n to which q = (p_i, b_(n-1)) is a Wieferich prime.

Original entry on oeis.org

2, 5, 3, 7, 17, 5, 19, 131, 7, 7, 127, 659, 19, 19, 11, 911, 503, 127, 127, 3, 13, 7331, 9833, 911, 911, 17, 19, 17, 167149, 49603, 7331, 7331, 131, 127, 131, 19, 387749, 327317, 167149, 167149, 659, 911, 659, 127, 23, 17153317, 13900147, 387749, 387749, 503
Offset: 1

Views

Author

Felix Fröhlich, Oct 22 2014

Keywords

Examples

			A(6,4) = 911, since the 6th prime is 13 and the smallest prime Wieferich base for 13 is 19. Applying this procedure recursively to the resulting bases a total of b-1 = 3 times leads to 911.
Array starts:
  2    5    7   19    127    911     7331   167149    387749  17153317 ...
  3   17  131  659    503   9833    49603   327317  13900147 144229223 ...
  5    7   19  127    911   7331   167149   387749  17153317       ...
  7   19  127  911   7331 167149   387749 17153317 432383657       ...
  11   3   17  131    659    503     9833    49603    327317       ...
  13  19  127  911   7331 167149   387749      ...
  17 131  659  503   9833  49603   327317      ...
  19 127  911 7331 167149 387749 17153317      ...
  23 263   79   31    229    503      ...
  29  41  313 1499    941  12011      ...
  ...
		

Crossrefs

Second column of table is A125636.

Programs

  • PARI
    forprime(p=1, 30, b=1; i=0; q=p; print1(p, ", "); while(i < 6, b++; if(Mod(b, q^2)^(q-1)==1 && isprime(b), print1(b, ", "); q=b; b=1; i++)); print(""))
Showing 1-10 of 14 results. Next