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.

A079008 a(n) is smallest number k such that the n successive values of phi(k+j) (j=0,..,n-1) are all distinct.

Original entry on oeis.org

1, 2, 5, 11, 11, 17, 17, 37, 46, 46, 112, 112, 123, 149, 149, 149, 257, 257, 257, 257, 257, 257, 257, 261, 658, 658, 685, 741, 741, 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359, 1359, 4097, 4097, 4097, 4097, 4097
Offset: 1

Views

Author

Labos Elemer, Jan 08 2003

Keywords

Examples

			a(8)=37, values of phi(k) for k=37,..,44 are {36, 18, 24, 16, 40, 12, 42, 20}.
		

Crossrefs

Programs

  • Mathematica
    kul[x_] := Length[x]-Length[Union[x]]; frt[x_] := Table[EulerPhi[x+j], {j, 0, h-1}]; Table[fa=1; k=0; Do[s=frt[n]; s1=kul[s]; If[Equal[s1, 0]&&Equal[fa, 1], k=k+1; Print[{h, n, s}]; fa=0], {n, 1, 10000}], {h, 1, 50}]
  • PARI
    a(n) = if(n==1, 1, my(v=vector(n, i, eulerphi(i))); for(k=n, oo, if(#Set(v)==n, return(k-n)); v[k%n+1]=eulerphi(k))); \\ Jinyuan Wang, Feb 10 2021