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

A341122 Number of partitions of n into 4 prime powers (including 1).

Original entry on oeis.org

1, 1, 2, 3, 5, 5, 8, 9, 12, 13, 17, 17, 22, 22, 26, 27, 33, 31, 39, 38, 44, 43, 51, 47, 58, 54, 63, 60, 71, 64, 79, 74, 88, 82, 99, 88, 108, 97, 116, 105, 126, 110, 134, 119, 141, 126, 153, 133, 164, 143, 172, 149, 184, 155, 194, 168, 204, 173, 215, 180, 227, 192, 238
Offset: 4

Views

Author

Ilya Gutkovskiy, Feb 05 2021

Keywords

Crossrefs

Programs

  • Maple
    q:= proc(n) option remember; nops(ifactors(n)[2])<2 end:
    b:= proc(n, i, t) option remember; `if`(n=0,
          `if`(t=0, 1, 0), `if`(i<1 or t<1, 0, b(n, i-1, t)+
          `if`(q(i), b(n-i, min(n-i, i), t-1), 0)))
        end:
    a:= n-> b(n$2, 4):
    seq(a(n), n=4..66);  # Alois P. Heinz, Feb 05 2021
  • Mathematica
    q[n_] := q[n] = Length[FactorInteger[n]] < 2;
    b[n_, i_, t_] := b[n, i, t] = If[n == 0,
         If[t == 0, 1, 0], If[i < 1 || t < 1, 0, b[n, i - 1, t] +
         If[q[i], b[n - i, Min[n - i, i], t - 1], 0]]];
    a[n_] := b[n, n, 4];
    Table[a[n], {n, 4, 66}] (* Jean-François Alcover, Feb 22 2022, after Alois P. Heinz *)

A341124 Number of partitions of n into 6 prime powers (including 1).

Original entry on oeis.org

1, 1, 2, 3, 5, 6, 10, 12, 17, 20, 27, 31, 41, 45, 56, 63, 77, 83, 101, 108, 128, 136, 160, 168, 196, 204, 236, 245, 281, 288, 331, 340, 387, 395, 450, 457, 519, 525, 594, 598, 677, 678, 763, 764, 855, 851, 957, 949, 1062, 1053, 1177, 1161, 1300, 1276, 1425, 1403, 1564
Offset: 6

Views

Author

Ilya Gutkovskiy, Feb 05 2021

Keywords

Crossrefs

Programs

  • Maple
    q:= proc(n) option remember; nops(ifactors(n)[2])<2 end:
    b:= proc(n, i, t) option remember; `if`(n=0,
          `if`(t=0, 1, 0), `if`(i<1 or t<1, 0, b(n, i-1, t)+
          `if`(q(i), b(n-i, min(n-i, i), t-1), 0)))
        end:
    a:= n-> b(n$2, 6):
    seq(a(n), n=6..62);  # Alois P. Heinz, Feb 05 2021
  • Mathematica
    q[n_] := q[n] = Length[FactorInteger[n]] < 2;
    b[n_, i_, t_] := b[n, i, t] = If[n == 0,
         If[t == 0, 1, 0], If[i < 1 || t < 1, 0, b[n, i - 1, t] +
         If[q[i], b[n - i, Min[n - i, i], t - 1], 0]]];
    a[n_] := b[n, n, 6];
    Table[a[n], {n, 6, 62}] (* Jean-François Alcover, Feb 22 2022, after Alois P. Heinz *)

A341112 Number of partitions of n into 3 prime powers (including 1).

Original entry on oeis.org

1, 1, 2, 3, 4, 4, 6, 6, 8, 8, 10, 9, 12, 10, 13, 12, 15, 13, 17, 15, 18, 15, 19, 16, 21, 17, 23, 18, 24, 19, 27, 23, 30, 24, 32, 25, 32, 26, 34, 26, 36, 26, 36, 28, 38, 28, 40, 30, 42, 32, 43, 30, 45, 32, 47, 35, 49, 30, 50, 35, 51, 36, 53, 35, 55, 37, 54, 40, 57, 36, 61, 40, 61
Offset: 3

Views

Author

Ilya Gutkovskiy, Feb 05 2021

Keywords

Crossrefs

