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.

Previous Showing 11-20 of 25 results. Next

A321728 Number of integer partitions of n whose Young diagram cannot be partitioned into vertical sections of the same sizes as the parts of the original partition.

Original entry on oeis.org

0, 0, 1, 1, 2, 3, 5, 7, 10, 14, 20, 28, 37, 50
Offset: 0

Views

Author

Gus Wiseman, Nov 18 2018

Keywords

Comments

First differs from A000701 at a(11) = 28, A000701(11) = 27
A vertical section is a partial Young diagram with at most one square in each row.
Conjecture: a(n) is the number of non-half-loop-graphical partitions of n. An integer partition is half-loop-graphical if it comprises the multiset of vertex-degrees of some graph with half-loops, where a half-loop is an edge with one vertex, to be distinguished from a full loop, which has two equal vertices.

Examples

			The a(2) = 1 through a(9) = 14 partitions whose Young diagram cannot be partitioned into vertical sections of the same sizes as the parts of the original partition are the same as the non-half-loop-graphical partitions up to n = 9:
  (2)  (3)  (4)   (5)   (6)    (7)    (8)     (9)
            (31)  (32)  (33)   (43)   (44)    (54)
                  (41)  (42)   (52)   (53)    (63)
                        (51)   (61)   (62)    (72)
                        (411)  (331)  (71)    (81)
                               (421)  (422)   (432)
                               (511)  (431)   (441)
                                      (521)   (522)
                                      (611)   (531)
                                      (5111)  (621)
                                              (711)
                                              (4311)
                                              (5211)
                                              (6111)
For example, a complete list of all half/full-loop-graphs with degrees y = (4,3,1) is the following:
  {{1,1},{1,2},{1,3},{2,2}}
  {{1},{2},{1,1},{1,2},{2,3}}
  {{1},{2},{1,1},{1,3},{2,2}}
  {{1},{3},{1,1},{1,2},{2,2}}
None of these is a half-loop-graph, as they have full loops (x,x), so y is counted under a(8).
		

Crossrefs

The complement is counted by A321729.
The following pertain to the conjecture.
Half-loop-graphical partitions by length are A029889 or A339843 (covering).
The version for full loops is A339655.
A027187 counts partitions of even length, with Heinz numbers A028260.
A058696 counts partitions of even numbers, ranked by A300061.
A320663/A339888 count unlabeled multiset partitions into singletons/pairs.
A322661 counts labeled covering half-loop-graphs, ranked by A340018/A340019.
A339659 counts graphical partitions of 2n into k parts.

