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-6 of 6 results.

A083254 a(n) = 2*phi(n) - n.

Original entry on oeis.org

1, 0, 1, 0, 3, -2, 5, 0, 3, -2, 9, -4, 11, -2, 1, 0, 15, -6, 17, -4, 3, -2, 21, -8, 15, -2, 9, -4, 27, -14, 29, 0, 7, -2, 13, -12, 35, -2, 9, -8, 39, -18, 41, -4, 3, -2, 45, -16, 35, -10, 13, -4, 51, -18, 25, -8, 15, -2, 57, -28, 59, -2, 9, 0, 31, -26, 65, -4, 19, -22, 69, -24, 71, -2, 5, -4, 43, -30, 77, -16, 27, -2, 81, -36, 43, -2, 25
Offset: 1

Views

Author

Labos Elemer, May 08 2003

Keywords

Comments

Möbius transform of A033879, deficiency of n. - Antti Karttunen, Dec 26 2017

Examples

			Case 1# - totient(x)-cototient[x] = 0 if x is a power of 2;
Case 2# - totient(x)>cototient[x] gives odd primes and also A067800, (= A014076 except probably A036798); e.g. n = 33: a(33) = 2.20-33 = 7; n = p prime: a(p) = p-2;
Case 3# - totient(x)<cototient[x] gives even numbers without powers of 2 and most probably A036798; e.g. n = 20: a(20) = -4; n = 105: a(105) = 2.48-105 = 96-105 = -9.
		

Crossrefs

Programs

Formula

a(n) = totient(n) - cototient(n) = A000010(n) - A051953(n).
From Antti Karttunen, Dec 26 2017: (Start)
a(n) = A065620(A297153(n)) = A117966(A297154(n)).
a(n) = A297114(n) + A297115(n).
a(2n) = A297114(2n).
For all n >= 1, -a(A000010(n)) = A293516(n).
(End)
Sum_{k=1..n} a(k) ~ c * n^2, where c = 6/Pi^2 - 1/2 = 0.107927... . - Amiram Eldar, Sep 07 2023

A083260 a(n) = gcd(A046523(n), A071364(n)).

Original entry on oeis.org

1, 2, 2, 4, 2, 6, 2, 8, 4, 6, 2, 12, 2, 6, 6, 16, 2, 6, 2, 12, 6, 6, 2, 24, 4, 6, 8, 12, 2, 30, 2, 32, 6, 6, 6, 36, 2, 6, 6, 24, 2, 30, 2, 12, 12, 6, 2, 48, 4, 6, 6, 12, 2, 6, 6, 24, 6, 6, 2, 60, 2, 6, 12, 64, 6, 30, 2, 12, 6, 30, 2, 72, 2, 6, 6, 12, 6, 30, 2, 48, 16, 6, 2, 60, 6, 6, 6, 24, 2, 30, 6
Offset: 1

Views

Author

Labos Elemer, May 09 2003

Keywords

Crossrefs

Programs

A083258 a(n) = gcd(A046523(n), n).

Original entry on oeis.org

1, 2, 1, 4, 1, 6, 1, 8, 1, 2, 1, 12, 1, 2, 3, 16, 1, 6, 1, 4, 3, 2, 1, 24, 1, 2, 1, 4, 1, 30, 1, 32, 3, 2, 1, 36, 1, 2, 3, 8, 1, 6, 1, 4, 3, 2, 1, 48, 1, 2, 3, 4, 1, 6, 1, 8, 3, 2, 1, 60, 1, 2, 3, 64, 1, 6, 1, 4, 3, 10, 1, 72, 1, 2, 3, 4, 1, 6, 1, 16, 1, 2, 1, 12, 1, 2, 3, 8, 1, 30, 1, 4, 3, 2, 1, 96, 1, 2
Offset: 1

Views

Author

Labos Elemer, May 09 2003

Keywords

Crossrefs

