This site is supported by donations to The OEIS Foundation.

 Hints (Greetings from The On-Line Encyclopedia of Integer Sequences!)
 A117658 Number of solutions to x^(k+1)=x^k mod n for some k>=1. 2
 1, 2, 2, 3, 2, 4, 2, 5, 4, 4, 2, 6, 2, 4, 4, 9, 2, 8, 2, 6, 4, 4, 2, 10, 6, 4, 10, 6, 2, 8, 2, 17, 4, 4, 4, 12, 2, 4, 4, 10, 2, 8, 2, 6, 8, 4, 2, 18, 8, 12, 4, 6, 2, 20, 4, 10, 4, 4, 2, 12, 2, 4, 8, 33, 4, 8, 2, 6, 4, 8, 2, 20, 2, 4, 12 (list; graph; refs; listen; history; text; internal format)
 OFFSET 1,2 COMMENTS If n is prime, then the solutions are x = 0, 1, and so a(n) = 2. - Michael B. Porter, Jul 08 2016 The set of solutions is independent of the choice of k. - Michael B. Porter, Jul 08 2016 LINKS Robert Israel, Table of n, a(n) for n = 1..10000 S. R. Finch, Idempotents and Nilpotents Modulo n, arXiv:math/0605019 [math.NT], 2006. FORMULA a(n) = Sum_{k=1..n} floor((k^n-k^(n-1))/n)-floor((k^n-k^(n-1)-1)/n). - Anthony Browne, Jul 06 2016 Multiplicative with a(p^e) = 1 + p^(e-1)) for primes p. - Robert Israel, Jul 06 2016 EXAMPLE For n = 10, using k = 1, the solutions are x = 0, 1, 5, and 6, so a(10) = 4. - Michael B. Porter, Jul 08 2016 MAPLE f:= proc(n) local F, f;     F:= ifactors(n)[2];     mul(1 + f[1]^(f[2]-1), f = F) end proc: map(f, [\$1..100]); # Robert Israel, Jul 06 2016 MATHEMATICA a[n_] := Module[{F, f}, F = FactorInteger[n]; Product[1 + f[[1]]^(f[[2]] - 1), {f, F}]]; a[1] = 1; Array[a, 100] (* Jean-François Alcover, Nov 05 2016, after Robert Israel *) CROSSREFS Cf. A117659. Sequence in context: A237433 A236515 A129294 * A289435 A067540 A218701 Adjacent sequences:  A117655 A117656 A117657 * A117659 A117660 A117661 KEYWORD mult,nonn AUTHOR Steven Finch, Apr 11 2006 STATUS approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recent | More pages
The OEIS Community | Maintained by The OEIS Foundation Inc.