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 A325968 #11 Jun 02 2019 23:43:07 %S A325968 1,3,4,7,6,7,8,15,13,17,12,27,14,23,20,31,18,38,20,41,32,35,24,59,31, %T A325968 39,40,29,30,71,32,63,44,53,48,91,38,59,56,89,42,95,44,83,74,69,48, %U A325968 123,57,93,68,95,54,119,72,119,80,89,60,167,62,95,104,127,84,143,68,125,92,143,72,194,74,113,124,137,96,167,80,185,121,125 %N A325968 a(n) is the sum k of such a subset of divisors of n with the largest sum and for which n-k and n-(sigma(n)-k) are relatively prime. %H A325968 Antti Karttunen, <a href="/A325968/b325968.txt">Table of n, a(n) for n = 1..25000</a> %H A325968 <a href="/index/Si#SIGMAN">Index entries for sequences related to sigma(n)</a> %F A325968 a(n) = A000203(n) - A325967(n). %F A325968 a(n) = n + A325969(n). %F A325968 For all n: %F A325968 a(A000040(n)) = A000040(n)+1. %F A325968 a(A000396(n)) = A000396(n)+1. %F A325968 a(n) <= A325818(n). %e A325968 For n=15, its divisors are [1, 3, 5, 15]. If we take the full set [1, 3, 5, 15] and its complement [], their sums are 24 and 0, but gcd(15-0, 24-15) = gcd(15, 9) = 3 > 1. If we take subsets [1] and [3, 5, 15], then their sums are 1 and 23, but gcd(15-1, 23-15) = gcd(14,8) = 2 > 1. If we take subsets [3] and [1, 5, 15], their sums are 3 and 21, but gcd(15-3, 21-15) = gcd(12, 6) = 6 > 1. Only when we take the subset with the four smallest sum, [1, 3] and its complement [5, 15], we get such sums 4 and 20 for which gcd(15-4, 20-15) = gcd(11, 5) = 1. Thus a(15) = 20, the size of the subset with larger sum. %o A325968 (PARI) %o A325968 A325968(n) = { my(divs=divisors(n), s=sigma(n),r,ms=0); for(b=0,(2^(length(divs)))-1,r=sumbybits(divs,b);if(1==gcd(n-(s-r),n-r),ms=max(r,ms))); (ms); }; %o A325968 sumbybits(v,b) = { my(s=0,i=1); while(b>0,s += (b%2)*v[i]; i++; b >>= 1); (s); }; %Y A325968 Cf. A000040, A000203, A000396, A009194, A325807, A325818, A325967, A325969. %K A325968 nonn %O A325968 1,2 %A A325968 _Antti Karttunen_, May 29 2019