Programs

  • Mathematica
    Table[GCD[n, Times @@ MapIndexed[Prime[First[#2]]^#1 &, Sort[FactorInteger[n][[All, -1]], Greater]]], {n, 98}] (* Michael De Vlieger, May 21 2017 *)
  • PARI
    A046523(n) = { my(f=vecsort(factor(n)[, 2], , 4), p); prod(i=1, #f, (p=nextprime(p+1))^f[i]); };  \\ This function from Charles R Greathouse IV, Aug 17 2011
    A083258(n) = gcd(n,A046523(n)); \\ Antti Karttunen, May 21 2017

A083259 a(n) = gcd(n, A071364(n)), where A071364(n) is the smallest number with same sequence of exponents in canonical prime factorization as n.

Original entry on oeis.org

1, 2, 1, 4, 1, 6, 1, 8, 1, 2, 1, 12, 1, 2, 3, 16, 1, 18, 1, 4, 3, 2, 1, 24, 1, 2, 1, 4, 1, 30, 1, 32, 3, 2, 1, 36, 1, 2, 3, 8, 1, 6, 1, 4, 3, 2, 1, 48, 1, 2, 3, 4, 1, 54, 1, 8, 3, 2, 1, 60, 1, 2, 3, 64, 1, 6, 1, 4, 3, 10, 1, 72, 1, 2, 3, 4, 1, 6, 1, 16, 1, 2, 1, 12, 1, 2, 3, 8, 1, 90, 1, 4, 3, 2, 1, 96, 1
Offset: 1

Views

Author

Labos Elemer, May 09 2003

Keywords

Crossrefs

Programs

A083261 a(n) = gcd(A046523(n+1), A046523(n)).

Original entry on oeis.org

1, 2, 2, 2, 2, 2, 2, 4, 2, 2, 2, 2, 2, 6, 2, 2, 2, 2, 2, 6, 6, 2, 2, 4, 2, 2, 4, 2, 2, 2, 2, 2, 6, 6, 6, 2, 2, 6, 6, 2, 2, 2, 2, 12, 6, 2, 2, 4, 4, 6, 6, 2, 2, 6, 6, 6, 6, 2, 2, 2, 2, 6, 4, 2, 6, 2, 2, 6, 6, 2, 2, 2, 2, 6, 12, 6, 6, 2, 2, 16, 2, 2, 2, 6, 6, 6, 6, 2, 2, 6, 6, 6, 6, 6, 6, 2, 2, 12, 12, 2, 2, 2, 2
Offset: 1

Views

Author

Labos Elemer, May 09 2003

Keywords

Crossrefs

Programs

A233466 Numbers k such that phi(k) = (k-5)/2.

Original entry on oeis.org

165, 64005, 6992962170388485, 18446744047939747845
Offset: 1

Views

Author

Farideh Firoozbakht, Dec 26 2013

Keywords

Comments

According to the following theorem I discovered recently, the 20-digit number 18446744047939747845 is in the sequence.
Theorem: If k and m are integers, k < 6, and p = 2^2^k + m is a prime such that p does not divide 2^2^k-1, then p*(2^2^k-1) is a solution to the equation phi(x) = (x+m)/2.
Note that m cannot be -1 and for k < 6, 2^2^k-1 is the product of the first k Fermat primes.
Take m=-5; since 2^2^2-5, 2^2^3-5 and 2^2^5-5 are prime we get three terms of the sequence.
Take m=1; since 2^2^0+1, 2^2^1+1, 2^2^2+1, 2^2^3+1 and 2^2^4+1 are prime (Fermat primes) we get five terms of the sequence A050474.
Conjecture (i): There is no solution to the equation phi(x) = (x-1)/2.
Conjecture (ii): The sequence has only three terms and a(3) = (2^2^5-5) * (2^2^5-1) = 18446744047939747845.
Conjecture (i) is a part of Lehmer's totient problem. Conjecture (ii) is disproved with the term a(3) = 6992962170388485 = 3 * 5 * 17 * 353 * 929 * 83623931. - Max Alekseyev, Oct 28 2023
a(5) <= 202317618492499837497376768005 = 3 * 5 * 17 * 257 * 65951 * 10414721 * 4494603392933. - Max Alekseyev, Oct 30 2023

Examples

			phi(165) = 80 = (165-5)/2.
		

Crossrefs

Subsequence of A083255. - R. J. Mathar, Jan 13 2014

Programs

  • Mathematica
    Do[If[EulerPhi[n]==1/2(n-5),Print[n]],{n,1,70001,4}]
  • PARI
    is(n)=eulerphi(n)==(n-5)/2 \\ Charles R Greathouse IV, Jan 20 2014
    
  • Python
    from itertools import islice, count
    from sympy import totient
    def A233466gen(): return filter(lambda n:2*totient(n) == n-5,count(1,2))
    A233466_list = list(islice(A233466gen(),2)) # Chai Wah Wu, Dec 15 2021

Extensions

Missing term a(3) inserted, a(4) confirmed by Max Alekseyev, Oct 28 2023
Showing 1-6 of 6 results.