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.

A239061 Number of integers x, 1 <= x <= n, such that x^x == 1 (mod n).

Original entry on oeis.org

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

Views

Author

Keywords

Crossrefs

Cf. A239062, A239063 (indices of 1's).

Programs

  • Mathematica
    gg1[n_] := Sum[If[PowerMod[x, x, n] == Mod[1, n], 1, 0], {x, n}];Array[gg1,200]

A338445 Numbers m with integer solution to x^x == (x+1)^(x+1) (mod m) with 1<=x

Original entry on oeis.org

3, 11, 13, 19, 23, 29, 31, 43, 49, 53, 57, 59, 61, 67, 71, 73, 77, 79, 83, 85, 89, 91, 93, 97, 101, 103, 109, 113, 127, 129, 131, 133, 141, 143, 147, 149, 151, 157, 161, 163, 167, 169, 173, 177, 179, 183, 187, 197, 199, 201, 203, 205, 211, 217, 229, 235, 237, 239
Offset: 1

Views

Author

Owen C. Keith, Oct 28 2020

Keywords

Comments

Some values of m have multiple solutions.
For example, for m = 49, 25^25 == 26^26 (mod 49) and 37^37 == 38^38 (mod 49).
All terms are odd. - Robert Israel, Nov 25 2020

Examples

			3 is a term because 1^1 == 2^2 (mod 3).
11 is a term because 8^8 == 9^9 (mod 11).
13 is a term because 8^8 == 9^9 (mod 13).
		

Crossrefs

Similar sequences: A174824, A239061, A239062, A239063.

Programs

  • Maple
    filter:= proc(n) local x,y,z;
      y:= 1;
      for x from 2 to n-1 do
        z:= x &^ x mod n;
        if z = y then return true fi;
        y:= z
      od;
      false
    end proc:
    select(filter, [$2..1000]); # Robert Israel, Nov 25 2020
  • Mathematica
    seqQ[n_] := AnyTrue[Range[n - 1], PowerMod[#, #, n] == PowerMod[# + 1, # + 1, n] &]; Select[Range[240], seqQ] (* Amiram Eldar, Oct 28 2020 *)
  • PARI
    isok(m)=sum(i=1, m-1, Mod(i,m)^i == Mod((i+1),m)^(i+1)) \\ Andrew Howroyd, Oct 28 2020
Showing 1-2 of 2 results.