cp's OEIS Frontend

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.

Showing 1-6 of 6 results.

A005063 Sum of squares of primes dividing n.

Original entry on oeis.org

0, 4, 9, 4, 25, 13, 49, 4, 9, 29, 121, 13, 169, 53, 34, 4, 289, 13, 361, 29, 58, 125, 529, 13, 25, 173, 9, 53, 841, 38, 961, 4, 130, 293, 74, 13, 1369, 365, 178, 29, 1681, 62, 1849, 125, 34, 533, 2209, 13, 49, 29, 298, 173, 2809, 13, 146, 53, 370, 845, 3481, 38, 3721
Offset: 1

Views

Author

Keywords

Comments

The set of these terms apart from 0 is A048261. - Bernard Schott, Feb 10 2022
Inverse Möbius transform of n^2 * c(n), where c(n) is the prime characteristic (A010051). - Wesley Ivan Hurt, Jun 22 2024

Crossrefs

Sum of the k-th powers of the primes dividing n for k=0..10 : A001221 (k=0), A008472 (k=1), this sequence (k=2), A005064 (k=3), A005065 (k=4), A351193 (k=5), A351194 (k=6), A351195 (k=7), this sequence (k=8), A351197 (k=9), A351198 (k=10).
Cf. A010051.

Programs

Formula

Additive with a(p^e) = p^2.
G.f.: Sum_{k>=1} prime(k)^2*x^prime(k)/(1 - x^prime(k)). - Ilya Gutkovskiy, Dec 24 2016
From Antti Karttunen, Jul 11 2017: (Start)
a(n) = A005066(n) + 4*A059841(n).
a(n) = A005079(n) + A005083(n) + 4*A059841(n).
a(n) = A005071(n) + A005075(n) + 9*A079978(n).
(End)
Dirichlet g.f.: primezeta(s-2)*zeta(s). - Benedict W. J. Irwin, Jul 11 2018
a(n) = Sum_{p|n, p prime} p^2. - Wesley Ivan Hurt, Feb 04 2022
a(n) = Sum_{d|n} d^2 * c(d), where c = A010051. - Wesley Ivan Hurt, Jun 22 2024

Extensions

More terms from Franklin T. Adams-Watters, May 03 2009

A005079 Sum of squares of primes = 1 mod 4 dividing n.

Original entry on oeis.org

