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 A309491 #16 Dec 28 2019 17:02:37 %S A309491 0,1,1,3,1,6,1,8,5,10,1,17,1,14,11,20,1,26,1,29,15,22,1,44,9,26,21,41, %T A309491 1,56,1,48,23,34,17,73,1,38,27,76,1,80,1,65,51,46,1,108,13,74,35,77,1, %U A309491 102,25,108,39,58,1,157,1 %N A309491 Let gcd_2(b,c) be the second-largest common divisor of non-coprime integers b and c; then a(n) = Sum_{k=1..n} gcd_2(k,n). If b and c are coprime, then gcd_2(b,c) = 0. %C A309491 The first even solution of the equation a(n) = n which divided by 2 is not a prime number is 8. Is there a larger such number? If such a number exists, is greater than 5*10^4. If no such number exists, consecutive even solutions of the above equation are consecutive terms of A073582. %H A309491 Antti Karttunen, <a href="/A309491/b309491.txt">Table of n, a(n) for n = 1..10080</a> %H A309491 Antti Karttunen, <a href="/A309491/a309491.txt">Data supplement: n, a(n) computed for n = 1..65537</a> %e A309491 a(4) = gcd_2(1,4) + gcd_2(2,4) + gcd_2(3,4) + gcd_2(4,4) = 0 + 1 + 0 + 2 = 3. %t A309491 r[n_] := If[n==1, 0, n/FactorInteger[n][[1, 1]]]; a[n_] := Sum[r[GCD[n, k]], {k, 1, n}]; Array[a, 70] (* _Amiram Eldar_, Aug 06 2019 *) %o A309491 (PARI) %o A309491 A032742with_a1_0(n) = if(1==n,0,n/vecmin(factor(n)[,1])); %o A309491 gcd_2(a,b) = A032742with_a1_0(gcd(a,b)); %o A309491 A309491(n) = sum(k=1,n,gcd_2(k,n)); \\ _Antti Karttunen_, Dec 28 2019 %Y A309491 Cf. A018804, A073582. %K A309491 nonn %O A309491 1,4 %A A309491 _Lechoslaw Ratajczak_, Aug 04 2019 %E A309491 Definition clarified by _Antti Karttunen_, Dec 28 2019