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-2 of 2 results.

A064372 Additive function a(n) defined by the recursive formula a(1)=1 and a(p^k)=a(k) for any prime p.

Original entry on oeis.org

1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 1, 2, 1, 2, 2, 1, 1, 2, 1, 2, 2, 2, 1, 2, 1, 2, 1, 2, 1, 3, 1, 1, 2, 2, 2, 2, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 2, 1, 2, 2, 2, 1, 2, 2, 2, 2, 2, 1, 3, 1, 2, 2, 2, 2, 3, 1, 2, 2, 3, 1, 2, 1, 2, 2, 2, 2, 3, 1, 2, 1, 2, 1, 3, 2, 2, 2, 2, 1, 3, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 1, 3, 1, 2, 3
Offset: 1

Views

Author

Steven Finch, Sep 26 2001

Keywords

Comments

That is, if i, j, k, ... are relatively prime, then a(i*j*k*...) = a(i) + a(j) + a(k) + ... - N. J. A. Sloane, Nov 20 2007
Starts almost the same as A001221 (the number of distinct primes dividing n): the first twelve terms which are different are a(1), a(64), a(192), a(320), a(448), a(576), a(704), a(729), a(832), a(960), a(1024) and a(1088), since the first non-unitary values of n are a(6) and(10). - Henry Bottomley, Sep 23 2002
a(A164336(n)) = 1. - Reinhard Zumkeller, Aug 27 2011

Examples

			a(30) = a(5^1 * 3^1 * 2^1) = a(1) + a(1) + a(1) = 3.
		

Crossrefs

Programs

  • Haskell
    a064372 1 = 1
    a064372 n = sum $ map a064372 $ a124010_row n
    -- Reinhard Zumkeller, Aug 27 2011
  • Maple
    a:= proc(n) option remember; `if`(n=1, 1,
          add(a(i[2]), i=ifactors(n)[2]))
        end:
    seq(a(n), n=1..120);  # Alois P. Heinz, Aug 23 2020
  • Mathematica
    a[1] = 1; a[n_] := a[n] = Plus @@ a /@ FactorInteger[n][[All, 2]]; Table[a[n], {n, 1, 105}] (* Jean-François Alcover, Sep 19 2012 *)

Formula

a(n) = A106491(n) - A106490(n) = A106495(A106444(n)). - Antti Karttunen, May 09 2005
a(1) = 1, a(n) = Sum_{k=1..A001221(n)} a(A124010(n,k)) for n > 1. - Reinhard Zumkeller, Aug 27 2011

A087802 a(n) = Sum_{d|n, d nonprime} mu(d), where mu = A008683.

Original entry on oeis.org

1, 1, 1, 1, 1, 2, 1, 1, 1, 2, 1, 2, 1, 2, 2, 1, 1, 2, 1, 2, 2, 2, 1, 2, 1, 2, 1, 2, 1, 3, 1, 1, 2, 2, 2, 2, 1, 2, 2, 2, 1, 3, 1, 2, 2, 2, 1, 2, 1, 2, 2, 2, 1, 2, 2, 2, 2, 2, 1, 3, 1, 2, 2, 1, 2, 3, 1, 2, 2, 3, 1, 2, 1, 2, 2, 2, 2, 3, 1, 2, 1, 2, 1, 3, 2, 2, 2, 2, 1, 3, 2, 2, 2, 2, 2, 2, 1, 2, 2, 2, 1, 3
Offset: 1

Views

Author

Reinhard Zumkeller, Oct 11 2003

Keywords

Comments

A064372 and this sequence first differ at term 64: A064372(64)=2 and a(64)=1. - Rick L. Shepherd, Mar 07 2004

Examples

			Divisors of n=42: {1,2,3,6,7,14,21,42}, a(42) = mu(1) + mu(6) + mu(14) + mu(21) + mu(42) = 1+1+1+1-1 = 3.
		

Crossrefs

Cf. A001221, A008683 (mu), A023890, A033273. Different from A079553.

Programs

  • Mathematica
    Table[Total[MoebiusMu[#]&/@Select[Divisors[n],!PrimeQ[#]&]],{n,120}] (* Harvey P. Dale, Oct 14 2014 *)
  • PARI
    A087802(n) = sumdiv(n,d,if(!isprime(d),moebius(d)))

Formula

a(n) = if n=1 then 1, else A001221(n). - Vladeta Jovovic, Oct 17 2003
Showing 1-2 of 2 results.