cp's OEIS Frontend

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.

A070164 Least number m such that cototient(m) - 1 = prime(n).

This page as a plain text file.
%I A070164 #15 Mar 17 2025 06:50:39
%S A070164 9,6,10,12,18,26,34,38,36,42,48,74,82,60,72,78,84,122,134,108,146,152,
%T A070164 164,126,194,202,206,156,150,226,192,180,198,204,222,296,266,260,328,
%U A070164 258,252,338,288,386,270,398,340,392,452,350,342,336,482,372,514,360
%N A070164 Least number m such that cototient(m) - 1 = prime(n).
%H A070164 Amiram Eldar, <a href="/A070164/b070164.txt">Table of n, a(n) for n = 1..10000</a>
%F A070164 a(n) = Min{x: A051953(x) - 1 = n-th prime}.
%e A070164 prime(17) = 59, cototient(k) - 1 = 59 for k = 84, 100, 116 and 118, and the smallest is a(17) = 84.
%t A070164 seq[lim_] := Module[{c = Table[n - EulerPhi[n] - 1, {n, 1, lim}], m}, m = PrimePi[Max[c]]; TakeWhile[Flatten[FirstPosition[c,#]& /@ Prime[Range[m]]], !MissingQ[#] &]]; seq[600] (* _Amiram Eldar_, Mar 17 2025 *)
%o A070164 (PARI) list(len) = {my(v = vector(len), k = 2, c = 0, p, i); while(c < len, p = k - eulerphi(k) - 1; if(isprime(p), i = primepi(p); if(i <= len && v[i] == 0, v[i] = k; c++)); k++); v;} \\ _Amiram Eldar_, Mar 17 2025
%Y A070164 Cf. A000010, A051953, A070162, A219428.
%K A070164 nonn
%O A070164 1,1
%A A070164 _Labos Elemer_, Apr 26 2002