A037202 Number of lines in Pratt certificate for n-th prime.
1, 2, 2, 4, 4, 4, 2, 4, 6, 6, 6, 4, 4, 8, 8, 6, 8, 6, 8, 8, 4, 8, 6, 6, 4, 4, 6, 8, 4, 6, 8, 8, 4, 10, 6, 6, 8, 4, 8, 10, 8, 6, 8, 4, 6, 8, 10, 8, 8, 8, 8, 8, 6, 4, 2, 10, 10, 6, 10, 8, 12, 6, 6, 10, 8, 10, 10, 8, 12, 10, 6, 10, 10, 10, 8, 10, 6, 8, 4, 6, 10, 10, 12, 4, 8, 8, 6, 8, 10, 12, 10, 10
Offset: 1
References
- E. Bach and Jeffrey Shallit, Algorithmic Number Theory, I, p. 270.
Links
- T. D. Noe, Table of n, a(n) for n = 1..10000
- Eric Weisstein's World of Mathematics, Definition
Programs
-
Mathematica
a[1] = 1; a[n_] := 1 + Plus @@ (a@ PrimePi@ # & /@ First /@ FactorInteger[ Prime@ n - 1]); Array[a, 92]
Formula
a(2)=1, a(n) = 1 + Sum a(p), p prime, p | n-1, where n runs through primes.
Comments