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-10 of 20 results. Next

A008683 Möbius (or Moebius) function mu(n). mu(1) = 1; mu(n) = (-1)^k if n is the product of k different primes; otherwise mu(n) = 0.

Original entry on oeis.org

1, -1, -1, 0, -1, 1, -1, 0, 0, 1, -1, 0, -1, 1, 1, 0, -1, 0, -1, 0, 1, 1, -1, 0, 0, 1, 0, 0, -1, -1, -1, 0, 1, 1, 1, 0, -1, 1, 1, 0, -1, -1, -1, 0, 0, 1, -1, 0, 0, 0, 1, 0, -1, 0, 1, 0, 1, 1, -1, 0, -1, 1, 0, 0, 1, -1, -1, 0, 1, -1, -1, 0, -1, 1, 0, 0, 1, -1
Offset: 1

Views

Author

Keywords

Comments

Moebius inversion: f(n) = Sum_{d|n} g(d) for all n <=> g(n) = Sum_{d|n} mu(d)*f(n/d) for all n.
a(n) depends only on prime signature of n (cf. A025487). So a(24) = a(375) since 24 = 2^3 * 3 and 375 = 3 * 5^3 both have prime signature (3, 1).
A008683 = A140579^(-1) * A140664. - Gary W. Adamson, May 20 2008
Coons & Borwein prove that Sum_{n>=1} mu(n) z^n is transcendental. - Jonathan Vos Post, Jun 11 2008; edited by Charles R Greathouse IV, Sep 06 2017
Equals row sums of triangle A144735 (the square of triangle A054533). - Gary W. Adamson, Sep 20 2008
Conjecture: a(n) is the determinant of Redheffer matrix A143104 where T(n, n) = 0. Verified for the first 50 terms. - Mats Granvik, Jul 25 2008
From Mats Granvik, Dec 06 2008: (Start)
The Editorial Office of the Journal of Number Theory kindly provided (via B. Conrey) the following proof of the conjecture: Let A be A143104 and B be A143104 where T(n, n) = 0.
"Suppose you expand det(B_n) along the bottom row. There is only a 1 in the first position and so the answer is (-1)^n times det(C_{n-1}) say, where C_{n-1} is the (n-1) by (n-1) matrix obtained from B_n by deleting the first column and the last row. Now the determinant of the Redheffer matrix is det(A_n) = M(n) where M(n) is the sum of mu(m) for 1 <= m <= n. Expanding det(A_n) along the bottom row, we see that det(A_n) = (-1)^n * det(C_{n-1}) + M(n-1). So we have det(B_n) = (-1)^n * det(C_{n-1}) = det(A_n) - M(n-1) = M(n) - M(n-1) = mu(n)." (End)
Conjecture: Consider the table A051731 and treat 1 as a divisor. Move the value in the lower right corner vertically to a divisor position in the transpose of the table and you will find that the determinant is the Moebius function. The number of permutation matrices that contribute to the Moebius function appears to be A074206. - Mats Granvik, Dec 08 2008
Convolved with A152902 = A000027, the natural numbers. - Gary W. Adamson, Dec 14 2008
[Pickover, p. 226]: "The probability that a number falls in the -1 mailbox turns out to be 3/Pi^2 - the same probability as for falling in the +1 mailbox". - Gary W. Adamson, Aug 13 2009
Let A = A176890 and B = A * A * ... * A, then the leftmost column in matrix B converges to the Moebius function. - Mats Granvik, Gary W. Adamson, Apr 28 2010 and May 28 2020
Equals row sums of triangle A176918. - Gary W. Adamson, Apr 29 2010
Calculate matrix powers: A175992^0 - A175992^1 + A175992^2 - A175992^3 + A175992^4 - ... Then the Mobius function is found in the first column. Compare this to the binomial series for (1+x)^-1 = 1 - x + x^2 - x^3 + x^4 - ... . - Mats Granvik, Gary W. Adamson, Dec 06 2010
From Richard L. Ollerton, May 08 2021: (Start)
Formulas for the numerous OEIS entries involving the Möbius transform (Dirichlet convolution of a(n) and some sequence h(n)) can be derived using the following (n >= 1):
Sum_{d|n} mu(d)*h(n/d) = Sum_{k=1..n} h(gcd(n,k))*mu(n/gcd(n,k))/phi(n/gcd(n,k)) = Sum_{k=1..n} h(n/gcd(n,k))*mu(gcd(n,k))/phi(n/gcd(n,k)), where phi = A000010.
Use of gcd(n,k)*lcm(n,k) = n*k provides further variations. (End)
Formulas for products corresponding to the sums above are also available for sequences f(n) > 0: Product_{d|n} f(n/d)^mu(d) = Product_{k=1..n} f(gcd(n,k))^(mu(n/gcd(n,k))/phi(n/gcd(n,k))) = Product_{k=1..n} f(n/gcd(n,k))^(mu(gcd(n,k))/phi(n/gcd(n,k))). - Richard L. Ollerton, Nov 08 2021

Examples

			G.f. = x - x^2 - x^3 - x^5 + x^6 - x^7 + x^10 - x^11 - x^13 + x^14 + x^15 + ...
		

References

  • T. M. Apostol, Introduction to Analytic Number Theory, Springer-Verlag, 1976, page 24.
  • L. Comtet, Advanced Combinatorics, Reidel, 1974, p. 161, #16.
  • G. H. Hardy, Ramanujan: twelve lectures on subjects suggested by his life and work, Cambridge, University Press, 1940, pp. 64-65.
  • G. H. Hardy and E. M. Wright, An Introduction to the Theory of Numbers, 5th ed., Oxford Univ. Press, 1979, th. 262 and 287.
  • Clifford A. Pickover, "The Math Book, from Pythagoras to the 57th Dimension, 250 Milestones in the History of Mathematics", Sterling Publishing, 2009, p. 226. - Gary W. Adamson, Aug 13 2009
  • G. Pólya and G. Szegő, Problems and Theorems in Analysis Volume II. Springer_Verlag 1976.
  • James J. Tattersall, Elementary Number Theory in Nine Chapters, Cambridge University Press, 1999, pages 98-99.

