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 A167766 #25 Feb 16 2025 08:33:11 %S A167766 5,19,23,59,47,107,479,383,283,467,1367,1187,167,347,1319,643,2837, %T A167766 2203,2153,3413,587,5693,1997,359,5827,1619,2063,2999,4799,3167,1019, %U A167766 1579,5483,3343,7159,3023,12569,1307,4679,2083,719,3623,4597,3863,18917,4783 %N A167766 Minimum numbers whose phi of phi are multiples of the n-th prime: the n-th term is the minimum integer x such that: prime(n) | phi(phi(x)), prime(n) being the n-th prime. %C A167766 These minimal integers are always prime. To be clear, the phi function referred to here is Euler's totient function. %H A167766 Donovan Johnson, <a href="/A167766/b167766.txt">Table of n, a(n) for n = 1..10000</a> %H A167766 Eric Weisstein's World of Mathematics, <a href="https://mathworld.wolfram.com/TotientFunction.html">Euler's Totient Function</a> %e A167766 The first term is 5. phi(5) = 4 and phi(4)=2. 2 is a multiple of the first prime 2. 5 is the lowest such number x where 2 divides phi(phi(x)). %p A167766 with(numtheory): P:=proc(n) local a,k; a:=ithprime(n); %p A167766 for k from 1 to 10^3 do if frac(phi(phi(ithprime(k)))/a)=0 %p A167766 then RETURN(ithprime(k)); break; fi; od; end: %p A167766 seq(P(i),i=1..46); # _Paolo P. Lava_, Oct 10 2018 %t A167766 a[n_] := (p=Prime[n]; k=1; While[k++; x=Prime[k]; Mod[ EulerPhi[ EulerPhi[x]], p] != 0]; x); Table[a[n], {n, 50}] (* _Jean-François Alcover_, Sep 14 2011 *) %o A167766 (PARI) /* not the most efficient implementation */ ppp(a,b)= { forprime(p=a,b, v = 2*p + 1; v2 = 1; minv = 100000000; while (v2 <= minv || v <=minv, /* print ("Checking ",v, " for ",p); */ while(!isprime(v), v += 2*p /*; print ("Checking ",v, " for ",p)*/ ); if (v%(p*p)==1, /* don't do this step if: p^2 | v-1 */ v2 = v , v2 = 2*v + 1; while (!isprime(v2) && v2 < minv, v2 += 2*v ) ); if (v2 < minv, minv = v2; ); v += 2*p ); print (p," => ",minv) ) } %Y A167766 Cf. A010554. %K A167766 easy,nice,nonn %O A167766 1,1 %A A167766 _Fred Schneider_, Nov 11 2009