A348017 Numbers k such that the numerator of the fractional part of the k-th harmonic is a prime number.
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
Keywords
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.
Links
- Amiram Eldar, Table of n, a(n) for n = 1..96
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
Comments