This is a front-end for the Online Encyclopedia of Integer Sequences, made by Christian Perfect. The idea is to provide OEIS entries in non-ancient HTML, and then to think about how they're presented visually. The source code is on GitHub.
%I A286254 #10 Feb 16 2025 08:33:44 %S A286254 1,5,1,13,1,12,1,14,1,17,1,31,1,5,1,60,1,38,1,9,1,47,1,19,1,5,1,69,1, %T A286254 68,1,27,1,8,1,94,1,5,1,124,1,107,1,9,1,122,1,33,1,5,1,156,1,8,1,14,1, %U A286254 155,1,193,1,5,1,43,1,192,1,9,1,212,1,280,1,5,1,18,1,255,1,20,1,278,1,13,1,5,1,355,1,12,1,9,1,8,1,441,1,5,1,381,1,380,1,14 %N A286254 Compound filter: a(n) = P(A001511(n), A055396(1+n)), where P(n,k) is sequence A000027 used as a pairing function. %H A286254 Antti Karttunen, <a href="/A286254/b286254.txt">Table of n, a(n) for n = 1..10000</a> %H A286254 MathWorld, <a href="https://mathworld.wolfram.com/PairingFunction.html">Pairing Function</a> %F A286254 a(n) = (1/2)*(2 + ((A001511(n)+A055396(1+n))^2) - A001511(n) - 3*A055396(1+n)). %o A286254 (PARI) %o A286254 A001511(n) = (1+valuation(n,2)); %o A286254 A055396(n) = if(n==1, 0, primepi(factor(n)[1, 1])); \\ This function from _Charles R Greathouse IV_, Apr 23 2015 %o A286254 A286254(n) = (2 + ((A001511(n)+A055396(1+n))^2) - A001511(n) - 3*A055396(1+n))/2; %o A286254 for(n=1, 10000, write("b286254.txt", n, " ", A286254(n))); %o A286254 (Scheme) (define (A286254 n) (* (/ 1 2) (+ (expt (+ (A001511 n) (A055396 (+ 1 n))) 2) (- (A001511 n)) (- (* 3 (A055396 (+ 1 n)))) 2))) %o A286254 (Python) %o A286254 from sympy import primepi, isprime, primefactors %o A286254 def T(n, m): return ((n + m)**2 - n - 3*m + 2)/2 %o A286254 def a049084(n): return primepi(n)*(1*isprime(n)) %o A286254 def a055396(n): return 0 if n==1 else a049084(min(primefactors(n))) %o A286254 def a001511(n): return 2 + bin(n - 1)[2:].count("1") - bin(n)[2:].count("1") %o A286254 def a(n): return T(a001511(n), a055396(n + 1)) # _Indranil Ghosh_, May 07 2017 %Y A286254 Cf. A000027, A001511, A055396, A253790, A286161, A286251, A286252, A286253. %K A286254 nonn %O A286254 1,2 %A A286254 _Antti Karttunen_, May 07 2017