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.

Showing 1-8 of 8 results.

A001838 Numbers k such that phi(k+2) = phi(k) + 2.

Original entry on oeis.org

3, 5, 6, 11, 12, 14, 17, 18, 20, 29, 41, 44, 59, 62, 71, 92, 101, 107, 116, 137, 149, 164, 179, 191, 197, 212, 227, 239, 254, 269, 281, 311, 332, 347, 356, 419, 431, 452, 461, 521, 524, 569, 599, 617, 641, 659, 692, 716, 764, 809, 821, 827, 857, 881, 932, 956
Offset: 1

Views

Author

Keywords

Comments

If p and p+2 are primes then p is a solution. If p and 2p+1 are both odd primes then 4p is a solution. Several numbers of the form 2^j-2 are solutions (see cross-referenced sequences). Although 18 is a solution, it is not of any of these forms.
Twice Mersenne primes (cf. A000668) are also solutions. - Vladeta Jovovic, Feb 14 2002

Examples

			phi(18+2) = 8 = phi(18) + 2, so 18 is in the sequence.
		

References

  • M. Abramowitz and I. A. Stegun, eds., Handbook of Mathematical Functions, National Bureau of Standards Applied Math. Series 55, 1964 (and various reprintings), p. 840.
  • D. M. Burton, Elementary Number Theory, section 7-2.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence as N0951, although there are errors, probably caused by errors in the original source).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A050472, A050473, etc. Essentially the same as A056853.

Programs

Extensions

More terms from Jud McCranie, Dec 24 1999

A171271 Numbers n such that phi(n)=2*phi(n-1).

Original entry on oeis.org

3, 5, 17, 155, 257, 287, 365, 805, 1067, 2147, 3383, 4551, 6107, 7701, 8177, 9269, 11285, 12557, 12971, 16403, 19229, 19277, 20273, 25133, 26405, 27347, 29155, 29575, 35645, 36419, 38369, 39647, 40495, 47215, 52235, 54653, 65537, 84863
Offset: 1

Views

Author

Farideh Firoozbakht, Feb 23 2010

Keywords

Comments

Theorem: A prime p is in the sequence iff p is a Fermat prime.
Proof: If p=2^2^n+1 is prime (Fermat prime) then phi(p)=2^2^n=2* phi(2^2^n)=2*phi(p-1), so p is in the sequence. Now if p is a prime term of the sequence then phi(p)=2*phi(p-1) so p-1=2*phi(p-1) and we deduce that p-1=2^m hence p is a Fermat prime.

Crossrefs

Programs

Formula

a(n) = A050472(n) + 1. - Ray Chandler, May 01 2015

A055458 a(n) = smallest composite solution x to the equation phi(x+2n) = phi(x)+2n.

Original entry on oeis.org

6, 12, 21, 24, 36, 45, 48, 39, 63, 72, 72, 95, 60, 57, 224, 84, 15, 135, 1058, 45, 301, 144
Offset: 1

Views

Author

Labos Elemer, Jun 26 2000

Keywords

Comments

Sivaramakrishnan (1989) quotes Makowski, who gave solutions for phi(x+d) = phi(x)+d with d = 2^a and d = 2*3^a. Compare also A007694 and A049237.
Smallest prime solutions appear to be identical with A054906.
a(23) is presently unknown.
The sequence continues as (with ? for unknown values): ?, 95, 162, 63, 189, 69, 156, 161, 180, 69, 260, 150, ?, 115, 204, 129, 400, 75, 180, 165, 35, 117, 476, 7105, 288, 195, ?, 324, 620, 240, 81, 145, 14531, 153, 644, 309, ?, 203, ?, 63, 640, 75, 372, 285, 2312, 33, 343, 642, 336, 155, ?, 147, 728, 396, 1564, 185, 564, 87, 567, 360, 360, 155, 492, 510, 560, 516, 516, 301, 4232, 261, 860, 387, 576, 185, 564, 309, 1000, 225 ... - Don Reble, Apr 29 2015

Examples

			a(19) = 1058 because phi(1058 + 38) = phi(1096) = 544 = 506 + 38 = phi(1058) + 38.
a(100) = 225, phi(225 + 200) = phi(425) = 320 = 120 + 200 = phi(225) + 200.
		

References

  • Sivaramakrishnan, R. (1989): Classical theory of Arithmetical Functions. Marcel Dekker, Inc., New York-Basel. Chapter V, Problem 20, page 113.

Crossrefs

Programs

  • Maple
    A055458 := proc(n)
        local x;
        for x from 0 do
            if not isprime(x) then
            if numtheory[phi](x+2*n) = numtheory[phi](x)+2*n then
                return x;
            end if;
            end if;
        end do:
    end proc: # R. J. Mathar, Sep 23 2016
  • Mathematica
    Table[k = 4; While[Nand[CompositeQ@ k, EulerPhi[k + 2 n] == EulerPhi[k] + 2 n], k++]; k, {n, 22}] (* Michael De Vlieger, Dec 17 2016 *)
  • PARI
    a(n)=forcomposite(x=4,, if(eulerphi(x+2*n) == eulerphi(x)+2*n, return(x))) \\ does not handle -1s; Charles R Greathouse IV, Apr 28 2015

Extensions

More terms from Michel ten Voorde Jun 14 2003
Entry revised by N. J. A. Sloane, Apr 28 2015

A050473 Smallest k such that phi(k+n) = 2*phi(k).

Original entry on oeis.org

2, 1, 1, 2, 1, 4, 3, 4, 3, 5, 5, 8, 26, 7, 5, 8, 9, 12, 5, 10, 7, 8, 46, 16, 5, 13, 9, 14, 7, 25, 21, 13, 9, 17, 7, 24, 62, 19, 11, 20, 76, 28, 13, 16, 15, 23, 17, 32, 21, 25, 17, 26, 52, 36, 11, 28, 13, 26, 13, 45, 74, 28, 17, 26, 13, 39, 33, 31, 21, 32, 13, 48, 39, 37, 25, 38
Offset: 1

