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

A237984 Number of partitions of n whose mean is a part.

Original entry on oeis.org

1, 2, 2, 3, 2, 5, 2, 6, 5, 8, 2, 21, 2, 14, 22, 30, 2, 61, 2, 86, 67, 45, 2, 283, 66, 80, 197, 340, 2, 766, 2, 663, 543, 234, 703, 2532, 2, 388, 1395, 4029, 2, 4688, 2, 4476, 7032, 1005, 2, 17883, 2434, 9713, 7684, 14472, 2, 25348, 17562, 37829, 16786, 3721
Offset: 1

Views

Author

Clark Kimberling, Feb 27 2014

Keywords

Comments

a(n) = 2 if and only if n is a prime.

Examples

			a(6) counts these partitions:  6, 33, 321, 222, 111111.
From _Gus Wiseman_, Sep 14 2019: (Start)
The a(1) = 1 through a(10) = 8 partitions (A = 10):
  1  2   3    4     5      6       7        8         9          A
     11  111  22    11111  33      1111111  44        333        55
              1111         222              2222      432        22222
                           321              3221      531        32221
                           111111           4211      111111111  33211
                                            11111111             42211
                                                                 52111
                                                                 1111111111
(End)
		

Crossrefs

Cf. A238478.
The Heinz numbers of these partitions are A327473.
A similar sequence for subsets is A065795.
Dominated by A067538.
The strict case is A240850.
Partitions without their mean are A327472.

