I want as many 80-bits words as possible with the constraint that the hamming distance between any couple of words is exactly 40. How many can I generate? Is there a generic formula telling me how many n-bits words I can generate with the constraint that any couple of words is at hamming distance exactly n/2? Any general algorithm to generate them?

For 2 bits codewords, "00, 01, 10" are all at HD=1. For 4-bits codewords, "0000, 0011, 0101, 1001" are all at HD=2. And then?

Thank You,

JMC