|
|
A246271
|
|
Starting from A003961(n), the number of additional iterations of A003961 required for the result to be of the form 4k+1.
|
|
15
|
|
|
0, 1, 0, 0, 2, 2, 1, 1, 0, 0, 0, 0, 0, 0, 1, 0, 2, 1, 1, 2, 6, 1, 0, 2, 0, 2, 0, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 2, 0, 1, 0, 2, 7, 0, 0, 0, 1, 1, 0, 1, 2, 5, 0, 2, 0, 0, 1, 2, 1, 1, 0, 1, 3, 1, 2, 0, 3, 0, 1, 2, 2, 0, 1, 1, 1, 1, 2, 0, 0, 0, 6, 0, 0, 6, 1, 0, 0, 4, 0, 0, 3, 0, 2, 0, 1, 0, 0, 2, 0, 1, 2, 0, 0, 0, 0, 0, 0, 0, 1, 2, 0, 1, 1, 0, 2, 0, 0, 0, 0, 1
(list;
graph;
refs;
listen;
history;
text;
internal format)
|
|
|
OFFSET
|
1,5
|
|
LINKS
|
|
|
FORMULA
|
|
|
EXAMPLE
|
a(5) = 2, because exactly two additional iterations of A003961 are needed before A003961(5) = 7 is of the form 4k+1; as A003961(7) = 11 and A003961(11) = 13. (We have 7 = 3 mod 4, 11 = 3 mod 4 and 13 = 1 mod 4.)
|
|
PROG
|
(PARI)
A003961(n) = my(f = factor(n)); for (i=1, #f~, f[i, 1] = nextprime(f[i, 1]+1)); factorback(f); \\ Using code of Michel Marcus
for(n=1, 10001, write("b246271.txt", n, " ", A246271(n)));
(Scheme, two different variants, the second one employing memoizing definec-macro)
(define (A246271 n) (let loop ((i 0) (n n)) (let ((next (A003961 n))) (if (= 1 (modulo next 4)) i (loop (+ i 1) next)))))
|
|
CROSSREFS
|
A246261 gives the positions of zeros, A246263 the positions of nonzeros.
A246280 the positions where n occurs for the first time, A246167 the positions of new distinct values.
|
|
KEYWORD
|
nonn
|
|
AUTHOR
|
|
|
STATUS
|
approved
|
|
|
|