conjecscore
Login Sign up

Leaderboard

deeply_dreaming
2779447
ZamoC
2626567
liuguangxi
2608005
thyrgle
2469571
rexcirus
2367775

Hadamard Determinant Problem

The Problem

The Hadamard Determinant Problem asks what is the maximum value of the determinant of an \(n \times n\) matrix that has entries consisting of only \(\pm 1\). The optimal determinant is known up to \(n = 22\). This problem asks you to come up with a \(23 \times 23\) matrix such that the determinant is as large as possible.

Submission Format

Please submit a CSV file that contains \(23 \times 23 = 529\) values that are either \(\pm 1\). Each group of \(23\) numbers corresponds to a row of the \(23 \times 23\) matrix, call it \(M\). The best score corresponds to maximizing \(\frac{\det(M)}{10^9}\)

Score Implementation

The following is a Python implementation of the score function to help you get started.


import numpy as np
from sympy import Matrix


def score(mat: [int]):
    if len(mat) != 23 * 23:
        return None
    for num in mat:
        if num != 1 and num != -1:
            return None
    np_mat = np.reshape(mat, (23, 23))
    sym_mat = Matrix(np_mat)
    return sym_mat.det() // (10 ** 9)