Programs

  • Mathematica
    spsu[,{}]:={{}};spsu[foo,set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@spsu[Select[foo,Complement[#,Complement[set,s]]=={}&],Complement[set,s]]]/@Cases[foo,{i,_}];
    ptnpos[y_]:=Position[Table[1,{#}]&/@y,1];
    ptnverts[y_]:=Select[Join@@Table[Subsets[ptnpos[y],{k}],{k,Reverse[Union[y]]}],UnsameQ@@First/@#&];
    Table[Length[Select[IntegerPartitions[n],Select[spsu[ptnverts[#],ptnpos[#]],Function[p,Sort[Length/@p]==Sort[#]]]=={}&]],{n,8}]

Formula

a(n) is the number of integer partitions y of n such that the coefficient of m(y) in e(y) is zero, where m is monomial and e is elementary symmetric functions.
a(n) = A000041(n) - A321729(n).

A349801 Number of integer partitions of n into three or more parts or into two equal parts.

Original entry on oeis.org

0, 0, 1, 1, 3, 4, 8, 11, 18, 25, 37, 50, 71, 94, 128, 168, 223, 288, 376, 480, 617, 781, 991, 1243, 1563, 1945, 2423, 2996, 3704, 4550, 5589, 6826, 8333, 10126, 12293, 14865, 17959, 21618, 25996, 31165, 37318, 44562, 53153, 63239, 75153, 89111, 105535, 124730
Offset: 0

Views

Author

Gus Wiseman, Dec 23 2021

Keywords

Comments

This sequence arose as the following degenerate case. If we define a sequence to be alternating if it is alternately strictly increasing and strictly decreasing, starting with either, then a(n) is the number of non-alternating integer partitions of n. Under this interpretation:
- The non-strict case is A047967, weak A349796, weak complement A349795.
- The complement is counted by A065033(n) = ceiling(n/2) for n > 0.
- These partitions are ranked by A289553 \ {1}, complement A167171 \/ {1}.
- The version for compositions is A345192, ranked by A345168.
- The weak version for compositions is A349053, ranked by A349057.
- The weak version is A349061, complement A349060, ranked by A349794.

Examples

			The a(2) = 1 through a(7) = 11 partitions:
  (11)  (111)  (22)    (221)    (33)      (322)
               (211)   (311)    (222)     (331)
               (1111)  (2111)   (321)     (421)
                       (11111)  (411)     (511)
                                (2211)    (2221)
                                (3111)    (3211)
                                (21111)   (4111)
                                (111111)  (22111)
                                          (31111)
                                          (211111)
                                          (1111111)
		

Crossrefs

A000041 counts partitions, ordered A011782.
A001250 counts alternating permutations, complement A348615.
A004250 counts partitions into three or more parts, strict A347548.
A025047/A025048/A025049 count alternating compositions, ranked by A345167.
A096441 counts weakly alternating 0-appended partitions.
A345165 counts partitions w/ no alternating permutation, complement A345170.

Programs

  • Mathematica
    Table[Length[Select[IntegerPartitions[n],MatchQ[#,{x_,x_}|{,,__}]&]],{n,0,10}]

Formula

a(1) = 0; a(n > 0) = A000041(n) - ceiling(n/2).

A325399 Heinz numbers of integer partitions whose k-th differences are strictly decreasing for all k >= 0.

Original entry on oeis.org

1, 2, 3, 5, 6, 7, 10, 11, 13, 14, 15, 17, 19, 21, 22, 23, 26, 29, 31, 33, 34, 35, 37, 38, 39, 41, 43, 46, 47, 51, 53, 55, 57, 58, 59, 61, 62, 65, 67, 69, 70, 71, 73, 74, 77, 79, 82, 83, 85, 86, 87, 89, 91, 93, 94, 95, 97, 101, 103, 106, 107, 109, 111, 113, 115
Offset: 1

Views

Author

Gus Wiseman, May 02 2019

Keywords

Comments

First differs from A167171 in having 70. First differs from A325398 in lacking 42.
The Heinz number of an integer partition (y_1,...,y_k) is prime(y_1)*...*prime(y_k).
The differences of a sequence are defined as if the sequence were increasing, so for example the differences of (6,3,1) are (-3,-2).
The zeroth differences of a sequence are the sequence itself, while the k-th differences for k > 0 are the differences of the (k-1)-th differences.
The enumeration of these partitions by sum is given by A325393.

Examples

			The sequence of terms together with their prime indices begins:
    1: {}
    2: {1}
    3: {2}
    5: {3}
    6: {1,2}
    7: {4}
   10: {1,3}
   11: {5}
   13: {6}
   14: {1,4}
   15: {2,3}
   17: {7}
   19: {8}
   21: {2,4}
   22: {1,5}
   23: {9}
   26: {1,6}
   29: {10}
   31: {11}
   33: {2,5}
		

Crossrefs

Programs

  • Mathematica
    primeptn[n_]:=If[n==1,{},Reverse[Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]]];
    Select[Range[100],And@@Table[Greater@@Differences[primeptn[#],k],{k,0,PrimeOmega[#]}]&]

A321729 Number of integer partitions of n whose Young diagram can be partitioned into vertical sections of the same sizes as the parts of the original partition.

Original entry on oeis.org

1, 1, 1, 2, 3, 4, 6, 8, 12, 16, 22, 28, 40, 51
Offset: 0

Views

Author

Gus Wiseman, Nov 18 2018

Keywords

Comments

First differs from A046682 at a(11) = 28, A046682(11) = 29.
A vertical section is a partial Young diagram with at most one square in each row. For example, a suitable partition (shown as a coloring by positive integers) of the Young diagram of (322) is:
1 2 3
1 2
2 3
Conjecture: a(n) is the number of half-loop-graphical partitions of n. An integer partition is half-loop-graphical if it comprises the multiset of vertex-degrees of some graph with half-loops, where a half-loop is an edge with one vertex, to be distinguished from a full loop, which has two equal vertices.

Examples

			The a(1) = 1 through a(8) = 12 partitions whose Young diagram cannot be partitioned into vertical sections of the same sizes as the parts of the original partition are the same as the half-loop-graphical partitions up to n = 8:
  (1)  (11)  (21)   (22)    (221)    (222)     (322)      (332)
             (111)  (211)   (311)    (321)     (2221)     (2222)
                    (1111)  (2111)   (2211)    (3211)     (3221)
                            (11111)  (3111)    (4111)     (3311)
                                     (21111)   (22111)    (4211)
                                     (111111)  (31111)    (22211)
                                               (211111)   (32111)
                                               (1111111)  (41111)
                                                          (221111)
                                                          (311111)
                                                          (2111111)
                                                          (11111111)
For example, the half-loop-graphs
  {{1},{1,2},{1,3},{2,3}}
  {{1},{2},{3},{1,2},{1,3}}
both have degrees y = (3,2,2), so y is counted under a(7).
		

Crossrefs

The complement is counted by A321728.
The following pertain to the conjecture.
Half-loop-graphical partitions by length are A029889 or A339843 (covering).
The version for full loops is A339656.
A027187 counts partitions of even length, ranked by A028260.
A058696 counts partitions of even numbers, ranked by A300061.
A320663/A339888 count unlabeled multiset partitions into singletons/pairs.
A322661 counts labeled covering half-loop-graphs, ranked by A340018/A340019.
A339659 is a triangle counting graphical partitions by length.

Programs

  • Mathematica
    spsu[,{}]:={{}};spsu[foo,set:{i_,_}]:=Join@@Function[s,Prepend[#,s]&/@spsu[Select[foo,Complement[#,Complement[set,s]]=={}&],Complement[set,s]]]/@Cases[foo,{i,_}];
    ptnpos[y_]:=Position[Table[1,{#}]&/@y,1];
    ptnverts[y_]:=Select[Join@@Table[Subsets[ptnpos[y],{k}],{k,Reverse[Union[y]]}],UnsameQ@@First/@#&];
    Table[Length[Select[IntegerPartitions[n],Length[Select[spsu[ptnverts[#],ptnpos[#]],Function[p,Sort[Length/@p]==Sort[#]]]]>0&]],{n,8}]

Formula

a(n) is the number of integer partitions y of n such that the coefficient of m(y) in e(y) is nonzero, where m is monomial symmetric functions and e is elementary symmetric functions.
a(n) = A000041(n) - A321728(n).

A289553 Numbers that are not the product of two distinct noncomposite numbers (A008578).

Original entry on oeis.org

1, 4, 8, 9, 12, 16, 18, 20, 24, 25, 27, 28, 30, 32, 36, 40, 42, 44, 45, 48, 49, 50, 52, 54, 56, 60, 63, 64, 66, 68, 70, 72, 75, 76, 78, 80, 81, 84, 88, 90, 92, 96, 98, 99, 100, 102, 104, 105, 108, 110, 112, 114, 116, 117, 120, 121, 124, 125, 126, 128, 130, 132
Offset: 1

Views

Author

Jaroslav Krizek, Jul 07 2017

Keywords

Comments

Numbers k such that tau(k) = A000005(k) is not equal to 2*omega(k) = 2*A001221(k).

Examples

			Number 6 is not in the sequence because 6 = 2 * 3.
		

Crossrefs

Complement of A167171.
Cf. A246716 (with two distinct primes), A008578 (with two distinct nonprimes), A289555 (with two distinct composites).

Programs

  • Magma
    [n: n in [1..1000] | NumberOfDivisors(n) ne 2*#PrimeDivisors(n)];

A339843 Number of distinct sorted degree sequences among all n-vertex half-loop-graphs without isolated vertices.

Original entry on oeis.org

1, 1, 3, 9, 29, 97, 336, 1188, 4275, 15579, 57358, 212908, 795657, 2990221, 11291665, 42814783, 162920417, 621885767, 2380348729
Offset: 0

Views

Author

Gus Wiseman, Dec 27 2020

Keywords

Comments

In the covering case, these degree sequences, sorted in decreasing order, are the same thing as half-loop-graphical partitions (A321729). An integer partition is half-loop-graphical if it comprises the multiset of vertex-degrees of some graph with half-loops, where a half-loop is an edge with one vertex.
The following are equivalent characteristics for any positive integer n:
(1) the prime indices of n can be partitioned into distinct singletons or strict pairs, i.e., into a set of half-loops or edges;
(2) n can be factored into distinct primes or squarefree semiprimes;
(3) the prime signature of n is half-loop-graphical.

Examples

			The a(0) = 1 through a(3) = 9 sorted degree sequences:
  ()  (1)  (1,1)  (1,1,1)
           (2,1)  (2,1,1)
           (2,2)  (2,2,1)
                  (2,2,2)
                  (3,1,1)
                  (3,2,1)
                  (3,2,2)
                  (3,3,2)
                  (3,3,3)
For example, the half-loop-graphs
  {{1},{1,2},{1,3},{2,3}}
  {{1},{2},{3},{1,2},{1,3}}
both have degrees y = (3,2,2), so y is counted under a(3).
		

Crossrefs

See link for additional cross references.
The version for simple graphs is A004251, covering: A095268.
The non-covering version (it allows isolated vertices) is A029889.
The same partitions counted by sum are conjectured to be A321729.
These graphs are counted by A006125 shifted left, covering: A322661.
The version for full loops is A339844, covering: A339845.
These graphs are ranked by A340018 and A340019.
A006125 counts labeled simple graphs, covering: A006129.
A027187 counts partitions of even length, ranked by A028260.
A058696 counts partitions of even numbers, ranked by A300061.
A320663/A339888 count unlabeled multiset partitions into singletons/pairs.
A339659 counts graphical partitions of 2n into k parts.

Programs

  • Mathematica
    Table[Length[Union[Sort[Table[Count[Join@@#,i],{i,n}]]&/@Select[Subsets[Subsets[Range[n],{1,2}]],Union@@#==Range[n]&]]],{n,0,5}]

Formula

a(n) = A029889(n) - A029889(n-1) for n > 0. - Andrew Howroyd, Jan 10 2024

Extensions

a(7)-a(18) added (using A029889) by Andrew Howroyd, Jan 10 2024

A339002 Numbers of the form prime(x) * prime(y) where x and y are distinct and have a common divisor > 1.

Original entry on oeis.org

21, 39, 57, 65, 87, 91, 111, 115, 129, 133, 159, 183, 185, 203, 213, 235, 237, 247, 259, 267, 299, 301, 303, 305, 319, 321, 339, 365, 371, 377, 393, 417, 427, 445, 453, 481, 489, 497, 515, 517, 519, 543, 551, 553, 559, 565, 579, 597, 611, 623, 669, 685, 687
Offset: 1

Views

Author

Gus Wiseman, Nov 22 2020

Keywords

Examples

			The sequence of terms together with their prime indices begins:
     21: {2,4}     235: {3,15}    393: {2,32}
     39: {2,6}     237: {2,22}    417: {2,34}
     57: {2,8}     247: {6,8}     427: {4,18}
     65: {3,6}     259: {4,12}    445: {3,24}
     87: {2,10}    267: {2,24}    453: {2,36}
     91: {4,6}     299: {6,9}     481: {6,12}
    111: {2,12}    301: {4,14}    489: {2,38}
    115: {3,9}     303: {2,26}    497: {4,20}
    129: {2,14}    305: {3,18}    515: {3,27}
    133: {4,8}     319: {5,10}    517: {5,15}
    159: {2,16}    321: {2,28}    519: {2,40}
    183: {2,18}    339: {2,30}    543: {2,42}
    185: {3,12}    365: {3,21}    551: {8,10}
    203: {4,10}    371: {4,16}    553: {4,22}
    213: {2,20}    377: {6,10}    559: {6,14}
		

Crossrefs

A300912 is the complement in A001358.
A338909 is the not necessarily squarefree version.
A001358 lists semiprimes, with odd and even terms A046315 and A100484.
A005117 lists squarefree numbers.
A006881 lists squarefree semiprimes, with odd/even terms A046388/A100484.
A339005 lists products of pairs of distinct primes of divisible index.
A320656 counts factorizations into squarefree semiprimes.
A338898, A338912, and A338913 give the prime indices of semiprimes, with product A087794, sum A176504, and difference A176506.
A338899, A270650, and A270652 give the prime indices of squarefree semiprimes, with difference A338900.
A338910/A338911 list products of pairs of primes both of odd/even index.
A339003/A339004 list squarefree semiprimes of odd/even index.

Programs

  • Mathematica
    Select[Range[100],SquareFreeQ[#]&&PrimeOmega[#]==2&&GCD@@PrimePi/@First/@FactorInteger[#]>1&]

A350352 Products of three or more distinct prime numbers.

Original entry on oeis.org

30, 42, 66, 70, 78, 102, 105, 110, 114, 130, 138, 154, 165, 170, 174, 182, 186, 190, 195, 210, 222, 230, 231, 238, 246, 255, 258, 266, 273, 282, 285, 286, 290, 310, 318, 322, 330, 345, 354, 357, 366, 370, 374, 385, 390, 399, 402, 406, 410, 418, 426, 429, 430
Offset: 1

Views

Author

Gus Wiseman, Jan 11 2022

Keywords

Comments

First differs from A336568 in lacking 420.

Examples

			The terms and their prime indices begin:
     30: {1,2,3}     182: {1,4,6}      285: {2,3,8}
     42: {1,2,4}     186: {1,2,11}     286: {1,5,6}
     66: {1,2,5}     190: {1,3,8}      290: {1,3,10}
     70: {1,3,4}     195: {2,3,6}      310: {1,3,11}
     78: {1,2,6}     210: {1,2,3,4}    318: {1,2,16}
    102: {1,2,7}     222: {1,2,12}     322: {1,4,9}
    105: {2,3,4}     230: {1,3,9}      330: {1,2,3,5}
    110: {1,3,5}     231: {2,4,5}      345: {2,3,9}
    114: {1,2,8}     238: {1,4,7}      354: {1,2,17}
    130: {1,3,6}     246: {1,2,13}     357: {2,4,7}
    138: {1,2,9}     255: {2,3,7}      366: {1,2,18}
    154: {1,4,5}     258: {1,2,14}     370: {1,3,12}
    165: {2,3,5}     266: {1,4,8}      374: {1,5,7}
    170: {1,3,7}     273: {2,4,6}      385: {3,4,5}
    174: {1,2,10}    282: {1,2,15}     390: {1,2,3,6}
		

Crossrefs

This is the squarefree case of A033942.
Including squarefree semiprimes gives A120944.
The squarefree complement consists of 1 and A167171.
These are the Heinz numbers of the partitions counted by A347548.
A000040 lists prime numbers (exactly 1 prime factor).
A005117 lists squarefree numbers.
A006881 lists squarefree numbers with exactly 2 prime factors.
A007304 lists squarefree numbers with exactly 3 prime factors.
A046386 lists squarefree numbers with exactly 4 prime factors.

Programs

  • Mathematica
    Select[Range[100],SquareFreeQ[#]&&PrimeOmega[#]>=3&]
  • PARI
    is(n,f=factor(n))=my(e=f[,2]); #e>2 && vecmax(e)==1 \\ Charles R Greathouse IV, Jul 08 2022
    
  • PARI
    list(lim)=my(v=List()); forsquarefree(n=30,lim\1, if(#n[2][,2]>2, listput(v,n[1]))); Vec(v) \\ Charles R Greathouse IV, Jul 08 2022
  • Python
    from sympy import factorint
    def ok(n): f = factorint(n, multiple=True); return len(f) == len(set(f)) > 2
    print([k for k in range(431) if ok(k)]) # Michael S. Branicky, Jan 14 2022
    
  • Python
    from math import isqrt, prod
    from sympy import primerange, integer_nthroot, primepi
    def A350352(n):
        def g(x,a,b,c,m): yield from (((d,) for d in enumerate(primerange(b+1,isqrt(x//c)+1),a+1)) if m==2 else (((a2,b2),)+d for a2,b2 in enumerate(primerange(b+1,integer_nthroot(x//c,m)[0]+1),a+1) for d in g(x,a2,b2,c*b2,m-1)))
        def f(x): return int(n+x-sum(sum(primepi(x//prod(c[1] for c in a))-a[-1][0] for a in g(x,0,1,1,i)) for i in range(3,x.bit_length())))
        def bisection(f,kmin=0,kmax=1):
            while f(kmax) > kmax: kmax <<= 1
            while kmax-kmin > 1:
                kmid = kmax+kmin>>1
                if f(kmid) <= kmid:
                    kmax = kmid
                else:
                    kmin = kmid
            return kmax
        return bisection(f,n,n) # Chai Wah Wu, Sep 11 2024
    

A230594 Number of ways to write n as n = x*y, where x, y = noncomposite numbers (A008578), 1 <= x <= n, 1 <= y <= n.

Original entry on oeis.org

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

Views

Author

Jaroslav Krizek, Oct 27 2013

Keywords

Comments

Dirichlet convolution of A080339(n) with itself, where A080339 = characteristic function of noncomposite numbers (A008578).
Dirichlet convolution of functions b(n) and c(n) is function a(n) = Sum_{d|n} b(d) * c(n/d).
a(n) = 0, 1 or 2. a(n) = 0 for numbers n from A033942 (numbers with least 3 prime factors (counted with multiplicity)); a(n) = 1 for n = p^2, p = prime; a(n) = 2 for numbers n from A167171 (A006881 union A000040).

Examples

			For n = 6: a(6) = Sum_(d|6) A080339(d) * A080339(6/d) = 1*0 + 1*1 + 1*1 + 0*1 = 2.
		

Crossrefs

Programs

Formula

a(n) = Sum_{d|n} A080339(d) * A080339(n/d).

A230851 Numbers with divisors which are half odious (A000069) and half evil (A001969).

Original entry on oeis.org

3, 5, 6, 10, 12, 17, 20, 23, 24, 29, 33, 34, 39, 40, 43, 46, 48, 53, 57, 58, 63, 65, 66, 68, 69, 71, 78, 80, 83, 86, 87, 89, 92, 95, 96, 101, 105, 106, 111, 113, 114, 115, 116, 117, 119, 123, 125, 126, 130, 132, 136, 138, 139, 141, 142, 145, 149, 156, 160, 163, 166, 171, 172, 174, 177, 178, 183
Offset: 1

Views

Author

Juri-Stepan Gerasimov, Oct 31 2013

Keywords

Crossrefs

Programs

  • Mathematica
    aQ[n_] := DivisorSum[n, (-1)^DigitCount[#, 2][[1]] &] == 0; Select[Range[200], aQ] (* Amiram Eldar, Sep 23 2019 *)
  • PARI
    is(n)=!sumdiv(n,d,(-1)^hammingweight(d)) \\ Charles R Greathouse IV, Oct 31 2013

Formula

Numbers n such that d(n) = 2*A227872(n) where A227872(n) is number of odious divisors of n.

Extensions

Corrected by Charles R Greathouse IV, Oct 31 2013
Previous Showing 11-20 of 25 results. Next