Crossrefs

Variants of a(n) are A178536, A181434, A181435.
Cf. A059956 (Dgf at s=2), A088453 (Dgf at s=3), A215267 (Dgf at s=4), A343308 (Dgf at s=5).

Programs

  • Axiom
    [moebiusMu(n) for n in 1..100]
    
  • Haskell
    import Math.NumberTheory.Primes.Factorisation (factorise)
    a008683 = mu . snd . unzip . factorise where
    mu [] = 1; mu (1:es) = - mu es; mu (_:es) = 0
    -- Reinhard Zumkeller, Dec 13 2015, Oct 09 2013
    
  • Haskell
    a008683 1 = 1
    a008683 n = - sum [a008683 d | d <- [1..(n-1)], n `mod` d == 0]
    -- Harry Richman, Jun 13 2025
    
  • Magma
    [ MoebiusMu(n) : n in [1..100]];
    
  • Maple
    with(numtheory): A008683 := n->mobius(n);
    with(numtheory): [ seq(mobius(n), n=1..100) ];
    # Note that older versions of Maple define mobius(0) to be -1.
    # This is unwise! Moebius(0) is better left undefined.
    with(numtheory):
    mu:= proc(n::posint) option remember; `if`(n=1, 1,
           -add(mu(d), d=divisors(n) minus {n}))
         end:
    seq(mu(n), n=1..100);  # Alois P. Heinz, Aug 13 2008
  • Mathematica
    Array[ MoebiusMu, 100]
    (* Second program: *)
    m = 100; A[_] = 0;
    Do[A[x_] = x - Sum[A[x^k], {k, 2, m}] + O[x]^m // Normal, {m}];
    CoefficientList[A[x]/x, x] (* Jean-François Alcover, Oct 20 2019, after Ilya Gutkovskiy *)
  • Maxima
    A008683(n):=moebius(n)$ makelist(A008683(n),n,1,30); /* Martin Ettl, Oct 24 2012 */
    
  • PARI
    a=n->if(n<1,0,moebius(n));
    
  • PARI
    {a(n) = if( n<1, 0, direuler( p=2, n, 1 - X)[n])};
    
  • PARI
    list(n)=my(v=vector(n,i,1)); forprime(p=2, sqrtint(n), forstep(i=p, n, p, v[i]*=-1); forstep(i=p^2, n, p^2, v[i]=0)); forprime(p=sqrtint(n)+1, n, forstep(i=p, n, p, v[i]*=-1)); v \\ Charles R Greathouse IV, Apr 27 2012
    
  • Python
    from sympy import mobius
    print([mobius(i) for i in range(1, 101)])  # Indranil Ghosh, Mar 18 2017
  • Sage
    @cached_function
    def mu(n):
        if n < 2: return n
        return -sum(mu(d) for d in divisors(n)[:-1])
    # Changing the sign of the sum gives the number of ordered factorizations of n A074206.
    print([mu(n) for n in (1..96)])  # Peter Luschny, Dec 26 2016
    

Formula

Sum_{d|n} mu(d) = 1 if n = 1 else 0.
Dirichlet generating function: Sum_{n >= 1} mu(n)/n^s = 1/zeta(s). Also Sum_{n >= 1} mu(n)*x^n/(1-x^n) = x.
In particular, Sum_{n > 0} mu(n)/n = 0. - Franklin T. Adams-Watters, Jun 20 2014
phi(n) = Sum_{d|n} mu(d)*n/d.
a(n) = A091219(A091202(n)).
Multiplicative with a(p^e) = -1 if e = 1; 0 if e > 1. - David W. Wilson, Aug 01 2001
abs(a(n)) = Sum_{d|n} 2^A001221(d)*a(n/d). - Benoit Cloitre, Apr 05 2002
Sum_{d|n} (-1)^(n/d)*mobius(d) = 0 for n > 2. - Emeric Deutsch, Jan 28 2005
a(n) = (-1)^omega(n) * 0^(bigomega(n) - omega(n)) for n > 0, where bigomega(n) and omega(n) are the numbers of prime factors of n with and without repetition (A001222, A001221, A046660). - Reinhard Zumkeller, Apr 05 2003
Dirichlet generating function for the absolute value: zeta(s)/zeta(2s). - Franklin T. Adams-Watters, Sep 11 2005
mu(n) = A129360(n) * (1, -1, 0, 0, 0, ...). - Gary W. Adamson, Apr 17 2007
mu(n) = -Sum_{d < n, d|n} mu(d) if n > 1 and mu(1) = 1. - Alois P. Heinz, Aug 13 2008
a(n) = A174725(n) - A174726(n). - Mats Granvik, Mar 28 2010
a(n) = first column in the matrix inverse of a triangular table with the definition: T(1, 1) = 1, n > 1: T(n, 1) is any number or sequence, k = 2: T(n, 2) = T(n, k-1) - T(n-1, k), k > 2 and n >= k: T(n,k) = (Sum_{i = 1..k-1} T(n-i, k-1)) - (Sum_{i = 1..k-1} T(n-i, k)). - Mats Granvik, Jun 12 2010
Product_{n >= 1} (1-x^n)^(-a(n)/n) = exp(x) (product form of the exponential function). - Joerg Arndt, May 13 2011
a(n) = Sum_{k=1..n, gcd(k,n)=1} exp(2*Pi*i*k/n), the sum over the primitive n-th roots of unity. See the Apostol reference, p. 48, Exercise 14 (b). - Wolfdieter Lang, Jun 13 2011
mu(n) = Sum_{k=1..n} A191898(n,k)*exp(-i*2*Pi*k/n)/n. (conjecture). - Mats Granvik, Nov 20 2011
Sum_{k=1..n} a(k)*floor(n/k) = 1 for n >= 1. - Peter Luschny, Feb 10 2012
a(n) = floor(omega(n)/bigomega(n))*(-1)^omega(n) = floor(A001221(n)/A001222(n))*(-1)^A001221(n). - Enrique Pérez Herrero, Apr 27 2012
Multiplicative with a(p^e) = binomial(1, e) * (-1)^e. - Enrique Pérez Herrero, Jan 19 2013
G.f. A(x) satisfies: x^2/A(x) = Sum_{n>=1} A( x^(2*n)/A(x)^n ). - Paul D. Hanna, Apr 19 2016
a(n) = -A008966(n)*A008836(n)/(-1)^A005361(n) = -floor(rad(n)/n)Lambda(n)/(-1)^tau(n/rad(n)). - Anthony Browne, May 17 2016
a(n) = Kronecker delta of A001221(n) and A001222(n) (which is A008966) multiplied by A008836(n). - Eric Desbiaux, Mar 15 2017
a(n) = A132971(A156552(n)). - Antti Karttunen, May 30 2017
Conjecture: a(n) = Sum_{k>=0} (-1)^(k-1)*binomial(A001222(n)-1, k)*binomial(A001221(n)-1+k, k), for n > 1. Verified for the first 100000 terms. - Mats Granvik, Sep 08 2018
From Peter Bala, Mar 15 2019: (Start)
Sum_{n >= 1} mu(n)*x^n/(1 + x^n) = x - 2*x^2. See, for example, Pólya and Szegő, Part V111, Chap. 1, No. 71.
Sum_{n >= 1} (-1)^(n+1)*mu(n)*x^n/(1 - x^n) = x + 2*(x^2 + x^4 + x^8 + x^16 + ...).
Sum_{n >= 1} (-1)^(n+1)*mu(n)*x^n/(1 + x^n) = x - 2*(x^4 + x^8 + x^16 + x^32 + ...).
Sum_{n >= 1} |mu(n)|*x^n/(1 - x^n) = Sum_{n >= 1} (2^w(n))*x^n, where w(n) is the number of different prime factors of n (Hardy and Wright, Chapter XVI, Theorem 264).
Sum_{n odd} |mu(n)|*x^n/(1 + x^(2*n)) = Sum_{n in S_1} (2^w_1(n))*x^n, where S_1 = {1, 5, 13, 17, 25, 29, ...} is the multiplicative semigroup of positive integers generated by 1 and the primes p = 1 (mod 4), and w_1(n) is the number of different prime factors p = 1 (mod 4) of n.
Sum_{n odd} (-1)^((n-1)/2)*mu(n)*x^n/(1 - x^(2*n)) = Sum_{n in S_3} (2^w_3(n))*x^n, where S_3 = {1, 3, 7, 9, 11, 19, 21, ...} is the multiplicative semigroup of positive integers generated by 1 and the primes p = 3 (mod 4), and where w_3(n) is the number of different prime factors p = 3 (mod 4) of n. (End)
G.f. A(x) satisfies: A(x) = x - Sum_{k>=2} A(x^k). - Ilya Gutkovskiy, May 11 2019
a(n) = sign(A023900(n)) * [A007947(n) = n] where [] is the Iverson bracket. - I. V. Serov, May 15 2019
a(n) = Sum_{k = 1..n} gcd(k, n)*a(gcd(k, n)) = Sum_{d divides n} a(d)*d*phi(n/d). - Peter Bala, Jan 16 2024

A063524 Characteristic function of 1.

Original entry on oeis.org

0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0
Offset: 0

Views

Author

Labos Elemer, Jul 30 2001

Keywords

Comments

The identity function for Dirichlet multiplication (see Apostol).
Sum of the Moebius function mu(d) of the divisors d of n. - Robert G. Wilson v, Sep 30 2006
-a(n) is the Hankel transform of A000045(n), n >= 0 (Fibonacci numbers). See A055879 for the definition of Hankel transform. - Wolfdieter Lang, Jan 23 2007
a(A000012(n)) = 1; a(A087156(n)) = 0. - Reinhard Zumkeller, Oct 11 2008
a(n) for n >= 1 is the Dirichlet convolution of following functions b(n), c(n), a(n) = Sum_{d|n} b(d)*c(n/d): a(n) = A008683(n) * A000012(n), a(n) = A007427(n) * A000005(n), a(n) = A007428(n) * A007425(n). - Jaroslav Krizek, Mar 03 2009
From Christopher Hunt Gribble, Jul 11 2013: (Start)
a(n) for 1 <= n <= 4 and conjectured for n > 4 is the number of Hamiltonian circuits in a 2n X 2n square lattice of nodes, reduced for symmetry, where the orbits under the symmetry group of the square, D4, have 1 element: When n=1, there is only 1 Hamiltonian circuit in a 2 X 2 square lattice, as illustrated below. The circuit is the same when rotated and/or reflected and so has only 1 orbital element under the symmetry group of the square.
o--o
| |
o--o (End)
Convolution property: For any sequence b(n), the sequence c(n)=b(n)*a(n) has the following values: c(1)=0, c(n+1)=b(n) for all n > 1. In other words, the sequence b(n) is shifted 1 step to the right. - David Neil McGrath, Nov 10 2014

References

  • T. M. Apostol, Introduction to Analytic Number Theory, Springer-Verlag, 1976, page 30.

Crossrefs

Programs

Formula

From Philippe Deléham, Nov 25 2008: (Start)
G.f.: x.
E.g.f.: x. (End)
a(n) = mu(n^2). - Enrique Pérez Herrero, Sep 04 2009
a(n) = floor(n/A000203(n)) for n > 0. - Enrique Pérez Herrero, Nov 11 2009
a(n) = (1-(-1)^(2^abs(n-1)))/2 = (1-(-1)^(2^((n-1)^2)))/2. - Luce ETIENNE, Jun 05 2015
a(n) = n*(A057427(n) - A057427(n-1)) = A000007(abs(n-1)). - Chayim Lowen, Aug 01 2015
a(n) = A010051(p*n) for any prime p (where A010051(0)=0). - Chayim Lowen, Aug 05 2015
From Antti Karttunen, Jun 04 2022: (Start)
For n >= 1:
a(n) = Sum_{d|n} A000010(n/d) * A023900(d), and similarly for any pair of sequences that are Dirichlet inverses of each other, like for example A000027 & A055615 and those mentioned in Krizek's Mar 03 2009 comment above.
a(n) = [A101296(n) == 1], where [ ] is the Iverson bracket.
Fully multiplicative with a(p^e) = 0. (End)

A007425 d_3(n), or tau_3(n), the number of ordered factorizations of n as n = r s t.

Original entry on oeis.org

1, 3, 3, 6, 3, 9, 3, 10, 6, 9, 3, 18, 3, 9, 9, 15, 3, 18, 3, 18, 9, 9, 3, 30, 6, 9, 10, 18, 3, 27, 3, 21, 9, 9, 9, 36, 3, 9, 9, 30, 3, 27, 3, 18, 18, 9, 3, 45, 6, 18, 9, 18, 3, 30, 9, 30, 9, 9, 3, 54, 3, 9, 18, 28, 9, 27, 3, 18, 9, 27, 3, 60, 3, 9, 18, 18, 9, 27, 3, 45, 15, 9, 3, 54, 9, 9, 9, 30, 3
Offset: 1

Views

Author

N. J. A. Sloane, May 24 1994

Keywords

Comments

Let n = Product p_i^e_i. Tau (A000005) is tau_2, this sequence is tau_3, A007426 is tau_4, where tau_k(n) (also written as d_k(n)) = Product_i binomial(k-1+e_i, k-1) is the k-th Piltz function. It gives the number of ordered factorizations of n as a product of k terms. - Len Smiley
Inverse Möbius transform applied twice to all 1's sequence.
A085782 gives the range of values of this sequence. - Matthew Vandermast, Jul 12 2004
Appears to equal the number of plane partitions of n that can be extended in exactly 3 ways to a plane partition of n+1 by adding one element. - Wouter Meeussen, Sep 11 2004
Number of divisors of n's divisors. - Lekraj Beedassy, Sep 07 2004
Number of plane partitions of n that can be extended in exactly 3 ways to a plane partition of n+1 by adding one element. If the partition is not a box, there is a minimal i+j where b_{i,j} != b_{1,1} and an element can be added there. - Franklin T. Adams-Watters, Jun 14 2006
Equals row sums of A127170. - Gary W. Adamson, May 20 2007
Equals A134577 * [1/1, 1/2, 1/3, ...]. - Gary W. Adamson, Nov 02 2007
Equals row sums of triangle A143354. - Gary W. Adamson, Aug 10 2008
a(n) is congruent to 1 (mod 3) if n is a perfect cube, otherwise a(n) is congruent to 0 (mod 3). - Geoffrey Critzer, Mar 20 2015
Also row sums of A195050. - Omar E. Pol, Nov 26 2015
Number of 3D grids of n congruent boxes with three different edge lengths, in a box, modulo rotation (cf. A034836 for cubes instead of boxes and A140773 for boxes with two different edge lengths; cf. A000005 for the 2D case). - Manfred Boergens, Apr 06 2021
Number of ordered pairs of divisors of n, (d1,d2) with d1<=d2, such that d1|d2. - Wesley Ivan Hurt, Mar 22 2022

Examples

			a(6) = 9; the divisors of 6 are {1,2,3,6} and the numbers of divisors of these divisors are 1, 2, 2, and 4. Adding them, we get 9 as a result.
Also, since 6 is a squarefree number, the formula from Herrero can be used to obtain the result: a(6) = 3^omega(6) = 3^2 = 9. - _Wesley Ivan Hurt_, May 30 2014
		

References

  • M. N. Huxley, Area, Lattice Points and Exponential Sums, Oxford, 1996; p. 239.
  • A. Ivic, The Riemann Zeta-Function, Wiley, NY, 1985, see p. xv.
  • Paul J. McCarthy, Introduction to Arithmetical Functions, Springer, 1986.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A000005 (Mobius transform), A007426 (inverse Mobius transform), A061201 (partial sums), A127270, A143354, A027750, A007428 (Dirichlet inverse), A175596.
Column k=3 of A077592.
Additional cross-references mentioned in a comment: A034836, A038548, A140733.

Programs

  • Haskell
    a007425 = sum . map a000005 . a027750_row
    -- Reinhard Zumkeller, Feb 16 2012
    
  • Maple
    f:=proc(n) local t1,i,j,k; t1:=0; for i from 1 to n do for j from 1 to n do for k from 1 to n do if i*j*k = n then t1:=t1+1; fi; od: od: od: t1; end;
    A007425 := proc(n) local e,j; e := ifactors(n)[2]: product(binomial(2+e[j][2],2), j=1..nops(e)); end; # Len Smiley
  • Mathematica
    f[n_] := Plus @@ DivisorSigma[0, Divisors[n]]; Table[ f[n], {n, 90}] (* Robert G. Wilson v, Sep 13 2004 *)
    SetAttributes[tau, Listable]; tau[1, n_] := 1; tau[k_, n_] := Plus @@ (tau[k-1, Divisors[n]]); Table[tau[3, n], {n, 100}] (* Enrique Pérez Herrero, Nov 08 2009 *)
    Table[Sum[DivisorSigma[0, d], {d, Divisors[n]}], {n, 50}] (* Wesley Ivan Hurt, May 30 2014 *)
    f[p_, e_] := (e+1)*(e+2)/2;  a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Jan 27 2019 *)
  • PARI
    for(n=1,100,print1(sumdiv(n,k,numdiv(k)),","))
    
  • PARI
    a(n)=if(n<1,0,direuler(p=2,n,1/(1-X)^3)[n]) \\ Ralf Stephan
    
  • PARI
    a(n)=sumdiv(n, x, sumdiv(x, y, 1 )) \\ Joerg Arndt, Oct 07 2012
    
  • PARI
    a(n)=sumdivmult(n,k,numdiv(k)) \\ Charles R Greathouse IV, Aug 30 2013
    
  • PARI
    for(n=1, 100, print1(numerator(direuler(p=2, n, 1/(1-X)^3)[n]), ", ")) \\ Vaclav Kotesovec, May 06 2025
    
  • Python
    from math import prod, comb
    from sympy import factorint
    def A007425(n): return prod(comb(2+e,2) for e in factorint(n).values()) # Chai Wah Wu, Dec 22 2024

