OFFSET
1,2
LINKS
FORMULA
PROG
(PARI) A336932(n) = { my(f = factor(n)); for(i=1, #f~, f[i, 1] = nextprime(f[i, 1]+1)); valuation(sigma(factorback(f)), 2); };
(PARI)
A007814(n) = valuation(n, 2);
A336932(n) = { my(f=factor(n)); sum(i=1, #f~, (f[i, 2]%2) * (A007814(1+nextprime(1+f[i, 1]))+A007814(1+f[i, 2])-1)); };
(Python)
from math import prod
from sympy import factorint, nextprime
def A336932(n): return (~(m:=prod(((q:=nextprime(p))**(e+1)-1)//(q-1) for p, e in factorint(n).items()))& m-1).bit_length() # Chai Wah Wu, Jul 05 2022
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, Aug 16 2020
STATUS
approved