login
The OEIS is supported by the many generous donors to the OEIS Foundation.

 

Logo
Hints
(Greetings from The On-Line Encyclopedia of Integer Sequences!)
A323523 Number of positive integer square matrices with entries summing to n and equal row and column sums. 3
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 (list; graph; refs; listen; history; text; internal format)
OFFSET
0,5
COMMENTS
Also the number of non-normal semi-magic squares with positive integer entries summing to n.
LINKS
Andrew Howroyd, Table of n, a(n) for n = 0..200 (terms 0..59 from Chai Wah Wu)
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
EXAMPLE
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]
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}]
CROSSREFS
Sequence in context: A143862 A115118 A115121 * A124072 A189357 A100053
KEYWORD
nonn
AUTHOR
Gus Wiseman, Jan 17 2019
EXTENSIONS
a(16)-a(55) from Chai Wah Wu, Jan 20 2019
STATUS
approved

Lookup | Welcome | Wiki | Register | Music | Plot 2 | Demos | Index | Browse | More | WebCam
Contribute new seq. or comment | Format | Style Sheet | Transforms | Superseeker | Recents
The OEIS Community | Maintained by The OEIS Foundation Inc.

License Agreements, Terms of Use, Privacy Policy. .

Last modified April 16 08:27 EDT 2024. Contains 371698 sequences. (Running on oeis4.)