Formula

a(n) = Sum_{d dividing n} tau(d). - Benoit Cloitre, Apr 04 2002
G.f.: Sum_{k>=1} tau(k)*x^k/(1-x^k). - Benoit Cloitre, Apr 21 2003
For n = Product p_i^e_i, a(n) = Product_i A000217(e_i + 1). - Lekraj Beedassy, Sep 07 2004
Dirichlet g.f.: zeta^3(s).
From Enrique Pérez Herrero, Nov 03 2009: (Start)
a(n^2) = tau_3(n^2) = tau_2(n^2)*tau_2(n), where tau_2 is A000005 and tau_3 is this sequence.
a(s) = 3^omega(s), if s>1 is squarefree (A005117) and omega(s) is: A001221. (End)
From Enrique Pérez Herrero, Nov 08 2009: (Start)
a(n) = tau_3(n) = tau_2(n)*tau_2(n*rad(n))/tau_2(rad(n)), where rad(n) is A007947 and tau_2(n) is A000005.
tau_3(n) >= 2*tau_2(n) - 1.
tau_3(n) <= tau_2(n)^2 + tau_2(n)-1. (End)
From Vladimir Shevelev, Dec 22 2017: (Start)
a(n) = sqrt(Sum_{d|n}(tau(d))^3);
a(n) = |Sum_{d|n} A008836(d)*(tau(d))^2|.
The first formula follows from the first Cloitre formula and a Liouville formula; the second formula follows from our analogous formula (cf. our comment in Formula section of A000005). (End)
L.g.f.: -log(Product_{k>=1} (1 - x^k)^(tau(k)/k)) = Sum_{n>=1} a(n)*x^n/n. - Ilya Gutkovskiy, May 23 2018

