MATLAB: Random Generation of Binary Orthogonal Matrix of Size n * n with Matlab

binary matrixorthogonal matrixrandom generation of orthogonal matrix

Dear all…
How can I generate random binary orthogonal matrix of size n * n with matlab?
Regards,

Best Answer

I'm not a mathematician so I could be completely wrong but aren't square binary orthogonal matrices just permutations of the rows (or columns) of the identity matrix?
If yes,
m = eye(n);
m = m(randperm(n), :)
This certainly generates random binary orthogonal matrices of size nxn. Whether it can generate all the possible ones, I don't know.
Related Question