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.

A069825 Numbers k such that there is no x < k such that sigma(x) = phi(k).

Original entry on oeis.org

1, 3, 4, 6, 11, 17, 22, 23, 32, 34, 40, 46, 47, 48, 53, 59, 60, 67, 71, 83, 85, 89, 94, 101, 106, 107, 115, 118, 125, 128, 131, 134, 136, 137, 141, 142, 149, 160, 166, 167, 170, 173, 177, 178, 179, 184, 188, 191, 192, 197, 202, 204, 214, 227, 230, 233, 235, 236
Offset: 1

Views

Author

Benoit Cloitre, Apr 28 2002

Keywords

Crossrefs

Cf. A000010 (phi), A000203 (sigma).

Programs

  • Maple
    with(numtheory): A069825 := proc(n) local p,i; p := phi(n); for i from 1 to n-1 do if sigma(i) = p then RETURN(NULL) fi od; n end; # Peter Luschny, Nov 02 2010
    # Alternative:
    N:= 1000: # to get terms <= N
    R:= Vector(N):
    for k from 1 to N-1 do
      s:= numtheory:-sigma(k);
      if s <= N and R[s] = 0 then R[s]:= k fi;
    od:
    1, op(select(t -> R[numtheory:-phi(t)]=0, [$2..N])); # Robert Israel, Aug 25 2017
  • Mathematica
    okQ[n_] := NoneTrue[Range[n-1], DivisorSigma[1,#] == EulerPhi[n]&];
    Select[Range[250], okQ] (* Jean-François Alcover, Jun 03 2019 *)
  • PARI
    for(n=1,600,if(abs(prod(i=1,n-1,eulerphi(n)-sigma(i)))>0,print1(n,",")))
    
  • PARI
    isok(k) = {my(p = eulerphi(k), v = invsigma(p)); #v == 0 || vecmin(v) >= k;}; \\ Amiram Eldar, May 03 2025, using Max Alekseyev's invphi.gp (see links).