OFFSET
1,2
COMMENTS
Conjecture: every odd number, beginning with 3, is the sum of a prime number and a primitive practical number. This is a tighter conjecture than that posed by Hal M. Switkay (see comments of A005153).
EXAMPLE
a(61) = 20, because 61st odd number is 123 = {(10+113), (14+109), (16+107), (20+103), ...} and 20 is the least primitive practical number. 10 and 14 are not practical numbers and 16 is practical but not primitive.
MATHEMATICA
PracticalQ[n_] := Module[{f, p, e, prod=1, ok=True}, If[n<1 || (n>1 && OddQ[n]), False, If[n==1, True, f=FactorInteger[n]; {p, e}=Transpose[f]; Do[If[p[[i]]>1+DivisorSigma[1, prod], ok=False; Break[]]; prod=prod*p[[i]]^e[[i]], {i, Length[p]}]; ok]]];
DivFreeQ[n_] := Module[{plst=First/@Select[FactorInteger[n], #[[2]]>1 &], m, ok=False}, Do[If[! PracticalQ[n/plst[[m]]], ok=True, ok=False; Break[]], {m, 1, Length@plst}]; ok];
PPracticalQ[n_] := PracticalQ[n] && (SquareFreeQ[n] || DivFreeQ[n]);
part[n_, m_] := Module[{p = NextPrime[n, -m], d}, d = n - p; {d, p}];
find[n_] := Module[{m=1}, While[!PPracticalQ[part[n, m][[1]]], m++]; part[n, m]];
Table[find[2 n + 1][[1]], {n, 1, 1000}]
PROG
(Python)
from sympy import prevprime, factorint
def is_primitive(n):
for i in range(0, len(list(factorint(n)))):
if list(factorint(n).values())[i] > 1:
if is_A005153(n//list(factorint(n))[i]): return False
return True
def is_A267124(n):
if is_A005153(n) and is_primitive(n) : return True
A361301 = []
for odds in range(3, 192, 2):
prime = prevprime(odds)
while not is_A267124(odds - prime): prime = prevprime(prime)
A361301.append(odds - prime)
print(A361301) # Karl-Heinz Hofmann, Mar 10 2023
CROSSREFS
KEYWORD
nonn
AUTHOR
Frank M Jackson, Mar 08 2023
STATUS
approved