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

A035310 Let f(n) = number of ways to factor n = A001055(n); a(n) = sum of f(k) over all terms k in A025487 that have n factors.

Original entry on oeis.org

1, 4, 12, 47, 170, 750, 3255, 16010, 81199, 448156, 2579626, 15913058, 102488024, 698976419, 4976098729, 37195337408, 289517846210, 2352125666883, 19841666995265, 173888579505200, 1577888354510786, 14820132616197925, 143746389756336173, 1438846957477988926
Offset: 1

Views

Author

Keywords

Comments

Ways of partitioning an n-multiset with multiplicities some partition of n.
Number of multiset partitions of strongly normal multisets of size n, where a finite multiset is strongly normal if it covers an initial interval of positive integers with weakly decreasing multiplicities. The (weakly) normal version is A255906. - Gus Wiseman, Dec 31 2019

Examples

			a(3) = 12 because there are 3 terms in A025487 with 3 factors, namely 8, 12, 30; and f(8)=3, f(12)=4, f(30)=5 and 3+4+5 = 12.
From _Gus Wiseman_, Dec 31 2019: (Start)
The a(1) = 1 through a(3) = 12 multiset partitions of strongly normal multisets:
  {{1}}  {{1,1}}    {{1,1,1}}
         {{1,2}}    {{1,1,2}}
         {{1},{1}}  {{1,2,3}}
         {{1},{2}}  {{1},{1,1}}
                    {{1},{1,2}}
                    {{1},{2,3}}
                    {{2},{1,1}}
                    {{2},{1,3}}
                    {{3},{1,2}}
                    {{1},{1},{1}}
                    {{1},{1},{2}}
                    {{1},{2},{3}}
(End)
		

Crossrefs

Sequence A035341 counts the ordered cases. Tables A093936 and A095705 distribute the values; e.g. 81199 = 30 + 536 + 3036 + 6181 + 10726 + 11913 + 14548 + 13082 + 21147.
Row sums of A317449.
The uniform case is A317584.
The case with empty intersection is A317755.
The strict case is A317775.
The constant case is A047968.
The set-system case is A318402.
The case of strict parts is A330783.
Multiset partitions of integer partitions are A001970.
Unlabeled multiset partitions are A007716.

