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

A065824 Smallest solution m to (n+1)*phi(m) = n*sigma(m), or -1 if no solution exists.

Original entry on oeis.org

3, 5, 7, 323, 11, 13, 899, 17, 19, 1763, 23, 5249, 3239, 29, 31, 979801, 5459, 37, 10763, 41, 43, 9179, 47, 9701, 10403, 53, 12319, 5646547, 59, 61, 24569, 19109, 67, 19043, 71, 73, 22499, 50819, 79, 41309, 83, 32639, 46979, 89, 34579, 39059, 125969
Offset: 1

Views

Author

Labos Elemer, Nov 23 2001

Keywords

Comments

If p = a(n) is a prime solution, then (n+1)*(p-1) = n*(p+1) and p = 2n+1, so position for p if it is in fact a minimal solution is at n = (p-1)/2. E.g. 29 appears at 14th position shown by A005097. On the other hand large and (seemingly always composite) solutions arise at indices shown essentially by A047845. Also, differences between the sites of two consecutive small prime solutions appears to be d/2, half the difference between consecutive primes (A001223).

Crossrefs

Programs

  • Mathematica
    max = 10^7; a[n_] := For[m = 3, m <= max, m++, If[(n+1)*EulerPhi[m] == n*DivisorSigma[1, m], Print[m]; Return[m]]] /. Null -> -1; Array[a, 50] (* Jean-François Alcover, Oct 08 2016 *)
  • Python
    from itertools import count
    from math import prod
    from sympy import factorint
    def A065824(n):
        for m in count(1):
            f = factorint(m)
            if (n+1)*m*prod((p-1)**2 for p in f)==n*prod(p**(e+2)-p for p,e in f.items()):
                return m # Chai Wah Wu, Aug 12 2024

Formula

(n+1)*A000010(a(n)) = n*A000203(a(n)), smallest x=a(n) solutions.
Showing 1-1 of 1 results.