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 A334903 #8 May 17 2020 02:15:31 %S A334903 6,40,54,918,1240,1288,1408,1480,1672,1720,1768,1974,2440,2728,2838, %T A334903 2968,3198,3318,4134,4264,4422,4480,4758,5248,6102,6270,6424,7590, %U A334903 7830,10624,11128,13110,13182,14248,15496,15928,16254,16768,18088,19864,21112,21318,21630 %N A334903 Numbers k such that k and k+2 are both infinitary practical numbers (A334901). %H A334903 Amiram Eldar, <a href="/A334903/b334903.txt">Table of n, a(n) for n = 1..10000</a> %e A334903 6 is a term since 6 and 6 + 2 = 8 are both infinitary practical numbers. %t A334903 bin[n_] := 2^(-1 + Position[Reverse @ IntegerDigits[n, 2], _?(# == 1 &)] // Flatten); f[p_, e_] := p^bin[e]; icomp[n_] := Flatten[f @@@ FactorInteger[n]]; fun[p_, e_] := Module[{b = IntegerDigits[e, 2]}, m = Length[b]; Product[If[b[[j]] > 0, 1 + p^(2^(m - j)), 1], {j, 1, m}]]; isigma[1] = 1; isigma[n_] := Times @@ fun @@@ FactorInteger[n]; infPracQ[n_] := Module[{f, p, e, prod = 1, ok = True}, If[n < 1 || (n > 1 && OddQ[n]), False, If[n == 1, True, r = Sort[icomp[n]]; Do[If[r[[i]] > 1 + isigma[prod], ok = False; Break[]]; prod = prod*r[[i]], {i, Length[r]}]; ok]]]; seq = {}; q1 = infPracQ[2]; Do[q2 = infPracQ[n]; If[q1 && q2, AppendTo[seq, n - 2]]; q1 = q2, {n, 4, 10^4, 2}]; seq %Y A334903 Cf. A287681, A330871, A334882, A334900, A334901. %K A334903 nonn %O A334903 1,1 %A A334903 _Amiram Eldar_, May 16 2020