[go: up one dir, main page]

login
A351567
The second least significant nonzero digit in the primorial base expansion of n, or 0 if there is no such digit.
3
0, 0, 0, 1, 0, 2, 0, 1, 1, 1, 1, 2, 0, 2, 2, 1, 2, 2, 0, 3, 3, 1, 3, 2, 0, 4, 4, 1, 4, 2, 0, 1, 1, 1, 1, 2, 1, 1, 1, 1, 1, 2, 1, 2, 2, 1, 2, 2, 1, 3, 3, 1, 3, 2, 1, 4, 4, 1, 4, 2, 0, 2, 2, 1, 2, 2, 2, 1, 1, 1, 1, 2, 2, 2, 2, 1, 2, 2, 2, 3, 3, 1, 3, 2, 2, 4, 4, 1, 4, 2, 0, 3, 3, 1, 3, 2, 3, 1, 1, 1, 1, 2, 3, 2, 2, 1
OFFSET
0,6
FORMULA
a(n) = A351563(A276086(n)).
For all n, a(n) < A351566(n).
MATHEMATICA
a[n_] := Module[{k = n, p = 2, s = {}, r}, While[{k, r} = QuotientRemainder[k, p]; k != 0 || r != 0, If[r > 0, AppendTo[s, r]]; p = NextPrime[p]]; i = Position[s, _?(# > 0 &)] // Flatten; If[Length[s] < 2, 0, s[[2]]]]; Array[a, 100, 0] (* Amiram Eldar, Mar 13 2024 *)
PROG
(PARI)
A351563(n) = if(1>=omega(n), 0, (factor(n))[2, 2]);
A276086(n) = { my(m=1, p=2); while(n, m *= (p^(n%p)); n = n\p; p = nextprime(1+p)); (m); };
CROSSREFS
Cf. A060735 (gives the positions of zeros after a(0)=0).
Sequence in context: A115861 A282355 A199322 * A284203 A375106 A341594
KEYWORD
nonn,base
AUTHOR
Antti Karttunen, Apr 01 2022
STATUS
approved