login

Reminder: The OEIS is hiring a new managing editor, and the application deadline is January 26.

Odd composite numbers whose sum of prime factors is palindromic (counted with multiplicity).
3

%I #17 Apr 28 2018 07:44:27

%S 9,15,27,45,57,85,121,123,259,305,351,403,413,415,483,495,575,597,627,

%T 639,663,687,689,705,717,735,807,875,893,931,935,985,989,1073,1135,

%U 1183,1203,1207,1263,1285,1293,1331,1353,1383,1385,1407,1473,1505,1545

%N Odd composite numbers whose sum of prime factors is palindromic (counted with multiplicity).

%H John Cerkan, <a href="/A046353/b046353.txt">Table of n, a(n) for n = 1..10000</a>

%e 689 = 13 * 53 -> 13 + 53 = 66 and 66 is a palindrome.

%t palQ[n_]:=Reverse[x=IntegerDigits[n]]==x; Select[Range[9,1545,2],!PrimeQ[#]&&palQ[Total[Times@@@FactorInteger[#]]]&] (* _Jayanta Basu_, Jun 05 2013 *)

%o (Python)

%o from sympy import factorint

%o def is_046353(n):

%o if n % 2 == 0: return False

%o f = factorint(n)

%o if sum([f[i] for i in f]) < 2: return False

%o sfa = sum([i*f[i] for i in f])

%o if sfa == int(str(sfa)[::-1]): return True

%o return False # _John Cerkan_, Apr 24 2018

%Y Cf. A046352, A046354.

%K nonn,base

%O 1,1

%A _Patrick De Geest_, Jun 15 1998

%E Name clarified and offset changed by _John Cerkan_, Apr 24 2018