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.

A348017 Numbers k such that the numerator of the fractional part of the k-th harmonic is a prime number.

Original entry on oeis.org

3, 5, 7, 9, 10, 12, 19, 21, 24, 29, 34, 39, 45, 46, 54, 65, 84, 86, 116, 128, 161, 177, 248, 254, 274, 297, 349, 352, 412, 422, 475, 493, 636, 747, 793, 811, 855, 864, 1012, 1060, 1074, 1097, 1127, 1139, 1152, 1299, 1371, 1423, 1785, 1847, 1872, 1873, 2072, 2326
Offset: 1

Views

Author

Amiram Eldar, Sep 24 2021

Keywords

Comments

The corresponding primes are 5, 17, 83, 2089, 2341, 2861, 42503239, 3338549, 276977179, 2239777822987, ...

Examples

			3 is a term since 1 + 1/2 + 1/3 = 11/6, the fractional part of 11/6 is 5/6 and its numerator, 5, is prime.
5 is a term since 1 + 1/2 + 1/3 + 1/4 + 1/5 = 137/60, the fractional part of 137/60 is 17/60 and its numerator, 17, is prime.
		

Crossrefs

Programs

  • Mathematica
    s = 0; seq = {}; Do[s += 1/n; If[PrimeQ @ Numerator @ FractionalPart[s], AppendTo[seq, n]], {n, 1, 2500}]; seq
  • Python
    from sympy import harmonic, isprime
    A348017_list = [k for k in range(10**3) if isprime((lambda x: x.p % x.q)(harmonic(k)))] # Chai Wah Wu, Sep 26 2021
Showing 1-1 of 1 results.