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-3 of 3 results.

A167934 a(n) = A000041(n) - A032741(n).

Original entry on oeis.org

1, 1, 1, 2, 3, 6, 8, 14, 19, 28, 39, 55, 72, 100, 132, 173, 227, 296, 380, 489, 622, 789, 999, 1254, 1568, 1956, 2433, 3007, 3713, 4564, 5597, 6841, 8344, 10140, 12307, 14880, 17969, 21636, 26012, 31182, 37331, 44582, 53167, 63260, 75170
Offset: 0

Views

Author

Omar E. Pol, Nov 16 2009

Keywords

Comments

a(n) is also the number of partitions of n whose parts are not all equal, (including however the partition with a single part of size n). Note that the number of partitions of n whose parts are all equal gives the number of divisors of n, for n>0. (See also A144300.)

Examples

			The partitions of n = 6 are:
6 ....................... All parts are equal, but included .. (1).
5 + 1 ................... All parts are not equal ............ (2).
4 + 2 ................... All parts are not equal ............ (3).
4 + 1 + 1 ............... All parts are not equal ............ (4).
3 + 3 ................... All parts are equal, not included.
3 + 2 + 1 ............... All parts are not equal ............ (5).
3 + 1 + 1 + 1 ........... All parts are not equal ............ (6).
2 + 2 + 2 ............... All parts are equal, not included.
2 + 2 + 1 + 1 ........... All parts are not equal ............ (7).
2 + 1 + 1 + 1 + 1 ....... All parts are not equal ............ (8).
1 + 1 + 1 + 1 + 1 + 1 ... All parts are equal, not included.
Then a(6) = 8.
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, k) option remember;
          if n<0 then 0
        elif n=0 then `if`(k=0, 1, 0)
        elif i=0 then 0
        else b(n, i-1, k)+
             b(n-i, i, `if`(k<0, i, `if`(k<>i, 0, k)))
          fi
        end:
    a:= n-> 1 +b(n, n-1, -1):
    seq(a(n), n=0..50);  #  Alois P. Heinz, Dec 01 2010
  • Mathematica
    a[0] = 1; a[n_] := PartitionsP[n] - DivisorSigma[0, n] + 1; Table[a[n], {n, 0, 50}] (* Jean-François Alcover, Jan 08 2016 *)

Formula

a(n) = A000041(n) - A032741(n).

Extensions

More terms from Alois P. Heinz, Dec 01 2010

A167930 Number of partitions of n in which some but not all parts are equal.

Original entry on oeis.org

0, 0, 0, 0, 1, 3, 4, 9, 13, 20, 29, 43, 57, 82, 110, 146, 195, 258, 334, 435, 558, 713, 910, 1150, 1446, 1814, 2268, 2815, 3491, 4308, 5301, 6501, 7954, 9692, 11795, 14295, 17301, 20876, 25148, 30200, 36218, 43322, 51741, 61650, 73354
Offset: 0

Views

Author

Omar E. Pol, Nov 15 2009

Keywords

Comments

The parts may not all be equal, and at least one part must occur at least twice. - N. J. A. Sloane, May 30 2024

Examples

			The partitions of 6 are:
6 ....................... All parts are distinct.
5 + 1 ................... All parts are distinct.
4 + 2 ................... All parts are distinct.
4 + 1 + 1 ............... Only some parts are equal ...... (1).
3 + 3 ................... All parts are equal.
3 + 2 + 1 ............... All parts are distinct.
3 + 1 + 1 + 1 ........... Only some parts are equal ...... (2).
2 + 2 + 2 ............... All parts are equal.
2 + 2 + 1 + 1 ........... Only some parts are equal ...... (3).
2 + 1 + 1 + 1 + 1 ....... Only some parts are equal ...... (4).
1 + 1 + 1 + 1 + 1 + 1 ... All parts are equal.
Then a(6) = 4.
a(7) = 9 from 511  4111  331  322  3211  31111  2221  22111  211111. - _N. J. A. Sloane_, May 30 2024
		

Crossrefs

Programs

  • Mathematica
    f[lst_]:=With[{c=Split[lst]},Length[lst]>2&&Max[Length/@c]>1&&Length[c]>1]; Table[Length[ Select[ IntegerPartitions[n],f]],{n,0,50}] (* Harvey P. Dale, May 30 2024 *)

Formula

a(n) = A047967(n) - A032741(n).
a(n) = A000041(n) - A000009(n) - A032741(n).
a(0) = 0: For n>0, a(n) = A000041(n) - A000009(n) - A000005(n) + 1.

Extensions

Edited by Omar E. Pol, Nov 16 2009
More terms from Max Alekseyev, May 02 2011

A167928 Number of partitions of n that do not contain 1 as a part and whose parts are not the same divisor of n.

Original entry on oeis.org

1, 0, 0, 0, 0, 1, 1, 3, 4, 6, 9, 13, 16, 23, 31, 38, 51, 65, 83, 104, 132, 162, 207, 252, 313, 381, 475, 571, 703, 846, 1032, 1237, 1502, 1791, 2164, 2570, 3086, 3659, 4375, 5167, 6146, 7244, 8584, 10086, 11909, 13954, 16421, 19195, 22510, 26250, 30696, 35714
Offset: 0

Views

Author

Omar E. Pol, Nov 17 2009

Keywords

Comments

Note that these partitions are located in the head of the last section of the set of partitions of n (see the shell model of partitions, here).

Examples

			The partitions of 6 are:
6 ....................... All parts are the same divisor of n.
5 + 1 ................... Contains 1 as a part.
4 + 2 ................... All parts are not the same divisor of n. <------(1)
4 + 1 + 1 ............... Contains 1 as a part.
3 + 3 ................... All parts are the same divisor of n.
3 + 2 + 1 ............... Contains 1 as a part.
3 + 1 + 1 + 1 ........... Contains 1 as a part.
2 + 2 + 2 ............... All parts are the same divisor of n.
2 + 2 + 1 + 1 ........... Contains 1 as a part.
2 + 1 + 1 + 1 + 1 ....... Contains 1 as a part.
1 + 1 + 1 + 1 + 1 + 1 ... Contains 1 as a part.
Then a(6) = 1.
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, t) option remember;
          `if`(n=0, `if`(t<>1, 1, 0), `if`(i<2, 0,
          add(b(n-i*j, i-1, `if`(j=0, t, max(0, t-1))), j=0..n/i)))
        end:
    a:= n-> b(n, n, 2):
    seq(a(n), n=0..60);  # Alois P. Heinz, May 24 2013
  • Mathematica
    Prepend[Array[ n \[Function] Length@Select[IntegerPartitions[n, All, Range[2, n - 1]], Length[Union[ # ]] > 1 &], 40], 1] (* J. Mulder (jasper.mulder(AT)planet.nl), Jan 25 2010 *)
    b[n_, i_, t_] := b[n, i, t] = If[n == 0, If[t != 1, 1, 0], If[i < 2, 0, Sum[b[n - i*j, i - 1, If[j == 0, t, Max[0, t - 1]]], {j, 0, n/i}]]]; a[n_] := b[n, n, 2]; Table[a[n], {n, 0, 60}] (* Jean-François Alcover, Aug 29 2016, after Alois P. Heinz *)

Formula

a(n) = A002865(n) - A032741(n).

Extensions

More terms from J. Mulder (jasper.mulder(AT)planet.nl), Jan 25 2010
More terms from Alois P. Heinz, May 24 2013
Showing 1-3 of 3 results.