Programs

  • Maple
    q:= proc(n) option remember; nops(ifactors(n)[2])<2 end:
    b:= proc(n, i, t) option remember; `if`(n=0,
          `if`(t=0, 1, 0), `if`(i<1 or t<1, 0, b(n, i-1, t)+
          `if`(q(i), b(n-i, min(n-i, i), t-1), 0)))
        end:
    a:= n-> b(n$2, 3):
    seq(a(n), n=3..75);  # Alois P. Heinz, Feb 05 2021
  • Mathematica
    q[n_] := q[n] = Length[FactorInteger[n]] < 2;
    b[n_, i_, t_] := b[n, i, t] = If[n == 0,
         If[t == 0, 1, 0], If[i < 1 || t < 1, 0, b[n, i - 1, t] +
         If[q[i], b[n - i, Min[n - i, i], t - 1], 0]]];
    a[n_] := b[n, n, 3];
    Table[a[n], {n, 3, 75}] (* Jean-François Alcover, Feb 22 2022, after Alois P. Heinz *)

A341125 Number of partitions of n into 7 prime powers (including 1).

Original entry on oeis.org

1, 1, 2, 3, 5, 6, 10, 13, 18, 22, 30, 35, 47, 54, 68, 78, 97, 107, 132, 146, 173, 190, 225, 242, 285, 305, 352, 377, 434, 456, 525, 553, 627, 659, 748, 778, 881, 916, 1028, 1068, 1197, 1232, 1381, 1421, 1578, 1619, 1801, 1837, 2041, 2079, 2296, 2337, 2583, 2613
Offset: 7

Views

Author

Ilya Gutkovskiy, Feb 05 2021

Keywords

Crossrefs

Programs

  • Maple
    q:= proc(n) option remember; nops(ifactors(n)[2])<2 end:
    b:= proc(n, i, t) option remember; `if`(n=0,
          `if`(t=0, 1, 0), `if`(i<1 or t<1, 0, b(n, i-1, t)+
          `if`(q(i), b(n-i, min(n-i, i), t-1), 0)))
        end:
    a:= n-> b(n$2, 7):
    seq(a(n), n=7..60);  # Alois P. Heinz, Feb 05 2021
  • Mathematica
    q[n_] := q[n] = Length[FactorInteger[n]] < 2;
    b[n_, i_, t_] := b[n, i, t] = If[n == 0,
         If[t == 0, 1, 0], If[i < 1 || t < 1, 0, b[n, i - 1, t] +
         If[q[i], b[n - i, Min[n - i, i], t - 1], 0]]];
    a[n_] := b[n, n, 7];
    Table[a[n], {n, 7, 60}] (* Jean-François Alcover, Feb 22 2022, after Alois P. Heinz *)

A341126 Number of partitions of n into 8 prime powers (including 1).

Original entry on oeis.org

1, 1, 2, 3, 5, 6, 10, 13, 19, 23, 32, 38, 51, 60, 77, 90, 113, 128, 158, 179, 215, 240, 287, 316, 373, 409, 475, 517, 599, 645, 741, 799, 908, 971, 1104, 1173, 1326, 1408, 1580, 1670, 1874, 1967, 2198, 2310, 2563, 2680, 2976, 3097, 3426, 3566, 3926, 4070, 4485
Offset: 8

Views

Author

Ilya Gutkovskiy, Feb 05 2021

Keywords

Crossrefs

Programs

  • Maple
    q:= proc(n) option remember; nops(ifactors(n)[2])<2 end:
    b:= proc(n, i, t) option remember; `if`(n=0,
          `if`(t=0, 1, 0), `if`(i<1 or t<1, 0, b(n, i-1, t)+
          `if`(q(i), b(n-i, min(n-i, i), t-1), 0)))
        end:
    a:= n-> b(n$2, 8):
    seq(a(n), n=8..60);  # Alois P. Heinz, Feb 05 2021
  • Mathematica
    q[n_] := q[n] = Length[FactorInteger[n]] < 2;
    b[n_, i_, t_] := b[n, i, t] = If[n == 0,
         If[t == 0, 1, 0], If[i < 1 || t < 1, 0, b[n, i - 1, t] +
         If[q[i], b[n - i, Min[n - i, i], t - 1], 0]]];
    a[n_] := b[n, n, 8];
    Table[a[n], {n, 8, 60}] (* Jean-François Alcover, Feb 22 2022, after _Alois P. Heinz *)

A341127 Number of partitions of n into 9 prime powers (including 1).

Original entry on oeis.org

