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.
%I A087991 #32 Apr 17 2025 08:09:01 %S A087991 0,0,0,0,0,0,0,0,0,1,0,1,1,1,1,1,1,1,1,2,1,0,1,2,1,2,1,2,1,3,1,2,0,2, %T A087991 1,3,1,2,2,3,1,3,1,0,2,2,1,4,1,3,2,3,1,3,0,3,2,2,1,6,1,2,2,3,2,0,1,3, %U A087991 2,4,1,5,1,2,3,3,0,4,1,5,2,2,1,6,2,2,2,0,1,6,2,3,2,2,2,6,1,3,0,5,0,4,1,4,4 %N A087991 Number of non-palindromic divisors of n. %H A087991 Indranil Ghosh, <a href="/A087991/b087991.txt">Table of n, a(n) for n = 1..10000</a> %F A087991 a(n) = A000005(n) - A087990(n). %F A087991 Sum_{k=1..n} a(k) ~ n * (log(n) + c), where c = 2*A001620 - 1 - A118031 = -3.2158519... . - _Amiram Eldar_, Apr 17 2025 %e A087991 For n = 132: divisors = {1,2,3,4,6,11,12,22,33,44,66,132}, revdivisors = {1,2,3,4,6,11,21,22,33,44,66,231}, two of the 12 divisors of n are non-palindromic: {21,132}, so a(132) = 2. %t A087991 palQ[n_] := Reverse[x = IntegerDigits[n]] == x; Table[Count[Divisors[n], _?(! palQ[#] &)], {n, 105}] (* _Jayanta Basu_, Aug 10 2013 *) %o A087991 (Python) %o A087991 def ispal(n): %o A087991 w=str(n) %o A087991 return w==w[::-1] %o A087991 def A087991(n): %o A087991 s = 0 %o A087991 for i in range(1, n+1): %o A087991 if n%i==0 and not ispal(i): %o A087991 s+=1 %o A087991 return s %o A087991 print([A087991(n) for n in range(1,60)]) # _Indranil Ghosh_, Feb 10 2017 %Y A087991 Cf. A000005, A087990, A062687. %Y A087991 Cf. A001620, A118031. %K A087991 nonn,base %O A087991 1,20 %A A087991 _Labos Elemer_, Oct 08 2003