login
A334990
a(1) = 1 and for any n > 1 with prime factorization Product_{k = 1..m} prime(k)^e_k (where prime(k) denotes the k-th prime number and e_m > 0), a(n) = Product_{k = 1..m-1} prime(k)^(e_k XOR e_{k+1}) (where XOR denotes the bitwise XOR operator).
1
1, 1, 2, 1, 3, 1, 5, 1, 4, 6, 7, 8, 11, 10, 2, 1, 13, 8, 17, 12, 30, 14, 19, 4, 9, 22, 8, 20, 23, 1, 29, 1, 42, 26, 3, 1, 31, 34, 66, 24, 37, 15, 41, 28, 108, 38, 43, 32, 25, 18, 78, 44, 47, 4, 105, 40, 102, 46, 53, 8, 59, 58, 180, 1, 165, 21, 61, 52, 114, 6
OFFSET
1,3
COMMENTS
This sequence has similarities with A038554; here we consider prime exponents, there binary digits.
FORMULA
a(n) = 1 iff n belongs to A100778.
a(n^2) = a(n)^2.
a(n^k) = a(n)^k for any k >= 0 and any squarefree number n.
a(prime(n+1)) = prime(n).
A006530(a(n)) < A006530(n) for any n > 1.
PROG
(PARI) a(n) = { my (v=1, p=2, e=valuation(n, p)); n/=p^e; forprime (q=p+1, oo, if (n==1, return (v), my (f=valuation(n, q)); n/=q^f; v*=p^bitxor(e, f); [p, e]=[q, f])) }
CROSSREFS
KEYWORD
nonn,base
AUTHOR
Rémy Sigrist, May 18 2020
STATUS
approved