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 A387654 #8 Sep 05 2025 04:42:33 %S A387654 1,4095,5775,5984,11024,21735,21944,26144,39375,49664,58695,61424, %T A387654 69615,76544,79695,89775,91664,98175,104895,106784,111824,116655, %U A387654 116864,121904,134504,135135,144584,152775,155295,160544,165375,170624,174824,180495,185535,192464 %N A387654 Numbers k such that each of k and k+1 is either a practical number (A005153) or an almost practical number (A174533). %C A387654 Differs from A103289 by not having the terms 7424, 27404, 43064, 56924, 70784, ... . The first 344 terms of this sequence are in A103289. Is this sequence a subsequence of A103289? %C A387654 Differs from A096399 by not having the terms 7424, 27404, 43064, 56924, 70784, ... . The first 342 terms after 1 and 4095 are in A096399. Is this sequence \ {1, 4095} a subsequence of A096399? %C A387654 Terms k such that both k and k+1 are almost practical numbers are in A387653. %C A387654 The only pair of consecutive integers that are both practical is 1 and 2, since 1 is the only odd practical number. %C A387654 All the rest are pairs in which one member (the odd member) is almost practical and the second member (the even member) is practical. %C A387654 Are there 3 consecutive numbers that are all either practical or almost practical? There are none below 2.8*10^6. %H A387654 Amiram Eldar, <a href="/A387654/b387654.txt">Table of n, a(n) for n = 1..344</a> %t A387654 q[n_] := q[n] = Module[{d = Divisors[n], c, x}, c = CoefficientList[Product[1 + x^i, {i, d}], x]; MemberQ[{0, 2}, Total[d] - Count[Rest[c], _?(# > 0 &)]]]; %t A387654 Select[Range[40000], q[#] && q[#+1] &] (* warning: a slow program *) %o A387654 (PARI) isp(k) = {my(d = divisors(k), nd = #d, s = vecsum(d), p = prod(i = 1, nd, 1 + 'x^d[i])); abs(#select(x -> x > 0, Col(p)) - s) == 1;} %o A387654 list(kmax) = {my(is1 = 1, is2); for(k = 2, kmax, is2 = isp(k); if(is1 && is2, print1(k-1, ", ")); is1 = is2);} \\ warning: a slow program %Y A387654 Cf. A005153, A096399, A103289, A174533, A287681. %Y A387654 A387653 is subsequence. %K A387654 nonn,new %O A387654 1,2 %A A387654 _Amiram Eldar_, Sep 05 2025