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 21-30 of 41 results. Next

A229239 Total number of parts in all partitions of n^2 into squares.

Original entry on oeis.org

0, 1, 5, 19, 64, 206, 616, 1766, 4836, 12910, 33248, 83768, 205693, 495357, 1169030, 2713262, 6193247, 13932454, 30905452, 67684181, 146439145, 313266730, 663004212, 1389106622, 2882712626, 5928222338, 12086570971, 24440494114, 49035791349, 97646904849
Offset: 0

Views

Author

Keywords

Examples

			a(2) = 5 because there are 5 parts in the set of partitions of 2^2 into squares. The partitions are (1 2 X 2 square) and (4 1 X 1 squares) giving 5 parts in all.
		

Crossrefs

Row sums of A229468.
Cf. A037444.

Programs

  • Maple
    b:= proc(n, i) option remember; `if`(n=0, [1, 0], `if`(i<1, [0$2],
           b(n, i-1)+`if`(i^2>n, [0$2], (g->g+[0, g[1]])(b(n-i^2, i)))))
        end:
    a:= n-> b(n^2, n)[2]:
    seq(a(n), n=0..40);  # Alois P. Heinz, Sep 23 2013
  • Mathematica
    b[n_, i_] := b[n, i] = If[n == 0, {1, 0}, If[i<1, {0, 0}, b[n, i-1] + If[ i^2 > n, {0, 0}, Function[g, g + {0, g[[1]]}][b[n - i^2, i]]]]]; a[n_] := b[n^2, n][[2]]; Table[a[n], {n, 0, 40}] (* Jean-François Alcover, Nov 11 2015, after Alois P. Heinz *)

A229468 Number T(n,k) of parts of each size k^2 in all partitions of n^2 into squares; triangle T(n,k), 1 <= k <= n, read by rows.

Original entry on oeis.org

1, 4, 1, 15, 3, 1, 50, 11, 2, 1, 156, 35, 10, 4, 1, 460, 101, 36, 14, 4, 1, 1296, 298, 105, 44, 16, 6, 1, 3522, 798, 300, 130, 56, 23, 6, 1, 9255, 2154, 827, 377, 174, 82, 31, 9, 1, 23672, 5490, 2164, 1015, 502, 243, 108, 43, 10, 1, 59050, 13914, 5525, 2658, 1350, 705, 343, 154, 55, 13, 1
Offset: 1

Views

Author

Keywords

Examples

			For n = 3, the 4 partitions are:
Square side 1 2 3
            9 0 0
            5 1 0
            1 2 0
            0 0 1
Total      15 3 1
So T(3,1) = 15, T(3,2) = 3, T(3,3) = 1.
The triangle begins:
.\ k    1     2     3     4     5     6     7     8     9 ...
.n
.1      1
.2      4     1
.3     15     3     1
.4     50    11     2     1
.5    156    35    10     4     1
.6    460   101    36    14     4     1
.7   1296   298   105    44    16     6     1
.8   3522   798   300   130    56    23     6     1
.9   9255  2154   827   377   174    82    31     9     1
10  23672  5490  2164  1015   502   243   108    43    10 ...
11  59050 13914  5525  2658  1350   705   343   154    55 ...
		

Crossrefs

Row sums give: A229239.
Cf. A037444.

Programs

  • Maple
    b:= proc(n, i) option remember;
          `if`(n=0 or i=1, 1+n*x, b(n, i-1)+
          `if`(i^2>n, 0, (g->g+coeff(g, x, 0)*x^i)(b(n-i^2, i))))
        end:
    T:= n-> (p->seq(coeff(p, x, i), i=1..n))(b(n^2, n)):
    seq(T(n), n=1..14);  # Alois P. Heinz, Sep 24 2013
  • Mathematica
    b[n_, i_] := b[n, i] = If[n==0 || i==1, 1+n*x, b[n, i-1] + If[i^2>n, 0, Function[ {g}, g+Coefficient[g, x, 0]*x^i][b[n-i^2, i]]]]; T[n_] := Function[{p}, Table[ Coefficient[p, x, i], {i, 1, n}]][ b[n^2, n]]; Table[T[n], {n, 1, 14}] // Flatten (* Jean-François Alcover, Mar 09 2015, after Alois P. Heinz *)

