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

A294105 Number of compositions (ordered partitions) of n into squares dividing n.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 1, 7, 2, 1, 1, 26, 1, 1, 1, 96, 1, 12, 1, 345, 1, 1, 1, 1252, 2, 1, 76, 4544, 1, 1, 1, 17473, 1, 1, 1, 127654, 1, 1, 1, 217286, 1, 1, 1, 788674, 2490, 1, 1, 3182706, 2, 28, 1, 10390321, 1, 14128, 1, 37713313, 1, 1, 1, 136886433, 1, 1, 80396, 579739960, 1, 1, 1, 1803399103, 1, 1
Offset: 0

Views

Author

Ilya Gutkovskiy, Oct 28 2017

Keywords

Examples

			a(8) = 7 because 8 has 4 divisors {1, 2, 4, 8} among which 2 are squares {1, 4} therefore we have [4, 4], [4, 1, 1, 1, 1], [1, 4, 1, 1, 1], [1, 1, 4, 1, 1], [1, 1, 1, 4, 1], [1, 1, 1, 1, 4] and [1, 1, 1, 1, 1, 1, 1, 1].
		

Crossrefs

Programs

  • Maple
    a:= proc(n) option remember; local b, l;
          l, b:= select(issqr, numtheory[divisors](n)),
          proc(m) option remember; `if`(m=0, 1,
             add(`if`(j>m, 0, b(m-j)), j=l))
          end; b(n)
        end:
    seq(a(n), n=0..50);  # Alois P. Heinz, Oct 30 2017
  • Mathematica
    Table[SeriesCoefficient[1/(1 - Sum[Boole[Mod[n, k] == 0 && IntegerQ[k^(1/2)]] x^k, {k, 1, n}]), {x, 0, n}], {n, 0, 70}]

A284466 Number of compositions (ordered partitions) of n into odd divisors of n.

Original entry on oeis.org

1, 1, 1, 2, 1, 2, 6, 2, 1, 20, 8, 2, 60, 2, 10, 450, 1, 2, 726, 2, 140, 3321, 14, 2, 5896, 572, 16, 26426, 264, 2, 394406, 2, 1, 226020, 20, 51886, 961584, 2, 22, 2044895, 38740, 2, 20959503, 2, 676, 478164163, 26, 2, 56849086, 31201, 652968, 184947044, 980, 2, 1273706934, 6620376, 153366, 1803937344
Offset: 0

Views

Author

Ilya Gutkovskiy, Mar 27 2017

Keywords

Examples

			a(10) = 8 because 10 has 4 divisors {1, 2, 5, 10} among which 2 are odd {1, 5} therefore we have [5, 5], [5, 1, 1, 1, 1, 1], [1, 5, 1, 1, 1, 1], [1, 1, 5, 1, 1, 1], [1, 1, 1, 5, 1, 1], [1, 1, 1, 1, 5, 1], [1, 1, 1, 1, 1, 5] and [1, 1, 1, 1, 1, 1, 1, 1, 1, 1].
		

Crossrefs

Programs

  • Maple
    with(numtheory):
    a:= proc(n) option remember; local b, l;
          l, b:= select(x-> is(x:: odd), divisors(n)),
          proc(m) option remember; `if`(m=0, 1,
             add(`if`(j>m, 0, b(m-j)), j=l))
          end; b(n)
        end:
    seq(a(n), n=0..60);  # Alois P. Heinz, Mar 30 2017
  • Mathematica
    Table[d = Divisors[n]; Coefficient[Series[1/(1 - Sum[Boole[Mod[d[[k]], 2] == 1] x^d[[k]], {k, Length[d]}]), {x, 0, n}], x, n], {n, 0, 57}]
  • Python
    from sympy import divisors
    from sympy.core.cache import cacheit
    @cacheit
    def a(n):
        l=[x for x in divisors(n) if x%2]
        @cacheit
        def b(m): return 1 if m==0 else sum(b(m - j) for j in l if j <= m)
        return b(n)
    print([a(n) for n in range(61)]) # Indranil Ghosh, Aug 01 2017, after Maple code

Formula

a(n) = [x^n] 1/(1 - Sum_{d|n, d positive odd} x^d).
a(n) = 1 if n is a power of 2.
a(n) = 2 if n is an odd prime.

