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 21-30 of 174 results. Next

A128669 Primes p such that p^2 divides 23^(p-1) - 1.

Original entry on oeis.org

13, 2481757, 13703077, 15546404183, 2549536629329
Offset: 1

Views

Author

Alexander Adamchuk, Mar 26 2007

Keywords

Comments

No further terms up to 3.127*10^13.

References

  • Paulo Ribenboim, The Little Book of Bigger Primes, Springer-Verlag NY 2004. See p. 233.

Crossrefs

Programs

  • Mathematica
    Select[Prime[Range[5*10^7]], Mod[ 23^(# - 1) - 1, #^2] == 0 &] (* G. C. Greubel, Jan 18 2018 *)
    Select[Prime[Range[93*10^9]],PowerMod[23,#-1,#^2]==1&] (* Harvey P. Dale, May 15 2018 *)

A258367 a(n) is the smallest A (in absolute value) such that for p = prime(n), 2^{(p-1)/2} == +-1 + A*p (mod p^2), i.e., such that p is a near-Wieferich prime.

Original entry on oeis.org

1, 1, 1, 3, 5, 2, 8, 3, 14, 3, 18, 9, 9, 22, 18, 4, 18, 5, 1, 28, 30, 24, 3, 20, 46, 22, 47, 21, 15, 9, 57, 42, 15, 48, 28, 41, 48, 60, 85, 25, 74, 25, 52, 11, 32, 51, 17, 13, 34, 113, 13, 71, 2, 16, 64, 130, 81, 35, 37, 29, 39, 147, 68, 60, 71, 96, 92, 99, 12
Offset: 2

Views

Author

Felix Fröhlich, May 28 2015

Keywords

Comments

p is in A001220 iff a(n) = 0. This is the case iff A014664(n) = A243905(n), which happens for n = 183 and n = 490.
Is a(n) = 0 for any other n, and, if yes, are there infinitely many such n?

Crossrefs

Programs

  • PARI
    a(n,p=prime(n))=abs(centerlift(Mod(2,p^2)^((p-1)/2))\/p)
    apply(p->a(0,p), primes(100)[2..100]) \\ Charles R Greathouse IV, Jun 15 2015

Formula

a(n) = min(b(n) mod p, -b(n) mod p) where p = prime(n) and b(n) = Sum_{i=1..ceiling((p-1)/4)} (2i-1)^(p-2). - Daniel Chen, Sep 01 2022

A244249 Table A(n,k) in which n-th row lists in increasing order all bases b to which p = prime(n) is a Wieferich prime (i.e., b^(p-1) is congruent to 1 mod p^2), read by antidiagonals.

Original entry on oeis.org

5, 9, 8, 13, 10, 7, 17, 17, 18, 18, 21, 19, 24, 19, 3, 25, 26, 26, 30, 9, 19, 29, 28, 32, 31, 27, 22, 38, 33, 35, 43, 48, 40, 23, 40, 28, 37, 37, 49, 50, 81, 70, 65, 54, 28, 41, 44, 51, 67, 94, 80, 75, 62, 42, 14, 45, 46, 57, 68, 112, 89, 110, 68, 63, 41, 115
Offset: 1

Views

Author

Felix Fröhlich, Jun 23 2014

Keywords

Examples

			Table starts with:
p =  2:   5,  9, 13, 17,  21,  25,  29,  33, ...
p =  3:   8, 10, 17, 19,  26,  28,  35,  37, ...
p =  5:   7, 18, 24, 26,  32,  43,  49,  51, ...
p =  7:  18, 19, 30, 31,  48,  50,  67,  68, ...
p = 11:   3,  9, 27, 40,  81,  94, 112, 118, ...
p = 13:  19, 22, 23, 70,  80,  89,  99, 146, ...
p = 17:  38, 40, 65, 75, 110, 131, 134, 155, ...
		

Crossrefs

First column of table is A039678.
Main diagonal gives A280721.

Programs

  • Maple
    A:= proc(n, k) option remember; local p, b;
          p:= ithprime(n);
          for b from 1 +`if`(k=1, 1, A(n, k-1))
            while b &^ (p-1) mod p^2<>1
          do od; b
        end:
    seq(seq(A(n, 1+d-n), n=1..d), d=1..14);  # Alois P. Heinz, Jul 02 2014
  • Mathematica
    A[n_, k_] := A[n, k] = Module[{p, b}, p = Prime[n]; For[b = 1 + If[k == 1, 1, A[n, k-1]], PowerMod[b, p-1, p^2] != 1, b++]; b]; Table[Table[A[n, 1+d-n], {n, 1, d}], {d, 1, 14}] // Flatten (* Jean-François Alcover, Mar 09 2015, after Alois P. Heinz *)
  • PARI
    forprime(p=2, 10^1, print1("p=", p, ": "); for(a=2, 10^2, if(Mod(a, p^2)^(p-1)==1, print1(a, ", "))); print(""))

A134307 Primes p such that A^(p-1) == 1 (mod p^2) for some A in the range 2 <= A <= p-1.

Original entry on oeis.org

11, 29, 37, 43, 59, 71, 79, 97, 103, 109, 113, 127, 131, 137, 151, 163, 181, 191, 197, 199, 211, 223, 229, 233, 241, 257, 263, 269, 281, 283, 293, 307, 313, 331, 347, 349, 353, 359, 367, 373, 379, 397, 401, 419, 421, 433, 439, 449, 461, 463, 487, 499, 509
Offset: 1

Views

Author

Joerg Arndt, Aug 27 2008

Keywords

Comments

It's worth observing that there are p-1 elements of order dividing p-1 modulo p^2 that are of the form r^(k*p) mod p^2 where r is a primitive element modulo p and k=0,1,...,p-2. Heuristically, one can expect that at least one of them belongs to the interval [2,p-1] with probability about 1 - (1 - 1/p)^(p-1) ~= 1 - 1/e.
Numerically, among the primes below 1000 (out of the total number pi(1000)=168) there are 103 terms of the sequence, and the ratio 103/168 = 0.613 which is already somewhat close to 1-1/e ~= 0.632.
If we replace p^2 with p^3, heuristically it is likely that the sequence is finite (since 1 - (1 - 1/p^2)^(p-1) tends to 0 as p grows). - Max Alekseyev, Jan 09 2009
Replacing p^2 with p^3 gives just the one term (113) for p < 10^6. - Joerg Arndt, Jan 07 2011
If furthermore the number A can be taken to be a primitive root modulo p, i.e., A is a generator of (Z/pZ)*, then that p belongs to A060503. - Jeppe Stig Nielsen, Jul 31 2015
The number of terms not exceeding prime(10^k), for k=1,2,..., are 2, 55, 652, 6303, 63219, ... - Amiram Eldar, May 08 2021

Examples

			Examples (pairs [p, A]):
[11, 3]
[11, 9]
[29, 14]
[37, 18]
[43, 19]
[59, 53]
[71, 11]
[71, 26]
[79, 31]
[97, 53]
		

References

  • L. E. Dickson, History of the theory of numbers, vol. 1, p. 105.

Crossrefs

Programs

  • Mathematica
    Select[ Prime[ Range[100]], Product[ (PowerMod[a, # - 1, #^2] - 1), {a, 2, # - 1}] == 0 &] (* Jonathan Sondow, Feb 11 2013 *)
  • PARI
    { forprime (p=2, 1000,
       for (a=2, p-1, p2 = p^2;
         if( Mod(a, p2)^(p-1) == Mod(1, p2), print1(p, ", ") ;break() );
      ); ); }

A158358 Pseudoprimes to base 2 that are not squarefree, including the even pseudoprimes.

Original entry on oeis.org

1194649, 12327121, 3914864773, 5654273717, 6523978189, 22178658685, 26092328809, 31310555641, 41747009305, 53053167441, 58706246509, 74795779241, 85667085141, 129816911251, 237865367741, 259621495381, 333967711897, 346157884801, 467032496113, 575310702877, 601401837037, 605767053061
Offset: 1

Views

Author

Rick L. Shepherd, Mar 16 2009

Keywords

Comments

Intersection of (A001567 U A006935) and A013929. Also, intersection of A015919 and A013929.
The first six terms are given by Ribenboim, who references calculations by Lehmer and by Pomerance, Selfridge & Wagstaff supporting "that the only possible factors p^2 (where p is a prime less than 6*10^9) of any pseudoprime, must be 1093 or 3511." Ribenboim states that the first four terms are strong pseudoprimes. The first two terms are squares of these Wieferich primes, 1093^2 and 3511^2.
Only Wieferich primes (A001220) can appear with an exponent greater than one. In particular, all members of this sequence are divisible by a square of a Wieferich prime. Up to 67 * 10^14 the only Wieferich primes are 1093 and 3511. - Charles R Greathouse IV, Sep 12 2012
The first term divisible by the squares of two (Wieferich) primes is a(11870) = 4578627124156945861 = 29 * 71 * 151 * 1093^2 * 3511^2. See A219346. - Charles R Greathouse IV, Sep 20 2012
Unless there are other Wieferich primes besides 1093 and 3511, the sequence is the union of A247830 and A247831. - Max Alekseyev, Nov 26 2017
The even terms are listed in A295740. - Max Alekseyev, Nov 26 2017 [Their indices in this sequence are 2882, 3476, 3573, 4692, 5434, 5581, 6332, 8349, 8681, 9515, ... - Jianing Song, Feb 08 2019]

Examples

			a(6) = 22178658685 = 5 * 47 * 79 * 1093^2 is a pseudoprime that is not squarefree.
		

References

  • P. Ribenboim, The Little Book of Big Primes. Springer-Verlag, NY, 1991, pp. 77, 83, 167.

Crossrefs

Programs

  • PARI
    list(lim)=vecsort(concat(concat(apply(p->select(n->Mod(2, n)^(n-1)==1, p^2*vector(lim\p^2\2, i, 2*i-1)), [1093, 3511])), select(n->Mod(2, n)^n==2, 2*3511^2*vector(lim\3511^2\2, i, i))), , 8) \\ valid up to 4.489 * 10^31, Charles R Greathouse IV, Sep 12 2012, changed to include the even terms by Jianing Song, Feb 07 2019

Extensions

More terms from Max Alekseyev, May 09 2010
Name changed by Jianing Song, Feb 07 2019 to include the even pseudoprimes to base 2 (A006935) as was suggested by Max Alekseyev.

A111027 Wieferich primes in base 12.

Original entry on oeis.org

2693, 123653
Offset: 1

Views

Author

Walter Kehowski, Oct 05 2005

Keywords

Comments

I have searched up to the 9 millionth prime, 160481183 and gave up trying to find a third term. The sequence is conjectured to be infinite. If the behavior is similar to base 10, A045616, then the next term could be greater than 2*10^11. In base 12 with X for ten and E for eleven the sequence is [1685, 5E685] so it would be interesting to see if the third term ends in 685 as well. These primes are also the Wieferich numbers in base 12: 12^phi(n) = 1 mod n^2.
Richard Fischer has carried this search to 4.8 * 10^13 (as of January 2014). - John Blythe Dobson, Mar 06 2014

Crossrefs

Programs

  • Maple
    WP:=[]: for z from 1 to 1 do for k from 1 to 9000000 do p:=ithprime(k); if 12 &^(p-1) mod p^2 = 1 then WP:=[op(WP),p]; printf("p=%d, ",p); fi; if k mod 10^5 = 0 then printf("k=%d, ",k); fi; od; od; WP;
  • Mathematica
    Select[Prime[Range[1000000]], PowerMod[12, # - 1, #^2] == 1 &] (* Robert Price, May 17 2019 *)

Formula

12^(p-1) == 1 mod p^2

A126197 GCDs arising in A126196.

Original entry on oeis.org

11, 1093, 1093, 3511, 3511, 5557, 104891, 1006003
Offset: 1

Views

Author

Max Alekseyev and Tanya Khovanova, Mar 07 2007

Keywords

Comments

All terms are primes. Note a connection to the Wieferich primes A001220: a(2) = a(3) = A001220(1), a(3) = a(4) = A001220(2).
From John Blythe Dobson, Jan 14 2017: (Start)
All Wieferich primes p will belong to this sequence twice, because if H([p/k]) denotes the harmonic number with index floor(p/k), then p divides all of H([p/4]), H([p/2]), and H(p-1). The first two of these elements gives one solution, and the second and third another. This property of the Wieferich primes predates their name, and was apparently first proved by Glaisher in "On the residues of r^(p-1) to modulus p^2, p^3, etc.," pp. 21-22, 23 (see References).
Note also a connection to the Mirimanoff primes A014127: a(1) = A014127(1), a(8) = A014127(2). All Mirimanoff primes p will belong to this sequence, because p divides both H([p/3]) and H([2p/3]). This property of the Mirimanoff primes likewise predates their name, and was apparently first proved by Glaisher in "A general congruence theorem relating to the Bernoullian function," p. 50 (see Links).
The Wieferich primes and Mirimanoff primes would seem to be the only cases for which the value of n in A126196(n) is predictable from knowledge of p. It is not obvious that all members of the present sequence are prime; however, by definition all their divisors must be non-harmonic primes A092102. Furthermore, it is clear from the cited literature under that entry that H([n/2]) == H(n) == 0 (mod p) is only possible when n < p. Thus, all divisors of the present sequence must belong to the harmonic irregular primes A092194.
One possible reason for interest in this sequence is a 1995 result of Dilcher and Skula (see Links) which among other things shows that if a prime p were an exception to the first case of Fermat's Last Theorem, then p would divide both H([p/k]) and H([2p/k]) for every value of k from 2 to 46. To date, the only values for which such coincidences have been found have k = 2, 3, or 4. For k = 6 to hold, p would have to be simultaneously a Wieferich prime and a Mirimanoff prime, while for k = 5 to hold, p would have to be simultaneously a Wall-Sun-Sun prime and a member of A123692. The sparse numerical results for the present sequence suggest that even the more relaxed condition H([n/2]) == H(n) == 0 (mod p) is rarely satisfied. (End)

References

  • J. W. L. Glaisher, On the residues of r^(p-1) to modulus p^2, p^3, etc., Quarterly Journal of Pure and Applied Mathematics 32 (1900-1901), 1-27.

Crossrefs

Programs

  • Mathematica
    f[n_] := GCD @@ Numerator@ HarmonicNumber@ {n, Floor[n/2]}; f@ Select[ Range[5000], f[#] > 1 &] (* Giovanni Resta, May 13 2016 *)

Extensions

a(8) from Giovanni Resta, May 13 2016

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
    				

A126196 Numbers k such that gcd(A001008(k), A001008(floor(k/2))) > 1.

Original entry on oeis.org

7, 546, 1092, 1755, 3510, 4896, 52447, 670668
Offset: 1

Views

Author

Max Alekseyev and Tanya Khovanova, Mar 07 2007, corrected Mar 10 2007

Keywords

Comments

Note a connection to the Wieferich primes A001220: a(2) = (A001220(1) - 1)/2, a(3) = A001220(1) - 1, a(4) = (A001220(2) - 1)/2, a(5) = A001220(2) - 1. [Comment regarding a(2) added by Kevin J. Gomez, Jul 11 2017]
a(9) > 840000. - Giovanni Resta, May 13 2016

Crossrefs

The corresponding GCDs are given by A126197.

Programs

  • Mathematica
    Select[Range[5000], GCD @@ Numerator@ HarmonicNumber@{#, Floor[#/2]} > 1 &] (* Giovanni Resta, May 13 2016 *)
  • PARI
    a001008(n)=numerator(sum(i=1, n, 1/i))
    for(n=1, 1e6, if(gcd(a001008(n), a001008(n/2)) > 1, print1(n, ", "))) \\ Felix Fröhlich, Aug 08 2014

Extensions

a(8) from Giovanni Resta, May 13 2016

A196202 a(n) = 2^(prime(n)-1) mod prime(n)^2.

Original entry on oeis.org

2, 4, 16, 15, 56, 40, 222, 58, 392, 30, 187, 38, 944, 1076, 2069, 1909, 473, 2197, 671, 143, 4089, 1502, 3985, 535, 5530, 9293, 6078, 1392, 7304, 9380, 2287, 2228, 7262, 4171, 14305, 8457, 12875, 10922, 7850, 520, 8951, 26789, 9551, 20073, 34476, 26866
Offset: 1

Views

Author

Reinhard Zumkeller, Sep 29 2011

Keywords

Comments

a(A049084(A001220(1))) = a(A049084(A001220(2))) = 1.

Examples

			A001220(1)=1093=A000040(183): a(183)=1, or a(A049084(A001220(1)))=1;
A001220(2)=3511=A000040(490): a(490)=1, or a(A049084(A001220(2)))=1.
		

References

  • N. G. W. H. Beeger, On a new case of the congruence 2^(p-1) ≡ 1 (p^2), Messenger of Mathematics 51, (1922), p. 149-150
  • Paulo Ribenboim, 1093 (Chap 8), in 'My Numbers, My Friends', Springer-Verlag 2000 NY, page 213ff.

Crossrefs

Cf. A061286.

Programs

  • Haskell
    import Math.NumberTheory.Moduli (powerMod)
    a196202 n = powerMod 2 (p - 1) (p ^ 2) where p = a000040 n
    -- Reinhard Zumkeller, May 18 2015
  • Maple
    seq(2 &^ (ithprime(n)-1) mod ithprime(n)^2, n=1..1000); # Robert Israel, Aug 03 2014
  • Mathematica
    PowerMod[2,#-1,#^2]&/@Prime[Range[50]] (* Harvey P. Dale, Apr 25 2012 *)
  • PARI
    forprime(p=2, 1e2, print1(lift(Mod(2, p^2)^(p-1)), ", ")) \\ Felix Fröhlich, Aug 03 2014
    
Previous Showing 21-30 of 174 results. Next