Formula

Sum_{k=1..n} T(n,k) * k^2 = A037444(n) * n^2.

A298642 Number of partitions of n^2 into distinct squares > 1.

Original entry on oeis.org

1, 0, 1, 1, 1, 2, 1, 2, 1, 2, 2, 2, 1, 5, 2, 10, 4, 12, 12, 11, 19, 23, 43, 50, 55, 78, 120, 126, 234, 207, 407, 385, 701, 712, 1090, 1231, 1850, 2102, 3054, 3385, 4988, 5584, 7985, 9746, 12205, 15737, 18968, 25157, 30927, 39043, 47708, 61915, 74592, 99554
Offset: 0

Views

Author

Ilya Gutkovskiy, Jan 24 2018

Keywords

Examples

			a(5) = 2 because we have [25] and [16, 9].
		

Crossrefs

Formula

a(n) = [x^(n^2)] Product_{k>=2} (1 + x^(k^2)).
a(n) = A280129(A000290(n)).

A298938 Number of ordered ways of writing n^3 as a sum of n squares of nonnegative integers.

Original entry on oeis.org

1, 1, 1, 4, 5, 686, 13942, 455988, 13617853, 454222894, 18323165948, 802161109047, 42149084452070, 2481730049781672, 157265294178424356, 10977302934685469078, 812821237985857557677, 64539935903231450294134, 5504599828399250884049308
Offset: 0

Views

Author

Ilya Gutkovskiy, Jan 29 2018

Keywords

Examples

			a(4) = 5 because we have [64, 0, 0, 0], [16, 16, 16, 16], [0, 64, 0, 0], [0, 0, 64, 0] and [0, 0, 0, 64].
		

Crossrefs

Programs

  • Mathematica
    Table[SeriesCoefficient[(1 + EllipticTheta[3, 0, x])^n/2^n, {x, 0, n^3}], {n, 0, 18}]

Formula

a(n) = [x^(n^3)] (Sum_{k>=0} x^(k^2))^n.

A298939 Number of ordered ways of writing n^3 as a sum of n squares of positive integers.

Original entry on oeis.org

1, 1, 1, 4, 1, 286, 7582, 202028, 6473625, 226029577, 8338249868, 391526193477, 19990594900630, 1159906506684446, 74890158861242740, 5119732406649036418, 380146984328280974281, 30198665638519565614034, 2555354508318427693497565
Offset: 0

Views

Author

Ilya Gutkovskiy, Jan 29 2018

Keywords

Examples

			a(3) = 4 because we have [25, 1, 1], [9, 9, 9], [1, 25, 1] and [1, 1, 25].
		

Crossrefs

Programs

  • Mathematica
    Table[SeriesCoefficient[(-1 + EllipticTheta[3, 0, x])^n/2^n, {x, 0, n^3}], {n, 0, 18}]

Formula

a(n) = [x^(n^3)] (Sum_{k>=1} x^(k^2))^n.

A321186 a(n) = [x^(n*(n+1)*(2*n+1)/6)] Product_{k=1..n} Sum_{m>=0} x^(k^2*m).

Original entry on oeis.org

1, 1, 2, 6, 25, 123, 683, 4083, 25839, 171324, 1178755, 8362768, 60867478, 452760486, 3431366195, 26430813268, 206504120774, 1633813641572, 13071700375914, 105635826348216, 861408409243195, 7081998941608535, 58658594339423251, 489168002223876023, 4104791591982736028
Offset: 0

Views

Author

Seiichi Manyama, Oct 29 2018

Keywords

Comments

Also the number of nonnegative integer solutions (a_1, a_2, ... , a_n) to the equation 1^2*a_1 + 2^2*a_2 + ... + n^2*a_n = n*(n+1)*(2*n+1)/6.