1, 1, 2, 3, 5, 6, 10, 13, 19, 24, 33, 40, 54, 64, 83, 99, 125, 144, 180, 206, 250, 284, 341, 383, 455, 506, 593, 656, 762, 835, 965, 1054, 1206, 1309, 1491, 1610, 1825, 1964, 2213, 2374, 2664, 2843, 3179, 3387, 3769, 3998, 4440, 4695, 5194, 5480, 6043, 6357
Offset: 9

Views

Author

Ilya Gutkovskiy, Feb 05 2021

Keywords

Crossrefs

Programs

  • Maple
    q:= proc(n) option remember; nops(ifactors(n)[2])<2 end:
    b:= proc(n, i, t) option remember; `if`(n=0,
          `if`(t=0, 1, 0), `if`(i<1 or t<1, 0, b(n, i-1, t)+
          `if`(q(i), b(n-i, min(n-i, i), t-1), 0)))
        end:
    a:= n-> b(n$2, 9):
    seq(a(n), n=9..60);  # Alois P. Heinz, Feb 05 2021
  • Mathematica
    q[n_] := q[n] = Length[FactorInteger[n]] < 2;
    b[n_, i_, t_] := b[n, i, t] = If[n == 0,
         If[t == 0, 1, 0], If[i < 1 || t < 1, 0, b[n, i - 1, t] +
         If[q[i], b[n - i, Min[n - i, i], t - 1], 0]]];
    a[n_] := b[n, n, 9];
    Table[a[n], {n, 9, 60}] (* Jean-François Alcover, Feb 22 2022, after Alois P. Heinz *)

A341142 Number of partitions of n into 5 distinct prime powers (including 1).

Original entry on oeis.org

1, 0, 1, 2, 3, 3, 5, 5, 7, 8, 10, 12, 15, 15, 18, 21, 23, 26, 31, 33, 36, 41, 43, 48, 52, 58, 62, 72, 72, 82, 85, 95, 97, 112, 112, 125, 127, 142, 142, 161, 159, 181, 180, 200, 196, 222, 217, 243, 239, 269, 261, 291, 284, 316, 308, 341, 332, 370, 358, 394, 381, 427, 414, 456
Offset: 15

Views

Author

Ilya Gutkovskiy, Feb 05 2021

Keywords

Crossrefs

