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

A323348 Number of integer partitions of n whose parts cannot be arranged into a (not necessarily square) matrix with equal row-sums and equal column-sums.

Original entry on oeis.org

0, 0, 0, 1, 2, 5, 6, 13, 17, 27, 36, 54, 66, 99, 128, 169, 221, 295, 367, 488, 610, 779, 993, 1253, 1525, 1955, 2426, 2986, 3684, 4563, 5519, 6840, 8298, 10097, 12298, 14874, 17716, 21635, 26002, 31105, 37081, 44581, 52916, 63259, 74852, 88703, 105543, 124752, 145740, 173522, 203999, 239737, 280424, 329929
Offset: 0

Views

Author

Gus Wiseman, Jan 13 2019

Keywords

Examples

			The a(8) = 17 integer partitions:
  (53), (62), (71),
  (332), (422), (431), (521), (611),
  (3221), (4211), (5111),
  (22211), (32111), (41111),
  (221111), (311111),
  (2111111).
		

Crossrefs

Programs

  • Mathematica
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]];
    ptnmats[n_]:=Union@@Permutations/@Select[Union@@(Tuples[Permutations/@#]&/@Map[primeMS,facs[n],{2}]),SameQ@@Length/@#&];
    Table[Length[Select[IntegerPartitions[n],Select[ptnmats[Times@@Prime/@#],And[SameQ@@Total/@#,SameQ@@Total/@Transpose[#]]&]=={}&]],{n,10}]

Extensions

a(17)-a(53) from Chai Wah Wu, Jan 15 2019

A270876 Number of magic tori of order n composed of the numbers from 1 to n^2.

Original entry on oeis.org

1, 0, 1, 255, 251449712
Offset: 1

Views

Author

William Walkington, Mar 24 2016

Keywords

Comments

Initially based on empirical observations by William Walkington, the results for the orders 1 to 4 have since been computed and confirmed by Walter Trump. The results for the order 5 have been computed by Walter Trump.

Crossrefs

A271104 Number of magic and semi-magic tori of order n composed of the numbers from 1 to n^2.

Original entry on oeis.org

1, 0, 1, 4293, 23161722048, 2627518340149999905600
Offset: 1

Views

Author

William Walkington, Mar 30 2016

Keywords

Comments

Initially based on empirical observations by the author, the results for the magic tori of orders 1 to 4, have since been computed and confirmed by Walter Trump. The results for the magic tori of order 5, and for the semi-magic tori of orders 4 and 5, have been computed by Walter Trump. The result for the order 6 is deduced from Artem Ripatti's findings (cf. A271103).
A semi-magic torus differs from a magic torus in that there are no magic intersections of magic diagonals, and in consequence only semi-magic squares are displayed on its surface.

Crossrefs

Formula

a(n) = A271103(n)/ n^2.

Extensions

a(6) added by William Walkington, Jul 18 2018

A321725 Irregular triangle read by rows where T(n,k) is the number of d X d non-normal semi-magic squares with d = A027750(n,k) and sum of all entries equal to n.

Original entry on oeis.org

1, 1, 2, 1, 6, 1, 3, 24, 1, 120, 1, 4, 21, 720, 1, 5040, 1, 5, 282, 40320, 1, 55, 362880, 1, 6, 6210, 3628800, 1, 39916800, 1, 7, 120, 2008, 202410, 479001600, 1, 6227020800, 1, 8, 9135630, 87178291200, 1, 231, 153040, 1307674368000, 1, 9, 10147
Offset: 1

Views

Author

Gus Wiseman, Nov 18 2018

Keywords

Comments

A non-normal semi-magic square is a nonnegative integer square matrix with all row sums and column sums equal to d, for some d|n.

Examples

			Triangle begins:
   1
   1   2
   1   6
   1   3  24
   1 120
   1   4  21 720
The T(6,2) = 4 semi-magic squares (zeros not shown):
  [3  ] [2 1] [1 2] [  3]
  [  3] [1 2] [2 1] [3  ]
The T(6,3) = 21 semi-magic squares (zeros not shown):
  [2    ] [2    ] [2    ] [1 1  ] [1 1  ] [1 1  ] [1 1  ]
  [  2  ] [  1 1] [    2] [1 1  ] [1   1] [  1 1] [    2]
  [    2] [  1 1] [  2  ] [    2] [  1 1] [1   1] [1 1  ]
.
  [1   1] [1   1] [1   1] [1   1] [  2  ] [  2  ] [  2  ]
  [1 1  ] [1   1] [  2  ] [  1 1] [2    ] [1   1] [    2]
  [  1 1] [  2  ] [1   1] [1 1  ] [    2] [1   1] [2    ]
.
  [  1 1] [  1 1] [  1 1] [  1 1] [    2] [    2] [    2]
  [2    ] [1 1  ] [1   1] [  1 1] [2    ] [1 1  ] [  2  ]
  [  1 1] [1   1] [1 1  ] [2    ] [  2  ] [1 1  ] [2    ]
		

Crossrefs

Programs

  • Mathematica
    prs2mat[prs_]:=Table[Count[prs,{i,j}],{i,Union[First/@prs]},{j,Union[Last/@prs]}];
    multsubs[set_,k_]:=If[k==0,{{}},Join@@Table[Prepend[#,set[[i]]]&/@multsubs[Drop[set,i-1],k-1],{i,Length[set]}]];
    Table[Length[Select[multsubs[Tuples[Range[n],2],n],And[Union[First/@#]==Range[k]==Union[Last/@#],SameQ@@Total/@prs2mat[#],SameQ@@Total/@Transpose[prs2mat[#]]]&]],{n,5},{k,Divisors[n]}]

Formula

T(n, A000005(n)) = n!. Sum_k T(n,k) = A321719(n). - Chai Wah Wu, Jan 15 2019

Extensions

a(15)-a(48) from Chai Wah Wu, Jan 15 2019
Edited by Peter Munn, Mar 05 2025

A323523 Number of positive integer square matrices with entries summing to n and equal row and column sums.

Original entry on oeis.org

1, 1, 1, 1, 2, 1, 3, 1, 4, 2, 5, 1, 12, 1, 7, 22, 9, 1, 64, 1, 34, 121, 11, 1, 525, 2, 13, 407, 2022, 1, 801, 1, 10163, 1036, 17, 6211, 41735, 1, 19, 2212, 285784, 1, 3822, 1, 381446, 2229142, 23, 1, 1189540, 2, 22069276, 7261, 2309410, 1, 20943183, 164176641
Offset: 0

Views

Author

Gus Wiseman, Jan 17 2019

Keywords

Comments

Also the number of non-normal semi-magic squares with positive integer entries summing to n.

Examples

			The a(12) = 12 matrices:
  [12]
.
  [1 5] [5 1] [2 4] [4 2] [3 3]
  [5 1] [1 5] [4 2] [2 4] [3 3]
.
  [1 1 2] [1 1 2] [1 2 1] [1 2 1] [2 1 1] [2 1 1]
  [1 2 1] [2 1 1] [1 1 2] [2 1 1] [1 1 2] [1 2 1]
  [2 1 1] [1 2 1] [2 1 1] [1 1 2] [1 2 1] [1 1 2]
		

Crossrefs

Programs

  • Mathematica
    primeMS[n_]:=If[n==1,{},Flatten[Cases[FactorInteger[n],{p_,k_}:>Table[PrimePi[p],{k}]]]];
    facs[n_]:=If[n<=1,{{}},Join@@Table[Map[Prepend[#,d]&,Select[facs[n/d],Min@@#>=d&]],{d,Rest[Divisors[n]]}]];
    ptnsqrs[n_]:=Union@@Permutations/@Select[Union@@(Tuples[Permutations/@#]&/@Map[primeMS,facs[n],{2}]),And[SameQ@@Length/@#,Length[#]==0||Length[#]==Length[First[#]]]&];
    Table[Sum[Length[Select[ptnsqrs[Times@@Prime/@y],And[SameQ@@Total/@#,SameQ@@Total/@Transpose[#]]&]],{y,IntegerPartitions[n]}],{n,10}]

Formula

a(p) = 1 and a(p^2) = 2 for p prime (see comment in A323349). - Chai Wah Wu, Jan 20 2019
a(n) = Sum_{d|n, d<=n/d} A257493(d, n/d-d) for n > 0. - Andrew Howroyd, Apr 10 2020

Extensions

a(16)-a(55) from Chai Wah Wu, Jan 20 2019

A027567 Number of distinct (modulo rotation and reflection) n X n panmagic = pandiagonal = diabolic = Nasik squares.

Original entry on oeis.org

1, 0, 0, 48, 3600, 0
Offset: 1

Views

Author

Keywords

References

  • Hunter, J. A. H. and Madachy, J. S. "Mystic Arrays." Ch. 3 in Mathematical Diversions. New York: Dover, pp. 24-25, 1975.

Crossrefs

Cf. A006052.

Extensions

Corrected by Eric Weisstein, Mar 14 2003 to include only distinct squares; Hunter and Madachy give the count of all such squares (there are 384).

A081262 Number of distinct (modulo rotation and reflection) n X n associative magic squares.

Original entry on oeis.org

1, 0, 1, 48, 48544, 0, 1125154039419854784
Offset: 1

Views

Author

Eric W. Weisstein, Mar 14 2003

Keywords

Crossrefs

Extensions

a(5) from Jud McCranie, Mar 17 2003
a(6) from Max Alekseyev, May 22 2008
a(7) from Go Kato, Nov 30 2018

A081263 Number of distinct (modulo rotation and reflection) n X n associative panmagic squares.

Original entry on oeis.org

1, 0, 0, 0, 16, 0, 20190684
Offset: 1

Views

Author

Eric W. Weisstein, Mar 14 2003

Keywords

Comments

It is known that a(10)=0.
Walter Trump estimates a(8) ~= 4.677*10^15 and a(9) ~= 1.363*10^24.

References

  • Gardner, M. "Magic Squares and Cubes." Ch. 17 in Time Travel and Other Mathematical Bewilderments. New York: W.H. Freeman, pp. 213-225, 1988.

Crossrefs

Extensions

a(6)-a(7) from Walter Trump's website, added by Max Alekseyev, May 22 2008

A321734 Number of nonnegative integer square matrices with sum of entries equal to n, no zero rows or columns, weakly decreasing row and column sums, and the same row sums as column sums.

Original entry on oeis.org

1, 1, 3, 9, 37, 177, 1054, 7237, 57447, 512664, 5101453, 55870885, 668438484, 8667987140, 121123281293, 1814038728900, 28988885491655, 492308367375189, 8854101716492463, 168108959387012804, 3360171602215686668, 70527588239926854144, 1550926052235372201700
Offset: 0

Views

Author

Gus Wiseman, Nov 18 2018

Keywords

Examples

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

Crossrefs

Programs

  • Mathematica
    prs2mat[prs_]:=Table[Count[prs,{i,j}],{i,Union[First/@prs]},{j,Union[Last/@prs]}];
    multsubs[set_,k_]:=If[k==0,{{}},Join@@Table[Prepend[#,set[[i]]]&/@multsubs[Drop[set,i-1],k-1],{i,Length[set]}]];
    Table[Length[Select[multsubs[Tuples[Range[n],2],n],And[Union[First/@#]==Range[Max@@First/@#]==Union[Last/@#],OrderedQ[Total/@prs2mat[#]],OrderedQ[Total/@Transpose[prs2mat[#]]],Total/@prs2mat[#]==Total/@Transpose[prs2mat[#]]]&]],{n,5}]

Formula

Let c(y) be the coefficient of m(y) in h(y), where m is monomial symmetric functions and h is homogeneous symmetric functions. Then a(n) = Sum_{|y| = n} c(y).

Extensions

a(11) - a(22) from Ludovic Schwob, Sep 29 2023

A355119 a(n) is the number of order-n magic triangles composed of the numbers from 1 to n(n+1)/2 in which the sum of the k-th row and the (n-k+1)-st row is the same for all k and all three directions, counted up to rotations and reflections.

Original entry on oeis.org

1, 1, 0, 0, 7584, 5546793216
Offset: 1

Views

Author

Donghwi Park, Jun 19 2022

Keywords

Comments

The magic sum is (n(n+1)/2 + 1)(n+1)/2.
For n >= 3, a(n) is a multiple of 6 because the rotation of only three corners does not affect the sum of the 1st row and n-th row.
This magic triangle is an analog of magic triangles from St. Olaf College, which are published in the Pi Mu Epsilon Journal (Fall 2021). Their magic triangles use square numbers of triangles.

Examples

			a(1) and a(2) are trivially 1.
a(3) is trivially 0 because the sum of 2nd row cannot be same for each direction.
a(4k) for positive integers k is trivially 0 because the magic sums are not integers in this cases.
An example of a solution at n=5:
         4
       7   9
     12  1  11
   14  2   3  13
  6  15  10  8  5
An example of a solution at n=6:
          9
        20 18
      21  8  13
    11   3  2  19
   10  6  4  7   12
 1  16  17 15  14  5
		

Crossrefs

Formula

a(n) = 0 if n is a multiple of 4. - Stefano Spezia, Jun 20 2022

Extensions

a(6) from Donghwi Park, Dec 31 2023
Previous Showing 21-30 of 40 results. Next