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.

Previous Showing 11-20 of 42 results. Next

A145749 Numbers n such that sigma(n)+phi(n)=sigma(n+1)+phi(n+1).

Original entry on oeis.org

6, 8, 10, 22, 46, 58, 82, 106, 166, 178, 188, 226, 262, 285, 346, 358, 382, 466, 478, 502, 562, 586, 718, 838, 862, 886, 902, 982, 1018, 1186, 1282, 1306, 1318, 1366, 1438, 1486, 1522, 1618, 1822, 1906, 2013, 2026, 2038, 2062, 2098, 2206, 2446, 2458, 2578
Offset: 1

Views

Author

Farideh Firoozbakht, Nov 01 2008

Keywords

Comments

If n/2 is an odd prime and n+1 is prime then n is in the sequence, the proof is easy. 8,188,285,902,2013,... are terms of the sequence which they aren't of such form. This sequence is a subsequence of A066198.
If p is an odd Sophie Germain prime then 2*p is in the sequence. There is no term of the sequence which is of the form 2*p where p is prime and p isn't Sophie Germain prime. A244438 gives terms of the sequence which isn't of the form 2*p where p is prime. - Farideh Firoozbakht, Aug 14 2014

Examples

			10 is in the sequence because phi(10) + sigma(10) = 4 + 18 = 22 and phi(11) + sigma(11) = 10 + 12 = 22 also.
