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 A005078 #20 Jun 21 2022 05:09:33 %S A005078 0,0,0,0,5,0,0,0,0,5,0,0,13,0,5,0,17,0,0,5,0,0,0,0,5,13,0,0,29,5,0,0, %T A005078 0,17,5,0,37,0,13,5,41,0,0,0,5,0,0,0,0,5,17,13,53,0,5,0,0,29,0,5,61,0, %U A005078 0,0,18,0,0,17,0,5,0,0,73,37,5,0,0,13,0,5,0,41,0,0,22,0,29,0,89,5,13,0,0,0,5,0,97,0,0,5,101 %N A005078 Sum of primes = 1 mod 4 dividing n. %H A005078 Antti Karttunen, <a href="/A005078/b005078.txt">Table of n, a(n) for n = 1..10000</a> %F A005078 Additive with a(p^e) = p if p = 1 (mod 4), 0 otherwise. %F A005078 a(n) = A008472(n) - A005082(n) - 2*A059841(n). - _Antti Karttunen_, Jul 11 2017 %t A005078 Array[DivisorSum[#, # &, And[PrimeQ@ #, Mod[#, 4] == 1] &] &, 101] (* _Michael De Vlieger_, Jul 11 2017 *) %t A005078 f[p_, e_] := If[Mod[p, 4] == 1, p, 0]; a[n_] := Plus @@ f @@@ FactorInteger[n]; a[1] = 0; Array[a, 100] (* _Amiram Eldar_, Jun 21 2022 *) %o A005078 (PARI) a(n)=my(f=factor(n)[,1]); sum(i=1,#f,if(f[i]%4==1,f[i])) \\ _Charles R Greathouse IV_, Mar 11 2014 %o A005078 (Scheme) (define (A005078 n) (if (= 1 n) 0 (+ (if (= 1 (modulo (A020639 n) 4)) (A020639 n) 0) (A005078 (A028234 n))))) ;; _Antti Karttunen_, Jul 11 2017 %Y A005078 Cf. A005069, A005079, A005080, A005081, A005082, A008472, A059841. %K A005078 nonn %O A005078 1,5 %A A005078 _N. J. A. Sloane_ %E A005078 More terms from _Antti Karttunen_, Jul 11 2017