A286851 Number of compositions (ordered partitions) of n into unitary divisors of n.

Original entry on oeis.org

1, 1, 2, 2, 2, 2, 25, 2, 2, 2, 129, 2, 170, 2, 742, 450, 2, 2, 4603, 2, 1503, 3321, 29967, 2, 9278, 2, 200390, 2, 13460, 2, 154004511, 2, 2, 226020, 9262157, 51886, 127654, 2, 63346598, 2044895, 170354, 2, 185493291001, 2, 1304512, 567124, 2972038875, 2, 59489916, 2, 20367343494, 184947044, 14324735, 2
Offset: 0

Views

Author

Ilya Gutkovskiy, Aug 01 2017

Keywords

Examples

			a(8) = 2 because 8 has 4 divisors {1, 2, 4, 8} among which 2 are unitary divisors {1, 8} therefore we have [8] and [1, 1, 1, 1, 1, 1, 1, 1].
		

Crossrefs

Programs

  • Maple
    a:= proc(n) option remember; local b, l; l, b:=
          select(x-> igcd(x, n/x)=1, numtheory[divisors](n)),
          proc(m) option remember; `if`(m=0, 1,
             add(`if`(j>m, 0, b(m-j)), j=l))
          end; b(n)
        end:
    seq(a(n), n=0..60);  # Alois P. Heinz, Aug 01 2017
  • Mathematica
    Join[{1}, Table[d = Divisors[n]; Coefficient[Series[1/(1 - Sum[Boole[GCD[n/d[[k]], d[[k]]] == 1] x^d[[k]], {k, Length[d]}]), {x, 0, n}], x, n], {n, 1, 53}]]
  • Python
    from sympy import divisors, gcd
    from sympy.core.cache import cacheit
    @cacheit
    def a(n):
        l=[x for x in divisors(n) if gcd(x, n//x)==1]
        @cacheit
        def b(m): return 1 if m==0 else sum(b(m - j) for j in l if j <= m)
        return b(n)
    print([a(n) for n in range(61)]) # Indranil Ghosh, Aug 01 2017, after Maple code

Formula

a(n) = [x^n] 1/(1 - Sum_{d|n, gcd(d, n/d) = 1} x^d).
a(n) = 2 if n is a prime power (A246655).

A331928 Number of compositions (ordered partitions) of n into distinct proper divisors of n.

Original entry on oeis.org

1, 0, 0, 0, 0, 0, 6, 0, 0, 0, 0, 0, 30, 0, 0, 0, 0, 0, 30, 0, 24, 0, 0, 0, 894, 0, 0, 0, 120, 0, 150, 0, 0, 0, 0, 0, 1134, 0, 0, 0, 864, 0, 30, 0, 0, 0, 0, 0, 11934, 0, 0, 0, 0, 0, 150, 0, 840, 0, 0, 0, 129438, 0, 0, 0, 0, 0, 126, 0, 0, 0, 0
Offset: 0

Views

Author

Ilya Gutkovskiy, Feb 01 2020

Keywords

Examples

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

Crossrefs

Programs

  • PARI
    a(n)={if(n==0, 1, my(v=divisors(n)); subst(serlaplace((0*y) + polcoef(prod(i=1, #v-1, 1 + y*x^v[i] + O(x*x^n)), n)), y, 1))} \\ Andrew Howroyd, Feb 01 2020

Formula

a(n) = A331927(n) - 1 for n > 0.

A331979 Number of compositions (ordered partitions) of n into distinct nontrivial divisors of n.

Original entry on oeis.org

1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 6, 0, 0, 0, 0, 0, 6, 0, 0, 0, 0, 0, 30, 0, 0, 0, 0, 0, 30, 0, 0, 0, 0, 0, 894, 0, 0, 0, 24, 0, 6, 0, 0, 0, 0, 0, 894, 0, 0, 0, 0, 0, 30, 0, 120, 0, 0, 0, 19518, 0, 0, 0, 0, 0, 126, 0, 0, 0, 0, 0, 18558, 0, 0, 0, 0, 0, 6, 0, 864
Offset: 0

Views

Author

Ilya Gutkovskiy, Feb 03 2020

Keywords

Examples

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

Crossrefs

Programs

  • Maple
    with(numtheory):
    a:= proc(n) local b, l; l:= sort([(divisors(n) minus {1, n})[]]):
          b:= proc(m, i, p) option remember; `if`(m=0, p!, `if`(i<1, 0,
                 b(m, i-1, p)+`if`(l[i]>m, 0, b(m-l[i], i-1, p+1))))
              end; forget(b):
          b(n, nops(l), 0)
        end:
    seq(a(n), n=0..100);  # Alois P. Heinz, Feb 03 2020
  • Mathematica
    a[n_] := If[n == 0, 1, Module[{b, l = Divisors[n] ~Complement~ {1, n}}, b[m_, i_, p_] := b[m, i, p] = If[m == 0, p!, If[i < 1, 0, b[m, i-1, p] + If[l[[i]] > m, 0, b[m - l[[i]], i-1, p+1]]]]; b[n, Length[l], 0]]];
    a /@ Range[0, 100] (* Jean-François Alcover, Nov 17 2020, after Alois P. Heinz *)

A357312 Number of compositions (ordered partitions) of n into divisors of n that are smaller than sqrt(n).

Original entry on oeis.org

1, 0, 1, 1, 1, 1, 13, 1, 34, 1, 89, 1, 927, 1, 610, 189, 1597, 1, 35890, 1, 46754, 1873, 28657, 1, 3919944, 1, 196418, 18560, 4205249, 1, 110187694, 1, 39882198, 183916, 9227465, 9496, 10312882481, 1, 63245986, 1822473, 11969319436, 1, 141930520462, 1, 34020543362, 339200673
Offset: 0

Views

Author

Ilya Gutkovskiy, Sep 23 2022

Keywords

Crossrefs

Programs

  • Maple
    a:= proc(n) option remember; uses numtheory; local b, l;
          l, b:= select(x-> is(xm, 0, b(m-j)), j=l))
          end; b(n)
        end:
    seq(a(n), n=0..45);  # Alois P. Heinz, Sep 23 2022
  • Mathematica
    a[n_] := SeriesCoefficient[1/(1 - Sum[Boole[d < Sqrt[n]] x^d, {d, Divisors[n]}]), {x, 0, n}]; Table[a[n], {n, 0, 45}]

Formula

a(n) = [x^n] 1 / (1 - Sum_{d|n, d < sqrt(n)} x^d).

A130708 Number of compositions of n such that every part divides the largest part.

Original entry on oeis.org

1, 1, 2, 4, 8, 14, 26, 45, 79, 137, 241, 423, 754, 1343, 2410, 4344, 7870, 14305, 26103, 47763, 87649, 161229, 297251, 549108, 1016243, 1883898, 3497761, 6503420, 12107958, 22570221, 42121298, 78692765, 147165225, 275476533, 516115940
Offset: 0

Views

Author

Vladeta Jovovic, Jul 01 2007

Keywords

Crossrefs

Programs

  • Maple
    A130708 := proc(n) local gf,den1,den2,i,d ; gf := 1 ; for i from 1 to n do den1 := 1 ; den2 := 1 ; for d in numtheory[divisors](i) do den1 := den1-x^d ; if d < i then den2 := den2-x^d ; fi ; od ; gf := taylor(gf+x^i/den1/den2,x=0,n+1) ; od: coeftayl(gf,x=0,n) ; end: seq(A130708(n),n=0..40) ; # R. J. Mathar, Oct 28 2007
  • Mathematica
    m = 35;
    1 + Sum[x^n/((1 - Sum[x^d, {d, Divisors[n]}]) (1 - Sum[Boole[d < n] x^d, {d, Divisors[n]}])), {n, 1, m}] + O[x]^m // CoefficientList[#, x]& (* Jean-François Alcover, May 22 2020 *)

Formula

G.f.: 1 + Sum_{n>0} x^n/((1-Sum_{d divides n} x^d)*(1-Sum_{d divides n,d

Extensions

More terms from R. J. Mathar, Oct 28 2007

A284839 Number of compositions (ordered partitions) of n into prime power divisors of n (including 1).

Original entry on oeis.org

1, 1, 2, 2, 6, 2, 24, 2, 56, 20, 128, 2, 1490, 2, 741, 449, 5272, 2, 36901, 2, 81841, 3320, 29966, 2, 4135004, 572, 200389, 26426, 5452795, 2, 110187694, 2, 47350056, 226019, 9262156, 51885, 10783889706, 2, 63346597, 2044894, 14064551462, 2, 109570982403, 2, 35537376325, 470326038, 2972038874, 2
Offset: 0

Author

Ilya Gutkovskiy, Apr 03 2017

Keywords

Examples

			a(4) = 6 because 4 has 3 divisors {1, 2, 4} and all are prime powers therefore we have [4], [2, 2], [2, 1, 1], [1, 2, 1], [1, 1, 2] and [1, 1, 1, 1].
		

Crossrefs

Programs

  • Maple
    with(numtheory):
    a:= proc(n) local d, b; d, b:= select(x->
          nops(factorset(x))<2, divisors(n)),
          proc(n) option remember; `if`(n=0, 1,
            add(`if`(j>n, 0, b(n-j)), j=d))
          end: b(n)
        end:
    seq(a(n), n=0..60);  # Alois P. Heinz, Apr 15 2017
  • Mathematica
    Table[d = Divisors[n]; Coefficient[Series[1/(1 - x - Sum[Boole[PrimePowerQ[d[[k]]]] x^d[[k]], {k, Length[d]}]), {x, 0, n}], x, n], {n, 0, 47}]

Formula

a(n) = [x^n] 1/(1 - x - Sum_{p^k|n, p prime, k>=1} x^(p^k)).
a(n) = 2 if n is a prime.

A327766 Number of compositions (ordered partitions) of n into divisors of n that are at most sqrt(n).

Original entry on oeis.org

1, 1, 1, 1, 5, 1, 13, 1, 34, 19, 89, 1, 927, 1, 610, 189, 4930, 1, 35890, 1, 46754, 1873, 28657, 1, 3919944, 571, 196418, 18560, 4205249, 1, 110187694, 1, 39882198, 183916, 9227465, 9496, 14484956252, 1, 63245986, 1822473, 11969319436, 1, 141930520462, 1, 34020543362, 339200673
Offset: 0

Author

Ilya Gutkovskiy, Sep 24 2019

Keywords

Crossrefs

Programs

  • Mathematica
    a[n_] := SeriesCoefficient[1/(1 - Sum[Boole[d <= Sqrt[n]] x^d, {d, Divisors[n]}]), {x, 0, n}]; Table[a[n], {n, 0, 45}]

Formula

a(n) = [x^n] 1 / (1 - Sum_{d|n, d <= sqrt(n)} x^d).
a(p) = 1, where p is prime.

A332001 Number of compositions (ordered partitions) of n into distinct parts that do not divide n.

Original entry on oeis.org

1, 0, 0, 0, 0, 2, 0, 4, 2, 4, 4, 20, 2, 34, 14, 20, 14, 146, 8, 244, 22, 140, 202, 956, 16, 782, 596, 752, 216, 5786, 82, 10108, 640, 4016, 5200, 6028, 218, 53674, 14570, 19004, 980, 152810, 1786, 245884, 13588, 16534, 108382, 719156, 1494, 532532, 54316
Offset: 0

Author

Ilya Gutkovskiy, Feb 04 2020

Keywords

Examples

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

Programs

  • Maple
    a:= proc(n) local b, l; l, b:= numtheory[divisors](n),
          proc(m, i, p) option remember; `if`(m=0, p!, `if`(i<2, 0,
            b(m, i-1, p)+`if`(i>m or i in l, 0, b(m-i, i-1, p+1))))
          end; forget(b): b(n, n-1, 0)
        end:
    seq(a(n), n=0..63);  # Alois P. Heinz, Feb 04 2020
  • Mathematica
    a[n_] := Module[{b, l = Divisors[n]}, b[m_, i_, p_] := b[m, i, p] = If[m == 0, p!, If[i < 2, 0, b[m, i - 1, p] + If[i > m || MemberQ[l, i], 0, b[m - i, i - 1, p + 1]]]]; b[n, n - 1, 0]];
    a /@ Range[0, 63] (* Jean-François Alcover, Nov 30 2020, after Alois P. Heinz *)
Previous Showing 11-20 of 23 results. Next