A007427 Moebius transform applied twice to sequence 1,0,0,0,....

Original entry on oeis.org

1, -2, -2, 1, -2, 4, -2, 0, 1, 4, -2, -2, -2, 4, 4, 0, -2, -2, -2, -2, 4, 4, -2, 0, 1, 4, 0, -2, -2, -8, -2, 0, 4, 4, 4, 1, -2, 4, 4, 0, -2, -8, -2, -2, -2, 4, -2, 0, 1, -2, 4, -2, -2, 0, 4, 0, 4, 4, -2, 4, -2, 4, -2, 0, 4, -8, -2, -2, 4, -8, -2, 0, -2, 4, -2, -2, 4, -8, -2, 0, 0
Offset: 1

Views

Author

Keywords

Comments

|a(n)| is the number of ways to write n as a product of 2 squarefree numbers (i.e., number of ways to write n = x*y with 1 <= x <= n, 1 <= y <= n, x and y squarefree). - Benoit Cloitre, Jan 01 2003

Examples

			G.f. = x - 2*x^2 - 2*x^3 + x^4 - 2*x^5 + 4*x^6 - 2*x^7 + x^9 + 4*x^10 + ...
We have a(3^1) = C(2, 1)*(-1)^1 = -2, a(3^2) = C(2, 2)*(-1)^2 = 1, and a(3^m) = C(2, m)*(-1)^m = 0 for m >= 3. - _Petros Hadjicostas_, Jun 07 2019
		

