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 A332806 #8 Feb 27 2020 22:48:45 %S A332806 2,3,5,7,13,11,17,19,29,23,37,31,41,43,53,47,61,59,71,79,67,89,101,73, %T A332806 83,97,107,113,103,109,131,139,127,151,137,163,149,173,181,157,193, %U A332806 167,199,179,191,223,229,239,251,197,211,263,227,271,233,281,241,293,257,269,311,277,317,337,283,307,349,313,359,331,347,373,383,353 %N A332806 Permutation of primes, inverse of A108546. %H A332806 Antti Karttunen, <a href="/A332806/b332806.txt">Table of n, a(n) for n = 1..19962</a> %F A332806 a(n) = A000040(A332805(n)). %F A332806 a(A000720(A108547(n))) = A108547(n). %o A332806 (PARI) %o A332806 up_to = 10000; %o A332806 A332806list(up_to) = { my(v=vector(2), xs=Map(), lista=List([]), p,q,u); v[2] = 3; v[1] = 5; mapput(xs,1,1); mapput(xs,2,2); mapput(xs,3,3); for(n=4,up_to, p = v[2-(n%2)]; q = nextprime(1+p); while(q%4 != p%4, q=nextprime(1+q)); v[2-(n%2)] = q; mapput(xs,primepi(q),n)); for(i=1, oo, if(!mapisdefined(xs, i, &u), return(Vec(lista)), listput(lista, prime(u)))); }; %o A332806 v332806 = A332806list(up_to); %o A332806 A332806(n) = v332806[n]; %Y A332806 Cf. A000040, A108547, A332805, A332808. %Y A332806 Differs from its inverse A108546 for the first time at n=19, where a(19) = 71, while A108546(19) = 73. %K A332806 nonn %O A332806 1,1 %A A332806 _Antti Karttunen_, Feb 27 2020