Programs

  • Mathematica
    Table[Count[IntegerPartitions[n], p_ /; MemberQ[p, Mean[p]]], {n, 40}]
  • Python
    from sympy.utilities.iterables import partitions
    def A237984(n): return sum(1 for s,p in partitions(n,size=True) if not n%s and n//s in p) # Chai Wah Wu, Sep 21 2023

Formula

a(n) = A000041(n) - A327472(n). - Gus Wiseman, Sep 14 2019

A362611 Number of modes in the prime factorization of n.

Original entry on oeis.org

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

Views

Author

Gus Wiseman, May 05 2023

Keywords

Comments

A mode in a multiset is an element that appears at least as many times as each of the others. For example, the modes of {a,a,b,b,b,c,d,d,d} are {b,d}.
a(n) depends only on the prime signature of n. - Andrew Howroyd, May 08 2023

Examples

			The factorization of 450 is 2*3*3*5*5, modes {3,5}, so a(450) = 2.
The factorization of 900 is 2*2*3*3*5*5, modes {2,3,5}, so a(900) = 3.
The factorization of 1500 is 2*2*3*5*5*5, modes {5}, so a(1500) = 1.
The factorization of 8820 is 2*2*3*3*5*7*7, modes {2,3,7}, so a(8820) = 3.
		

Crossrefs

Positions of first appearances are A002110.
Positions of 1's are A356862, counted by A362608.
Positions of terms > 1 are A362605, counted by A362607.
For co-mode we have A362613, counted by A362615.
This statistic (mode-count) has triangular form A362614.
A027746 lists prime factors (with multiplicity).
A112798 lists prime indices, length A001222, sum A056239.
A359178 ranks partitions with a unique co-mode, counted by A362610.
A362606 ranks partitions with more than one co-mode, counted by A362609.

Programs

  • Mathematica
    Table[x=Last/@If[n==1,0,FactorInteger[n]];Count[x,Max@@x],{n,100}]
  • PARI
    a(n) = if(n==1, 0, my(f=factor(n)[,2], m=vecmax(f)); #select(v->v==m, f)) \\ Andrew Howroyd, May 08 2023
  • Python
    from sympy import factorint
    def A362611(n): return list(v:=factorint(n).values()).count(max(v,default=0)) # Chai Wah Wu, May 08 2023
    

Formula

For n > 1, 1 <= a(n) << log n. - Charles R Greathouse IV, May 09 2023
a(n) <= A001221(n), with equality if and only if n is a power of a squarefree number (A072774). - Amiram Eldar, Mar 02 2025

A327476 Heinz numbers of integer partitions whose mean A326567/A326568 is not a part.

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, 42, 44, 45, 46, 48, 50, 51, 52, 54, 55, 56, 57, 58, 60, 62, 63, 65, 66, 68, 69, 70, 72, 74, 75, 76, 77, 78, 80, 82, 85, 86, 87, 88, 91, 92, 93, 94, 95, 96, 98, 99, 100, 102, 104, 106
Offset: 1

Views

Author

Gus Wiseman, Sep 13 2019

Keywords

Comments

The Heinz number of an integer partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k).

Examples

			The sequence of terms together with their prime indices begins:
    1: {}
    6: {1,2}
   10: {1,3}
   12: {1,1,2}
   14: {1,4}
   15: {2,3}
   18: {1,2,2}
   20: {1,1,3}
   21: {2,4}
   22: {1,5}
   24: {1,1,1,2}
   26: {1,6}
   28: {1,1,4}
   33: {2,5}
   34: {1,7}
   35: {3,4}
   36: {1,1,2,2}
   38: {1,8}
   39: {2,6}
   40: {1,1,1,3}
		

Crossrefs

Complement of A327473.
The enumeration of these partitions by sum is given by A327472.
Subsets whose mean is not an element are A327471.

Programs

  • Mathematica
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    Select[Range[100],!MemberQ[primeMS[#],Mean[primeMS[#]]]&]

A327472 Number of integer partitions of n not containing their mean.

Original entry on oeis.org

1, 0, 0, 1, 2, 5, 6, 13, 16, 25, 34, 54, 56, 99, 121, 154, 201, 295, 324, 488, 541, 725, 957, 1253, 1292, 1892, 2356, 2813, 3378, 4563, 4838, 6840, 7686, 9600, 12076, 14180, 15445, 21635, 25627, 29790, 33309, 44581, 48486, 63259, 70699, 82102, 104553, 124752
Offset: 0

Views

Author

Gus Wiseman, Sep 13 2019

Keywords

Examples

			The a(3) = 1 through a(8) = 16 partitions not containing their mean:
  (21)  (31)   (32)    (42)     (43)      (53)
        (211)  (41)    (51)     (52)      (62)
               (221)   (411)    (61)      (71)
               (311)   (2211)   (322)     (332)
               (2111)  (3111)   (331)     (422)
                       (21111)  (421)     (431)
                                (511)     (521)
                                (2221)    (611)
                                (3211)    (3311)
                                (4111)    (5111)
                                (22111)   (22211)
                                (31111)   (32111)
                                (211111)  (41111)
                                          (221111)
                                          (311111)
                                          (2111111)
		

Crossrefs

The Heinz numbers of these partitions are A327476.
Partitions with their mean are A237984.
Subsets without their mean are A327471.
Subsets with n but without their mean are A327477.
Strict partitions without their mean are A240851.

Programs

  • Mathematica
    Table[Length[Select[IntegerPartitions[n],!MemberQ[#,Mean[#]]&]],{n,0,20}]
  • Python
    from sympy.utilities.iterables import partitions
    def A327472(n): return sum(1 for s,p in partitions(n,size=True) if n%s or n//s not in p) if n else 1 # Chai Wah Wu, Sep 21 2023

A359889 Numbers that are 1 or whose prime indices have the same mean as median.

Original entry on oeis.org

1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 13, 14, 15, 16, 17, 19, 21, 22, 23, 25, 26, 27, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 41, 43, 46, 47, 49, 51, 53, 55, 57, 58, 59, 61, 62, 64, 65, 67, 69, 71, 73, 74, 77, 79, 81, 82, 83, 85, 86, 87, 89, 90, 91, 93, 94
Offset: 1

Views

Author

Gus Wiseman, Jan 22 2023

Keywords

Comments

First differs from A236510 in having 252 (prime indices {1,1,2,2,4}).
A prime index of n is a number m such that prime(m) divides n. The multiset of prime indices of n is row n of A112798.
The median of a multiset is either the middle part (for odd length), or the average of the two middle parts (for even length).

Examples

			The prime indices of 900 are {1,1,2,2,3,3}, with mean 2 and median 2, so 900 is in the sequence.
		

Crossrefs

These partitions are counted by A240219, strict A359897.
The LHS (mean of prime indices) is A326567/A326568.
The complement is A359890, counted by A359894.
The odd-length case is A359891, complement A359892, counted by A359895.
The RHS (median of prime indices) is A360005/2.
A058398 counts partitions by mean, see also A008284, A327482.
A088529/A088530 gives mean of prime signature A124010.
A112798 lists prime indices, length A001222, sum A056239.
A316413 lists numbers whose prime indices have integer mean.
A359893 and A359901 count partitions by median, odd-length A359902.
A359908 lists numbers whose prime indices have integer median.

Programs

  • Mathematica
    prix[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    Select[Range[100],#==1||Mean[prix[#]]==Median[prix[#]]&]

Formula

Numbers n such that A326567(n)/A326568(n) = A360005(n)/2.

A356862 Numbers with a unique largest prime exponent.

Original entry on oeis.org

2, 3, 4, 5, 7, 8, 9, 11, 12, 13, 16, 17, 18, 19, 20, 23, 24, 25, 27, 28, 29, 31, 32, 37, 40, 41, 43, 44, 45, 47, 48, 49, 50, 52, 53, 54, 56, 59, 60, 61, 63, 64, 67, 68, 71, 72, 73, 75, 76, 79, 80, 81, 83, 84, 88, 89, 90, 92, 96, 97, 98, 99, 101, 103, 104
Offset: 1

Views

Author

Jens Ahlström, Sep 01 2022

Keywords

Comments

If the prime factorization of k has a unique largest exponent, then k is a term.
Numbers whose multiset of prime factors (with multiplicity) has a unique mode. - Gus Wiseman, May 12 2023
Disjoint union of A246655 and A376250. The asymptotic density of this sequence, 0.3660366524547281232052..., is equal to the density of A376250 since the prime powers have a zero density. - Amiram Eldar, Sep 17 2024

Examples

			Prime powers (A246655) are in the sequence, since they have only one prime exponent in their prime factorization, hence a unique largest exponent.
144 is in the sequence, since 144 = 2^4 * 3^2 and there is the unique largest exponent 4.
225 is not in the sequence, since 225 = 3^2 * 5^2 and the largest exponent 2 is not unique, but rather it is the exponent of both the prime factor 3 and of the prime factor 5.
		

Crossrefs

Subsequence of A319161 (which has additional terms 1, 180, 252, 300, 396, 450, 468, ...).
For factors instead of exponents we have A102750.
For smallest instead of largest we have A359178, counted by A362610.
The complement is A362605, counted by A362607.
The complement for co-mode is A362606, counted by A362609.
Partitions of this type are counted by A362608.
These are the positions of 1's in A362611, for co-modes A362613.
A001221 is the number of prime exponents, sum A001222.
A027746 lists prime factors, A112798 indices, A124010 exponents.
A362614 counts partitions by number of modes, A362615 co-modes.

Programs

  • Mathematica
    Select[Range[2, 100], Count[(e = FactorInteger[#][[;; , 2]]), Max[e]] == 1 &] (* Amiram Eldar, Sep 01 2022 *)
  • PARI
    isok(k) = if (k>1, my(f=factor(k), m=vecmax(f[,2]), w=select(x->(f[x,2] == m), [1..#f~])); #w == 1); \\ Michel Marcus, Sep 01 2022
  • Python
    from sympy import factorint
    from collections import Counter
    def ok(k):
        c = Counter(factorint(k)).most_common(2)
        return not (len(c) > 1 and c[0][1] == c[1][1])
    print([k for k in range(2, 105) if ok(k)])
    
  • Python
    from sympy import factorint
    from itertools import count, islice
    def A356862_gen(startvalue=2): # generator of terms >= startvalue
        return filter(lambda n:len(f:=sorted(factorint(n).values(),reverse=True))==1 or f[0]!=f[1],count(max(startvalue,2)))
    A356862_list = list(islice(A356862_gen(),30)) # Chai Wah Wu, Sep 10 2022
    

A362613 Number of co-modes in the prime factorization of n.

Original entry on oeis.org

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

Views

Author

Gus Wiseman, May 05 2023

Keywords

Comments

First differs from A327500 at n = 180.
First differs from A351946 at n = 180.
First differs from A353507 at n = 180.
We define a co-mode in a multiset to be an element that appears at most as many times as each of the others. For example, the co-modes of {a,a,b,b,b,c,c} are {a,c}.
a(n) depends only on the prime signature of n. - Andrew Howroyd, May 08 2023

Examples

			The factorization of 180 is 2*2*3*3*5, co-modes {5}, so a(180) = 1.
The factorization of 900 is 2*2*3*3*5*5, co-modes {2,3,5}, so a(900) = 3.
The factorization of 8820 is 2*2*3*3*5*7*7, co-modes {5}, so a(8820) = 1.
		

Crossrefs

Positions of first appearances are A002110.
Positions of 1's are A359178, counted by A362610.
Positions of terms > 1 are A362606, counted by A362609.
For mode we have A362611, counted by A362614.
Counting partitions by this statistic (co-mode count) gives A362615.
A027746 lists prime factors (with multiplicity).
A112798 lists prime indices, length A001222, sum A056239.

Programs

  • Mathematica
    Table[x=Last/@If[n==1,0,FactorInteger[n]];Count[x,Min@@x],{n,100}]
  • PARI
    a(n) = if(n==1, 0, my(f=factor(n)[,2], m=vecmin(f)); #select(v->v==m, f)) \\ Andrew Howroyd, May 08 2023
  • Python
    from sympy import factorint
    def A362613(n):
        v = factorint(n).values()
        w = min(v,default=0)
        return sum(1 for e in v if e<=w) # Chai Wah Wu, May 08 2023
    

A359894 Number of integer partitions of n whose parts do not have the same mean as median.

Original entry on oeis.org

0, 0, 0, 0, 1, 3, 3, 10, 13, 20, 28, 49, 53, 93, 113, 145, 203, 287, 329, 479, 556, 724, 955, 1242, 1432, 1889, 2370, 2863, 3502, 4549, 5237, 6825, 8108, 9839, 12188, 14374, 16958, 21617, 25852, 30582, 36100, 44561, 51462, 63238, 73386, 85990, 105272, 124729
Offset: 0

Views

Author

Gus Wiseman, Jan 20 2023

Keywords

Examples

			The a(4) = 1 through a(8) = 13 partitions:
  (211)  (221)   (411)    (322)     (332)
         (311)   (3111)   (331)     (422)
         (2111)  (21111)  (421)     (431)
                          (511)     (521)
                          (2221)    (611)
                          (3211)    (4211)
                          (4111)    (5111)
                          (22111)   (22211)
                          (31111)   (32111)
                          (211111)  (41111)
                                    (221111)
                                    (311111)
                                    (2111111)
		

Crossrefs

The complement is counted by A240219.
These partitions are ranked by A359890, complement A359889.
The odd-length case is ranked by A359892, complement A359891.
The odd-length case is A359896, complement A359895.
The strict case is A359898, complement A359897.
The odd-length strict case is A359900, complement A359899.
A000041 counts partitions, strict A000009.
A008284 and A058398 count partitions by mean, ranked by A326567/A326568.
A008289 counts strict partitions by mean.
A027193 counts odd-length partitions, strict A067659, ranked by A026424.
A067538 counts ptns with integer mean, strict A102627, ranked by A316413.
A237984 counts ptns containing their mean, strict A240850, ranked by A327473.
A325347 counts ptns with integer median, strict A359907, ranked by A359908.
A326622 counts factorizations with integer mean, strict A328966.
A359893 and A359901 count partitions by median, odd-length A359902.
A359909 counts factorizations with the same mean as median, odd-len A359910.

Programs

  • Mathematica
    Table[Length[Select[IntegerPartitions[n],Mean[#]!=Median[#]&]],{n,0,30}]

A359178 Numbers with a unique smallest prime exponent.

Original entry on oeis.org

2, 3, 4, 5, 7, 8, 9, 11, 12, 13, 16, 17, 18, 19, 20, 23, 24, 25, 27, 28, 29, 31, 32, 37, 40, 41, 43, 44, 45, 47, 48, 49, 50, 52, 53, 54, 56, 59, 61, 63, 64, 67, 68, 71, 72, 73, 75, 76, 79, 80, 81, 83, 88, 89, 92, 96, 97, 98, 99, 101, 103, 104, 107, 108, 109, 112, 113, 116, 117
Offset: 1

Views

Author

Jens Ahlström, Jan 08 2023

Keywords

Comments

180 is the smallest number with a unique smallest prime exponent that is not a member of A130091.

Examples

			2 = 2^1 is a term since it has 1 as a unique smallest exponent.
6 = 2^1 * 3^1 is not a term since it has two primes with the same smallest exponent.
180 = 2^2 * 3^2 * 5^1 is a term since it has 1 as a unique smallest exponent.
		

Crossrefs

For parts instead of multiplicities we have A247180, counted by A002865.
For greatest instead of smallest we have A356862, counted by A362608.
The complement is A362606, counted by A362609.
Partitions of this type are counted by A362610.
These are the positions of 1's in A362613, for modes A362611.
A001221 counts prime exponents and A001222 adds them up.
A027746 lists prime factors, A112798 indices, A124010 exponents.

Programs

  • Mathematica
    q[n_] := Module[{e = FactorInteger[n][[;; , 2]]}, Count[e, Min[e]] == 1]; Select[Range[2, 200], q] (* Amiram Eldar, Jan 08 2023 *)
  • PARI
    isok(n) = if (n>1, my(f=factor(n), e = vecmin(f[,2])); #select(x->(x==e), f[,2], 1) == 1); \\ Michel Marcus, Jan 27 2023
  • Python
    from sympy import factorint
    def ok(k):
      c = sorted(factorint(k).values())
      return len(c) == 1 or c[0] != c[1]
    print([k for k in range(2, 118) if ok(k)])
    
  • Python
    from itertools import count, islice
    from sympy import factorint
    def A359178_gen(startvalue=2): # generator of terms >= startvalue
        return filter(lambda n:(f:=list(factorint(n).values())).count(min(f))==1,count(max(startvalue,2)))
    A359178_list = list(islice(A359178_gen(),20)) # Chai Wah Wu, Feb 08 2023
    

A362605 Numbers whose prime factorization has more than one mode. Numbers without a unique exponent of maximum frequency in the prime signature.

Original entry on oeis.org

6, 10, 14, 15, 21, 22, 26, 30, 33, 34, 35, 36, 38, 39, 42, 46, 51, 55, 57, 58, 62, 65, 66, 69, 70, 74, 77, 78, 82, 85, 86, 87, 91, 93, 94, 95, 100, 102, 105, 106, 110, 111, 114, 115, 118, 119, 122, 123, 129, 130, 133, 134, 138, 141, 142, 143, 145, 146, 154
Offset: 1

Views

Author

Gus Wiseman, May 05 2023

Keywords

Comments

A mode in a multiset is an element that appears at least as many times as each of the others. For example, the modes of {a,a,b,b,b,c,d,d,d} are {b,d}.

Examples

			The prime indices of 180 are {1,1,2,2,3}, with modes {1,2}, so 180 is in the sequence, and the sequence differs from A182853.
The terms together with their prime indices begin:
     6: {1,2}
    10: {1,3}
    14: {1,4}
    15: {2,3}
    21: {2,4}
    22: {1,5}
    26: {1,6}
    30: {1,2,3}
    33: {2,5}
    34: {1,7}
    35: {3,4}
    36: {1,1,2,2}
    38: {1,8}
    39: {2,6}
    42: {1,2,4}
    46: {1,9}
    51: {2,7}
    55: {3,5}
		

Crossrefs

The first term with bigomega n appears to be A166023(n).
The complement is A356862, counted by A362608.
For co-mode complement we have A359178, counted by A362610.
For co-mode we have A362606, counted by A362609.
Partitions of this type are counted by A362607.
These are the positions of terms > 1 in A362611.
A112798 lists prime indices, length A001222, sum A056239.
A362614 counts partitions by number of modes, ranks A362611.
A362615 counts partitions by number of co-modes, ranks A362613.

Programs

  • Maple
    q:= n-> (l-> nops(l)>1 and l[-1]=l[-2])(sort(map(i-> i[2], ifactors(n)[2]))):
    select(q, [$1..250])[];  # Alois P. Heinz, May 10 2023
  • Mathematica
    Select[Range[100],Count[Last/@FactorInteger[#], Max@@Last/@FactorInteger[#]]>1&]
  • PARI
    is(n) = {my(e = factor(n)[, 2]); if(#e < 2, 0, e = vecsort(e); e[#e-1] == e[#e]);} \\ Amiram Eldar, Jan 20 2024
  • Python
    from sympy import factorint
    def ok(n): return n>1 and (e:=list(factorint(n).values())).count(max(e))>1
    print([k for k in range(155) if ok(k)]) # Michael S. Branicky, May 06 2023
    
Showing 1-10 of 68 results. Next