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.

A319484 a(n) is the smallest k > 1 such that n^k == n (mod k) and gcd(k, b^k-b) = 1 for some b <> n.

Original entry on oeis.org

35, 35, 7957, 16531, 1247, 4495, 35, 817, 2501, 697, 55, 55, 143, 221, 35, 35, 1247, 493, 221, 95, 35, 35, 77, 253, 115, 403, 247, 247, 203, 35, 155, 155, 697, 187, 35, 35, 35, 589, 221, 95, 533, 35, 287, 77, 55, 55, 115, 221, 329, 35, 35, 221, 221, 689, 55, 35, 35
Offset: 0

Views

Author

Thomas Ordowski, Oct 26 2018

Keywords

Comments

a(n) is the smallest k > 1 such that n^k == n (mod k) and p-1 does not divide k-1 for every prime p dividing k, see A121707.
We have A000790(n) < a(n) <= A316940(n) for n > 0.
It seems that the sequence is unbounded like A316940.
The term a(5) = 4495 = 5*29*31 is not semiprime.

Examples

			a(6) = 35 since 6^35 == 6 (mod 35) and 35 = 5*7 is the smallest "anti-Carmichael number": 5-1 does not divide 7-1. We have gcd(35,2^35-2) = 1.
		

Crossrefs

Programs

  • PARI
    isac(n) = {my(f = factor(n)[,1]); for (i=1, #f, if (((n-1) % (f[i]-1)) == 0, return (0));); return (1);}
    isok(n,k) = {if (Mod(n, k)^k != Mod(n, k), return (0)); return (isac(k));}
    a(n) = {my(k=2); while (!isok(n,k), k++); return (k);} \\ Michel Marcus, Oct 27 2018

Extensions

More terms from Michel Marcus, Oct 26 2018

A345675 Numbers m such that D_{m-1} is the smallest base b > 1 for which b^{m-1} == 1 (mod m), where D_k is the denominator (A027642) of Bernoulli number B_k.

Original entry on oeis.org

35, 14315, 22399, 35711, 455891, 881809, 1198159, 1917071, 2287987, 3310037, 4464941, 11029439, 12190061, 13325753, 17832803, 33012941, 33296147, 37814849, 44986423, 74437181, 76911149, 82873661, 91909571, 98859851, 108266171, 128008159, 128981243, 132391409
Offset: 1

Views

Author

Thomas Ordowski, Sep 04 2021

Keywords

Comments

These are numbers m such that A027642(m-1) = A105222(m).
The corresponding bases of these pseudoprimes are 6, 6, 42, 66, 66, 46410, 3318, 66, 42, 30, 330, 6, 330, 61410, 6, 330, 1074, 510, 3318, 330, 7890, 330, 66, 12606, 66, 42, 6, 510, ...

Crossrefs

Programs

  • Mathematica
    Den[n_] := Times @@ (1 + Select[Divisors[n], PrimeQ[# + 1] &]); q[k_] := Module[{m = 2, d = Den[k - 1]}, If[PowerMod[d, k - 1, k] != 1, False, While[m < d && PowerMod[m, k - 1, k] != 1, m++]; m == d]]; Select[Range[3, 10^6, 2], q] (* Amiram Eldar, Sep 04 2021 *)
  • PARI
    f(n) = my(m=2); while(Mod(m, n)^(n-1)!=1, m++); m;
    isok(m) = f(m) == denominator(bernfrac(m-1)); \\ Michel Marcus, Sep 04 2021

Extensions

More terms from Amiram Eldar, Sep 04 2021
Showing 1-2 of 2 results.