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-2 of 2 results.

A179077 a(n) is the residue ((2^p - 2)/p) mod p, where p is the n-th prime.

Original entry on oeis.org

1, 2, 1, 4, 10, 6, 9, 6, 11, 2, 12, 2, 5, 7, 41, 19, 16, 11, 20, 4, 39, 38, 13, 12, 17, 83, 15, 26, 25, 53, 36, 34, 106, 60, 43, 112, 7, 134, 94, 6, 100, 115, 100, 15, 153, 71, 7, 155, 175, 136, 14, 52, 43, 243, 193, 256, 251, 218, 140, 148, 116, 156, 281, 39, 240, 33, 278
Offset: 1

Views

Author

Artur Jasinski, Jun 28 2010

Keywords

Comments

a(n) = 0 where n=183 (p=1093) and n=490 (p=3511).
From Felix Fröhlich, Sep 13 2019: (Start)
Conjecture: a(n) is the residue A036968(p-1) (mod p) for p = prime(n).
If the above conjecture is true, then a(n) = 0 if and only if p is a Wieferich prime (A001220) (cf. Hu et al., 2019, section 1.3). (End)

Crossrefs

Programs

  • Maple
    f:= p -> (2&^p-2 mod p^2)/p:
    seq(f(ithprime(i)),i=1..100);# Robert Israel, Nov 03 2024
  • Mathematica
    aa = {}; Do[AppendTo[aa, Mod[(2^Prime[n] - 2)/Prime[n], Prime[n]]], {n, 1, 100}]; aa
  • PARI
    a(n) = my(p=prime(n)); lift(Mod(((2^p-2)/p), p)) \\ Felix Fröhlich, Sep 13 2019

A377669 a(n) is the least prime p such that (3^p - 3)/p == n (mod p), or -1 if there is no such prime p.

Original entry on oeis.org

11, 2, 3, 5, 7, 23, 43, 5721619, 2311, 105830189, 31300663, 13, 113, 17, 821, 1181, 19, 37
Offset: 0

Views

Author

Robert Israel, Nov 03 2024

Keywords

Comments

For n = 18, 24, 27, 28, 30, 38, ..., a(n) > 6 * 10^9 if it is not -1.
a(18) > 2*10^11 if it is not -1. - Michael S. Branicky, Nov 04 2024

Examples

			a(4) = 7 because (3^7 - 3)/7 = 312 == 4 (mod 7), and 7 is the first prime that works.
		

Crossrefs

Programs

  • Maple
    f:= p -> (3&^p-3 mod p^2)/p:
    V:= Array(0..17): count:= 0:
    p:= 1:
    for i from 1 while count < 23 do
      p:= nextprime(p);
      v:= f(p);
      if v <= 22 and V[v] = 0 then V[v]:= i; count:= count+1 fi;
    od:
    convert(V, list);
  • Mathematica
    lpp[n_]:=Module[{p=2},While[Mod[(3^p-3)/p,p]!=n,p=NextPrime[p]];p]; Array[lpp,17,0] (* Harvey P. Dale, Jun 07 2025 *)

Formula

a(n) = prime(i) where A179078(i) = n, if such i exists.
Showing 1-2 of 2 results.