%I #8 Jan 15 2019 18:42:35
%S 1,2,3,4,3,5,3,6,7,8,3,9,3,10,11,12,3,13,3,14,15,16,3,17,18,19,20,21,
%T 3,22,3,23,24,25,24,26,3,27,28,29,3,30,3,31,32,33,3,34,35,36,37,38,3,
%U 39,37,40,41,42,3,43,3,44,45,46,47,48,3,49,50,48,3,51,3,52,53,54,50,55,3,56,57,58,3,59,60,61,62,63,3,64,65,66,67,68,62,69,3,70,71,72,3,73,3
%N Lexicographically earliest sequence such that for all i, j, a(i) = a(j) => f(i) = f(j) where f(n) = [A000035(n), A003557(n), A323363(n)] for all other numbers, except f(n) = 0 for odd primes.
%C For all i, j:
%C A305801(i) = A305801(j) => a(i) = a(j),
%C a(i) = a(j) => A323369(i) = A323369(j),
%C a(i) = a(j) => A323401(i) = A323401(j).
%H Antti Karttunen, <a href="/A323400/b323400.txt">Table of n, a(n) for n = 1..65537</a>
%o (PARI)
%o up_to = 65537;
%o rgs_transform(invec) = { my(om = Map(), outvec = vector(length(invec)), u=1); for(i=1, length(invec), if(mapisdefined(om,invec[i]), my(pp = mapget(om, invec[i])); outvec[i] = outvec[pp] , mapput(om,invec[i],i); outvec[i] = u; u++ )); outvec; };
%o DirInverse(v) = { my(u=vector(#v)); u[1] = (1/v[1]); for(n=2, #v, u[n] = -sumdiv(n, d, if(d<n, v[n/d]*u[d], 0))); (u) }; \\ Compute the Dirichlet inverse of the sequence given in input vector v.
%o A001615(n) = (n * sumdivmult(n, d, issquarefree(d)/d)); \\ From A001615
%o v323363 = DirInverse(vector(up_to,n,A001615(n)));
%o A323363(n) = v323363[n];
%o A003557(n) = { my(f=factor(n)); for(i=1, #f~, f[i, 2] = f[i, 2]-1); factorback(f); };
%o Aux323400(n) = if((n>2)&&isprime(n), 0, [(n%2), A003557(n), A323363(n)]);
%o v323400 = rgs_transform(vector(up_to, n, Aux323400(n)));
%o A323400(n) = v323400[n];
%Y Cf. A000035, A001615, A322588, A323363, A323369, A323400.
%Y Cf. also A305801, A323370, A323372.
%K nonn
%O 1,2
%A _Antti Karttunen_, Jan 15 2019