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.

A332424 If n = Product (p_j^k_j) then a(n) = Sum ((-1)^(pi(p_j) + 1) * p_j), where pi = A000720.

Original entry on oeis.org

0, 2, -3, 2, 5, -1, -7, 2, -3, 7, 11, -1, -13, -5, 2, 2, 17, -1, -19, 7, -10, 13, 23, -1, 5, -11, -3, -5, -29, 4, 31, 2, 8, 19, -2, -1, -37, -17, -16, 7, 41, -8, -43, 13, 2, 25, 47, -1, -7, 7, 14, -11, -53, -1, 16, -5, -22, -27, 59, 4, -61, 33, -10, 2, -8, 10, 67, 19, 20
Offset: 1

Views

Author

Ilya Gutkovskiy, Feb 12 2020

Keywords

Comments

Sum of distinct prime factors of n with odd indices minus the sum of distinct prime factors of n with even indices.

Examples

			a(66) = a(2 * 3 * 11) = a(prime(1) * prime(2) * prime(5)) = 2 - 3 + 11 = 10.
		

Crossrefs

Programs

  • Mathematica
    a[n_] := Plus @@ ((-1)^(PrimePi[#[[1]]] + 1) #[[1]] & /@ FactorInteger[n]); a[1] = 0; Table[a[n], {n, 1, 69}]
    nmax = 69; CoefficientList[Series[Sum[(-1)^(k + 1) Prime[k] x^Prime[k]/(1 - x^Prime[k]), {k, 1, nmax}], {x, 0, nmax}], x] // Rest

Formula

G.f.: Sum_{k>=1} (-1)^(k + 1) * prime(k) * x^prime(k) / (1 - x^prime(k)).
L.g.f.: log(Product_{k>=1} (1 - x^prime(k))^((-1)^k)).