Abstract:
We enumerate all $q$-ary additive (in particular, linear) block codes of length $n$ and
cardinality $N\geqslant q^2$ with exactly two distances: $d$ and $n$. For arbitrary codes of length $n$ with
distances $d$ and $n$, we obtain upper bounds on the cardinality via linear programming and using
relationships to $2$-distance sets on a Euclidean sphere.
Keywords:two-distance code, two-weight code, linear two-weight code, difference matrix, maximal arc, Latin square, orthogonal array, bounds for codes, linear programming bounds, spherical code.