A384530 Intersection of A055932 and A014574.
4, 6, 12, 18, 30, 60, 72, 108, 150, 180, 192, 240, 270, 420, 432, 600, 810, 1050, 1152, 1620, 2310, 2592, 3000, 3360, 4050, 4800, 5880, 6300, 7350, 7560, 8820, 9000, 9240, 9720, 10500, 11550, 15360, 21600, 23040, 25410, 26250, 26880, 28350, 29400, 30870, 33600
Offset: 1
Keywords
Examples
4 is a term since 4 = prime(1)# * 2 is in A055932 and 4-1 = 3 and 4+1 = 5 are both prime. 6 is a term since 6 = prime(2)# is in A055932 and 6-1 = 5 and 6+1 = 7 are both prime. 30 is a term since 30 = prime(3)# is in A055932 and 30-1 = 29 and 30+1 = 31 are both prime. 420 is a term since 420 = prime(4)# * 2 is in A055932 and 420-1 = 419 and 420+1 = 421 are both prime.
Links
- Alois P. Heinz, Table of n, a(n) for n = 1..3719
Programs
-
Maple
q:= n-> andmap(isprime, [n-1, n+1]) and (s-> nops(s)= numtheory[pi](max(s)))({ifactors(n)[2][.., 1][]}): select(q, [$1..40000])[]; # Alois P. Heinz, Jun 01 2025
-
Python
from sympy import factorint, prime, isprime def is_pi_complete(n): # n is a term of A055932 if n <= 1: return False factors = factorint(n) primes = list(factors.keys()) max_prime, r = max(primes), len(primes) return max_prime == prime(r) def is_twin_prime_bracketed(n): # n is a term of A014574 return isprime(n-1) and isprime(n+1) def aupto(limit): return [n for n in range(4, limit+1, 2) if is_twin_prime_bracketed(n) and is_pi_complete(n)] print(aupto(40_000))
Comments