login
Compound filter: a(n) = P(A007733(n), A046523(n)), where P(n,k) is sequence A000027 used as a pairing function.
6

%I #8 May 26 2017 20:46:34

%S 1,2,5,7,14,23,9,29,42,40,65,80,90,31,40,121,44,142,189,109,61,115,77,

%T 302,273,148,318,94,434,532,20,497,115,86,148,826,702,271,148,355,230,

%U 601,119,220,265,131,299,1178,297,485,86,265,1430,838,320,328,271,556,1769,1957,1890,50,142,2017,148,751,2277,179,373,832,665,2932,54,856,485

%N Compound filter: a(n) = P(A007733(n), A046523(n)), where P(n,k) is sequence A000027 used as a pairing function.

%H Antti Karttunen, <a href="/A286573/b286573.txt">Table of n, a(n) for n = 1..10000</a>

%F a(n) = (1/2)*(2 + ((A007733(n)+A046523(n))^2) - A007733(n) - 3*A046523(n)).

%o (PARI)

%o A007733(n) = znorder(Mod(2, n/2^valuation(n, 2))); \\ This function from _Michel Marcus_, Apr 11 2015

%o 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

%o A286573(n) = (1/2)*(2 + ((A007733(n)+A046523(n))^2) - A007733(n) - 3*A046523(n));

%o (Python)

%o from sympy import divisors, factorint

%o def T(n, m): return ((n + m)**2 - n - 3*m + 2)/2

%o def a002326(n):

%o m=1

%o while True:

%o if (2**m - 1)%(2*n + 1)==0: return m

%o else: m+=1

%o def a000265(n): return max(list(filter(lambda i: i%2 == 1, divisors(n))))

%o def a007733(n): return a002326((a000265(n) - 1)/2)

%o def P(n):

%o f = factorint(n)

%o return sorted([f[i] for i in f])

%o def a046523(n):

%o x=1

%o while True:

%o if P(n) == P(x): return x

%o else: x+=1

%o def a(n): return T(a007733(n), a046523(n)) # _Indranil Ghosh_, May 26 2017

%Y Cf. A000027, A007733, A046523, A286160, A286161.

%K nonn

%O 1,2

%A _Antti Karttunen_, May 26 2017