Creates normal magic squares of any order >2. Uses the appropriate method depending on n modulo 4.
Order of magic square. If a vector, return a list whose
i-th element is a magic square of order
magic.4np2() depending on the value of
n. Returns a
magic square in standard format (compare the
magic.2np1() et seq,
which return the square as generated by the direct algorithm).
Robin K. S. Hankin
William H. Benson and Oswald Jacoby. New recreations with magic squares. Dover 1976.
1 2 3 4 5 6 7 8
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.