12 is not in the sequence because phi(12) + sigma(12) = 4 + 28 = 32 but phi(13) + sigma(13) = 12 + 14 = 26.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[2600],DivisorSigma[1,# ]+EulerPhi[ # ]==DivisorSigma[1,#+1]+EulerPhi[ #+1]&]
  • PARI
    for(n=1,10^4, s=eulerphi(n)+sigma(n); if(s==eulerphi(n+1)+sigma(n+1), print1(n,", "))) /* Derek Orr, Aug 14 2014*/

Formula

{n: A065387(n)=A065387(n+1)}.

A011774 Nonprimes k that divide sigma(k) + phi(k).

Original entry on oeis.org

1, 312, 560, 588, 1400, 23760, 59400, 85632, 147492, 153720, 556160, 569328, 1590816, 2013216, 3343776, 4563000, 4695456, 9745728, 12558912, 22013952, 23336172, 30002960, 45326160, 52021242, 75007400, 113315400, 137617728, 153587720, 402831360, 699117024
Offset: 1

Views

Author

Keywords

Comments

2*k = sigma(k) + phi(k) if and only if k is 1 or a prime.
If 7*2^j - 1 is prime then m = 2^(j+2)*3*(7*2^j - 1) is in the sequence. Because phi(m) = 2^(j+2)*(7*2^j - 2); sigma(m) = 7*2^(j+2)*(2^(j+3) - 1) so phi(m) + sigma(m) = 2^(j+2)*((7*2^j - 2) + (7*2^(j+3) - 7)) = 2^(j+2)* (63*2^(j+2) - 9) = 3*(2^(j+2)*3*(7*2^j - 1)) = 3*m, hence m is a term of A011251 and consequently m is a term of this sequence. A112729 gives such m's. - Farideh Firoozbakht, Dec 01 2005
Conjecture: For n > 1, a(n) is a Zumkeller number (A083207). Verified for all n in [2,63]. - Ivan N. Ianakiev, Jan 25 2023

Examples

			a(26) = 113315400: sigma = 426535200, phi = 26726400, quotient = 4.
		

References

  • Richard K. Guy, Unsolved Problems in Number Theory, 3rd Edition, Springer, 2004. See Section B42, p. 151.
  • Zhang Ming-Zhi, typescript submitted to Unsolved Problems section of Monthly, 96-01-10.

Crossrefs

Programs

  • Mathematica
    Do[If[Mod[DivisorSigma[1, n]+EulerPhi[n], n]==0, Print[n]], {n, 1, 2*10^7}]
    Do[ If[ ! PrimeQ[n] && Mod[ DivisorSigma[1, n] + EulerPhi[n], n] == 0, Print[n] ], {n, 1, 10^8} ]
  • PARI
    sp(n)=my(f=factor(n));n*prod(i=1, #f[,1], 1-1/f[i,1]) + prod(i=1, #f[,1], (f[i,1]^(f[i,2]+1)-1)/(f[i,1]-1))
    p=2;forprime(q=3, 1e6, for(n=p+1, q-1, if(sp(n)%n==0, print1(n", ")));p=q) \\ Charles R Greathouse IV, Mar 19 2012

Extensions

More terms from David W. Wilson
Corrected by Labos Elemer, Feb 12 2004

A015702 Numbers k where phi(k) + sigma(k) increases to a record value.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 8, 10, 12, 16, 18, 20, 24, 30, 36, 40, 42, 48, 56, 60, 72, 84, 90, 96, 108, 120, 144, 168, 180, 210, 216, 240, 280, 288, 300, 324, 336, 360, 420, 480, 504, 540, 576, 600, 648, 660, 672, 720, 840, 960, 1008, 1080, 1200, 1260, 1440
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    seq = {}; sm = 0; s = 0; Do[s = EulerPhi[n] + DivisorSigma[1, n];
    If[s > sm, sm = s; AppendTo[seq, n]], {n, 1, 1500}]; seq (* Amiram Eldar, Dec 05 2018 *)
    DeleteDuplicates[Table[{n,EulerPhi[n]+DivisorSigma[1,n]},{n,1500}],GreaterEqual[ #1[[2]],#2[[2]]]&][[;;,1]] (* Harvey P. Dale, Mar 13 2023 *)
  • PARI
    f(n)=eulerphi(n=factor(n))+sigma(n)
    r=0;for(n=1,1e6,t=f(n); if(t>r,r=t; print1(n", "))) \\ Charles R Greathouse IV, Nov 27 2013

A073815 Least number x such that gcd(phi(x), sigma(x)) = n.

Original entry on oeis.org

1, 3, 18, 12, 200, 14, 3364, 15, 722, 328, 9801, 42, 25281, 116, 1800, 165, 36992, 810, 4414201, 88, 196, 29161, 541696, 35, 2928200, 1413, 103968, 172, 98942809, 488, 1547536, 336, 19602, 17536, 814088, 370, 49042009, 55297, 1521, 319, 3150464641
Offset: 1

Views

Author

Labos Elemer, Nov 12 2002

Keywords

Comments

Values are frequently identical to terms of A077102. Since gcd(a,b) and gcd(a+b,a-b) may differ, so may the smallest solutions. A077102(m) and a(m) differ at m = 1, 2, 4, 8, 16, 28, 32, 40, etc.

Crossrefs

Programs

  • Mathematica
    f[x_] := Apply[GCD, {DivisorSigma[1, x], EulerPhi[x]}] t=Table[0, {100}]; Do[s=f[n]; If[s<101&&t[[s]]==0, t[[s]]=n], {n, 1, 10^13}];
  • PARI
    a(n)=my(x=n);while(gcd(eulerphi(x),sigma(x))!=n, x++); x \\ Charles R Greathouse IV, Dec 09 2013

Formula

a(n) = Min{x; A055008(x)=n}. a(n)=Min{x; gcd(A000203(x), A000010(x))=n}
a(n) = Min{x: A023897(x)= n}, smallest balanced number (A020492) for which the quotient equals n.

A066198 Numbers n where phi changes as fast as sigma, i.e., abs(phi(n+1) - phi(n)) = abs(sigma(n+1) - sigma(n)).

Original entry on oeis.org

2, 6, 8, 10, 22, 46, 58, 82, 106, 166, 178, 188, 226, 262, 285, 346, 358, 382, 466, 478, 502, 562, 586, 718, 838, 854, 862, 886, 902, 982, 1018, 1186, 1282, 1306, 1318, 1366, 1438, 1486, 1522, 1618, 1822, 1906, 2013, 2026, 2038, 2062, 2098, 2206, 2446, 2458
Offset: 1

Views

Author

Joseph L. Pe, Dec 16 2001

Keywords

Comments

This sequence is the union of two sequences A145748 and A145749. See comment lines of A145749. [Farideh Firoozbakht, Nov 01 2008]

Examples

			|phi(7) - phi(6)| = |6 - 2| = |8 - 12| = |sigma(7) - sigma(6)|.
|phi(9) - phi(8)| = |6 - 4| = 2 = |13 - 15| = |sigma(9) - sigma(8)|.
		

Crossrefs

Programs

  • Mathematica
    Select[ Range[ 1, 10^4 ], Abs[ DivisorSigma[ 1, # + 1 ] - DivisorSigma[ 1, # ] ] == Abs[ EulerPhi[ # + 1 ] - EulerPhi[ # ] ] & ]
  • PARI
    { n=0; for (m=1, 10^9, if (abs(eulerphi(m + 1) - eulerphi(m)) == abs(sigma(m + 1) - sigma(m)), write("b066198.txt", n++, " ", m); if (n==1000, return)) ) } \\ Harry J. Smith, Feb 05 2010

Extensions

More terms from Jason Earls, Jun 05 2002

A077085 Initial values such that if A077080(x)=phi(sigma(x)+phi(x)) is started at these numbers then the sequence does not converge.

Original entry on oeis.org

534, 556, 557, 580, 624, 702, 710, 738, 739, 740, 748, 784, 789, 822, 823, 841, 852, 853, 900, 912, 913, 916, 924, 931, 938, 960, 961, 962, 1020, 1021, 1029, 1032, 1033, 1034, 1065, 1089, 1092, 1093, 1098, 1126, 1136
Offset: 1

Views

Author

Labos Elemer, Oct 28 2002

Keywords

Comments

These terms are only conjectures.
These terms survive 1000 iterations. - Sean A. Irvine, May 05 2025

Crossrefs

Programs

  • Mathematica
    f[x_] := EulerPhi[DivisorSigma[1, x]+EulerPhi[x]] Do[s=Part[NestList[f, n, 100], 100]; If[Greater[s, 10000000], Print[{n, s}]], {n, 1, 10000}]

A067351 Numbers k such that sigma(k) + phi(k) has exactly 2 distinct prime divisors.

Original entry on oeis.org

3, 5, 6, 7, 10, 11, 13, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 33, 35, 37, 39, 40, 41, 42, 43, 44, 46, 47, 49, 51, 52, 53, 55, 56, 57, 58, 59, 60, 61, 64, 66, 67, 68, 71, 72, 73, 75, 76, 78, 79, 80, 81, 82, 83, 84, 85, 87, 89, 91, 92, 93, 95, 96, 97
Offset: 1

Views

Author

Labos Elemer, Jan 17 2002

Keywords

Examples

			Includes all odd primes and some composites; e.g., 21 and 25, since sigma(21) + phi(21) = 32 + 12 = 44 = 2*2*11; sigma(25) + phi(25) = 31 + 20 = 51 = 3*17.
		

Crossrefs

Programs

  • Mathematica
    Select[ Range[ 1, 100 ], Length[ FactorInteger[ DivisorSigma[ 1, # ]+EulerPhi[ # ] ] ]==2& ]
    Select[Range[500], PrimeNu[EulerPhi[#] + DivisorSigma[1, #]] == 2 &] (* G. C. Greubel, May 08 2017 *)

Formula

a(n) = A001221(A000010(n) + A000203(n)) = A001221(A065387(n)) = 2.

Extensions

Edited by Dean Hickerson, Jan 20 2002

A071390 Least number m such that sigma(m) - phi(m) = n, or 0 if no such m exists.

Original entry on oeis.org

0, 2, 0, 0, 4, 0, 9, 0, 0, 6, 8, 0, 0, 10, 49, 15, 0, 14, 0, 21, 0, 27, 16, 12, 0, 22, 169, 33, 0, 26, 0, 39, 18, 20, 289, 65, 0, 34, 361, 51, 0, 38, 0, 28, 0, 0, 32, 95, 0, 46, 0, 24, 0, 45, 0, 115, 0, 0, 841, 161, 0, 58, 961, 30, 0, 62, 81, 63, 0, 0, 0, 155, 50, 40, 1369, 217, 0, 74
Offset: 1

Views

Author

Labos Elemer, May 23 2002

Keywords

Comments

For n <> 2, a(n) < n^2/4. - Robert Israel, Apr 02 2020

Examples

			n=255: a(255) = 16129 = 127^2, sigma(16129) = 16257, phi(16129) = 16002, 16257 - 16002 = 255 = n. Squares of primes are often solutions (4, 9, 49, 169, 289, 361, etc.).
		

Crossrefs

Programs

  • Maple
    N:= 100: # for a(1)..a(N)
    V:= Vector(N):
    for m from 2 to N^2/4 do
      v:= numtheory:-sigma(m)-numtheory:-phi(m);
      if v <= N and V[v]=0 then V[v]:= m fi
    od:
    convert(V,list); # Robert Israel, Apr 02 2020
  • Mathematica
    f[x_] := DivisorSigma[1, x]-EulerPhi[x] t=Table[0, {100}]; Do[c=f[n]; If[c<101&&t[[c]]==0, t[[c]]=n], {n, 1, 1000}]; t

Formula

a(n) = Min{x; A000203(x)-A000010(x)=n} or a(n)=0 if no solution exists.

A270837 Numbers k such that sigma(k-1) + phi(k-1) = (5*k-7)/2.

Original entry on oeis.org

3, 5, 7, 9, 17, 33, 65, 67, 129, 257, 513, 1025, 2049, 4097, 8193, 16385, 32769, 65537, 131073, 262145, 524289, 1048577, 2097153, 4194305, 8388609, 16777217, 33554433, 67108865, 134217729, 268435457, 536870913, 1073741825, 2147483649, 4294967297, 5606129563
Offset: 1

Views

Author

Jaroslav Krizek, Mar 23 2016

Keywords

Comments

Numbers k such that A065387(k-1) = (5*k-7)/2.
Numbers of the form 2^k + 1 for k >= 1 from A000051 are terms.
Prime terms are in A270779.

Examples

			17 is a term because sigma(16)+phi(16) = 31+8 = 39 = (5*17-7)/2.
		

Crossrefs

Programs

  • Magma
    [n: n in[2..10^7] | 2*(SumOfDivisors(n-1) + EulerPhi(n-1)) eq 5*n-7];
    
  • Mathematica
    Select[Range[10^6], DivisorSigma[1, # - 1] + EulerPhi[# - 1] == (5 # - 7)/2 &] (* Michael De Vlieger, Mar 24 2016 *)
  • PARI
    lista(nn) = {for(n=2, nn, if(sigma(n-1) + eulerphi(n-1) == (5*n-7)/2, print1(n, ", "))); } \\ Altug Alkan, Mar 23 2016

Extensions

a(29)-a(31) from Michel Marcus, Apr 05 2016
a(32)-a(35) from Giovanni Resta, Apr 11 2016

A061367 Composite n such that sigma(n)-phi(n) divides sigma(n)+phi(n).

Original entry on oeis.org

15, 35, 95, 119, 143, 209, 287, 319, 323, 357, 377, 527, 559, 779, 899, 923, 989, 1007, 1045, 1189, 1199, 1343, 1349, 1763, 1919, 2159, 2261, 2507, 2639, 2759, 2911, 3239, 3339, 3553, 3599, 3827, 4031, 4147, 4607, 5049, 5183, 5207, 5249, 5459, 5543, 6439
Offset: 1

Views

Author

Joseph L. Pe, Feb 13 2002

Keywords

Comments

Primes trivially satisfy the defining condition.

Examples

			sigma(15)-phi(15) = 24-8 = 16 divides sigma(15)-phi(15)=24+8 = 32, so 15 is a term of the sequence.
		

Crossrefs

Programs

  • Mathematica
    f[n_] := Module[{a = DivisorSigma[1, n], b = EulerPhi[n]}, Mod[(a + b), (a - b)] == 0]; Select[Range[2, 10^4], (f[ # ] && ! PrimeQ[ # ]) &]
    cnQ[n_]:=With[{s=DivisorSigma[1,n],p=EulerPhi[n]},Mod[s+p,s-p]==0]; Select[Range[6500],CompositeQ[#]&&cnQ[#]&] (* Harvey P. Dale, Jun 14 2025 *)

Formula

It seems that a(n) is asymptotic to c*n^2, 22*n^2. - Benoit Cloitre, Sep 17 2002
Previous Showing 11-20 of 42 results. Next