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 A078771 #15 May 03 2025 07:45:31 %S A078771 0,0,0,0,0,0,0,2,3,0,0,0,0,0,0,8,0,3,0,0,0,0,0,2,15,0,18,0,0,0,0,22,0, %T A078771 0,0,3,0,0,0,2,0,0,0,0,3,0,0,8,35,15,0,0,0,18,0,2,0,0,0,0,0,0,3,52,0, %U A078771 0,0,0,0,0,0,5,0,0,15,0,0,0,0,8,69,0,0,0,0,0,0,2,0,3,0,0,0,0,0,22,0,35,3,15 %N A078771 a(n) = A008475(n) - A001414(n). %C A078771 a(n) is not zero if n is in A046790. %H A078771 Antti Karttunen, <a href="/A078771/b078771.txt">Table of n, a(n) for n = 1..65537</a> %F A078771 Additive with a(p^e) = p^e - p*e. - _Amiram Eldar_, May 03 2025 %t A078771 Array[Total[Power @@@ #] - Total[Times @@@ #] &@ FactorInteger@ # &, 100] (* _Michael De Vlieger_, Nov 17 2017, after _Olivier Gérard_ at A008475 and _Ray Chandler_ at A001414 *) %o A078771 (PARI) %o A078771 A001414(n) = ((n=factor(n))[, 1]~*n[, 2]); \\ This function from _M. F. Hasler_, Feb 07 2009 %o A078771 A008475(n) = { my(f=factor(n)); vecsum(vector(#f~,i,f[i,1]^f[i,2])); }; %o A078771 A078771(n) = (A008475(n) - A001414(n)); \\ _Antti Karttunen_, Nov 17 2017 %o A078771 (PARI) a(n) = {my(f = factor(n)); sum(i = 1, #f~, f[i,1]^f[i,2] - f[i,1]*f[i,2]);} \\ _Amiram Eldar_, May 03 2025 %Y A078771 Cf. A001414, A008475, A046790. %K A078771 nonn %O A078771 1,8 %A A078771 _Benoit Cloitre_, Jan 11 2003