Views

Author

Jud McCranie, Dec 24 1999

Keywords

Comments

Makowski proved that the sequence is well-defined.
It appears that k <= 2n, with equality for the n in A110196 only. Computations for n < 10^6 appear to show that k < n for all but a finite number of n. - T. D. Noe, Jul 15 2005

Examples

			phi(13+26) = 24 = 2*phi(13), so a(13) = 26.
		

References

  • Richard K. Guy, Unsolved Problems in Number Theory, 3rd Edition, Springer, 2004, Section B36, p. 138.

Crossrefs

Cf. A110179 (least k such that phi(n+k)=2*phi(n)).

Programs

  • Mathematica
    Table[k=1; While[EulerPhi[n+k] != 2*EulerPhi[k], k++ ]; k, {n, 100}] (Noe)
  • PARI
    f(n) = apply(x -> x - n, select(x -> x > n, invphi(2*eulerphi(n)))); \\ using Max Alekseyev's invphi.gp
    lista(len) = {my(v = vector(len), c = 0, k = 1, s); while(c < len, s = f(k); for(i = 1, #s, if(s[i] <= len && v[s[i]] == 0, c++; v[s[i]] = k)); k++); v;} \\ Amiram Eldar, Nov 05 2024

A067143 Numbers n such that phi(n+1) = 3*phi(n).

Original entry on oeis.org

6, 12, 18, 36, 72, 90, 96, 108, 162, 192, 432, 486, 576, 702, 768, 792, 924, 1152, 1296, 1458, 2592, 2916, 3456, 3888, 4698, 5550, 6696, 7998, 8700, 10368, 10590, 11802, 12288, 16470, 17496, 18432, 33250, 39366, 52488, 56790, 79248, 124356
Offset: 1

Views

Author

Benoit Cloitre, Feb 19 2002

Keywords

Crossrefs

Programs

Extensions

More terms from Dean Hickerson, Feb 20 2002

A172314 Numbers k such that phi(k+1) = 4*phi(k).

Original entry on oeis.org

1260, 13650, 17556, 18720, 24510, 42120, 113610, 244530, 266070, 712080, 749910, 795690, 992250, 1080720, 1286730, 1458270, 1849470, 2271060, 2457690, 3295380, 3370770, 3414840, 3714750, 4061970, 4736490, 5314050, 5827080, 6566910, 6935082, 7303980, 7864080
Offset: 1

Views

Author

Michel Lagneau, Jan 31 2010

Keywords

Examples

			phi(1260) = 288. phi(1261) = 1152. 4*phi(1260) = phi(1261).
		

References

  • J.-M. De Koninck, Ces nombres qui nous fascinent, Entry 51, p. 19, Ellipses, Paris 2008.
  • R. K. Guy, Unsolved Problems Number Theory, Sect. B36.

Crossrefs

Programs

  • Magma
    [n: n in [1..2*10^6] | EulerPhi(n+1) eq 4*EulerPhi(n)]; // Vincenzo Librandi, Jan 27 2016
  • Maple
    with(numtheory): for n from 1 to 4000000 do; if 4*phi(n) = phi(n+1) then print(n); else fi ; od;
  • Mathematica
    #[[1,1]]&/@Select[Partition[Table[{n,EulerPhi[n]},{n,4000000}],2,1], 4#[[1,2]]==#[[2,2]]&] (* Harvey P. Dale, Oct 11 2011 *)
    Select[Range@1000000, EulerPhi@# 4 == EulerPhi[# + 1] &] (* Vincenzo Librandi, Jan 27 2016 *)

Extensions

References separated by R. J. Mathar, Feb 19 2010

A266276 a(n) is the smallest number k such that phi(k) = n*phi(k-1).

Original entry on oeis.org

2, 3, 7, 1261, 11242771
Offset: 1

Views

Author

Jaroslav Krizek, Jan 26 2016

Keywords

Comments

a(n) >= A266269(n). - Max Alekseyev, Jan 26 2025

Examples

			a(3) = 7 because 7 is the smallest number k such that phi(k) = n*phi(k-1); phi(7) = 6 =3*phi(6) = 3*2.
		

Crossrefs

Sequences of numbers n such that phi(n) = k*phi(n-1): {A001274 + 1} for k=1; A171271 = {A050472 + 1} for k=2; A266268 = {A067143 + 1} for k=3; A268126 = {A172314 + 1} for k=4; {A201253 + 1} for k=5.

Programs

  • Magma
    a:=func; [a(n):n in[1..5]];
    
  • PARI
    a(n) = my(k=2, epk=1, enk); while ((enk=eulerphi(k)) != n*epk, epk = enk; k++); k; \\ Michel Marcus, Feb 20 2020

A201253 Numbers k such that phi(k+1) = 5*phi(k).

Original entry on oeis.org

11242770, 18673200, 77805000, 117138840, 122649450, 278023200, 393513120, 881879460, 2177410830, 2364390210, 3440848320, 3919303080, 5151045900, 5836032510, 7284273360, 8029787220, 8505803460, 12998545560, 13081794180, 13759304790, 14031484740, 14104654410
Offset: 1

Views

Author

Ray Chandler, Nov 28 2011

Keywords

Crossrefs

Programs

  • PARI
    isok(k) = eulerphi(k+1) == 5*eulerphi(k); \\ Michel Marcus, Aug 10 2025

Extensions

a(9)-a(22) from Donovan Johnson, Nov 29 2011
Showing 1-8 of 8 results.