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.

A350500 Even numbers that are both the sum of a twin prime pair and the sum of 1 and a semiprime.

Original entry on oeis.org

36, 120, 144, 204, 216, 300, 396, 624, 696, 924, 1044, 1140, 1200, 1644, 1656, 1764, 2124, 2184, 2604, 2856, 3216, 3240, 3444, 3744, 3756, 3900, 4056, 4164, 4224, 4536, 4620, 4764, 5184, 5316, 5460, 5580, 5604, 6000, 6240, 6504, 6516, 6744, 7116, 7344, 7836, 7860, 8004
Offset: 1

Views

Author

Wesley Ivan Hurt, Jan 01 2022

Keywords

Examples

			36 is in the sequence since 36 = 17+19 = 1+35.
120 is in the sequence since 120 = 59+61 = 1+119.
		

Crossrefs

Intersection of A054735 and A088707.
Cf. A349757.

Programs

  • Mathematica
    Select[12 * Range[700], And @@ PrimeQ[#/2 + {-1, 1}] && PrimeOmega[# - 1] == 2 &] (* Amiram Eldar, Jan 02 2022 *)
    Select[Total/@Select[Partition[Prime[Range[600]],2,1],#[[2]]-#[[1]]==2&],PrimeOmega[#-1]==2&] (* Harvey P. Dale, Feb 02 2025 *)
  • Python
    from sympy import isprime, factorint
    def ok(n): return n%2 == 0 and isprime(n//2-1) and isprime(n//2+1) and sum(factorint(n-1).values()) == 2
    print([k for k in range(8005) if ok(k)]) # Michael S. Branicky, Jan 02 2022