0, 0, 0, 0, 25, 0, 0, 0, 0, 25, 0, 0, 169, 0, 25, 0, 289, 0, 0, 25, 0, 0, 0, 0, 25, 169, 0, 0, 841, 25, 0, 0, 0, 289, 25, 0, 1369, 0, 169, 25, 1681, 0, 0, 0, 25, 0, 0, 0, 0, 25, 289, 169, 2809, 0, 25, 0, 0, 841, 0, 25, 3721, 0, 0, 0, 194, 0, 0, 289, 0, 25, 0, 0, 5329, 1369, 25, 0, 0, 169, 0, 25, 0, 1681, 0, 0, 314
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    Array[DivisorSum[#, #^2 &, And[PrimeQ@ #, Mod[#, 4] == 1] &] &, 85] (* Michael De Vlieger, Jul 11 2017 *)
    f[p_, e_] := If[Mod[p, 4] == 1, p^2, 0]; a[n_] := Plus @@ f @@@ FactorInteger[n]; a[1] = 0; Array[a, 100] (* Amiram Eldar, Jun 21 2022 *)
  • PARI
    a(n) = my(f=factor(n)); sum(k=1, #f~, if (((p=f[k,1])%4) == 1, p^2)); \\ Michel Marcus, Jul 11 2017
  • Scheme
    (define (A005079 n) (if (= 1 n) 0 (+ (if (= 1 (modulo (A020639 n) 4)) (A000290 (A020639 n)) 0) (A005079 (A028234 n))))) ;; Antti Karttunen, Jul 11 2017
    

Formula

Additive with a(p^e) = p^2 if p = 1 (mod 4), 0 otherwise.
a(n) = A005063(n) - A005083(n) - 4*A059841(n). - Antti Karttunen, Jul 11 2017

Extensions

More terms from Antti Karttunen, Jul 11 2017

A005085 Sum of 4th powers of primes = 3 mod 4 dividing n.

Original entry on oeis.org

0, 0, 81, 0, 0, 81, 2401, 0, 81, 0, 14641, 81, 0, 2401, 81, 0, 0, 81, 130321, 0, 2482, 14641, 279841, 81, 0, 0, 81, 2401, 0, 81, 923521, 0, 14722, 0, 2401, 81, 0, 130321, 81, 0, 0, 2482, 3418801, 14641, 81, 279841, 4879681, 81, 2401, 0, 81, 0, 0, 81, 14641, 2401, 130402, 0, 12117361, 81, 0, 923521, 2482, 0, 0, 14722, 20151121, 0, 279922
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    Array[DivisorSum[#, #^4 &, And[PrimeQ@ #, Mod[#, 4] == 3] &] &, 69] (* Michael De Vlieger, Jul 11 2017 *)
    f[p_, e_] := If[Mod[p, 4] == 3, p^4, 0]; a[n_] := Plus @@ f @@@ FactorInteger[n]; a[1] = 0; Array[a, 100] (* Amiram Eldar, Jun 21 2022 *)
  • PARI
    a(n) = my(f=factor(n)); sum(k=1, #f~, if (((p=f[k,1])%4) == 3, p^4)); \\ Michel Marcus, Jul 11 2017
  • Scheme
    (define (A005085 n) (if (= 1 n) 0 (+ (if (= 3 (modulo (A020639 n) 4)) (A000583 (A020639 n)) 0) (A005085 (A028234 n))))) ;; Antti Karttunen, Jul 11 2017
    

Formula

Additive with a(p^e) = p^4 if p = 3 (mod 4), 0 otherwise.
a(n) = A005065(n) - A005081(n) - 16*A059841(n). - Antti Karttunen, Jul 11 2017

Extensions

More terms from Antti Karttunen, Jul 11 2017

A005066 Sum of squares of odd primes dividing n.

Original entry on oeis.org

0, 0, 9, 0, 25, 9, 49, 0, 9, 25, 121, 9, 169, 49, 34, 0, 289, 9, 361, 25, 58, 121, 529, 9, 25, 169, 9, 49, 841, 34, 961, 0, 130, 289, 74, 9, 1369, 361, 178, 25, 1681, 58, 1849, 121, 34, 529, 2209, 9, 49, 25, 298, 169, 2809, 9, 146, 49, 370, 841, 3481, 34, 3721, 961, 58, 0, 194, 130, 4489, 289, 538, 74, 5041, 9, 5329, 1369
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    Table[Total[Select[Divisors[n],OddQ[#]&&PrimeQ[#]&]^2],{n,60}] (* Harvey P. Dale, May 02 2012 *)
    Array[DivisorSum[#, #^2 &, And[PrimeQ@ #, OddQ@ #] &] &, 74] (* Michael De Vlieger, Jul 11 2017 *)
    f[2, e_] := 0; f[p_, e_] := p^2; a[n_] := Plus @@ f @@@ FactorInteger[n]; a[1] = 0; Array[a, 100] (* Amiram Eldar, Jun 20 2022 *)
  • PARI
    a(n) = sumdiv(n, d, ((d%2) && isprime(d))*d^2); \\ Michel Marcus, Jan 04 2017
    
  • Python
    from sympy import primefactors
    def a(n): return sum(p**2 for p in primefactors(n) if p % 2)
    print([a(n) for n in range(1, 101)]) # Indranil Ghosh, Jul 11 2017
  • Scheme
    (define (A005066 n) (cond ((= 1 n) 0) ((even? n) (A005066 (/ n 2))) (else (+ (A000290 (A020639 n)) (A005066 (A028234 n)))))) ;; Antti Karttunen, Jul 10 2017
    

Formula

Additive with a(p^e) = 0 if p = 2, p^2 otherwise.
G.f.: Sum_{k>=2} prime(k)^2*x^prime(k)/(1 - x^prime(k)). - Ilya Gutkovskiy, Jan 04 2017
From Antti Karttunen, Jul 10 & 11 2017: (Start)
a(1) = 0; after which, for even n: a(n) = a(n/2), for odd n: a(n) = A020639(n)^2 + a(A028234(n)).
a(n) = A005063(A000265(n)).
a(n) = A005079(n) + A005083(n).
(End)

Extensions

More terms from Antti Karttunen, Jul 10 2017

A005082 Sum of primes = 3 mod 4 dividing n.

Original entry on oeis.org

0, 0, 3, 0, 0, 3, 7, 0, 3, 0, 11, 3, 0, 7, 3, 0, 0, 3, 19, 0, 10, 11, 23, 3, 0, 0, 3, 7, 0, 3, 31, 0, 14, 0, 7, 3, 0, 19, 3, 0, 0, 10, 43, 11, 3, 23, 47, 3, 7, 0, 3, 0, 0, 3, 11, 7, 22, 0, 59, 3, 0, 31, 10, 0, 0, 14, 67, 0, 26, 7, 71, 3, 0, 0, 3, 19, 18, 3, 79, 0, 3, 0, 83, 10, 0, 43, 3, 11, 0, 3, 7, 23, 34, 47, 19, 3, 0, 7, 14, 0, 0, 3, 103
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

Formula

Additive with a(p^e) = p if p = 3 (mod 4), 0 otherwise.
From Antti Karttunen, Jul 11 2017: (Start)
a(1) = 0; for n > 1, a(n) = (A079978(A020639(n) mod 4)*A020639(n)) + a(A028234(n)).
a(n) = A008472(n) - A005078(n) - 2*A059841(n).
(End)

Extensions

More terms from Antti Karttunen, Jul 11 2017

A005084 Sum of cubes of primes = 3 mod 4 dividing n.

Original entry on oeis.org

0, 0, 27, 0, 0, 27, 343, 0, 27, 0, 1331, 27, 0, 343, 27, 0, 0, 27, 6859, 0, 370, 1331, 12167, 27, 0, 0, 27, 343, 0, 27, 29791, 0, 1358, 0, 343, 27, 0, 6859, 27, 0, 0, 370, 79507, 1331, 27, 12167, 103823, 27, 343, 0, 27, 0, 0, 27, 1331, 343, 6886, 0, 205379, 27, 0, 29791, 370, 0, 0, 1358, 300763, 0, 12194, 343, 357911
Offset: 1

Views

Author

Keywords

Crossrefs

Programs

  • Mathematica
    Array[DivisorSum[#, #^3 &, And[PrimeQ@ #, Mod[#, 4] == 3] &] &, 71] (* Michael De Vlieger, Jul 11 2017 *)
    f[p_, e_] := If[Mod[p, 4] == 3, p^3, 0]; a[n_] := Plus @@ f @@@ FactorInteger[n]; a[1] = 0; Array[a, 100] (* Amiram Eldar, Jun 21 2022 *)
  • PARI
    a(n) = my(f=factor(n)); sum(k=1, #f~, if (((p=f[k,1])%4) == 3, p^3)); \\ Michel Marcus, Jul 11 2017
  • Scheme
    (define (A005084 n) (if (= 1 n) 0 (+ (if (= 3 (modulo (A020639 n) 4)) (A000578 (A020639 n)) 0) (A005084 (A028234 n))))) ;;  Antti Karttunen, Jul 11 2017
    

Formula

Additive with a(p^e) = p^3 if p = 3 (mod 4), 0 otherwise.
a(n) = A005064(n) - A005080(n) - 8*A059841(n). - Antti Karttunen, Jul 11 2017

Extensions

More terms from Antti Karttunen, Jul 11 2017
Showing 1-6 of 6 results.