Programs

  • Maple
    with(numtheory):
    g:= proc(n, k) option remember;
          `if`(n>k, 0, 1) +`if`(isprime(n), 0,
          add(`if`(d>k, 0, g(n/d, d)), d=divisors(n) minus {1, n}))
        end:
    b:= proc(n, i, l)
          `if`(n=0, g(mul(ithprime(t)^l[t], t=1..nops(l))$2),
          `if`(i<1, 0, add(b(n-i*j, i-1, [l[], i$j]), j=0..n/i)))
        end:
    a:= n-> b(n$2, []):
    seq(a(n), n=1..10);  # Alois P. Heinz, May 26 2013
  • Mathematica
    g[n_, k_] := g[n, k] = If[n > k, 0, 1] + If[PrimeQ[n], 0, Sum[If[d > k, 0, g[n/d, d]], {d, Divisors[n] ~Complement~ {1, n}}]]; b[n_, i_, l_] := If[n == 0, g[p = Product[Prime[t]^l[[t]], {t, 1, Length[l]}], p], If[i < 1, 0, Sum[b[n - i*j, i-1, Join[l, Array[i&, j]]], {j, 0, n/i}]]]; a[n_] := b[n, n, {}]; Table[Print[an = a[n]]; an, {n, 1, 13}] (* Jean-François Alcover, Dec 12 2013, after Alois P. Heinz *)
  • PARI
    EulerT(v)={Vec(exp(x*Ser(dirmul(v, vector(#v, n, 1/n))))-1, -#v)}
    D(p, n)={my(v=vector(n)); for(i=1, #p, v[p[i]]++); my(u=EulerT(v)); Vec(1/prod(k=1, n, 1 - u[k]*x^k + O(x*x^n))-1, -n)/prod(i=1, #v, i^v[i]*v[i]!)}
    seq(n)={my(s=0); forpart(p=n, s+=D(p,n)); s} \\ Andrew Howroyd, Dec 30 2020
  • Python
    from sympy.core.cache import cacheit
    from sympy import divisors, isprime, prime
    from operator import mul
    @cacheit
    def g(n, k):
        return (0 if n > k else 1) + (0 if isprime(n) else sum(g(n//d, d) for d in divisors(n)[1:-1] if d <= k))
    @cacheit
    def b(n, i, l):
        if n==0:
            p = reduce(mul, (prime(t + 1)**l[t] for t in range(len(l))))
            return g(p, p)
        else:
            return 0 if i<1 else sum([b(n - i*j, i - 1, l + [i]*j) for j in range(n//i + 1)])
    def a(n):
        return b(n, n, [])
    for n in range(1, 11): print(a(n)) # Indranil Ghosh, Aug 19 2017, after Maple code
    

Extensions

More terms from Erich Friedman.
81199 from Alford Arnold, Mar 04 2008
a(10) from Alford Arnold, Mar 31 2008
a(10) corrected by Alford Arnold, Aug 07 2008
a(11)-a(13) from Alois P. Heinz, May 26 2013
a(14) from Alois P. Heinz, Sep 27 2014
a(15) from Alois P. Heinz, Jan 10 2015
Terms a(16) and beyond from Andrew Howroyd, Dec 30 2020

A247551 Decimal expansion of Product_{k>=2} 1/(1-1/k!).

Original entry on oeis.org

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

Views

Author

Vaclav Kotesovec, Sep 19 2014

Keywords

Examples

			2.5294774720791526481801161542539542411787023948459973375849349825...
		

Crossrefs

Programs

  • Maple
    evalf(1/product(1-1/k!,k=2..infinity),100); # Vaclav Kotesovec, Sep 19 2014
  • Mathematica
    digits = 105;
    RealDigits[NProduct[1/(1-1/k!), {k, 2, Infinity}, WorkingPrecision -> digits+10, NProductFactors -> digits], 10, digits][[1]] (* Jean-François Alcover, Nov 02 2020 *)
  • PARI
    default(realprecision,150); 1/prodinf(k=2,1 - 1/k!) \\ Vaclav Kotesovec, Sep 21 2014

Formula

Product_{k>=2} 1/(1-1/k!).
Equals lim_{n -> oo} A005651(n) / n!.
Equals 1/A282529. - Amiram Eldar, Sep 15 2023

A261719 Number T(n,k) of partitions of n where each part i is marked with a word of length i over a k-ary alphabet whose letters appear in alphabetical order and all k letters occur at least once in the partition; triangle T(n,k), n>=0, 0<=k<=n, read by rows.

Original entry on oeis.org

1, 0, 1, 0, 2, 3, 0, 3, 12, 10, 0, 5, 40, 81, 47, 0, 7, 104, 396, 544, 246, 0, 11, 279, 1751, 4232, 4350, 1602, 0, 15, 654, 6528, 25100, 44475, 36744, 11481, 0, 22, 1577, 23892, 136516, 369675, 512787, 352793, 95503, 0, 30, 3560, 80979, 666800, 2603670, 5413842, 6170486, 3641992, 871030
Offset: 0

Views

Author

Alois P. Heinz, Aug 29 2015

Keywords

Comments

T(n,k) is defined for n,k >= 0. The triangle contains only the terms with k<=n. T(n,k) = 0 for k>n.

Examples

			A(3,2) = 12: 3aab, 3abb, 2aa1b, 2ab1a, 2ab1b, 2bb1a, 1a1a1b, 1a1b1a, 1a1b1b, 1b1a1a, 1b1a1b, 1b1b1a.
Triangle T(n,k) begins:
  1
  0,  1;
  0,  2,    3;
  0,  3,   12,    10;
  0,  5,   40,    81,     47;
  0,  7,  104,   396,    544,    246;
  0, 11,  279,  1751,   4232,   4350,   1602;
  0, 15,  654,  6528,  25100,  44475,  36744,  11481;
  0, 22, 1577, 23892, 136516, 369675, 512787, 352793, 95503;
  ...
		

Crossrefs

Columns k=0-10 give: A000007, A000041 (for n>0), A293366, A293367, A293368, A293369, A293370, A293371, A293372, A293373, A293374.
Row sums give A035341.
Main diagonal gives A005651.
T(2n,n) gives A261732.
Cf. A060642, A261718, A261781 (same for compositions).

Programs

  • Maple
    b:= proc(n, i, k) option remember; `if`(n=0, 1, `if`(i<1, 0,
          b(n, i-1, k)+`if`(i>n, 0, b(n-i, i, k)*binomial(i+k-1, k-1))))
        end:
    T:= (n, k)-> add(b(n$2, k-i)*(-1)^i*binomial(k, i), i=0..k):
    seq(seq(T(n, k), k=0..n), n=0..10);
  • Mathematica
    b[n_, i_, k_] := b[n, i, k] = If[n == 0, 1, If[i < 1, 0, b[n, i - 1, k] + If[i > n, 0, b[n - i, i, k]*Binomial[i + k - 1, k - 1]]]]; T[n_, k_] := Sum[b[n, n, k - i]*(-1)^i*Binomial[k, i], {i, 0, k}]; Table[T[n, k], {n, 0, 10}, {k, 0, n}] // Flatten (* Jean-François Alcover, Jan 21 2017, translated from Maple *)

Formula

T(n,k) = Sum_{i=0..k} (-1)^i * C(k,i) * A261718(n,k-i).

A129306 Resort sequence A096443 by source partition as described by A053445 and A126442.

Original entry on oeis.org

1, 2, 2, 3, 4, 5, 5, 7, 11, 15, 9, 7, 12, 21, 36, 52, 16, 26, 11, 19, 38, 74, 135, 203, 29, 52, 92, 31, 66, 15, 30, 64, 141, 296, 566, 877, 47, 98, 198, 371, 57, 109, 137, 249, 22, 45, 105, 250, 592, 1315, 2610, 4140, 77, 171, 392, 850, 1663, 97, 212, 444, 269, 560, 1075
Offset: 1

Views

Author

Alford Arnold, May 07 2007

Keywords

Comments

The first array is described in A126442 and is the hook case. Sequence A129305 encodes the multisets counted by A096443 and A129306.

Examples

			a(11) = 9 because 2+2= 4 starting a new array. The arrays begin as follows:
1.....2.....3.....5......7......11.....15.....22
......2.....4.....7......12.....19.....30.....45
............5.....11.....21.....38.....64.....105
..................15.....36.....74.....141....250
.........................52.....135....296....592
................................203....566....1315
.......................................877....2610
..............................................4140
..................9......16.....29.....47.....77
.........................26.....52.....98.....171
................................92.....198....392
.......................................371....850
..............................................1663
................................31.....57.....97
.......................................109....212
..............................................444
................................66.....137....269
.......................................249....560
..............................................1075
..............................................109
..............................................300
..............................................712
which sums to
1.....4....12....47....170....750....3255.....16010
		

Crossrefs

A080688 Resort the index of A064553 using A080444 and maintaining ascending order within each grouping: seen as a triangle read by rows, the n-th row contains the A001055(n) numbers m with A064553(m)=n.

Original entry on oeis.org

1, 2, 3, 4, 5, 7, 6, 11, 13, 8, 10, 17, 9, 19, 14, 23, 29, 12, 15, 22, 31, 37, 26, 41, 21, 43, 16, 20, 25, 34, 47, 53, 18, 33, 38, 59, 61, 28, 35, 46, 67, 39, 71, 58, 73, 79, 24, 30, 44, 51, 55, 62, 83, 49, 89, 74, 97, 27, 57, 101, 52, 65, 82
Offset: 1

Views

Author

Alford Arnold, Mar 23 2003

Keywords

Comments

The number 12 can be written as 3*2*2, 4*3, 6*2 and 12 corresponding to each of the four values (12,15,22,31) in the example. Note that A001055(12) = 4. Since A001055(n) depends only on the least prime signature, the values 1,2,4,6,8,12,16,24,30,32,36,... A025487 are of special interest when counting multisets. (see for example, A035310 and A035341).
A064553(T(n,k)) = A080444(n,k) = n for k=1..A001055(n); T(n,1) = A064554(n); T(n,A001055(n)) = A064554(n). - Reinhard Zumkeller, Oct 01 2012
Row n is the sorted list of shifted Heinz numbers of factorizations of n into factors > 1, where the shifted Heinz number of a factorization (y_1, ..., y_k) is prime(y_1 - 1) * ... * prime(y_k - 1). - Gus Wiseman, Sep 05 2018

Examples

			a(18),a(19),a(20) and a(21) are 12,15,22 and 31 because A064553(12,15,22,31) = (12,12,12,12) similarly, A064553(36,45,66,76,93,95,118,121,149) = (36,36,36,36,36,36,36,36,36)
From _Gus Wiseman_, Sep 05 2018: (Start)
Triangle begins:
   1
   2
   3
   4  5
   7
   6 11
  13
   8 10 17
   9 19
  14 23
  29
  12 15 22 31
  37
  26 41
  21 43
  16 20 25 34 47
Corresponding triangle of factorizations begins:
  (),
  (2),
  (3),
  (2*2), (4),
  (5),
  (2*3), (6),
  (7),
  (2*2*2), (2*4), (8),
  (3*3), (9),
  (2*5), (10),
  (11),
  (2*2*3), (3*4), (2*6), (12).
(End)
		

Crossrefs

Programs

  • Haskell
    a080688 n k = a080688_row n !! (k-1)
    a080688_row n = map (+ 1) $ take (a001055 n) $
                    elemIndices n $ map fromInteger a064553_list
    a080688_tabl = map a080688_row [1..]
    a080688_list = concat a080688_tabl
    -- Reinhard Zumkeller, Oct 01 2012
  • Mathematica
    facs[n_]:=If[n<=1,{{}},Join@@Table[(Prepend[#1,d]&)/@Select[facs[n/d],Min@@#1>=d&],{d,Rest[Divisors[n]]}]];
    Table[Sort[Table[Times@@Prime/@(f-1),{f,facs[n]}]],{n,20}] (* Gus Wiseman, Sep 05 2018 *)

Extensions

More terms from Sean A. Irvine, Oct 05 2011
Keyword tabf added and definition complemented accordingly by Reinhard Zumkeller, Oct 01 2012

A095705 Triangular array read by rows: a(n, k) = sum of number of ordered factorizations of all prime signatures with n total prime factors and k distinct prime factors.

Original entry on oeis.org

1, 2, 3, 4, 8, 13, 8, 46, 44, 75, 16, 124, 308, 308, 541, 32, 572, 1790, 2536, 2612, 4683, 64, 1568, 8352, 17028, 24704, 25988, 47293, 128, 6728, 40628, 137498, 187928, 277456, 296564, 545835, 256, 18768, 228308, 719056, 1699184, 2356560, 3526448, 3816548, 7087261
Offset: 1

Views

Author

Alford Arnold, Jul 04 2004, Nov 22 2005

Keywords

Comments

A093936 is an analogous array for unordered factorizations.
First column is A000079. First two diagonals are A000670 and A005649.

Examples

			There are two prime signatures with 5 total primes and 3 distinct primes: p^3*q*r and p^2*q^2*r. A074206(p^3*q*r) = 132 and A074206(p^2*q^2*r) = 176, so a(5, 3) = 132+176 = 308.
Array begins:
  1
  2, 3
  4, 8, 13
  8, 46, 44, 75
  16, 124, 308, 308, 541
  32, 572, 1790, 2536, 2612, 4683
  64, 1568, 8352, 17028, 24704, 25988, 47293
  128, 6728, 40628, 137498, 187928, 277456, 296564, 545835
  256, 18768, 228308, 719056, 1699184, 2356560, 3526448, 3816548, 7087261
		

Crossrefs

A035341 gives the row sums. Cf. A050324, A074206, A093936, A096443.

Programs

  • Mathematica
    H[0] = 0; H[1] = 1; H[n_] := H[n] = Total[H /@ Most[Divisors[n]]];
    T[n_, k_] := Module[{t = IntegerPartitions[n, {k}]}, Total[H /@ Times @@@ ((Prime[Range[k]]^#) & /@ t)]];
    Table[T[n, k], {n, 1, 9}, {k, 1, n}] // Flatten (* Amiram Eldar, Jun 28 2025 *)

Extensions

Edited and extended by David Wasserman, Feb 22 2008

A365961 Number of (0,1)-matrices with sum of entries equal to n and no zero rows or columns, with weakly decreasing row sums.

Original entry on oeis.org

1, 1, 4, 19, 127, 967, 9063, 94595, 1139708, 15118010, 223571836, 3597458356, 63233950081, 1197193320701, 24418765771835, 532015160784016, 12363381055074017, 304754656068754421, 7952728315095555279, 218848562411197549582, 6338152295627215890669, 192627799720153909693048
Offset: 0

Views

Author

Ludovic Schwob, Sep 23 2023

Keywords

Comments

Let f(n) = number of ordered coprime factorizations of n (A325446(n)); a(n) = sum of f(k) over all terms k in A025487 that have n factors.

Examples

			The a(3) = 19 matrices:
  [1 1 1]
.
  [1 1] [1 1] [1 1 0] [1 0 1] [0 1 1]
  [1 0] [0 1] [0 0 1] [0 1 0] [1 0 0]
.
  [1] [1 0] [0 1] [1 0] [0 1] [1 0 0] [1 0 0] [0 1] [1 0]
  [1] [1 0] [0 1] [0 1] [1 0] [0 1 0] [0 0 1] [1 0] [0 1]
  [1] [0 1] [1 0] [1 0] [0 1] [0 0 1] [0 1 0] [1 0] [0 1]
.
  [0 1 0] [0 1 0] [0 0 1] [0 0 1]
  [1 0 0] [0 0 1] [1 0 0] [0 1 0]
  [0 0 1] [1 0 0] [0 1 0] [1 0 0]
		

Crossrefs

Programs

  • PARI
    R(n,k)={Vec(-1 + 1/prod(j=1, k, 1 - binomial(k,j)*x^j + O(x*x^n)))}
    seq(n) = {concat([1], sum(k=1, n, R(n, k)*sum(r=k, n, binomial(r, k)*(-1)^(r-k)) ))} \\ Andrew Howroyd, Sep 23 2023

Extensions

Terms a(13) and beyond from Andrew Howroyd, Sep 23 2023

A238962 Number of perfect partitions in graded colexicographic order.

Original entry on oeis.org

1, 1, 2, 3, 4, 8, 13, 8, 20, 26, 44, 75, 16, 48, 76, 132, 176, 308, 541, 32, 112, 208, 252, 368, 604, 818, 1076, 1460, 2612, 4683, 64, 256, 544, 768, 976, 1888, 2316, 3172, 3408, 5740, 7880, 10404, 14300, 25988, 47293, 128, 576, 1376, 2208, 2568, 2496, 5536, 7968
Offset: 0

Views

Author

Sung-Hyuk Cha, Mar 07 2014

Keywords

Examples

			Triangle T(n,k) begins:
   1;
   1;
   2,   3;
   4,   8,  13;
   8,  20,  26,  44,  75;
  16,  48,  76, 132, 176, 308, 541;
  32, 112, 208, 252, 368, 604, 818, 1076, 1460, 2612, 4683;
  ...
		

Crossrefs

Row sums are A035341.
Cf. A002033 in graded colexicographic order.

Programs

  • PARI
    \\ here b(n) is A074206.
    N(sig)={prod(k=1, #sig, prime(k)^sig[k])}
    b(n)={if(!n, 0, my(sig=factor(n)[,2], m=vecsum(sig)); sum(k=0, m, prod(i=1, #sig, binomial(sig[i]+k-1, k-1))*sum(r=k, m, binomial(r,k)*(-1)^(r-k))))}
    Row(n)={apply(s->b(N(s)), [Vecrev(p) | p<-partitions(n)])}
    { for(n=0, 6, print(Row(n))) } \\ Andrew Howroyd, Aug 30 2020

Formula

T(n,k) = A074206(A036035(n,k)). - Andrew Howroyd, Apr 25 2020

Extensions

Offset changed and terms a(44) and beyond from Andrew Howroyd, Apr 25 2020

A238975 Number of perfect partitions in canonical order.

Original entry on oeis.org

1, 1, 2, 3, 4, 8, 13, 8, 20, 26, 44, 75, 16, 48, 76, 132, 176, 308, 541, 32, 112, 208, 368, 252, 604, 1076, 818, 1460, 2612, 4683, 64, 256, 544, 976, 768, 1888, 3408, 2316, 3172, 5740, 10404, 7880, 14300, 25988, 47293, 128, 576, 1376, 2496, 2208, 5536, 10096, 2568
Offset: 0

Views

Author

Sung-Hyuk Cha, Mar 07 2014

Keywords

Examples

			Triangle T(n,k) begins:
   1;
   1;
   2,   3;
   4,   8,  13;
   8,  20,  26,  44,  75;
  16,  48,  76, 132, 176, 308,  541;
  32, 112, 208, 368, 252, 604, 1076, 818, 1460, 2612, 4683;
  ...
		

Crossrefs

Row sums are A035341.
Cf. A238962 in canonical order, A002033.

Programs

  • Maple
    g:= proc(n) option remember; (1+add(g(n/d),
          d=numtheory[divisors](n) minus {1, n}))
        end:
    b:= (n, i)-> `if`(n=0 or i=1, [[1$n]], [map(x->
        [i, x[]], b(n-i, min(n-i, i)))[], b(n, i-1)[]]):
    T:= n-> map(x-> g(mul(ithprime(i)^x[i], i=1..nops(x))), b(n$2))[]:
    seq(T(n), n=0..9);  # Alois P. Heinz, Apr 26 2020
  • Mathematica
    (* b is A074206 *)
    b[n_] := b[n] = If[n < 2, n, b /@ Most[Divisors[n]] // Total];
    T[n_] := b /@ (Product[Prime[k]^#[[k]], {k, 1, Length[#]}]& /@ IntegerPartitions[n]);
    T /@ Range[0, 9] // Flatten (* Jean-François Alcover, Jan 04 2021 *)
  • PARI
    \\ here b(n) is A074206.
    N(sig)={prod(k=1, #sig, prime(k)^sig[k])}
    b(n)={if(!n, 0, my(sig=factor(n)[,2], m=vecsum(sig)); sum(k=0, m, prod(i=1, #sig, binomial(sig[i]+k-1, k-1))*sum(r=k, m, binomial(r,k)*(-1)^(r-k))))}
    Row(n)={apply(s->b(N(s)), vecsort([Vecrev(p) | p<-partitions(n)], , 4))}
    { for(n=0, 6, print(Row(n))) } \\ Andrew Howroyd, Aug 30 2020

Formula

T(n,k) = A074206(A063008(n,k)). - Andrew Howroyd, Apr 26 2020

Extensions

Offset changed and terms a(42) and beyond from Andrew Howroyd, Apr 26 2020

A098349 Sum of ordered factorizations over hook-type prime signatures. (Row sums of A098348).

Original entry on oeis.org

1, 5, 25, 147, 1045, 8883, 88389, 1008723, 12984933, 186065011, 2936648325, 50611122451, 945623586725, 19037956164787, 410846314815941, 9460698944482643, 231538646070940901, 6001404380246870771, 164229726267373422853, 4731532138668375166355, 143154470312498479646245, 4538018949359464639487283, 150411282096757092041331781
Offset: 1

Views

Author

Alford Arnold, Sep 03 2004

Keywords

Comments

The general case for all prime signatures is described by A095705 with row sums A035341.

Examples

			The array begins
1
2 3
4 8 13
8 20 44 75
16 48 132 308 541
...
therefore sequence begins 1 5 25 147 1045 ...
		

Crossrefs

Extensions

More terms from David Wasserman, Feb 20 2008
Showing 1-10 of 11 results. Next