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.

A347366 Primes that are partial sums of the semiprimes.

Original entry on oeis.org

19, 29, 43, 79, 101, 331, 647, 709, 2039, 4723, 5261, 5827, 10271, 11057, 12163, 12743, 20183, 22039, 22807, 25999, 30319, 33563, 44777, 45319, 56843, 60623, 61927, 73583, 83077, 108013, 133447, 142183, 159541, 182659, 191833, 204803, 214463, 215689, 248789, 266239, 292573, 302593, 314339, 318823
Offset: 1

Views

Author

J. M. Bergot and Robert Israel, Aug 29 2021

Keywords

Examples

			a(3) = 43 is a term because 43 = A062198(5) is prime.
		

Crossrefs

Primes in A062198. Cf. A001358.

Programs

  • Maple
    SP:= select(t -> numtheory:-bigomega(t) = 2, [$2..10000]):
    PSSP:= ListTools:-PartialSums(SP):
    select(isprime,PSSP);
  • Mathematica
    Select[Accumulate @ Select[Range[1500], PrimeOmega[#] == 2 &], PrimeQ] (* Amiram Eldar, Aug 29 2021 *)
  • Python
    from sympy import factorint, isprime
    def aupto(limit):
        alst, k, s = [], 1, 0
        for k in range(1, limit+1):
            if sum(factorint(k).values()) == 2:
                s += k
                if s > limit: break
                if isprime(s): alst.append(s)
        return alst
    print(aupto(320000)) # Michael S. Branicky, Aug 29 2021