Examples

			1^2* 0 + 2^2*3 + 3^2*2 + 4^2*0 = 30.
1^2* 1 + 2^2*1 + 3^2*1 + 4^2*1 = 30.
1^2* 1 + 2^2*5 + 3^2*1 + 4^2*0 = 30.
1^2* 2 + 2^2*3 + 3^2*0 + 4^2*1 = 30.
1^2* 2 + 2^2*7 + 3^2*0 + 4^2*0 = 30.
1^2* 3 + 2^2*0 + 3^2*3 + 4^2*0 = 30.
1^2* 4 + 2^2*2 + 3^2*2 + 4^2*0 = 30.
1^2* 5 + 2^2*0 + 3^2*1 + 4^2*1 = 30.
1^2* 5 + 2^2*4 + 3^2*1 + 4^2*0 = 30.
1^2* 6 + 2^2*2 + 3^2*0 + 4^2*1 = 30.
1^2* 6 + 2^2*6 + 3^2*0 + 4^2*0 = 30.
1^2* 8 + 2^2*1 + 3^2*2 + 4^2*0 = 30.
1^2* 9 + 2^2*3 + 3^2*1 + 4^2*0 = 30.
1^2*10 + 2^2*1 + 3^2*0 + 4^2*1 = 30.
1^2*10 + 2^2*5 + 3^2*0 + 4^2*0 = 30.
1^2*12 + 2^2*0 + 3^2*2 + 4^2*0 = 30.
1^2*13 + 2^2*2 + 3^2*1 + 4^2*0 = 30.
1^2*14 + 2^2*0 + 3^2*0 + 4^2*1 = 30.
1^2*14 + 2^2*4 + 3^2*0 + 4^2*0 = 30.
1^2*17 + 2^2*1 + 3^2*1 + 4^2*0 = 30.
1^2*18 + 2^2*3 + 3^2*0 + 4^2*0 = 30.
1^2*21 + 2^2*0 + 3^2*1 + 4^2*0 = 30.
1^2*22 + 2^2*2 + 3^2*0 + 4^2*0 = 30.
1^2*26 + 2^2*1 + 3^2*0 + 4^2*0 = 30.
1^2*30 + 2^2*0 + 3^2*0 + 4^2*0 = 30.
So a(4) = 25.
		

Crossrefs

A331884 Number of compositions (ordered partitions) of n^2 into distinct squares.

Original entry on oeis.org

1, 1, 1, 1, 1, 3, 1, 7, 1, 31, 123, 151, 121, 897, 7351, 5415, 14881, 48705, 150583, 468973, 1013163, 1432471, 1730023, 50432107, 14925241, 125269841, 74592537, 241763479, 213156871, 895153173, 7716880623, 2681163865, 3190865761, 22501985413, 116279718801
Offset: 0

Views

Author

Ilya Gutkovskiy, Jan 30 2020

Keywords

Examples

			a(5) = 3 because we have [25], [16, 9] and [9, 16].
		

Crossrefs

Programs

  • Maple
    b:= proc(n, i, p) option remember;
          `if`(i*(i+1)*(2*i+1)/6n, 0, b(n-i^2, i-1, p+1))+b(n, i-1, p)))
        end:
    a:= n-> b(n^2, n, 0):
    seq(a(n), n=0..35);  # Alois P. Heinz, Jan 30 2020
  • Mathematica
    b[n_, i_, p_] := b[n, i, p] = If[i(i+1)(2i+1)/6 < n, 0, If[n == 0, p!, If[i^2 > n, 0, b[n - i^2, i - 1, p + 1]] + b[n, i - 1, p]]];
    a[n_] := b[n^2, n, 0];
    a /@ Range[0, 35] (* Jean-François Alcover, Nov 08 2020, after Alois P. Heinz *)

Formula

a(n) = A331844(A000290(n)).

Extensions

a(24)-a(34) from Alois P. Heinz, Jan 30 2020

