login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 


A005071
Sum of squares of primes = 1 mod 3 dividing n.
5
0, 0, 0, 0, 0, 0, 49, 0, 0, 0, 0, 0, 169, 49, 0, 0, 0, 0, 361, 0, 49, 0, 0, 0, 0, 169, 0, 49, 0, 0, 961, 0, 0, 0, 49, 0, 1369, 361, 169, 0, 0, 49, 1849, 0, 0, 0, 0, 0, 49, 0, 0, 169, 0, 0, 0, 49, 361, 0, 0, 0, 3721, 961, 49, 0, 169, 0, 4489, 0, 0, 49, 0, 0, 5329, 1369, 0, 361, 49, 169, 6241, 0, 0, 0, 0, 49, 0, 1849, 0, 0, 0, 0, 218
OFFSET
1,7
LINKS
FORMULA
Additive with a(p^e) = p^2 if p = 1 (mod 3), 0 otherwise.
MATHEMATICA
Module[{sp=Select[Prime[Range[100]], Mod[#, 3]==1&]}, Table[Total[ Select[ sp, Divisible[ n, #]&]^2], {n, 70}]] (* Harvey P. Dale, Dec 19 2014 *)
f[p_, e_] := If[Mod[p, 3] == 1, p^2, 0]; a[n_] := Plus @@ f @@@ FactorInteger[n]; a[1] = 0; Array[a, 100] (* Amiram Eldar, Jun 21 2022 *)
PROG
(Scheme) (define (A005071 n) (if (= 1 n) 0 (+ (A000290 (if (= 1 (modulo (A020639 n) 3)) (A020639 n) 0)) (A005071 (A028234 n))))) ;; Antti Karttunen, Jul 09 2017
CROSSREFS
KEYWORD
nonn
EXTENSIONS
More terms from Antti Karttunen, Jul 09 2017
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified September 22 23:47 EDT 2024. Contains 376140 sequences. (Running on oeis4.)