login
A286464
Compound filter (3-adic valuation & signature for base-2 1-runs): a(n) = P(A051064(n), A278222(n)), where P(n,k) is sequence A000027 used as a pairing function.
4
2, 2, 12, 2, 16, 12, 29, 2, 31, 16, 67, 12, 67, 29, 138, 2, 16, 31, 67, 16, 467, 67, 277, 12, 67, 67, 745, 29, 277, 138, 497, 2, 23, 16, 67, 31, 436, 67, 302, 16, 436, 467, 1771, 67, 1894, 277, 1129, 12, 67, 67, 668, 67, 1771, 745, 2557, 29, 302, 277, 2557, 138, 1129, 497, 2148, 2, 16, 23, 67, 16, 467, 67, 277, 31, 436, 436, 1832, 67, 1771, 302, 1129, 16, 566
OFFSET
1,1
LINKS
Eric Weisstein's World of Mathematics, Pairing Function
FORMULA
a(n) = (1/2)*(2 + ((A051064(n)+A278222(n))^2) - A051064(n) - 3*A278222(n)).
PROG
(PARI)
A005940(n) = { my(p=2, t=1); n--; until(!n\=2, if((n%2), (t*=p), p=nextprime(p+1))); t }; \\ Modified from code of M. F. Hasler
A051064(n) = if(n<1, 0, 1+valuation(n, 3));
A046523(n) = { my(f=vecsort(factor(n)[, 2], , 4), p); prod(i=1, #f, (p=nextprime(p+1))^f[i]); }; \\ This function from Charles R Greathouse IV, Aug 17 2011
A278222(n) = A046523(A005940(1+n));
A286464(n) = (1/2)*(2 + ((A051064(n)+A278222(n))^2) - A051064(n) - 3*A278222(n))
for(n=1, 10000, write("b286464.txt", n, " ", A286464(n)));
(Scheme) (define (A286464 n) (* (/ 1 2) (+ (expt (+ (A051064 n) (A278222 n)) 2) (- (A051064 n)) (- (* 3 (A278222 n))) 2)))
CROSSREFS
KEYWORD
nonn
AUTHOR
Antti Karttunen, May 10 2017
STATUS
approved