A375731 a(n) is the number of partitions of n having a square number of parts whose sum of squares is a square.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 1, 1, 2, 3, 2, 1, 2, 4, 2, 2, 7, 4, 4, 7, 7, 6, 9, 12, 9, 21, 21, 19, 26, 30, 32, 43, 54, 54, 64, 87, 85, 119, 128, 146, 174, 205, 213, 281, 324, 368, 420, 503, 531, 688, 760, 837, 992, 1174, 1252, 1535, 1705, 1931, 2236, 2619, 2821, 3402, 3769, 4272
Offset: 0

Views

Author

Felix Huber, Aug 28 2024

Keywords

Examples

			a(13) counts the 4 partitions [1, 1, 1, 1, 1, 1, 1, 3, 3] with 9 = 3^2 parts and 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 1^2 + 3^2 + 3^2 = 5^2, [1, 4, 4, 4] with 2^2 parts and 1^2 + 4^2 + 4^2 + 4^2 = 7^2, [2, 2, 4, 5] with 4 = 2^2 parts and 2^2 + 2^2 + 4^2 + 5^2 = 7^2, [13] with 1 = 1^2 part and 13^2 = 13^2.
		

Crossrefs

Programs

  • Maple
    # first Maple program to calculate the sequence:
    A375731:=proc(n) local a,i,j; a:=0; for i in combinat:-partition(n) do if issqr(numelems(i)) and issqr(add(i[j]^2,j=1..nops(i))) then a:=a+1 fi od; return a end proc; seq(A375731(n),n=0..63);
    # second Maple program to calculate the partitions:
    A375731part:=proc(n) local L,i,j;L:=[]; for i in combinat:-partition(n) do if issqr(numelems(i)) and issqr(add(i[j]^2,j=1..nops(i))) then L:=[op(L),i] fi od; return op(L) end proc; A375731part(13);
  • PARI
    a(n) = my(nb=0); forpart(p=n, if (issquare(#p) && issquare(norml2(Vec(p))), nb++)); nb; \\ Michel Marcus, Aug 30 2024

Formula

1 <= a(n) <= A240127(n).

A221843 Number of partitions of n^2 into squares providing prime dissections of an n X n square into integer-sided squares.

Original entry on oeis.org

1, 1, 2, 5, 10, 27, 56, 141, 309, 742, 1558, 3808
Offset: 1

Views

Author

Geoffrey H. Morley, Jan 26 2013

Keywords

Comments

In a prime dissection the GCD of the square sides is one.

Examples

			For n = 4 the a(4) = 5 sets of squares which provide prime dissections of a 4 X 4 square are {1(3 X 3), 7(1 X 1)}, {3(2 X 2), 4(1 X 1)}, {2(2 X 2), 8(1 X 1)}, {1(2 X 2), 12(1 X 1)} and {16(1 X 1)}.
		

Crossrefs

Extensions

a(7) corrected and a(9)-a(12) from Alois P. Heinz, Apr 15 2013

A227940 Number of runs of strictly increasing numbers of 2 X 2 squares in the list of partitions of n^2 into squares, where partition sorting order is ascending with larger squares taking higher precedence.

Original entry on oeis.org

1, 1, 2, 3, 6, 12, 20, 42, 84, 171, 327, 654, 1288, 2533, 4942, 9566, 18481, 35449, 67649, 128372, 242451, 455393, 851352, 1583854, 2932250, 5403874, 9913868, 18107914, 32932025, 59643292
Offset: 1

Views

Author

Keywords

Examples

			For n = 4, the 8 partitions of 16 into square parts are:
Partition  Square side
.           1  2  3  4
.
.    1     16  0  0  0
.    2     12  1  0  0
.    3      8  2  0  0
.    4      4  3  0  0
.    5      0  4  0  0
.    6      7  0  1  0
.    7      3  1  1  0
.    8      0  0  0  1
So a(4) = 3 as there are 3 runs of 2 X 2 squares: (0,1,2,3,4) from partitions 1 to 5, (0,1) from partitions 6 to 7 and (0) from partition 8.
		

Crossrefs

Cf. A037444.
Previous Showing 21-30 of 41 results. Next