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 19 results. Next

A076479 a(n) = mu(rad(n)), where mu is the Moebius-function (A008683) and rad is the radical or squarefree kernel (A007947).

Original entry on oeis.org

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

Views

Author

Reinhard Zumkeller, Oct 14 2002

Keywords

Comments

Multiplicative: a(1) = 1, a(n) for n >=2 is sign of parity of number of distinct primes dividing n. a(p) = -1, a(pq) = 1, a(pq...z) = (-1)^k, a(p^k) = -1, where p,q,.. z are distinct primes and k natural numbers. - Jaroslav Krizek, Mar 17 2009
a(n) is the unitary Moebius function, i.e., the inverse of the constant 1 function under the unitary convolution defined by (f X g)(n)= sum of f(d)g(n/d), where the sum is over the unitary divisors d of n (divisors d of n such that gcd(d,n/d)=1). - Laszlo Toth, Oct 08 2009

Crossrefs

Programs

  • Haskell
    a076479 = a008683 . a007947  -- Reinhard Zumkeller, Jun 01 2013
    
  • Magma
    [(-1)^(#PrimeDivisors(n)): n in [1..100]]; // Vincenzo Librandi, Dec 31 2018
    
  • Maple
    A076479 := proc(n)
        (-1)^A001221(n) ;
    end proc:
    seq(A076479(n),n=1..80) ; # R. J. Mathar, Nov 02 2016
  • Mathematica
    Table[(-1)^PrimeNu[n], {n,50}] (* Enrique Pérez Herrero, Jan 17 2013 *)
  • PARI
    N=66;
    mu=vector(N); mu[1]=1;
    { for (n=2,N,
        s = 0;
        fordiv (n,d,
            if (gcd(d,n/d)!=1, next() ); /* unitary divisors only */
            s += mu[d];
        );
        mu[n] = -s;
    ); };
    mu /* Joerg Arndt, May 13 2011 */
    /* omitting the line if ( gcd(...)) gives the usual Moebius function */
    
  • PARI
    a(n)=(-1)^omega(n) \\ Charles R Greathouse IV, Aug 02 2013
    
  • Python
    from math import prod
    from sympy.ntheory import mobius, primefactors
    def A076479(n): return mobius(prod(primefactors(n))) # Chai Wah Wu, Sep 24 2021

Formula

a(n) = A008683(A007947(n)).
a(n) = (-1)^A001221(n). Multiplicative with a(p^e) = -1. - Vladeta Jovovic, Dec 03 2002
a(n) = sign(A180403(n)). - Mats Granvik, Oct 08 2010
Sum_{n>=1} a(n)*phi(n)/n^3 = A065463 with phi()=A000010() [Cohen, Lemma 3.5]. - R. J. Mathar, Apr 11 2011
Dirichlet convolution of A000012 with A226177 (signed variant of A074823 with one factor mu(n) removed). - R. J. Mathar, Apr 19 2011
Sum_{n>=1} a(n)/n^2 = A065469. - R. J. Mathar, Apr 19 2011
a(n) = Sum_{d|n} mu(d)*tau_2(d) = Sum_{d|n} A008683(d)*A000005(d) . - Enrique Pérez Herrero, Jan 17 2013
a(A030230(n)) = -1; a(A030231(n)) = +1. - Reinhard Zumkeller, Jun 01 2013
Dirichlet g.f.: zeta(s) * Product_{p prime} (1 - 2p^(-s)). - Álvar Ibeas, Dec 30 2018
Sum_{n>=1} a(n)/n = 0 (van de Lune and Dressler, 1975). - Amiram Eldar, Mar 05 2021
From Richard L. Ollerton, May 07 2021: (Start)
For n>1, Sum_{k=1..n} a(gcd(n,k))*phi(gcd(n,k))*rad(gcd(n,k))/gcd(n,k) = 0.
For n>1, Sum_{k=1..n} a(n/gcd(n,k))*phi(gcd(n,k))*rad(n/gcd(n,k))*gcd(n,k) = 0. (End)
a(n) = Sum_{d1|n} Sum_{d2|n} mu(d1*d2). - Ridouane Oudra, May 25 2023

A000028 Let k = p_1^e_1 p_2^e_2 p_3^e_3 ... be the prime factorization of n. Sequence gives k such that the sum of the numbers of 1's in the binary expansions of e_1, e_2, e_3, ... is odd.

Original entry on oeis.org

2, 3, 4, 5, 7, 9, 11, 13, 16, 17, 19, 23, 24, 25, 29, 30, 31, 37, 40, 41, 42, 43, 47, 49, 53, 54, 56, 59, 60, 61, 66, 67, 70, 71, 72, 73, 78, 79, 81, 83, 84, 88, 89, 90, 96, 97, 101, 102, 103, 104, 105, 107, 108, 109, 110, 113, 114, 121, 126, 127, 128, 130, 131, 132, 135, 136, 137
Offset: 1

Views

Author

Keywords

Comments

This sequence and A000379 (its complement) give the unique solution to the problem of splitting the positive integers into two classes in such a way that products of pairs of distinct elements from either class occur with the same multiplicities [Lambek and Moser]. Cf. A000069, A001969.
Contains (for example) 180, so is different from A123193. - Max Alekseyev, Sep 20 2007
The sequence contains products of odd number of distinct terms of A050376. - Vladimir Shevelev, May 04 2010
From Vladimir Shevelev, Oct 28 2013: (Start)
Numbers m such that infinitary Moebius function of m (A064179) equals -1. This follows from the definition of A064179.
Number m is in the sequence if and only if the number k = k(m) of terms of A050376 which divide m with odd maximal exponent is odd.
For example, if m = 96, then the maximal exponent of 2 that divides 96 is 5, for 3 it is 1, for 4 it is 2, for 16 it is 1. Thus k(96) = 3 and 96 is a term.
(End)
Positions of odd terms in A064547, A268386 and A293439. - Antti Karttunen, Nov 09 2017
Lexicographically earliest sequence of distinct nonnegative integers such that no term is the A059897 product of 2 terms. (A059897 can be considered as a multiplicative operator related to the Fermi-Dirac factorization of numbers described in A050376.) Specifying that the A059897 product be of 2 distinct terms leaves the sequence unchanged. The equivalent sequences using standard integer multiplication are A026416 (with the 2 terms specified as distinct) and A026424 (otherwise). - Peter Munn, Mar 16 2019
From Amiram Eldar, Oct 02 2024: (Start)
Numbers whose number of infinitary divisors (A037445) is not a square.
Numbers whose exponentially odious part (A367514) has an odd number of distinct prime factors, i.e., numbers k such that A092248(A367514(k)) = 1. (End)

Examples

			If k = 96 then the maximal exponent of 2 that divides 96 is 5, for 3 it is 1. 5 in binary is 101_2 and has so has a sum of binary digits of 1 + 0 + 1 = 2. 1 in binary is 1_2 and so has a sum of binary digits of 1. Thus the sum of digits of binary exponents is 2 + 1 = 3 which is odd and so 96 is a term. - _Vladimir Shevelev_, Oct 28 2013, edited by _David A. Corneth_, Mar 20 2019
		

References

  • Joe Roberts, Lure of the Integers, Math. Assoc. America, 1992, p. 22.
  • N. J. A. Sloane, A Handbook of Integer Sequences, Academic Press, 1973 (includes this sequence).
  • N. J. A. Sloane and Simon Plouffe, The Encyclopedia of Integer Sequences, Academic Press, 1995 (includes this sequence).

Crossrefs

Cf. A133008, A000379 (complement), A000120 (binary weight function), A064547; also A066724, A026477, A050376, A084400, A268386, A293439.
Note that A000069 and A001969, also A000201 and A001950 give other decompositions of the integers into two classes.
Cf. A124010 (prime exponents).

Programs

  • Haskell
    a000028 n = a000028_list !! (n-1)
    a000028_list = filter (odd . sum . map a000120 . a124010_row) [1..]
    -- Reinhard Zumkeller, Oct 05 2011
    
  • Maple
    (Maple program from N. J. A. Sloane, Dec 20 2007) expts:=proc(n) local t1,t2,t3,t4,i; if n=1 then RETURN([0]); fi; if isprime(n) then RETURN([1]); fi; t1:=ifactor(n); if nops(factorset(n))=1 then RETURN([op(2,t1)]); fi; t2:=nops(t1); t3:=[]; for i from 1 to t2 do t4:=op(i,t1); if nops(t4) = 1 then t3:=[op(t3),1]; else t3:=[op(t3),op(2,t4)]; fi; od; RETURN(t3); end; # returns a list of the exponents e_1, e_2, ...
    A000120 := proc(n) local w,m,i; w := 0; m := n; while m > 0 do i := m mod 2; w := w+i; m := (m-i)/2; od; w; end: # returns weight of binary expansion
    LamMos:= proc(n) local t1,t2,t3,i; t1:=expts(n); add( A000120(t1[i]),i=1..nops(t1)); end; # returns sum of weights of exponents
    M:=400; t0:=[]; t1:=[]; for n from 1 to M do if LamMos(n) mod 2 = 0 then t0:=[op(t0),n] else t1:=[op(t1),n]; fi; od: t0; t1; # t0 is A000379, t1 is the present sequence
  • Mathematica
    iMoebiusMu[ n_ ] := Switch[ MoebiusMu[ n ], 1, 1, -1, -1, 0, If[ OddQ[ Plus@@ (DigitCount[ Last[ Transpose[ FactorInteger[ n ] ] ], 2, 1 ]) ], -1, 1 ] ]; q=Select[ Range[ 20000 ],iMoebiusMu[ # ]===-1& ] (* Wouter Meeussen, Dec 21 2007 *)
    Rest[Select[Range[150],OddQ[Count[Flatten[IntegerDigits[#,2]&/@ Transpose[ FactorInteger[#]][[2]]],1]]&]] (* Harvey P. Dale, Feb 25 2012 *)
  • PARI
    is(n)=my(f=factor(n)[,2]); sum(i=1,#f,hammingweight(f[i]))%2 \\ Charles R Greathouse IV, Aug 31 2013

Extensions

Entry revised by N. J. A. Sloane, Dec 20 2007, restoring the original definition, correcting the entries and adding a new b-file.

A030231 Numbers with an even number of distinct prime factors.

Original entry on oeis.org

1, 6, 10, 12, 14, 15, 18, 20, 21, 22, 24, 26, 28, 33, 34, 35, 36, 38, 39, 40, 44, 45, 46, 48, 50, 51, 52, 54, 55, 56, 57, 58, 62, 63, 65, 68, 69, 72, 74, 75, 76, 77, 80, 82, 85, 86, 87, 88, 91, 92, 93, 94, 95, 96, 98, 99, 100, 104, 106, 108, 111, 112, 115, 116, 117, 118, 119
Offset: 1

Views

Author

Keywords

Comments

Gcd(A008472(a(n)), A007947(a(n)))=1; see A014963. - Labos Elemer, Mar 26 2003
Superset of A007774. - R. J. Mathar, Oct 23 2008
A076479(a(n)) = +1. - Reinhard Zumkeller, Jun 01 2013
Union of the rows of A125666 with even indices. - R. J. Mathar, Jul 19 2023

Crossrefs

Programs

  • Haskell
    a030231 n = a030231_list !! (n-1)
    a030231_list = filter (even . a001221) [1..]
    -- Reinhard Zumkeller, Mar 26 2013
  • Mathematica
    Select[Range[200],EvenQ[PrimeNu[#]]&] (* Harvey P. Dale, Jun 22 2011 *)
  • PARI
    j=[]; for(n=1,200,x=omega(n); if(Mod(x,2)==0,j=concat(j,n))); j
    
  • PARI
    is(n)=omega(n)%2==0 \\ Charles R Greathouse IV, Sep 14 2015
    

Formula

From Benoit Cloitre, Dec 08 2002: (Start)
k such that Sum_{d|k} mu(d)*A000005(d) = (-1)^omega(k) = +1 where mu(d)=A008683(d), and omega(d)=A001221(d).
k such that A023900(k) > 0. (End)
Union of A007774, A033993, A074969,... - R. J. Mathar, Jul 22 2025

Extensions

Corrected by Dan Pritikin (pritikd(AT)muohio.edu), May 29 2002

A285799 Number of partitions of n into parts with an odd number of distinct prime divisors.

Original entry on oeis.org

1, 0, 1, 1, 2, 2, 3, 4, 6, 7, 9, 12, 15, 19, 23, 29, 37, 44, 54, 66, 80, 96, 115, 138, 165, 196, 231, 275, 322, 380, 444, 520, 608, 706, 821, 952, 1102, 1272, 1467, 1688, 1941, 2226, 2549, 2917, 3329, 3798, 4324, 4918, 5587, 6337, 7180, 8125, 9184, 10369, 11695, 13174, 14828, 16671, 18723, 21011, 23551
Offset: 0

Views

Author

Ilya Gutkovskiy, Apr 26 2017

Keywords

Examples

			a(7) = 4 because we have [7], [5, 2], [4, 3] and [3, 2, 2].
		

Crossrefs

Cf. A001156 (number of partitions into parts with an odd number of divisors), A030230, A285798.

Programs

  • Mathematica
    nmax = 60; CoefficientList[Series[Product[1/(1 - Boole[OddQ[PrimeNu[k]]] x^k), {k, 1, nmax}], {x, 0, nmax}], x]

Formula

G.f.: Product_{k>=1} 1/(1 - x^A030230(k)).

A123066 (Number of numbers <= n with an odd number of distinct prime factors) - (number of numbers <= n with an even number of distinct prime factors).

Original entry on oeis.org

0, 1, 2, 3, 4, 3, 4, 5, 6, 5, 6, 5, 6, 5, 4, 5, 6, 5, 6, 5, 4, 3, 4, 3, 4, 3, 4, 3, 4, 5, 6, 7, 6, 5, 4, 3, 4, 3, 2, 1, 2, 3, 4, 3, 2, 1, 2, 1, 2, 1, 0, -1, 0, -1, -2, -3, -4, -5, -4, -3, -2, -3, -4, -3, -4, -3, -2, -3, -4, -3, -2, -3, -2, -3, -4, -5, -6, -5, -4, -5, -4, -5, -4, -3, -4, -5, -6, -7, -6, -5, -6, -7, -8, -9, -10
Offset: 1

Views

Author

Keywords

Comments

Analog of A072203 for number of distinct factors. Conjecture that sequence changes sign infinitely often, although the next sign change is probably large.
The signs first change at n = 52 and then change again at n = 7954. - Harvey P. Dale, Jul 04 2012

Crossrefs

Programs

  • Maple
    a:= proc(n) option remember; `if`(n<2, 0, a(n-1)+
          `if`(nops(ifactors(n)[2])::odd, 1, -1))
        end:
    seq(a(n), n=1..120);  # Alois P. Heinz, Dec 21 2018
  • Mathematica
    dpf[n_] := Module[{df = PrimeNu[n]}, If[OddQ[df], 1, -1]]; Join[{0}, Accumulate[ Array[dpf, 100, 2]]] (* Harvey P. Dale, Jul 04 2012 *)
  • Python
    from sympy import primenu
    def A123066(n): return 1+sum(1 if primenu(i)&1 else -1 for i in range(1,n+1)) # Chai Wah Wu, Dec 31 2022

Formula

a(n) = Sum_{k>=1} (-1)^(k-1) * A346617(n,k). - Alois P. Heinz, Aug 19 2021

A279456 Numbers k such that number of distinct primes dividing k is odd and number of prime divisors (counted with multiplicity) of k is even.

Original entry on oeis.org

4, 9, 16, 25, 49, 60, 64, 81, 84, 90, 121, 126, 132, 140, 150, 156, 169, 198, 204, 220, 228, 234, 240, 256, 260, 276, 289, 294, 306, 308, 315, 336, 340, 342, 348, 350, 360, 361, 364, 372, 380, 414, 444, 460, 476, 490, 492, 495, 504, 516, 522, 525, 528, 529, 532, 540, 550, 558, 560, 564, 572, 580, 585, 600
Offset: 1

Views

Author

Ilya Gutkovskiy, Dec 12 2016

Keywords

Comments

Intersection of A028260 and A030230.
Numbers k such that A000035(A001221(k)) = 1 and A000035(A001222(k)) = 0.
Numbers k such that A076479(k) = -1 and A008836(k) = 1.

Examples

			90 is in the sequence because 90 = 2*3^2*5 therefore omega(90) = 3 {2,3,5} is odd and bigomega(90) = 4 {2,3,3,5} is even.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[600], Mod[PrimeNu[#1], 2] == 1 && Mod[PrimeOmega[#1], 2] == 0 & ]
  • PARI
    is(k) = {my(f = factor(k)); omega(f) % 2 && !(bigomega(f) % 2);} \\ Amiram Eldar, Sep 17 2024

A279457 Numbers k such that number of distinct primes dividing k is odd and number of prime divisors (counted with multiplicity) of k is odd.

Original entry on oeis.org

2, 3, 5, 7, 8, 11, 13, 17, 19, 23, 27, 29, 30, 31, 32, 37, 41, 42, 43, 47, 53, 59, 61, 66, 67, 70, 71, 73, 78, 79, 83, 89, 97, 101, 102, 103, 105, 107, 109, 110, 113, 114, 120, 125, 127, 128, 130, 131, 137, 138, 139, 149, 151, 154, 157, 163, 165, 167, 168, 170, 173, 174, 179, 180, 181, 182, 186, 190, 191, 193, 195, 197, 199, 211
Offset: 1

Views

Author

Ilya Gutkovskiy, Dec 12 2016

Keywords

Comments

Intersection of A026424 and A030230.
Numbers k such that A000035(A001221(k)) = 1 and A000035(A001222(k)) = 1.
Numbers k such that A076479(k) = -1 and A008836(k) = -1.
All primes (A000040) are included in the sequence.

Examples

			27 is in the sequence because 27 = 3^3 therefore omega(27) = 1 {3} is odd and bigomega(27) = 3 {3,3,3} is odd.
		

Crossrefs

Programs

  • Mathematica
    Select[Range[220], Mod[PrimeNu[#1], 2] == Mod[PrimeOmega[#1], 2] == 1 & ]
    Select[Range[300],AllTrue[{PrimeNu[#],PrimeOmega[#]},OddQ]&] (* Harvey P. Dale, Jul 10 2023 *)
  • PARI
    is(k) = {my(f = factor(k)); omega(f) % 2 && bigomega(f) % 2;} \\ Amiram Eldar, Sep 17 2024

A286220 Number of partitions of n into distinct parts with an odd number of distinct prime divisors.

Original entry on oeis.org

1, 0, 1, 1, 1, 2, 1, 3, 2, 4, 3, 5, 5, 6, 7, 7, 10, 9, 12, 12, 15, 15, 18, 19, 22, 24, 26, 30, 32, 36, 40, 43, 49, 52, 58, 63, 69, 76, 81, 91, 96, 108, 114, 127, 135, 148, 159, 173, 186, 202, 217, 234, 253, 271, 293, 313, 339, 361, 390, 416, 449, 478, 514, 547, 588, 625, 671, 714, 763, 815, 867
Offset: 0

Views

Author

Ilya Gutkovskiy, May 04 2017

Keywords

Examples

			a(9) = 4 because we have [9], [7, 2], [5, 4] and [4, 3, 2].
		

Crossrefs

Programs

  • Mathematica
    nmax = 70; CoefficientList[Series[Product[1 + Boole[OddQ[PrimeNu[k]]] x^k, {k, 1, nmax}], {x, 0, nmax}], x]

Formula

G.f.: Product_{k>=1} (1 + x^A030230(k)).

A306146 Numbers k such that A000010(A023900(k)) = A023900(A000010(k)).

Original entry on oeis.org

1, 14, 22, 28, 44, 46, 56, 75, 88, 92, 94, 112, 118, 166, 176, 184, 188, 214, 224, 236, 332, 334, 352, 358, 368, 375, 376, 422, 428, 448, 454, 472, 526, 639, 662, 664, 668, 694, 704, 716, 718, 736, 752, 766, 844, 856, 867, 896, 908, 926, 934, 944, 958, 1006, 1052, 1075, 1094, 1126, 1142, 1174, 1179, 1324
Offset: 1

Views

Author

Torlach Rush, Aug 11 2018

Keywords

Comments

No term is a product of an odd number of distinct prime factors (because then A023900 is negative, i.e., contains no terms from A030230).
For known terms:
- a(n) is nonsquarefree iff A000010(n) is nonsquarefree.
- If a(n) is squarefree then A000010(n) and A023900(n) are both squarefree.

Examples

			75 is a term because A000010(A023900(75)) = A023900(A000010(75)) = 4.
		

Crossrefs

Programs

  • Maple
    isA306146 := proc(n)
        local a239 ;
        a239 := A023900(n) ;
        if a239 >= 1 then
            simplify( numtheory[phi](a239) = A023900(numtheory[phi](n)) );
        else
            false;
        end if;
    end proc:
    for n from 1 to 1000 do
        if isA306146(n) then
            printf("%d,",n) ;
        end if;
    end do: # R. J. Mathar, Feb 14 2019
  • Mathematica
    f[p_, e_] := 1 - p; d[1] = 1; d[n_] := Times @@ (f @@@ FactorInteger[n]); Select[Range[1324],(d1 = d[#]) > 0 && d[EulerPhi[#]] == EulerPhi[d1] &] (* Amiram Eldar, Feb 19 2020 *)
  • PARI
    a023900(n) = sumdivmult(n, d, d*moebius(d))
    is(n) = sdm = a023900(n); if(sdm < 0, return(0), sdmphi = a023900(eulerphi(n)); eulerphi(sdm) == sdmphi) \\ David A. Corneth, Aug 17 2018

A286224 Number of compositions (ordered partitions) of n into parts with an odd number of distinct prime divisors.

Original entry on oeis.org

1, 0, 1, 1, 2, 3, 4, 8, 11, 19, 28, 47, 72, 116, 182, 289, 460, 724, 1153, 1820, 2891, 4572, 7249, 11482, 18190, 28821, 45651, 72338, 114582, 181549, 287597, 455647, 721849, 1143590, 1811753, 2870247, 4547245, 7203933, 11412922, 18080907, 28644799, 45380602, 71894401, 113899027, 180444897, 285870668
Offset: 0

Views

Author

Ilya Gutkovskiy, May 04 2017

Keywords

Examples

			a(6) = 4 because we have [4, 2], [3, 3], [2, 4] and [2, 2, 2].
		

Crossrefs

Programs

  • Mathematica
    nmax = 45; CoefficientList[Series[1/(1 - Sum[Boole[OddQ[PrimeNu[k]]] x^k, {k, 1, nmax}]), {x, 0, nmax}], x]

Formula

G.f.: 1/(1 - Sum_{k>=1} x^A030230(k)).
Showing 1-10 of 19 results. Next