Code to find generalised hadamard matrices