Programs

  • Maple
    q:= proc(n) option remember; nops(ifactors(n)[2])<2 end:
    b:= proc(n, i, t) option remember; `if`(n=0,
          `if`(t=0, 1, 0), `if`(i<1 or t<1, 0, b(n, i-1, t)+
          `if`(q(i), b(n-i, min(n-i, i-1), t-1), 0)))
        end:
    a:= n-> b(n$2, 5):
    seq(a(n), n=15..78);  # Alois P. Heinz, Feb 05 2021
  • Mathematica
    q[n_] := q[n] = PrimeNu[n] < 2;
    b[n_, i_, t_] := b[n, i, t] = If[n == 0,
         If[t == 0, 1, 0], If[i < 1 || t < 1, 0, b[n, i - 1, t] +
         If[q[i], b[n - i, Min[n - i, i - 1], t - 1], 0]]];
    a[n_] := b[n, n, 5];
    Table[a[n], {n, 15, 78}] (* Jean-François Alcover, Jul 13 2021, after Alois P. Heinz *)
    Table[Count[IntegerPartitions[n,{5}],?(Max[PrimeNu[#]]<2&&Length[#]==Length[Union[#]]&)],{n,15,80}] (* _Harvey P. Dale, Dec 22 2024 *)

A341134 Number of ways to write n as an ordered sum of 5 prime powers (including 1).

Original entry on oeis.org

1, 5, 15, 35, 70, 121, 190, 280, 395, 535, 711, 920, 1160, 1425, 1725, 2041, 2395, 2775, 3200, 3645, 4146, 4640, 5190, 5730, 6325, 6915, 7625, 8270, 9030, 9745, 10576, 11320, 12320, 13185, 14305, 15281, 16510, 17480, 18855, 19835, 21306, 22435, 24010, 25025, 26810, 27790, 29590
Offset: 5

Views

Author

Ilya Gutkovskiy, Feb 05 2021

Keywords

Crossrefs

Programs

  • Maple
    q:= proc(n) option remember; nops(ifactors(n)[2])<2 end:
    b:= proc(n, t) option remember;
          `if`(n=0, `if`(t=0, 1, 0), `if`(t<1, 0, add(
          `if`(q(j), b(n-j, t-1), 0), j=1..n)))
        end:
    a:= n-> b(n, 5):
    seq(a(n), n=5..51);  # Alois P. Heinz, Feb 05 2021
  • Mathematica
    nmax = 51; CoefficientList[Series[Sum[Boole[PrimePowerQ[k] || k == 1] x^k, {k, 1, nmax}]^5, {x, 0, nmax}], x] // Drop[#, 5] &

A365877 a(n) is the number of quadratic equations u*x^2 + v*x + w = 0 with distinct solution sets L != {} and integer coefficients u, v, w, where n >= abs(u) + abs(v) + abs(w) and the sum of the solutions equals the product of the solutions.

Original entry on oeis.org

1, 1, 2, 3, 5, 6, 9, 11, 15, 17, 23, 25, 32, 35, 40, 44, 53, 56, 66, 71, 78, 83, 95, 100, 111, 117, 127, 134, 150, 154, 171, 180, 191, 199, 213, 220, 240, 250, 263, 272, 294, 301, 324, 335, 348, 360, 386, 395, 419, 430, 448, 461, 490, 500, 522, 536, 556, 571, 603
Offset: 1

Views

Author

Felix Huber, Sep 22 2023

Keywords

Comments

According to Vieta's formulas, x_1 + x_2 = -v/u and x_1*x_2 = w/u. So x_1 + x_2 = x_1*x_2 when v = -w. Furthermore, the discriminant must not be negative, i.e., v^2 - 4*u*w = v^2 + 4*u*v >= 0.

Examples

			For n = 11 the a(11) = 23 equations are given by (u, v, w) = (1, 0, 0), (1, 1, -1), (2, 1, -1), (1, 2, -2), (3, 1, -1), (4, 1, -1), (5, 1, -1), (3, 2, -2), (1, 3, -3), (6, 1, -1), (2, 3, -3), (7, 1, -1), (5, 2, -2), (1, 4, -4), (-1, 4, -4), (8, 1, -1), (4, 3, -3), (9, 1, -1), (7, 2, -2), (5, 3, -3), (3, 4, -4), (1, 5, -5), (-1, 5, -5).
Equations multiplied by -1 do not have a different solution set; for example, (- 1, -1, 1) has the same solution set as (1, 1, -1).
Equations with GCD(u, v, w) != 1 are excluded, because their solution set are assigned to equations with lower n. For example, (2, 0, 0) is not included here, because its solution set is already assigned to (1, 0, 0).
Equations with a double solution are considered to have two equal solutions. For example, (-1, 4, -4) has the two solutions x_1 = x_2 = 2.
		

Crossrefs

Partial sums of A365876.

Programs

  • Maple
    A365876:= proc(n) local u, v, a, min; u := n; v := 0; a := 0; min := true; while min = true do if u <> 0 and gcd(u, v) = 1 then a := a + 1; end if; u := u - 2; v:=(n-abs(u))/2; if u < -1/9*n then min := false; end if; end do; return a; end proc;
    A365877:= proc(n) local s; option remember; if n = 1 then A365876(1); else procname(n - 1) + A365876(n); end if; end proc; seq(A365877(n), n = 1 .. 59);
  • Python
    from math import gcd
    def A365877(n):
        if n == 1: return 1
        c = 1
        for m in range(2,n+1):
            for v in range(1,m+1>>1):
                u = m-(v<<1)
                if gcd(u,v)==1:
                    v2, u2 = v*v, v*(u<<2)
                    if v2+u2 >= 0:
                        c +=1
                    if v2-u2 >= 0:
                        c +=1
        return c # Chai Wah Wu, Oct 05 2023

Formula

a(n) = Sum_{k=1..n} A365876(k).
a(n) = A341123(n) for 1 <= n <= 13.

A347646 Number of partitions of n into at most 5 prime powers (including 1).

Original entry on oeis.org

1, 1, 2, 3, 5, 7, 9, 12, 16, 20, 24, 30, 35, 42, 47, 55, 62, 71, 77, 88, 96, 107, 114, 127, 135, 149, 156, 173, 180, 198, 205, 224, 233, 254, 262, 287, 297, 321, 330, 358, 366, 396, 403, 436, 441, 478, 478, 517, 521, 560, 562, 609, 607, 655, 655, 702, 699, 756, 746
Offset: 0

Views

Author

Ilya Gutkovskiy, Sep 09 2021

Keywords

Crossrefs

Showing 1-10 of 11 results. Next