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.

A002174 Values taken by reduced totient function psi(n).

Original entry on oeis.org

1, 2, 4, 6, 8, 10, 12, 16, 18, 20, 22, 24, 28, 30, 32, 36, 40, 42, 44, 46, 48, 52, 54, 56, 58, 60, 64, 66, 70, 72, 78, 80, 82, 84, 88, 90, 92, 96, 100, 102, 104, 106, 108, 110, 112, 116, 120, 126, 128, 130, 132, 136, 138, 140, 144, 148, 150, 156, 160, 162, 164, 166, 168
Offset: 1

Views

Author

Keywords

Comments

If p is a Sophie Germain prime (A005384), then 2p is here. - T. D. Noe, Aug 13 2008
Terms of A002322, sorted and multiple values taken just once. - Vladimir Joseph Stephan Orlovsky, Jul 21 2009
a(2445343) = 10^7, suggesting that Luca & Pomerance's lower bound may be closer to the truth than the upper bound. The fit exponent log a(n)/log n - 1 = 0.0957... in this case. - Charles R Greathouse IV, Jul 02 2017

References

  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Programs

  • Mathematica
    lst={}; Do[AppendTo[lst, CarmichaelLambda[n]], {n, 6*7!}]; lst; Take[Union[lst], 123] (* Vladimir Joseph Stephan Orlovsky, Jul 21 2009 *)
    (* warning: there seems to be no guarantee that no terms near the end are omitted! - Joerg Arndt, Dec 23 2014 *)
    TakeWhile[Union@ Table[CarmichaelLambda@ n, {n, 10^6}], # <= 168 &] (* Michael De Vlieger, Mar 19 2016 *)
  • PARI
    list(lim)=my(v=List([1]),u,t); forprime(p=3,lim\3+1, u=List(); listput(u,p-1); while((t=u[#u]*p)<=lim, listput(u,t)); for(j=1,#v, for(i=1,#u, t=lcm(u[i],v[j]); if(t<=lim && t!=v[j], listput(v,t)))); v=List(Set(v))); forprime(p=lim\3+2,lim+1, listput(v,p-1)); v=List(Set(v)); for(i=1,#v, t=2*v[i]; if(t>lim, break); listput(v,t); while((t*=2)<=lim, listput(v,t))); Set(v) \\ Charles R Greathouse IV, Jun 23 2017
    
  • PARI
    is(n)=if(n%2, return(n==1)); my(f=factor(n),pe); for(i=1,#f~, if(n%(f[i,1]-1)==0, next); pe=f[i,1]^f[i,2]; forstep(q=2*pe+1,n+1,2*pe, if(n%(q-1)==0 && isprime(q), next(2))); return(0)); 1 \\ Charles R Greathouse IV, Jun 25 2017

Formula

n (log n)^0.086 << a(n) << n (log n)^0.36 where << is the Vinogradov symbol, see Luca & Pomerance. - Charles R Greathouse IV, Dec 28 2013

Extensions

More terms from T. D. Noe, Aug 13 2008