Date: Apr 4, 2013 4:16 PM
Author: Bruno Luong
Subject: Re: determinant calculation of integer matrices

"Bruno Luong" <b.luong@fogale.findmycountry> wrote in message <kjklja$j3n$1@newscl01ah.mathworks.com>...
> In the same way
>
> det(magic(2013)-2026085) = 0
>
> Bruno


Note that as

magic(N) has elements the permutation of { 1, 2, ... N^2 }. Sum of consecutive series formula gives this identity:

sum(sum(magic(N))) = sum { 1, 2, ... N^2 } = (N^2 + 1) * N^2 /2.

Therefore sum(magic(N)) / N = (N^2 + 1) / 2.

In other word det( magic(N) - (N^2 + 1) /2) = 0 for all N.

Bruno