References

  • Tom M. Apostol, Introduction to Analytic Number Theory, Springer-Verlag, 1976, page 30.
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Dirichlet inverse of A000005, Mobius transform of A008683.

Programs

  • Haskell
    a007427 n = sum $ zipWith (*) mds $ reverse mds where
       mds = a225817_row n
    -- Reinhard Zumkeller, Jul 30 2013
    
  • Maple
    möbius := proc(a)  local b, i, mo: b := NULL:
    mo := (m,n) -> `if`(irem(m,n) = 0, numtheory:-mobius(m/n), 0);
    for i to nops(a) do b := b, add(mo(i,j)*a[j], j=1..i) od: [b] end:
    (möbius@@2)([1, seq(0, i=1..80)]); # Peter Luschny, Sep 08 2017
  • Mathematica
    f[n_] := Plus @@ Times @@@ (MoebiusMu[{#, n/#}] & /@ Divisors@n); Array[f, 105] (* Robert G. Wilson v *)
    a[n_] := DivisorSum[n, MoebiusMu[#]*MoebiusMu[n/#]&]; Array[a, 80] (* Jean-François Alcover, Dec 01 2015 *)
  • PARI
    {a(n) = if( n<1, 0, direuler(p=2, n, (1 - X)^2)[n])}; /* Michael Somos, Nov 15 2002 */
    
  • PARI
    {a(n) = if(n<1, 0, sumdiv(n, d, moebius(d) * moebius(n/d)))}; /* Michael Somos, Nov 15 2002 */
    
  • PARI
    a(n)=if(n>1,my(f=factor(n)[,2],s=sum(i=1,#f,f[i]==1));if(vecmax(f)>2,0,(-1)^s<Charles R Greathouse IV, Jun 28 2011
    
  • Python
    from math import prod, comb
    from sympy import factorint
    def A007427(n): return prod(-comb(2,e) if e&1 else comb(2,e) for e in factorint(n).values()) # Chai Wah Wu, Jul 05 2024

Formula

Dirichlet g.f.: 1/zeta(s)^2.
Multiplicative function with a(p^e) = binomial(2, e)*(-1)^e for p prime and e >= 0.
a(n) = Sum_{d|n} mu(d)*mu(n/d). - Benoit Cloitre, Apr 05 2002
a(n^2) = A008683(n)^2. a(A005117(n)) = (-2)^A001221(A005117(n)). - Enrique Pérez Herrero, Jun 27 2011 [Misrendering of contribution rectified by Peter Munn, Mar 06 2020]
a(n) is the Dirichlet inverse of A000005, which means a(n) = -Sum_{d|n, dA000005(n/d)*a(d). - Enrique Pérez Herrero, Jan 19 2013
a(n) = 0 if n is not cubefree: A046099, otherwise sign(a(n)) = lambda(n), where lambda is A008836. - Enrique Pérez Herrero, Jan 19 2013
Dirichlet g.f. of |a(n)|: zeta(s)^2/zeta(2s)^2 (conjectured). - Ralf Stephan, Jul 05 2013. The conjecture is correct because 1+Sum_{e>=1} binomial(2,e)/p^(e*s) = (p^s+1)^2/p^2s, whose product over p is zeta(s)^2/zeta(2s)^2. - Michael Shamos
a(n) = Sum_{k=1..A000005(n)} A225817(n,k)*A225817(n,n+1-k). - Reinhard Zumkeller, Jul 30 2013
G.f. A(x) satisfies: A(x) = x - Sum_{k>=2} tau(k)*A(x^k), where tau = A000005. - Ilya Gutkovskiy, May 11 2019
Sum_{k=1..n} abs(a(k)) ~ (n/zeta(2)^2) * (log(n) + 2*gamma - 1 - 4*zeta'(2)/zeta(2)), where gamma is Euler's constant (A001620). - Amiram Eldar, Dec 24 2023

Extensions

Added a proof of Stephan's conjecture about the Dirichlet g.f. of |a(n)|.

A007431 a(n) = Sum_{d|n} phi(d)*mu(n/d).

Original entry on oeis.org

0, 1, 0, 1, 1, 3, 0, 5, 2, 4, 0, 9, 1, 11, 0, 3, 4, 15, 0, 17, 3, 5, 0, 21, 2, 16, 0, 12, 5, 27, 0, 29, 8, 9, 0, 15, 4, 35, 0, 11, 6, 39, 0, 41, 9, 12, 0, 45, 4, 36, 0, 15, 11, 51, 0, 27, 10, 17, 0, 57, 3, 59, 0, 20, 16, 33, 0, 65, 15, 21, 0, 69, 8, 71, 0, 16, 17, 45, 0, 77, 12, 36, 0, 81, 5, 45, 0
Offset: 0

Views

Author

Keywords

Comments

Also Moebius transform applied twice to natural numbers.
Also number of complex primitive Dirichlet characters modulo n and Sum_{k=1..n} a(k) is asymptotic to (18/Pi^4)*n^2. - Steven Finch, Feb 16 2006
Dirichlet convolution of phi(n) and mu(n). - Richard L. Ollerton, May 07 2021
From Jianing Song, May 21 2022: (Start)
a(n) is the number of degree-psi(n) primitive Dirichlet characters mod n, where psi = A002322. Also, a(n) is the number of degree-(k*psi(n)) primitive Dirichlet characters mod n for all k >= 1.
a(n) is the maximum element in the n-th row of A354058 (or A354061). (End)

Examples

			From _Jianing Song_, May 21 2022: (Start)
a(45) = 12: psi(45) = 12, there are 3 degree-12 primitive characters modulo 5 and 4 degree-12 primitive characters modulo 9, so a(45) = 3 * 4 = 12.
a(63) = 20: psi(63) = 6, there are 5 sextic primitive characters modulo 7 and 4 sextic primitive characters modulo 9, so a(63) = 5 * 4 = 20. (End)
		

References

  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A007432.
Cf. A000010, A008683, A130054 (Dirichlet inverse), A354058, A354061.

Programs

  • Haskell
    a007431 0 = 0
    a007431 n = sum $ map (a008683 . gcd n) [1..n]
    -- Reinhard Zumkeller, Jan 06 2014
    
  • Magma
    [0] cat [&+[EulerPhi(d)*MoebiusMu(Floor(n/d)):d in Divisors(n)]:n in [1..90]]; // Marius A. Burtea, Aug 10 2019
  • Maple
    with(numtheory); f:=n->add( phi(d)*mobius(n/d), d in divisors(n)); [seq(f(n),n=0..120)];
  • Mathematica
    Table[Sum[EulerPhi[d] MoebiusMu[n/d], {d, Divisors[n]}], {n, 0, 86}] (* Jean-François Alcover, Apr 04 2011 *)
    Table[DirichletConvolve[MoebiusMu[n], EulerPhi[n], n, m], {m, 86}] (* Jan Mangaldan, Mar 15 2013 *)
    f[p_, e_] := If[e == 1, p-2, p^e - 2*p^(e-1) + p^(e-2)]; a[1] = 1; a[n_] := Times @@ (f @@@ FactorInteger[n]); Array[a, 100] (* Amiram Eldar, Jun 23 2020 *)
  • PARI
    a(n)=if(n<1,0,direuler(p=2,n,(1-X)^2/(1-p*X))[n]) \\ Ralf Stephan
    
  • PARI
    a(n) = sumdiv(n,d, moebius(d) * eulerphi(n/d) ); \\ Joerg Arndt, Apr 14 2013
    
  • PARI
    A007431(n) = if(!n,n,my(f=factor(n)); prod(i=1, #f~, if(1==f[i, 2], f[i, 1]-2, ((f[i,1]-1)^2)*(f[i, 1]^(f[i, 2]-2))))); \\ Antti Karttunen, Dec 15 2024, after Vladeta Jovovic's multiplicative formula
    

Formula

Multiplicative with a(p) = p-2 and a(p^e) = (p-1)^2*p^(e-2) for e > 1. - Vladeta Jovovic, Jan 25 2002
Dirichlet g.f.: zeta(s-1)/zeta^2(s).
a(n) = Sum_{k=1..n} mu(gcd(n,k)) for n > 0. - Benoit Cloitre, Jun 14 2007
a(n) = Sum_{k=1..n} (phi(gcd(k,n)) * cos(2*Pi*k/n)). - Enrique Pérez Herrero, Jan 18 2013
a(n) = Sum_{d|n} tau_{-2}(d)*n/d = Sum_{d|n} tau_{-3}(d)*sigma_1(n/d), where tau_{-3} is A007428, tau_{-2} A007427 and sigma_1 A000203. - Enrique Pérez Herrero, Jan 19 2013
G.f.: Sum_{n>=1} a(n)*x^n/(1 - x^n) = Sum_{n>=1} mu(n)*x^n/(1 - x^n)^2. - Ilya Gutkovskiy, Apr 25 2017
Sum_{k=1..n} a(k) ~ 18 * n^2 / Pi^4. - Vaclav Kotesovec, Nov 04 2018
Sum_{n>=1} a(n)*x^n/(1 - x^n) = Sum_{n>=1} phi(n)*x^n. - Mamuka Jibladze, Aug 09 2019
Sum_{d|n} a(d) = phi(n) (A000010). - Amiram Eldar, Jun 23 2020
a(n) = Sum_{k=1..n} mu(n/gcd(n,k))*phi(gcd(n,k))/phi(n/gcd(n,k)). - Richard L. Ollerton, May 07 2021
a(n) = A354058(n,psi(n)) = A354061(n,psi(n)) with psi = A002322. - Jianing Song, May 21 2022

A046101 Biquadrateful numbers.

Original entry on oeis.org

16, 32, 48, 64, 80, 81, 96, 112, 128, 144, 160, 162, 176, 192, 208, 224, 240, 243, 256, 272, 288, 304, 320, 324, 336, 352, 368, 384, 400, 405, 416, 432, 448, 464, 480, 486, 496, 512, 528, 544, 560, 567, 576, 592, 608, 624, 625, 640, 648, 656, 672, 688, 704
Offset: 1

Views

Author

Keywords

Comments

The convention in the OEIS is that squareful, cubeful (A046099), biquadrateful, ... mean the same as "not squarefree" etc., while 2- or square-full, 3- or cube-full (A036966), 4-full (A036967) are used for Golomb's notion of powerful numbers (A001694, see references there), when each prime factor occurs to a power > 1. - M. F. Hasler, Feb 12 2008
Also solutions to equation tau_{-3}(n)=0, where tau_{-3} is A007428. - Enrique Pérez Herrero, Jan 19 2013
Sum_{n>0} 1/a(n)^s = Zeta(s) - Zeta(s)/Zeta(4s). - Enrique Pérez Herrero, Jan 21 2013
A051903(a(n)) > 3. - Reinhard Zumkeller, Sep 03 2015
The asymptotic density of this sequence is 1 - 1/zeta(4) = 1 - 90/Pi^4 = 0.076061... - Amiram Eldar, Jul 09 2020

Crossrefs

Programs

  • Haskell
    a046101 n = a046101_list !! (n-1)
    a046101_list = filter ((> 3) . a051903) [1..]
    -- Reinhard Zumkeller, Sep 03 2015
    
  • Maple
    with(NumberTheory):
    isBiquadrateful := n -> is(denom(Radical(n) / LargestNthPower(n, 2)) <> 1):
    select(isBiquadrateful, [`$`(1..704)]);  # Peter Luschny, Jul 12 2022
  • Mathematica
    lst={};Do[a=0;Do[If[FactorInteger[m][[n, 2]]>3, a=1], {n, Length[FactorInteger[m]]}];If[a==1, AppendTo[lst, m]], {m, 10^3}];lst (* Vladimir Joseph Stephan Orlovsky, Aug 15 2008 *)
    Select[Range[1000],Max[Transpose[FactorInteger[#]][[2]]]>3&] (* Harvey P. Dale, May 25 2014 *)
  • PARI
    is(n)=n>9 && vecmax(factor(n)[,2])>3 \\ Charles R Greathouse IV, Sep 03 2015
    
  • Python
    from sympy import mobius, integer_nthroot
    def A046101(n):
        def f(x): return n+sum(mobius(k)*(x//k**4) for k in range(1, integer_nthroot(x,4)[0]+1))
        m, k = n, f(n)
        while m != k:
            m, k = k, f(k)
        return m # Chai Wah Wu, Aug 05 2024

A247343 Moebius transform applied four times to sequence 1,0,0,0,....

Original entry on oeis.org

1, -4, -4, 6, -4, 16, -4, -4, 6, 16, -4, -24, -4, 16, 16, 1, -4, -24, -4, -24, 16, 16, -4, 16, 6, 16, -4, -24, -4, -64, -4, 0, 16, 16, 16, 36, -4, 16, 16, 16, -4, -64, -4, -24, -24, 16, -4, -4, 6, -24, 16, -24, -4, 16, 16, 16, 16, 16, -4, 96, -4, 16, -24, 0, 16, -64, -4, -24, 16, -64
Offset: 1

Views

Author

Enrique Pérez Herrero, Sep 14 2014

Keywords

Comments

Multiplicative because the Moebius transform of a multiplicative sequence is multiplicative. - Andrew Howroyd, Jul 25 2018

Crossrefs

Programs

  • Mathematica
    tau[1, n_Integer]:=1; SetAttributes[tau, Listable];
    tau[k_Integer, n_Integer]:=Plus@@(tau[k-1, Divisors[n]])/; k > 1;
    tau[k_Integer, n_Integer]:=Plus@@(tau[k+1, Divisors[n]]*MoebiusMu[n/Divisors[n]]); k<1;
    Table[tau[-4, n], {n, 70}]
    f[p_, e_] := (-1)^e * Binomial[4, e]; a[1] = 1; a[n_] := Times @@ f @@@ FactorInteger[n]; Array[a, 100] (* Amiram Eldar, Sep 11 2020 *)
  • PARI
    seq(n)={my(v=vector(n, n, n==1)); for(k=1, 4, v=dirmul(v, vector(#v, n, moebius(n)))); v} \\ Andrew Howroyd, Jul 25 2018
    
  • PARI
    for(n=1, 100, print1(direuler(p=2, n, (1 - X)^4)[n], ", ")) \\ Vaclav Kotesovec, Feb 22 2021

Formula

Dirichlet g.f.: 1/zeta(s)^4.
Multiplicative with a(p^e) = (-1)^e * binomial(4, e). - Amiram Eldar, Sep 11 2020

A341831 Dirichlet g.f.: 1 / zeta(s)^5.

Original entry on oeis.org

1, -5, -5, 10, -5, 25, -5, -10, 10, 25, -5, -50, -5, 25, 25, 5, -5, -50, -5, -50, 25, 25, -5, 50, 10, 25, -10, -50, -5, -125, -5, -1, 25, 25, 25, 100, -5, 25, 25, 50, -5, -125, -5, -50, -50, 25, -5, -25, 10, -50, 25, -50, -5, 50, 25, 50, 25, 25, -5, 250, -5, 25, -50, 0, 25
Offset: 1

Views

Author

Ilya Gutkovskiy, Feb 21 2021

Keywords

Comments

Dirichlet inverse of A061200.

Crossrefs

Programs

  • Mathematica
    a[1] = 1; a[n_] := Times @@ ((-1)^#[[2]] Binomial[5, #[[2]]] &/@ FactorInteger[n]); Table[a[n], {n, 65}]
  • PARI
    for(n=1, 100, print1(direuler(p=2, n, (1 - X)^5)[n], ", ")) \\ Vaclav Kotesovec, Feb 22 2021

Formula

Multiplicative with a(p^e) = (-1)^e * binomial(5, e).
a(1) = 1; a(n) = -Sum_{d|n, d < n} tau_5(n/d) * a(d).

A341832 Dirichlet g.f.: 1 / zeta(s)^6.

Original entry on oeis.org

1, -6, -6, 15, -6, 36, -6, -20, 15, 36, -6, -90, -6, 36, 36, 15, -6, -90, -6, -90, 36, 36, -6, 120, 15, 36, -20, -90, -6, -216, -6, -6, 36, 36, 36, 225, -6, 36, 36, 120, -6, -216, -6, -90, -90, 36, -6, -90, 15, -90, 36, -90, -6, 120, 36, 120, 36, 36, -6, 540, -6, 36, -90, 1, 36
Offset: 1

Views

Author

Ilya Gutkovskiy, Feb 21 2021

Keywords

Comments

Dirichlet inverse of A034695.

Crossrefs

Programs

  • Mathematica
    a[1] = 1; a[n_] := Times @@ ((-1)^#[[2]] Binomial[6, #[[2]]] &/@ FactorInteger[n]); Table[a[n], {n, 65}]
  • PARI
    for(n=1, 100, print1(direuler(p=2, n, (1 - X)^6)[n], ", ")) \\ Vaclav Kotesovec, Feb 22 2021

Formula

Multiplicative with a(p^e) = (-1)^e * binomial(6, e).
a(1) = 1; a(n) = -Sum_{d|n, d < n} tau_6(n/d) * a(d).

A341833 Dirichlet g.f.: 1 / zeta(s)^7.

Original entry on oeis.org

1, -7, -7, 21, -7, 49, -7, -35, 21, 49, -7, -147, -7, 49, 49, 35, -7, -147, -7, -147, 49, 49, -7, 245, 21, 49, -35, -147, -7, -343, -7, -21, 49, 49, 49, 441, -7, 49, 49, 245, -7, -343, -7, -147, -147, 49, -7, -245, 21, -147, 49, -147, -7, 245, 49, 245, 49, 49, -7, 1029, -7, 49
Offset: 1

Views

Author

Ilya Gutkovskiy, Feb 21 2021

Keywords

Comments

Dirichlet inverse of A111217.

Crossrefs

Programs

  • Mathematica
    a[1] = 1; a[n_] := Times @@ ((-1)^#[[2]] Binomial[7, #[[2]]] &/@ FactorInteger[n]); Table[a[n], {n, 62}]
  • PARI
    for(n=1, 100, print1(direuler(p=2, n, (1 - X)^7)[n], ", ")) \\ Vaclav Kotesovec, Feb 22 2021

Formula

Multiplicative with a(p^e) = (-1)^e * binomial(7, e).
a(1) = 1; a(n) = -Sum_{d|n, d < n} tau_7(n/d) * a(d).
Showing 1-10 of 20 results. Next